Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Other Things Gentoo
  • Search

[runscript] problem starting sendmail

Still need help with Gentoo, and your question doesn't fit in the above forums? Here is your last bastion of hope.
Post Reply
Advanced search
8 posts • Page 1 of 1
Author
Message
mobidyc
Tux's lil' helper
Tux's lil' helper
Posts: 109
Joined: Mon May 01, 2006 5:40 pm

[runscript] problem starting sendmail

  • Quote

Post by mobidyc » Mon Nov 26, 2007 4:07 pm

Hello,

it seems i can't stop/start sendmail through the init.d/sendmail script, i need to start it manually:

Code: Select all

#> ps -ef|grep sendmail|grep -v grep
root     19607     1  0 16:58 ?        00:00:00 sendmail: accepting connections       
smmsp    19610     1  0 16:58 ?        00:00:00 sendmail: Queue runner@00:30:00 for /var/spool/clientmqueue

#> /etc/init.d/sendmail stop
 * Caching service dependencies ...                                                                                                                    [ ok ]
 * Service sendmail stopping
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]                                                           [ !! ]
 * ERROR:  sendmail failed to stop

#> ps -ef|grep sendmail|grep -v grep
smmsp    19610     1  0 16:58 ?        00:00:00 sendmail: Queue runner@00:30:00 for /var/spool/clientmqueue

#> kill 19610
#> ps -ef|grep sendmail|grep -v grep

#> /etc/init.d/sendmail start
 * WARNING:  sendmail has already been started.

Code: Select all

#> cat /etc/init.d/sendmail 
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/mail-mta/sendmail/files/sendmail,v 1.6 2007/09/26 10:46:26 lcars Exp $

depend() {
        need net
        use logger antivirus
        provide mta
}

start() {
        ebegin "Starting sendmail"
        /usr/bin/newaliases > /dev/null 2>&1
        (cd /var/spool/mqueue; rm -f xf*)
        /usr/sbin/sendmail ${SENDMAIL_OPTS} > /dev/null 2>&1
        /usr/sbin/sendmail ${CLIENTMQUEUE_OPTS} > /dev/null 2>&1
        eend $?
}

stop() {
        ebegin "Stopping sendmail"
        kill ${KILL_OPTS} `head -n 1 /var/run/sendmail.pid`
        kill ${KILL_OPTS} `head -n 1 /var/spool/clientmqueue/sm-client.pid`
        eend $?
}

Code: Select all

#> source /etc/conf.d/sendmail
#> echo ${SENDMAIL_OPTS}     
-bd -q30m -L sm-mta
#> echo ${CLIENTMQUEUE_OPTS}
-Ac -q30m -L sm-cm

#> /usr/sbin/sendmail ${SENDMAIL_OPTS}
#> /usr/sbin/sendmail ${CLIENTMQUEUE_OPTS}

#> ps -ef|grep sendmail|grep -v grep
root     19762     1  0 17:03 ?        00:00:00 sendmail: accepting connections       
smmsp    19765     1  0 17:03 ?        00:00:00 sendmail: Queue runner@00:30:00 for /var/spool/clientmqueue
as you can see, i can manually start sendmail.

i use the stable sendmail and baselayout ebuilds :
sys-apps/baselayout-1.12.9-r2
mail-mta/sendmail-8.14.0

am i the only one with this problem?
(found nothing on bugs.gentoo.org)

--
Regards,
Mobidyc
Top
SnEptUne
l33t
l33t
User avatar
Posts: 656
Joined: Mon Aug 23, 2004 4:13 am

  • Quote

Post by SnEptUne » Mon Nov 26, 2007 11:54 pm

Is using sendmail a requirement? Postfix would be much better in term of configurations and easy of use.
"There will be more joy in heaven over the tear-bathed face of a repentant sinner than over the white robes of a hundred just men." (LM, 114)
Top
mobidyc
Tux's lil' helper
Tux's lil' helper
Posts: 109
Joined: Mon May 01, 2006 5:40 pm

  • Quote

Post by mobidyc » Tue Nov 27, 2007 10:18 am

Hello,

why asking me to change my MTA?
is my post seems to be a configuration or easy to use problem?

sendmail have prove its performance/robustness and is definitively not more complicated than postfix!!!, at the moment you have m4 in preprocessor, it's true;)

thanks for your answer SnEptUne but my problem is not through sendmail,
it is through the init script to launch sendmail, created by the gentoo team.

--
Regards,
Cedrick Gaillard
Top
SnEptUne
l33t
l33t
User avatar
Posts: 656
Joined: Mon Aug 23, 2004 4:13 am

  • Quote

Post by SnEptUne » Tue Nov 27, 2007 5:47 pm

Postfix is also proven to be robust and easier to use than sendmail. Maybe sendmail has fixed their unorganized configuration and syntax in the pass 4 years?

Unfortunately, I cannot help you with sendmail runscript problem since I don't have sendmail installed. You could however try to run the runscript by hands and see where it fails, such as the following:

Code: Select all

/usr/bin/newaliases
cd /var/spool/mqueue; rm -f xf*
You could also remove the "> /dev/null 2>&1" from run script to see what error is being displayed.

There should also be a pidfile in /var/run/sendmail.pid with the pid of sendmail.

There isn't any thing special about run script beside it is being ran with root priviledge
"There will be more joy in heaven over the tear-bathed face of a repentant sinner than over the white robes of a hundred just men." (LM, 114)
Top
mobidyc
Tux's lil' helper
Tux's lil' helper
Posts: 109
Joined: Mon May 01, 2006 5:40 pm

  • Quote

Post by mobidyc » Thu Nov 29, 2007 6:05 pm

Hi SnEptUne,

thanks for yout interest.

actually, it seems i'm the only one with this problem, strange because on this server, all packages are marqued stable and no special programs are installed (and revdep-rebuild is ok).
as you can see in my first post, i've manually ran the run script by hand, without any problem.

i persists an day that the problem is /sbin/runscript, it's not a shell script and i don't want to strace it nor to open a bug (because i'm the only one whit this problem).
maybe a future reboot will solve it.

anyway, i will rewrite the init.d/sendmail launcher for my purpose.

Thanks

--
Mobidyc
Top
SnEptUne
l33t
l33t
User avatar
Posts: 656
Joined: Mon Aug 23, 2004 4:13 am

  • Quote

Post by SnEptUne » Fri Nov 30, 2007 3:04 am

mobidyc wrote:thanks for yout interest.

actually, it seems i'm the only one with this problem, strange because on this server, all packages are marqued stable and no special programs are installed (and revdep-rebuild is ok).
as you can see in my first post, i've manually ran the run script by hand, without any problem.
No problem. But you have only ran sendmail, not newaliases and (rm -f xf*). Who knows where it failed?
"There will be more joy in heaven over the tear-bathed face of a repentant sinner than over the white robes of a hundred just men." (LM, 114)
Top
dreamlx
n00b
n00b
Posts: 1
Joined: Wed Jan 02, 2008 4:46 pm
Contact:
Contact dreamlx
Website

  • Quote

Post by dreamlx » Wed Jan 02, 2008 5:33 pm

I just had the same problem. In my case, it occured as the script was not able to stop sendmail once.

Here the steps I did to resolve the problem (everything in /etc/init.d/sendmail):

1. comment out the killproc lines
2. ./sendmail stop
3. uncomment the killproc lines

after these steps, everything worked again normally.

I thinks there must be a better way, but this solved my problem.

Bye,
David
Top
mobidyc
Tux's lil' helper
Tux's lil' helper
Posts: 109
Joined: Mon May 01, 2006 5:40 pm

  • Quote

Post by mobidyc » Thu Jan 03, 2008 10:07 am

thanks dreamlx,

i've re-wrote the init script for my convenience so, i've no more the problem.
this post is not solved because hacking the init script is no a clean way for solve it.

Happy new year

--
Mobidyc
Top
Post Reply

8 posts • Page 1 of 1

Return to “Other Things Gentoo”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy