During Debian installation, I set my hostname to the wrong value, and now I would like to correct that.
Debian – How to change a hostname
debianhostname
debianhostname
During Debian installation, I set my hostname to the wrong value, and now I would like to correct that.
Best Answer
The hostname is stored in three different files:
/etc/hostname
Used as the hostname/etc/hosts
Helps resolving the hostname to an IP address/etc/mailname
Determines the hostname the mail server identifies itselfYou might want to have a deeper look with
grep -ir hostname /etc
Restarting affected services might be a good idea as well.