[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: hostname of remote computer



Dne, 31. 10. 2010 19:57:22 je Seb napisal(a):
Hi,

I use SSH to connect to a laptop computer that is in an institutional
network. I would like to set an entry for it in my local /etc/hosts, so that I don't have to type the IP address every time I want to connect to
is and simply use an alias.  As per the man page, /etc/hosts has:

IP_address canonical_hostname [aliases]

To get the canonical_hostname I thought I'd easily get it by typing
"dnshostname" when logged into the remote laptop, but that returns
nothing, and "domainname" returns '(none)'.  How should this
canonical_hostname be specified in this case?


Any name you come up with will work, if hard-coded into your /etc/hosts. Of course, it won't be canonical ...

--
Cheerio,

Klistvud http://bufferoverflow.tiddlyspot.com Certifiable Loonix User #481801 Please reply to the list, not to me.


Reply to: