myhostname = <hostname>

mydomain = <hostname>

 

If the hostname is not valid, postfix fails to start. It have to be
resolved by DNS and the IP must be the IP of one of the interface of the
server which run Postfix.

 

So I have to use a name that is resolved in many different IPs, I think

 

rocsca

 

 

From: Thomas [mailto:[email protected]] 
Sent: Thursday, January 15, 2009 2:58 AM
To: Rocco Scappatura
Cc: postfix users list
Subject: Re: Share postfix config directory

 

I never had a problem to do exactly this ... 

For what do you need the hostname of the server? 
My main.cf does not contain a hostname - it can easily be used over an
NFS share: 

mkdir /data 
mount server:/data /data 
/etc/init.d/postfix stop 
cp -rp /etc/postfix /data/postfix_nfs 
mv /etc/postfix /etc/postfix_ORIG 
ln -s /data/postfix_nfs /etc/postfix 
/etc/init.d/postfix start 
echo `hostname`| Mail -s `hostname` <account>@<yourdomain> 

Works :) 

My simple client server main.cf: 

postconf -n 
config_directory = /etc/postfix 
mydomain = <yourdomain> 
mynetworks = 127.0.0.0/8 
myorigin = $mydomain 
relayhost = <your relay> 

Where does the hostname kick in at your site? 



Rocco Scappatura wrote: 



Hello, 

I have different SMTP gateways each one configurred exactly at the same 
manner. The only difference is the hostname. 

I would like to know if I could define "/etc/postfix" as an NFS share 
somewhere and export it on each of my SMTP gateways. The aim is 
obviously to change only one configuration file each time that a postfix

configuration update is needed. 

TIA, 

rocsca 
  

 

Reply via email to