I have a process that fails regularly & sometimes starts duplicate instances..
When I run: ps x |grep -v grep |grep -c \"processname\" I will get: <
ps x |grep -v grep |grep -c \"processname\"
The 'pidof' command will not display pids of shell/perl/python scripts. So to find the process id’s of my Perl script I had to use the -x option i.e. 'pidof -x perlscriptname'