Comments on: pgrep or pkill sometimes do not find process
http://amazing-development.com/archives/2009/10/15/pgrep-or-pkill-do-not-find-process/
ruby, java and the restWed, 17 Jul 2013 11:30:54 +0000hourly1http://wordpress.org/?v=3.4.2By: Frank Spychalski
http://amazing-development.com/archives/2009/10/15/pgrep-or-pkill-do-not-find-process/comment-page-1/#comment-124482
Frank SpychalskiThu, 15 Oct 2009 11:52:55 +0000http://amazing-development.com/?p=415#comment-124482Yes, it makes sense. But I was confused because I used a script which worked fine for $binary_name but failed when I used it for a binary with the -canary suffix.Yes, it makes sense. But I was confused because I used a script which worked fine for $binary_name but failed when I used it for a binary with the -canary suffix.
]]>By: Mike
http://amazing-development.com/archives/2009/10/15/pgrep-or-pkill-do-not-find-process/comment-page-1/#comment-124481
MikeThu, 15 Oct 2009 11:16:32 +0000http://amazing-development.com/?p=415#comment-124481I think only the first 15 characters are saved in kernel space as the process name. For longer comparisons the argv needs to be read and that can be swapped out.
man pkill:
NOTES: The process name used for matching is limited to the 15 characters present in the output of /proc/pid/stat. Use the -f option to match against the complete command line, /proc/pid/cmdline.I think only the first 15 characters are saved in kernel space as the process name. For longer comparisons the argv needs to be read and that can be swapped out.
man pkill:
NOTES: The process name used for matching is limited to the 15 characters present in the output of /proc/pid/stat. Use the -f option to match against the complete command line, /proc/pid/cmdline.