-1

my SSH client wont push request with my computer name(host name), it works only with my ipv4(IP Address) of my laptop when connected to campus network(public network), how can i fix this?(my automation depends on this) My server is windows laptop and my client iOS iPhone

1
  • You would need to either make your hostname available on the actual internet (e.g. using a DynDNS service might be an option) or tweak name resolution on your client (e.g. by using the hosts file).
    – Seth
    Commented Nov 23, 2021 at 12:57

1 Answer 1

0

Maybe you could add the computer name to the local host file: C:\Windows\System32\drivers\etc\hosts

That should make it resolve the computername for you.

More info here: https://www.howtogeek.com/howto/27350/beginner-geek-how-to-edit-your-hosts-file/

7
  • and what address is my laptop?
    – CSEE
    Commented Nov 26, 2021 at 10:52
  • Just write Hostname in a command prompt then you will get your hostname. Commented Nov 27, 2021 at 11:09
  • To get the IP of your computer you just type ipconfig in a command prompt. Then you have both values you need for your hosts file. Commented Nov 27, 2021 at 11:30
  • but the ipv4 keeps changing on every network!
    – CSEE
    Commented Nov 28, 2021 at 11:51
  • i want to have static host name for my computer, when trying to control it via my iphone
    – CSEE
    Commented Nov 28, 2021 at 11:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .