title: Getting the (parent) process executing the command in Linux shell
body: <p>Please advice , how to verify the program that execute the process ? </p>
  
  <p>For example</p>
  
  <p>the following commands ( ps -ef ) will view the process sendmail in case this process is running</p>
  
  <pre><code>  ps –ef | grep sendmail
    root     9558 9544 019:05?      00:00:00/usr/sbin/sendmail-FCronDaemon-i-odi-oem-oi-t
  </code></pre>
  
  <p>what I want to find is the script that execute the binary  <strong>/usr/sbin/sendmail</strong></p>
  
  <p>so my question – which flags I need to add to the syntax "ps –ef"  in order to get from ps –ef the full details , include which program running the process</p>
  
  <p>is it possible ?</p>
  
  <ul>
  <li>Example and remark</li>
  </ul>
  
  <p>If
  <strong>/etc/rc3.d/sendmail</strong> run the binary <strong>/usr/sbin/sendmail</strong></p>
  
  <p>Then I expect to see the <strong>/etc/rc3.d/sendmail</strong> PATH from the command ps –ef …….</p>