Finding hostname to run SSH

To access a remote machine using ssh, you will need to know either its public host name or its IP address.

You will also need to have either a username and password for an account on the other machine or an SSH private key corresponding to an SSH public key installed on a particular account on the machine you're connecting to.

If you do not know these details, you will have to ask someone who's administrating the other machine for how to best connect with ssh.

The hostname command is exclusively used for setting or displaying the name of the system it's being run on. If you run it locally, it will return the name of your local machine, which may or may not be a fully qualified host name (in either case, it's the name/IP-number of the local machine).


If memory serves me correctly, supposing your device IP address is 192.168.0.11, you would enter the following:

ssh 192.168.0.11 
<password>

If you are unsure of the address of your UNIX machine you can use the ifconfig command from the UNIX machine to obtain your IP address.

Tags:

Ssh

Hostname