Enable ssh to my computer from outside through Port forwarding












1















Update It's working actually, I had to adjust my local IP address, which is constantly changing.
So sorry for the inconvenience.





I can ssh to my computer1 from my computer2 on my local network, using my local IP:



ssh user@192.168.1.5


However, I want to ssh from outside my home, using my public IP:



ssh user@113.174.34.171


I have access to my router (ZTE F600W) configuration but obviously can’t make port forwarding right.



I tried different things and reboot the router like 10 times already.





enter image description here





enter image description here





The firewall on my computer is disabled. Is there something else I can possibly check?





Edit



As suggested by @Enrico Polesel, I stabilized my local IP on my computer manually, instead of getting one automatically via DHCP.



Network setting on the computer



It seems to work so far.



Now the last improvement I can make is using a dynamic IP service because my public IP is dynamic.





I'm using the service "my.noip.com" and it works fine.



enter image description here



Now I can ssh to my computer with the same hostname, and everything is handled correctly to my computer :-)










share|improve this question

























  • In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

    – n8te
    Dec 22 '18 at 5:29













  • @n8te Good catch, I made a typo in my first command (I just corrected it).

    – Yoric
    Dec 22 '18 at 5:34











  • Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

    – Appleoddity
    Dec 22 '18 at 5:35











  • @Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

    – Yoric
    Dec 22 '18 at 5:40











  • I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

    – Yoric
    Dec 22 '18 at 5:54
















1















Update It's working actually, I had to adjust my local IP address, which is constantly changing.
So sorry for the inconvenience.





I can ssh to my computer1 from my computer2 on my local network, using my local IP:



ssh user@192.168.1.5


However, I want to ssh from outside my home, using my public IP:



ssh user@113.174.34.171


I have access to my router (ZTE F600W) configuration but obviously can’t make port forwarding right.



I tried different things and reboot the router like 10 times already.





enter image description here





enter image description here





The firewall on my computer is disabled. Is there something else I can possibly check?





Edit



As suggested by @Enrico Polesel, I stabilized my local IP on my computer manually, instead of getting one automatically via DHCP.



Network setting on the computer



It seems to work so far.



Now the last improvement I can make is using a dynamic IP service because my public IP is dynamic.





I'm using the service "my.noip.com" and it works fine.



enter image description here



Now I can ssh to my computer with the same hostname, and everything is handled correctly to my computer :-)










share|improve this question

























  • In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

    – n8te
    Dec 22 '18 at 5:29













  • @n8te Good catch, I made a typo in my first command (I just corrected it).

    – Yoric
    Dec 22 '18 at 5:34











  • Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

    – Appleoddity
    Dec 22 '18 at 5:35











  • @Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

    – Yoric
    Dec 22 '18 at 5:40











  • I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

    – Yoric
    Dec 22 '18 at 5:54














1












1








1








Update It's working actually, I had to adjust my local IP address, which is constantly changing.
So sorry for the inconvenience.





I can ssh to my computer1 from my computer2 on my local network, using my local IP:



ssh user@192.168.1.5


However, I want to ssh from outside my home, using my public IP:



ssh user@113.174.34.171


I have access to my router (ZTE F600W) configuration but obviously can’t make port forwarding right.



I tried different things and reboot the router like 10 times already.





enter image description here





enter image description here





The firewall on my computer is disabled. Is there something else I can possibly check?





Edit



As suggested by @Enrico Polesel, I stabilized my local IP on my computer manually, instead of getting one automatically via DHCP.



Network setting on the computer



It seems to work so far.



Now the last improvement I can make is using a dynamic IP service because my public IP is dynamic.





I'm using the service "my.noip.com" and it works fine.



enter image description here



Now I can ssh to my computer with the same hostname, and everything is handled correctly to my computer :-)










share|improve this question
















Update It's working actually, I had to adjust my local IP address, which is constantly changing.
So sorry for the inconvenience.





I can ssh to my computer1 from my computer2 on my local network, using my local IP:



ssh user@192.168.1.5


However, I want to ssh from outside my home, using my public IP:



ssh user@113.174.34.171


I have access to my router (ZTE F600W) configuration but obviously can’t make port forwarding right.



I tried different things and reboot the router like 10 times already.





enter image description here





enter image description here





The firewall on my computer is disabled. Is there something else I can possibly check?





Edit



As suggested by @Enrico Polesel, I stabilized my local IP on my computer manually, instead of getting one automatically via DHCP.



Network setting on the computer



It seems to work so far.



Now the last improvement I can make is using a dynamic IP service because my public IP is dynamic.





I'm using the service "my.noip.com" and it works fine.



enter image description here



Now I can ssh to my computer with the same hostname, and everything is handled correctly to my computer :-)







networking macos router ssh port-forwarding






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Dec 23 '18 at 0:17







Yoric

















asked Dec 22 '18 at 5:23









YoricYoric

3096




3096













  • In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

    – n8te
    Dec 22 '18 at 5:29













  • @n8te Good catch, I made a typo in my first command (I just corrected it).

    – Yoric
    Dec 22 '18 at 5:34











  • Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

    – Appleoddity
    Dec 22 '18 at 5:35











  • @Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

    – Yoric
    Dec 22 '18 at 5:40











  • I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

    – Yoric
    Dec 22 '18 at 5:54



















  • In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

    – n8te
    Dec 22 '18 at 5:29













  • @n8te Good catch, I made a typo in my first command (I just corrected it).

    – Yoric
    Dec 22 '18 at 5:34











  • Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

    – Appleoddity
    Dec 22 '18 at 5:35











  • @Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

    – Yoric
    Dec 22 '18 at 5:40











  • I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

    – Yoric
    Dec 22 '18 at 5:54

















In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

– n8te
Dec 22 '18 at 5:29







In your ssh command example up top you have the IP address listed as 192.168.0.5 but in your router configuration you have the port forwarding setup to go to IP address 192.168.1.5. Is that IP address in your first command in the post just a typo as you wrote out your question, or is that disparity the root of your problem?

– n8te
Dec 22 '18 at 5:29















@n8te Good catch, I made a typo in my first command (I just corrected it).

– Yoric
Dec 22 '18 at 5:34





@n8te Good catch, I made a typo in my first command (I just corrected it).

– Yoric
Dec 22 '18 at 5:34













Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

– Appleoddity
Dec 22 '18 at 5:35





Have you confirmed your public IP really is what you think it is by using whatsmyip? That’s a weird network setup you’re showing.

– Appleoddity
Dec 22 '18 at 5:35













@Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

– Yoric
Dec 22 '18 at 5:40





@Appleoddity I used https://www.whatismyip.com to confirm my public IP (Your IPv4 is: 113.174.34.171). What is weird, the router interface, or the data I'm filling in?

– Yoric
Dec 22 '18 at 5:40













I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

– Yoric
Dec 22 '18 at 5:54





I'm sorry, it's actually working. Since my machine is constantly changing its local IP address (192.168.1.5 or 192.168.1.4 or 192.168.1.3 or 192.168.1.2) I had to adjust it accordingly. So sorry for the inconvenience. Thank you so much for your attention anyway, it still helped me a lot!

– Yoric
Dec 22 '18 at 5:54










1 Answer
1






active

oldest

votes


















1














If now your problem is that you PC IP is constantly changing you can reserve one address for your PC from your router DHCP configuration (you'll save the association between the MAC address and the IP and the DHCP server will always give that IP to your PC).



Another way to "stabilize" the PC ip would be to configure it as a static IP on the PC (but be careful to choose an address outside the DHCP pool of your router. This solution may be the easiest, but every time you move your PC to other networks you'd have to change the IP configuration.






share|improve this answer
























  • Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

    – Yoric
    Dec 22 '18 at 11:14











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1386865%2fenable-ssh-to-my-computer-from-outside-through-port-forwarding%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














If now your problem is that you PC IP is constantly changing you can reserve one address for your PC from your router DHCP configuration (you'll save the association between the MAC address and the IP and the DHCP server will always give that IP to your PC).



Another way to "stabilize" the PC ip would be to configure it as a static IP on the PC (but be careful to choose an address outside the DHCP pool of your router. This solution may be the easiest, but every time you move your PC to other networks you'd have to change the IP configuration.






share|improve this answer
























  • Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

    – Yoric
    Dec 22 '18 at 11:14
















1














If now your problem is that you PC IP is constantly changing you can reserve one address for your PC from your router DHCP configuration (you'll save the association between the MAC address and the IP and the DHCP server will always give that IP to your PC).



Another way to "stabilize" the PC ip would be to configure it as a static IP on the PC (but be careful to choose an address outside the DHCP pool of your router. This solution may be the easiest, but every time you move your PC to other networks you'd have to change the IP configuration.






share|improve this answer
























  • Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

    – Yoric
    Dec 22 '18 at 11:14














1












1








1







If now your problem is that you PC IP is constantly changing you can reserve one address for your PC from your router DHCP configuration (you'll save the association between the MAC address and the IP and the DHCP server will always give that IP to your PC).



Another way to "stabilize" the PC ip would be to configure it as a static IP on the PC (but be careful to choose an address outside the DHCP pool of your router. This solution may be the easiest, but every time you move your PC to other networks you'd have to change the IP configuration.






share|improve this answer













If now your problem is that you PC IP is constantly changing you can reserve one address for your PC from your router DHCP configuration (you'll save the association between the MAC address and the IP and the DHCP server will always give that IP to your PC).



Another way to "stabilize" the PC ip would be to configure it as a static IP on the PC (but be careful to choose an address outside the DHCP pool of your router. This solution may be the easiest, but every time you move your PC to other networks you'd have to change the IP configuration.







share|improve this answer












share|improve this answer



share|improve this answer










answered Dec 22 '18 at 8:40









Enrico PoleselEnrico Polesel

613




613













  • Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

    – Yoric
    Dec 22 '18 at 11:14



















  • Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

    – Yoric
    Dec 22 '18 at 11:14

















Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

– Yoric
Dec 22 '18 at 11:14





Yes that's a great idea. I'm trying to associate my MAC address with my local IP now... So that I won't get a "random" IP every time the machine reboot. I'll write here if I succeeded or not.

– Yoric
Dec 22 '18 at 11:14


















draft saved

draft discarded




















































Thanks for contributing an answer to Super User!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1386865%2fenable-ssh-to-my-computer-from-outside-through-port-forwarding%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Сан-Квентин

Алькесар

Josef Freinademetz