Remove lockfile dependency, add small robust pidfile manager