[CentOS] my postfix ignores myhostname parameter

mouss mouss at netoyen.net
Mon Oct 13 19:16:57 UTC 2008

David Hláčik a écrit :
> Hello guys,
> I do not know how it is posible :
> *vi /etc/postfix/main.cf <http://main.cf>*
> #
> # The myhostname parameter specifies the internet hostname of this
> # mail system. The default is to use the fully-qualified domain name
> # from gethostname(). $myhostname is used as a default value for many
> # other configuration parameters.
> #
> #myhostname = host.domain.tld
> myhostname = mail.hlacik.eu
> *service postfix restart*

I know you're testing. but once you get a "stable" config, restart is
often unnecessary. in most cases a 'postfix reload' is enough (and even
that isn't necessary in general, as most postfix services are relatively
short lived and will reread the conf at some time). of course, if you
change an IP:port, ..., you need to restart.

> [root at sx1 postfix]# postconf -d myhostname
> *myhostname = sx1.labs.hlacik.eu*

the 'd' in "-d" stands for "default". Use

# postconf myhostname
# postconf -n myhostname
# postconf -h myhostname


> What is wrong??

nothing, except that you forgot to RTFM ;-p

More information about the CentOS mailing list