Currently, I tried to prevent an onlytask.php script from running more than once:
onlytask.php
$fp = fopen(\"/tmp/\".\"onlyme.lock\", \"a+\"); if (flock($fp,
You can add an extra check by writing the pid and then check it within file_exist-statement. To secure it even more you can fetch all running applications by "ps fax" end check if this file is in the list.