Stale Lockfile Recovery
Execution Modes
- •Manual runbook: follow the shell steps below.
- •Executable helper path: run the skill code directly.
Skill helper files:
- •
diagnose.py - •
remediate.py - •
skill.py(exportsdiagnoseandremediate)
Examples:
- •
TARGET_URL=http://127.0.0.1:15000 TARGET_CONTAINER=openhands-gepa-demo python .agents/skills/stale-lockfile/diagnose.py - •
TARGET_URL=http://127.0.0.1:15000 TARGET_CONTAINER=openhands-gepa-demo python .agents/skills/stale-lockfile/remediate.py - •
cd .agents/skills/stale-lockfile && python -c "from skill import diagnose, remediate; print(diagnose()); print(remediate())"
Diagnostic Workflow
- •Verify failure with
curl -i http://127.0.0.1:15000 - •Check
/tmp/service.lockand related lock files - •Check lock owner process if tools are available (
fuser/lsof)
Remediation Workflow
- •Remove stale lock:
rm -f /tmp/service.lock - •Restart service only if still unhealthy
Verification
- •
curl -i http://127.0.0.1:15000 - •Confirm HTTP 200
- •Confirm lock file is absent