accessing DHCP connected hosts by name vs IP

Jay Ridgley jridgley2 at
Sat Dec 24 18:23:14 UTC 2011


I know that if a host is connected via a static connection and is in the 
/etc/hosts file by name and IP, it may be accessed by name when using ssh and sftp.

How can I or is it possible, to do the same for a host connected via DHCP?

For example: My laptop (hostname kodiak) has the following entry in /etc/hosts: kodiak

When connected with a cat 5 cable it can be accessed simply by ssh kodiak, 
however, when connected via DHCP I must use ssh (the assigned IP 
address on my local network).

I would rather only use the hostname. Once connected with ssh it does show as 
kodiak, so it is identified as expected. I just can not ssh kodiak with a 
wireless connection.

Is it possible to connect wirelessly with a static IP address? If so I would 
love to know how it is done.


Jay Ridgley
jridgley2 at
Registered Linux User ID - 9115
Registered Ubuntu User ID - 23320

More information about the ubuntu-users mailing list