Postfix local only problem: Difference between revisions
imported>Daniel15 m (Article cleanup :)) |
|||
| Line 1: | Line 1: | ||
== Synopsys == | == Synopsys == | ||
When you are running multiples vservers on a same physical box, | When you are running multiples vservers on a same physical box, it may be useful to allow box daemons (like cron) to send mail for debugging purpose or just seeing if a problem occurs. Debian GNU/Linux provides a good way to configure packages like postfix. You can use | ||
# dpkg-reconfigure postfix | |||
to start configuring (this script is also called when installing postfix) | |||
The problem is that, the local-only mode (which in this instance is the most useful) doesn't work 'out of the box' (Postfix starts without any messages, but doesn't appear in process list (ps)). | |||
The problem is that, the local-only mode | |||
( | |||
A few fixes are needed for Postfix to run properly: | |||
== | == /etc/hosts additions == | ||
Add a line in /etc/hosts with: | |||
nano /etc/hosts | |||
ip.of.the.host nameofhost | |||
You can also add: | |||
ip.of.the.host | ip.of.the.host localhost | ||
(the "localhost" hostname is used by some other daemons and normally points to 127.0.0.1.) | |||
== Modify postfix configuration == | |||
# nano /etc/postfix/main.cf | |||
# nano /etc/postfix/main.cf | |||
Replace | Replace | ||
inet_interfaces = loopback-only | |||
with | |||
inet_interfaces = name_of_host_entered_in__etc_hosts | |||
or | |||
inet_interfaces = localhost | |||
== Restart Postfix == | |||
Restart Postfix with | |||
/etc/init.d/postfix restart | |||
and check it run with "ps". | |||
That's all folks ;) | That's all folks ;) | ||
Revision as of 03:31, 24 August 2007
Synopsys
When you are running multiples vservers on a same physical box, it may be useful to allow box daemons (like cron) to send mail for debugging purpose or just seeing if a problem occurs. Debian GNU/Linux provides a good way to configure packages like postfix. You can use
# dpkg-reconfigure postfix
to start configuring (this script is also called when installing postfix)
The problem is that, the local-only mode (which in this instance is the most useful) doesn't work 'out of the box' (Postfix starts without any messages, but doesn't appear in process list (ps)).
A few fixes are needed for Postfix to run properly:
/etc/hosts additions
Add a line in /etc/hosts with:
nano /etc/hosts
ip.of.the.host nameofhost
You can also add:
ip.of.the.host localhost
(the "localhost" hostname is used by some other daemons and normally points to 127.0.0.1.)
Modify postfix configuration
# nano /etc/postfix/main.cf
Replace
inet_interfaces = loopback-only
with
inet_interfaces = name_of_host_entered_in__etc_hosts
or
inet_interfaces = localhost
Restart Postfix
Restart Postfix with
/etc/init.d/postfix restart
and check it run with "ps".
That's all folks ;)