Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

hostname

v(uutils coreutils) 0.8.0
hostname [OPTION]... [NOM_HÔTE]

Afficher ou définir le nom d’hôte du système.

Options

--domain, -d

Afficher le nom du domaine DNS si possible

--ip-address, -i

Afficher la ou les adresses réseau de l’hôte

--fqdn, -f

Afficher le FQDN (nom de domaine pleinement qualifié) (par défaut)

--short, -s

Afficher le nom d’hôte court (la partie avant le premier point) si possible

Examples

The examples have not been translated yet and are shown in English. You can help by translating them on tldr-pages.

Show current host name:

hostname

Show the network address of the host name:

hostname {{[-i|--ip-address]}}

Show the FQDN (Fully Qualified Domain Name):

hostname {{[-f|--fqdn]}}

Set current host name:

hostname {{new_hostname}}

The examples are provided by the tldr-pages project under the CC BY 4.0 License.

Please note that, as uutils is a work in progress, some examples might fail.