LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   I need some help configuring postfix... (https://www.linuxquestions.org/questions/linux-newbie-8/i-need-some-help-configuring-postfix-782784/)

trist007 01-17-2010 11:59 AM

I need some help configuring postfix...
 
I am using Slackware 13.0. I currently have sendmail installed and running. I then downloaded and installed postfix 2.6.5. I did not disable sendmail or anything.

I am confused about this. I just want to use postfix for smtp. So postfix uses the already installed sendmail program? You would think they would conflict. Anyhow, it's up and running. I have master running and listening on 0.0.0.0:25.

However, whenever I netcat to 127.0.0.1 25 I get no header, it just stays blank. Why is this so?

I do not have a FQDN, I just use an IP address. I would like to use smtp to sendmail to users within my computer and network. I would also like to be able to send mail to a few hosts like hotmail, yahoo, and some ISP servers, assuming they do not filter emails coming from a source that is not a FQDN.

A few key settings that I have changed in /etc/postfix/main.cf are

myhostname = server
mydomain = darkstar.net
myorigin = $myhostname
proxy_interfaces = x.x.x.x
inet_interfaces = all

The x.x.x.x is my external IP address.
The name of computer I am configuring postfix is called server and my domain name is darkstar.net(not FQDN). It's just called darkstar.net within my internal network.

In /etc/mail/sendmail.cf

# SMTP client options
#O ClientPortOptions=Family=inet, Address=x.x.x.x

What else should I check to get postfix working? It's running, but when I telnet in the banner doesn't come out, it just stays stuck on a blank line.

Also, why is the master program running as root? Shouldn't it be running as postfix? Or does it have to run as root to access sendmail? I even tried running postfix with

Code:

su postfix -c "/usr/sbin/postfix start"
and master still comes out running as root. I know I can chroot the postfix process, but for now I just want to learn the basics.

Also, in the /etc/postfix/master.cf

Code:

#
# ==========================================================================
# service type  private unpriv  chroot  wakeup  maxproc command + args
#              (yes)  (yes)  (yes)  (never) (100)
# ==========================================================================
smtp      inet  n      -      n      -      -      smtpd

If I comment out that smtp line then I don't get postfix running on port 25.

Also, found these errors in the maillog

Code:

Jan 17 12:07:24 server postfix/smtpd[3918]: fatal: open database /etc/aliases.db: No such file or directory
Jan 17 12:07:25 server postfix/master[3133]: warning: process /usr/libexec/postfix/smtpd pid 3918 exit status 1
Jan 17 12:07:25 server postfix/master[3133]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling
Jan 17 12:08:25 server postfix/smtpd[3922]: fatal: open database /etc/aliases.db: No such file or directory
Jan 17 12:08:26 server postfix/master[3133]: warning: process /usr/libexec/postfix/smtpd pid 3922 exit status 1
Jan 17 12:08:26 server postfix/master[3133]: warning: /usr/libexec/postfix/smtpd: bad command startup -- throttling
Jan 17 12:09:26 server postfix/smtpd[3926]: fatal: open database /etc/aliases.db: No such file or directory
Jan 17 12:09:27 server postfix/master[3133]: warning: process /usr/libexec/postfix/smtpd pid 3926 exit status 1

I have copied the /etc/postfix/aliases to /etc/aliases and now I do not get that error anymore. I have also added aliases
postmaster: you
postfix you
to the /etc/aliases.

However, I still cannot pull a banner after telnetting to 25.

trist007 01-17-2010 01:46 PM

I got it, just had to make a symbolic link /etc/aliases.db point to /etc/mail/aliases.db. W00t.


All times are GMT -5. The time now is 11:25 PM.