in reply to reliable lockfiles?

If you are going to check the process tree why not simply check if multiple copies of the process are running and die if so. If the lock file is used else where then if this is the only copy running then drop and recreate the lock file.