GNU/Linux >> Linux Esercitazione >  >> Ubuntu

Come modificare il nome host?

Il mio nome host è localhost , segnalato da hostname comando e prompt del terminale [email protected]:~# .

Come posso cambiarlo in mismis.com con mismis alias? e qual è la configurazione corretta.

Mi sono confuso dopo aver letto alcuni articoli sul web.

I miei /etc/hosts:

127.0.0.1       localhost
127.0.1.1       srv345.myweb.com      srv345
178.162.231.61  janstone.mismis.com    janstone
# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

Risposta accettata:

Prova a eseguire il seguente comando in un terminale.

sudo sysctl kernel.hostname=mismis.com

/etc/host:

127.0.0.1       localhost
127.0.1.1       mismis.com mismis srv345.myweb.com srv345
178.162.231.61  janstone.mismis.com    janstone

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

Ubuntu
  1. Come modificare il nome host su CentOS

  2. Come cambiare il nome host su Ubuntu

  3. Come cambiare il nome host su Ubuntu?

  4. Come modificare il nome host in Debian

  5. Come cambiare il nome host su Ubuntu

Come cambiare il nome host in Ubuntu Linux

Come modificare il nome host su AlmaLinux 8

Come modificare il nome host su Fedora 35

Come modificare il nome host di un server cPanel/WHM?

Come modificare il nome host del server in Ubuntu

Come modificare il nome host su Debian Linux