Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 413293 - --unmerge postfix; emerge sendmail fail
Summary: --unmerge postfix; emerge sendmail fail
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-23 19:44 UTC by Richard Lynch
Modified: 2012-04-24 06:27 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Lynch 2012-04-23 19:44:24 UTC
Take your stock gentoo build.

emerge postfix

/etc/init.d/postfix start

Decide that postfix just isn't for you.

emerge --unmerge postfix

Let's try sendmail

emerge sendmail

/ete/init.d/sendmail start

The init script claims to have started.

There is no /var/run/sendmail.pid file.

There is a /var/spool/clientmqueue/sm-client.pid file for the client queue runner.

ps auxwww | grep mail
shows:
    a) sendmail daemon with correct flags for the daemon
    b) the client queue runner

mail -vs test test@example.com < test.txt

"hangs"

/var/log/messages shows all kinds of failures from postfix...

Because the --unmerge didn't STOP the postfix process from running.

So sendmail can't bind port 25.

And /etc/init.d/sendmail script sends all the error output to /dev/null

I would suggest some or all of the following:

1) emerge --unmerge postfix should stop the postfix binary. It's not in a run-level, it's not in the init scripts, there's no code to run it if you re-start...

2) /etc/init.d/sendmail should redirect to /var/log/messages instead of /dev/null so we can SEE the sendmail error about not binding to port 25.

Actually, you'd want to do the right thing based on syslog/syslog-ng etc, ideally...

3) rm -rf /var/spool/postfix would be most welcome as well
Comment 1 Eray Aslan gentoo-dev 2012-04-24 06:27:35 UTC
(In reply to comment #0)
> 1) emerge --unmerge postfix should stop the postfix binary. It's not in a
> run-level, it's not in the init scripts, there's no code to run it if you
> re-start...

No.  We do not start daemons when you install them and neither do we stop them when uninstalled.  That's your job.  We won't second guess the sysadmin/user.

> 2) /etc/init.d/sendmail should redirect to /var/log/messages instead of
> /dev/null so we can SEE the sendmail error about not binding to port 25.

You should check the logs.  Sendmail logs the startup errors.

> Actually, you'd want to do the right thing based on syslog/syslog-ng etc,
> ideally.

And that's way too fragile.

> 3) rm -rf /var/spool/postfix would be most welcome as well

No.  There might still be undelivered mail in there.