Basic Linux Tutorial
Computer Tutorial

ARPA Services Commands

The hostname Command

Hostname is used to either set or display the current host, domain or node name of the system. These names are used by many of the networking programs to identify the machine.

Synopsis :

$hostname   [option]

Example :

Print the hostname of the system :
Output :
-a     Display the alias name of the host (if used) This option is deprecated and should not be used anymore.
-d     Display the name of the DNS domain.
-F     Read the host name from the specified file.
-i     Display the IP address(es) of the host.
-I     Display all network addresses of the host.

The telnet Command

The telnet command is used for interactive communication with another host using the TELNET protocol.

Synopsis :

telnet   [option]   [port]
host     Specifies a host to contact over the network.
port     Specifies a port number or service name to contact. If not specified, the telnet port (23) is used.
-4     Force IPv4 address resolution.
-6     Force IPv6 address resolution.
-a     Attempt automatic login.
-r     Emulate rlogin. In this mode, the default escape character is a tilde.
-l user     Specify user as the user to log in as on the remote system.

The ftp Command

The ftp stands for file transfer protocol. ftp command is used to copy a file to or from a remote computer using the ARPA Services.

Synopsis :

ftp   [option]

Example :

get   rfile   lfile
This copies the file rfile on the remote computer to the file lfile on your local computer. You can also use full path names as file names.
put   lfile   rfile
This will copy the local file lfile to the remote file named rfile.
List the files on the remote computer. This works just like the ls command we have been using.
List all of the ftp commands.
Disconnect from the remote computer and leave ftp.