1832244 Members
2953 Online
110041 Solutions
New Discussion

initrtab behavuour

 
Dan Am
Frequent Advisor

initrtab behavuour

This actually concerns a linux system, but I get a faster anwer her :-)
I thought I'
s get bright , and insert the sendmail daemon into inittab with:
mail:35:respawn:/usr/sbin/sendmail -bd -q30m -om
which is ok; only the way it works is funny:
1. I kill the daemon.
2) Nothing happens for ca. 3 mins
3) sendmail comes up in 8 instances
4) the surplus instances die after ca 3 mins.

How come ?
Anybody know where to to tune this ?

Regards
Dan
do what you can. don't if you can't.
4 REPLIES 4
Dan Am
Frequent Advisor

Re: initrtab behavuour

ps.: Sorry for the typos.
do what you can. don't if you can't.
Kodjo Agbenu
Honored Contributor

Re: initrtab behavuour

Hello Dan,

The "-bd" option tells sendmail to run in daemon mode.
Using inittab with "respawn" directive, you tell the "init" process to restart the sendmail daemon when it dies. In my opinion, it is not a good idea to mix both mechanisms.

If you look at "xdm" (or prefdm) in /etc/inittab, a "nodaemon" option is explicitly specified.

For sendmail in inittab, I would suggest "-bD" (capital D):

mail:35:respawn:/usr/sbin/sendmail -bD -q30m -om

The "-bd" (small d) should be used only when sendmail is started from command-line or rc scripts.

Good luck.

Kodjo
Learn and explain...
Dan Am
Frequent Advisor

Re: initrtab behavuour

To my own surprise, "-bD" did not change a thing,hmmm...
I think the problem is with sendmail going into daemon mode, it becommes a different process, and thus the original calling process is dead. There may some issues in handling this, I figure.
do what you can. don't if you can't.
U.SivaKumar_2
Honored Contributor

Re: initrtab behavuour

hi,
try using "once" instead of "respawn".

regards,
U.SivaKumar.
Innovations are made when conventions are broken