Mombu the GNU Linux Forum sponsored links

Go Back   Mombu the GNU Linux Forum > GNU_Linux > how to retrieve the actual arguments being used in the sendmail daemon
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 2nd August 17:23
bill
External User
 
Posts: 1
Default how to retrieve the actual arguments being used in the sendmail daemon



On Linux, ps -ef |grep sendmail, it returns something like this:

root 1920 1 0 10:13 ? 00:00:00 sendmail: accepting connections
smmsp 19211 1 0 10:13 ? 00:00:00 sendmail: Queue runner@01:00:00 for /var/spool/clientmqueue

I know the "sendmail: accepting connections" is for displaying purpose. Do we have a way to retrive the real arguments for a running process if the arg[0] is set to something else in the end of the program?
Thanks.
  Reply With Quote


  sponsored links


2 2nd August 17:23
bill
External User
 
Posts: 1
Default how to retrieve the actual arguments being used in the sendmail daemon



Someone in the sendmail group replied:

cat `grep '^O PidFile=' /etc/mail/se*cf | sed -e 's/^.*=//'`

as sendmail keep a PidFile to record the actually command the arguments. Now the question becomes a more OS-related... if the arg[] is set to a displaying title (which will be what ps -ef shows), and the program doesn't keep a PidFile, do we still have the info somewhere in the kernel?
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666