Announcement

Collapse
No announcement yet.

lsphp and process name

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • lsphp and process name

    Hello, I allow customers to use different PHP as they want but as administrator it is hard to track running processes from console.

    Example

    #ps auxfww
    .....
    testas 477679 0.0 0.0 718496 56372 ? Ss 13:39 0:00 lsphp
    testas 477769 0.0 0.0 549632 42624 ? Ss 13:39 0:00 lsphp

    ​I see two lsphp process are active but I need to lsof them to know which PHP it is.

    Is is possible to make lsphp process to show full path ?

    example /opt/alt/php81/usr/bin/lsphp instead of lsphp


    Thank you




  • #2
    Hello,

    Unfortunately there is no way to do that, however, you may use some kind of simple bash oneliner to grep and lsof them at once. Here is draft example:


    Code:
    ps axuwwwf | grep lsphp | awk '{print $2}' | xargs -I {} lsof -p {} | grep bin/lsphp

    Comment


    • #3
      Thank you. I like this way to track running php.

      Comment

      Working...
      X