Codist

Code Happiness

How to update hostname in postfix?

Updating hostname in postfix involves updating several files. First, we need to update the following file with the new hostname:

/etc/mailname

So, we can use the following command to update the file with nano editor

nano /etc/mailname

Then, we’ll need to update the postfix configuration file that’s located at /etc/postfix/main.cf . In the file, we’ll update the hostname with the new hostname. So, the new hostname line should be

myhostname = newhost.yourdomain.com 

Then, we need to restart postfix service with the following command –

sudo service postfix restart

Done! Your new hostname should appear in your mail now.

 

Related Posts

gmail-grid

New Gmail looks like

As you can see, the new Gmail looks like a hybrid between the current Gmail interface and inbox.google.com. It isn’t a huge departure from the current interface metaphor. So existing Gmail users will still feel

Read More »

Get Free Consultancy