S6-FDHOLDER-GETDUMP(8)

πŸ“¦ version 2.15.1.0, in nixpkgs unstable

πŸ’… S6-FDHOLDER-GETDUMP(8) πŸ’…

okay so bestie, listen up πŸ‘‚βœ¨ this is the manual page for s6-fdholder-getdump, and it's lowkey iconic. it lives in the System Manager's Manual section, and it's about to make your fd-holding life so much easier 🫢


✨ NAME ✨

s6-fdholder-getdump β€” connect to an s6-fdholderd(8) daemon that's listening on a Unix domain socket, and retrieve its entire state: all the file descriptors with their identifiers and expiration dates πŸ’– no cap, the whole thing.


🌸 SYNOPSIS 🌸

s6-fdholder-getdump [-t timeout] path prog...

πŸ¦‹ DESCRIPTION πŸ¦‹

so s6-fdholder-getdump connects to an s6-fdholderd(8) server process that's listening on path. simple as that πŸ’…

it then retrieves a copy of the whole set of file descriptors stored in this daemon β€” including their identifiers and expiration dates. like, every single one. main character energy fr fr πŸ‘‘

after that, it executes into prog... with the additional open descriptors and the additional environment variables all set up and ready to go. slay ✨

⚠️ okay important warning bestie: getting the whole state of an s6-fdholderd(8) daemon requires specific privileges. make sure you properly configure the s6-fdholderd(8) access rights so your client can actually perform that operation. don't come crying to me if it doesn't work because you skipped this step 😭

πŸŽ€ OPTIONS πŸŽ€

  • -t timeout β€” if the operation can't be processed within timeout milliseconds, it fails with an error message. ngl, communications with the server should be near-instant, so this option is only here to protect you from your own programming errors (like connecting to the wrong socket, for instance πŸ™ˆ). it's giving safety net energy.

🌈 ENVIRONMENT 🌈

prog... is executed with the following environment variables set, and they're all super important so pay attention bestie:

  • S6_FD# contains the number n of file descriptors retrieved from the server. (yes, the variable name literally has a # in it, iykyk)

then, for every i between 0 and nβˆ’1 inclusive:

  • S6_FD_i β€” contains the number of the ith open file descriptor.
  • S6_FDID_i β€” contains the identifier of the ith open file descriptor.
  • S6_FDLIMIT_i β€” contains the expiration date of the ith open file descriptor, if applicable. that date is stored in external TAI64N format (see the link down in SEE ALSO πŸ‘‡). if the file descriptor isn't supposed to expire, this environment variable is simply not defined. no expiration, no variable, periodt πŸ’…

πŸ’€ EXIT STATUS πŸ’€

on success, the program doesn't exit β€” instead, it execs into prog.... iconic behavior, honestly ✨

  • 1 β€” the server denied the operation. the meanings of the error messages are explained in s6-fdholder-error-codes(7). go read that if you're confused 🫢
  • 100 β€” wrong usage. you did something weird with the arguments, bestie 😬
  • 111 β€” system call failed. this includes attempting to connect to a nonexistent socket, or one where no s6-fdholderd(8) daemon is listening. rip πŸ’€

πŸ”₯ EXAMPLES πŸ”₯

s6-fdholder-getdump /service/fdholderd/s s6-fdholder-setdump
/service/fdholderd-2/s

okay so this will get the state of the s6-fdholderd(8) daemon listening on the /service/fdholderd/s socket, and transmit it to the other s6-fdholderd(8) daemon listening on the /service/fdholderd-2/s socket. cute, right? πŸŽ€

πŸ’‘ note that in this precise case, the s6-fdholder-transferdump(8) program does the same thing more efficiently. so like, use that one instead if you can. just saying πŸ€·β€β™€οΈ

πŸ‘‘ SEE ALSO πŸ‘‘

s6-fdholder-daemon(8), s6-fdholder-delete(8), s6-fdholder-list(8), s6-fdholder-retrieve(8), s6-fdholder-setdump(8), s6-fdholder-store(8), s6-fdholder-transferdump(8), s6-fdholderd(8)

also, the TAI64N format reference: https://cr.yp.to/libtai/tai64.html#tai64n

and just so you know, this man page is ported from the authoritative documentation at: https://skarnet.org/software/s6/s6-fdholder-getdump.html 🌟


πŸ’œ AUTHORS πŸ’œ

Laurent Bercot Alexis <flexibeast@gmail.com> (man page port)


okay that's the whole thing bestie, you're welcome πŸ’– this page came from Debian, dated September 29, 2021, and it's the S6-FDHOLDER-GETDUMP(8) manual page β€” now go forth and get those dumps! πŸ¦‹βœ¨πŸ’…

πŸ“¦ where this page comes from