Expand description
Processes holding a lock file open,
found by device and inode.
What:
Processes holding a lock file open,
found by device and inode:
/proc/<pid>/fd on
Linux,
lsof on macOS,
the Restart Manager on Windows.
Why:
An open descriptor proves a live owner.
Matching by device and inode,
never by path text,
means bind mounts and renamed paths cannot fake or hide a holder.
Processes the scan
cannot read are partial evidence (src/index-lock/index-lock-holders-linux.ts,
-darwin.ts,
-win32.ts).
In TS you’d write (pseudocode):
const evidence = await scanPlatformHolders({ lockPath, lock });Re-exports§
pub use super::index_lock_holder_parsers::LsofProcess;pub use super::index_lock_holder_parsers::matching_holders;pub use super::index_lock_holder_parsers::parse_lsof_fields;pub use super::index_lock_holder_parsers::parse_lsof_number;pub use super::index_lock_holder_parsers::parse_restart_manager_output;
Structs§
- Holder
- What:
One process holding the lock open.
Why:
LockHolderProcess. - Holder
Evidence - What:
The scan mechanism,
its holders,
and what it could not see.
Why:
LockHolderEvidence.
Constants§
- RESTART_
MANAGER_ SCRIPT - The incumbent’s Restart Manager script, byte for byte.
- SILENT_
DENIAL_ NOTE - Partial-evidence note every unprivileged macOS scan carries.
Functions§
- scan_
platform_ holders - What:
Scan for open holders with the host’s mechanism.
Why:
scanPlatformHolders. - scan_
proc_ fd_ holders - What:
Every process other than this one holding a file open,
by device and inode,
through a
proc root.
Why:
scanProcFdHolders; processes are scanned one after another (the incumbent runs 16 at once; the result is the same set).