On Linux, reads /proc/self/fd and resolves each symlink to identify what the fd points to. Returns a data.frame with one row per open fd; useful for diagnosing the cryptic "file descriptor is too large for select()" failure from parallelly::makeClusterPSOCK().

openFds()

Value

data.frame with columns fd (integer), target (character, with any Linux (deleted) suffix preserved), and bucket (character holder category: "socket", "pipe", "terra scratch", "terra scratch (deleted)", "tif (other)", "vrt", "sqlite", "qs/qs2", "anon_inode", "other file", "unknown").

Details

Returns an empty data.frame on non-Linux systems or if /proc/self/fd is unreadable.

See also

openFdsReport() for a printable summary; fdSelectLimit().