I'm upgrading a box from redhat to suse 8.1 pro. One task this box will assume is SMTP host. I've been using sendmail on the redhat box, but am interested in using postfix provided I can get it working. :) Here's what I changed in /etc/postfix/main.cf: myhostname = somehost.domain.com mydomain = domain.com myorigin = $mydomain After starting postfix, I can send mail from the localhost and the command line using this: echo "a test" | /usr/sbin/sendmail jejonas@yahoo.com But I'm not able to connect to postfix from another host using: telnet somehost 25 The connection is terminated and nothing is logged in /var/log/mail or /var/log/messages to indicate what the issue may be. Any insight is appreciated. I really don't want to go back to sendmail, but then this problem doesn't appear to be a postfix config issue either. Thanks! Jason
On Sunday 29 December 2002 16:46 pm, Jason Jonas - Sapien wrote:
I'm upgrading a box from redhat to suse 8.1 pro. One task this box will assume is SMTP host. I've been using sendmail on the redhat box, but am interested in using postfix provided I can get it working. :)
Here's what I changed in /etc/postfix/main.cf:
myhostname = somehost.domain.com mydomain = domain.com myorigin = $mydomain
After starting postfix, I can send mail from the localhost and the command line using this:
echo "a test" | /usr/sbin/sendmail jejonas@yahoo.com
But I'm not able to connect to postfix from another host using:
telnet somehost 25
The connection is terminated and nothing is logged in /var/log/mail or /var/log/messages to indicate what the issue may be. Any insight is appreciated. I really don't want to go back to sendmail, but then this problem doesn't appear to be a postfix config issue either. Thanks!
Jason
You must tell postfix to listen on port 25 of 'somehost' (as opposed to port 25 of localhost which is how you've been connecting) Put the following line into your master.cf for postfix: somehost:25 inet n - n - - smtpd -o content_filter= (watch for folding of the above long line) -- +----------------------------------------------------------------------------+ + Bruce S. Marshall bmarsh@bmarsh.com Bellaire, MI 12/29/02 16:22 + +----------------------------------------------------------------------------+ "There is no such thing as a 'Fail Safe' design."
On Sun, 29 Dec 2002, Bruce just had to get this off his chest:
On Sunday 29 December 2002 16:46 pm, Jason Jonas - Sapien wrote:
I'm upgrading a box from redhat to suse 8.1 pro. One task this box will assume is SMTP host. I've been using sendmail on the redhat box, but am interested in using postfix provided I can get it working. :)
Here's what I changed in /etc/postfix/main.cf:
myhostname = somehost.domain.com mydomain = domain.com myorigin = $mydomain
After starting postfix, I can send mail from the localhost and the command line using this:
echo "a test" | /usr/sbin/sendmail jejonas@yahoo.com
But I'm not able to connect to postfix from another host using:
telnet somehost 25
The connection is terminated and nothing is logged in /var/log/mail or /var/log/messages to indicate what the issue may be. Any insight is appreciated. I really don't want to go back to sendmail, but then this problem doesn't appear to be a postfix config issue either. Thanks!
Jason
You must tell postfix to listen on port 25 of 'somehost' (as opposed to port 25 of localhost which is how you've been connecting)
Put the following line into your master.cf for postfix:
somehost:25 inet n - n - - smtpd -o content_filter=
(watch for folding of the above long line)
For 99% of the normal operation of Postfix the (standard) master.cf file does *not* need to be editted, and certainly not for this. Postfix uses the $inet_interfaces value in main.cf to determine on what IP to listen, and normally it uses all available interfaces. It is possible that SuSE put only "localhost" there, in which case you just need to put a hash in front of that line and reload Postfix. The first thing the OP should do (if the above didn't solve things) is to determine if Postfix is running at all. $ ps aux|grep [p]ostfix root 1508 0.0 0.1 2328 944 ? S Dec29 0:00 \ /usr/libexec/postfix/master postfix 16600 0.0 0.1 2300 912 ? S Dec29 0:00 \ pickup -l -t unix postfix 16601 0.0 0.1 2340 960 ? S Dec29 0:00 \ qmgr -l -t unix -u If it is, then it /will/ write to syslog, you have to make sure it writes to the right log files of course. Here's my syslog.conf: # Split email-messages # mail.=debug;mail.=info;mail.=notice -/var/log/mail/info mail.=warn -/var/log/mail/warnings mail.err -/var/log/mail/errors If it is not then start with '/usr/sbin/postfix start' (forget about /etc/init.d for now) and watch the logs ( use tail -f logfile ). Tell us about the messages, and/or that it was all a bad dream and Postfix is working perfectly afterall (like it is here). Theo -- Theo v. Werkhoven Registered Linux user# 99872 http://counter.li.org ICBM 52 13 27N , 4 29 45E. SuSE 8.0 x86 Kernel k_Athlon 2.4.19-4GB See headers for PGP/GPG info.
Just to let everyone know... The issue was the inet_interfaces setting. In the /etc/postfix/main.cf file, the comments indicate the value defaults to 'all'. I left the settings unchanged. However, further down in the file, inet_interfaces is set to localhost. There are several other parameters who's description is in the file, but suse overrides at the bottom of the file. My bad for not checking the entire file, but I really don't like the fact that the comments/description of a property somehow got separated from the value setting of that property. I got caught on the mydestination property as well. I set it where the comments were located, but it's set again at the bottom of the file. I straightened it all out and everything's cool now. Thanks to everyone who responded on/off list. Jason -----Original Message----- From: Theo v. Werkhoven [mailto:twe-suse.e@ferrets4me.xs4all.nl] Sent: Sunday, December 29, 2002 6:17 PM To: SLE Subject: Re: [SLE] postfix communication Tell us about the messages, and/or that it was all a bad dream and Postfix is working perfectly afterall (like it is here). Theo -- Theo v. Werkhoven Registered Linux user# 99872 http://counter.li.org ICBM 52 13 27N , 4 29 45E. SuSE 8.0 x86 Kernel k_Athlon 2.4.19-4GB See headers for PGP/GPG info.
On Mon, 30 Dec 2002 11:38, Jason Jonas - Sapien wrote:
Just to let everyone know... The issue was the inet_interfaces setting. In the /etc/postfix/main.cf file, the comments indicate the value defaults to 'all'. I left the settings unchanged. However, further down in the file, inet_interfaces is set to localhost. There are several other parameters who's description is in the file, but suse overrides at the bottom of the file.
My bad for not checking the entire file, but I really don't like the fact that the comments/description of a property somehow got separated from the value setting of that property. I got caught on the mydestination property as well. I set it where the comments were located, but it's set again at the bottom of the file.
I straightened it all out and everything's cool now. Thanks to everyone who responded on/off list.
Jason, I have been struggling with postfix on and off for the past week and got totally confused with that file. I ended up pulling out all the comments to see what variables were set. grep ^[^#] main.cf > variables_main.list It makes looking at the variables a lot easier especially when they endup being double set. -- Regards, Graham Smith ---------------------------------------------------------
On Mon, 30 Dec 2002 08:46, Jason Jonas - Sapien wrote:
I'm upgrading a box from redhat to suse 8.1 pro. One task this box will assume is SMTP host. I've been using sendmail on the redhat box, but am interested in using postfix provided I can get it working. :)
Here's what I changed in /etc/postfix/main.cf:
myhostname = somehost.domain.com mydomain = domain.com myorigin = $mydomain
After starting postfix, I can send mail from the localhost and the command line using this:
echo "a test" | /usr/sbin/sendmail jejonas@yahoo.com
But I'm not able to connect to postfix from another host using:
telnet somehost 25
Jason, Under Yast2 there is a box to check under the Incoming mail section of the Mail Transfer Agent. It is marked "Accept remote SMTP connections" OR in the file /etc/sysconfig/mail change the variable SMTPD_LISTEN_REMOTE="no" to "yes" -- Regards, Graham Smith ---------------------------------------------------------
participants (5)
-
Bruce Marshall
-
Graham Smith
-
Jason Jonas - Sapien
-
Jason Jonas - Sapien
-
Theo v. Werkhoven