I have a script which checks that some node server process is running or not. I use pidof function, i.e. Code: pidof dziup-server-prod.js As you can see there is full server name with file extension. But for some names I have to use shorter name, because pidof does not find the process. I have this issue with, i.e. Code: quiz3m-server-test.js Pidof finds the process when I put as parameter shorter name like Code: quiz3m-server-tes Below you can see the examples: Code: root@s1:~/skrypty# pidof quiz3m-server-test.js root@s1:~/skrypty# pidof quiz3m-server-test.j root@s1:~/skrypty# pidof quiz3m-server-test root@s1:~/skrypty# pidof quiz3m-server-tes 3945 root@s1:~/skrypty# pidof dziup-server-prod.js 30636 root@s1:~/skrypty# pidof quiz3m-server-prod.js 11807 I don't understand why pidof works this way. I attached screens with more informations. PS Path and name of each server file mentioned above: /var/www/clients/client4/web4/web/tquiz3m/quiz3m-server-test.js /var/www/clients/client30/web88/web/dziup-server-prod.js