S6-IPCSERVER-SOCKETBINDER(8)
π s6-ipcserver-socketbinder(8) β System Manager's Manual π
okay so bestie, welcome to the s6-ipcserver-socketbinder(8) page from the System Manager's Manual β yes, section 8, Unix-admin main character energy π₯
β¨ NAME β¨
s6-ipcserver-socketbinder β bind a Unix domain socket, then execute a program π«Ά
πΈ SYNOPSIS πΈ
s6-ipcserver-socketbinder [-d | -D] [-b backlog] [-M | -m] [-a perms]
[-B] path prog...
π¦ DESCRIPTION π¦
So s6-ipcserver-socketbinder creates a Unix domain socket and binds it to path. It gets the socket ready to accept connections by calling listen(2) β lowkey iconic behavior π
Then it execs into prog... with the open socket as its standard input. periodt.
The socket is provided non-blocking by default. β¨
s6-ipcserver-socketbinder is part of a set of basic blocks used to build a flexible Unix super-server. It normally should be given a command line crafted to make it execute into s6-ipcserverd(8) to accept connections from clients, or into a program such as s6-applyuidgid(8) to drop privileges before doing so. it's giving modular, reusable, slightly chaotic but in a good way π§
The s6-ipcserver(8) program does exactly this. It implements a full Unix super-server by building a command line starting with s6-ipcserver-socketbinder and ending with s6-ipcserverd(8) followed by the application program, and executing into it. no cap, that's the whole trick π
π OPTIONS π
-dβ Allow instant rebinding to the samepatheven if it has been used not long ago. This is theSO_REUSEADDRflag tosetsockopt(2)and is generally used with server programs. This is the default. Note thatpathwill be deleted if it already exists at program start time. π-Dβ Disallow instant rebinding to the samepath. simple as that π-bbacklog β Set a maximum ofbacklogconnections on the socket β extra connection attempts will rejected by the kernel. The default isSOMAXCONN, i.e. the maximum number allowed by the system. Ifbacklogis0, then the socket will be created, but it will not be listening. okay so-b 0is not a vibe for listening, it's a vibe for "created but not listening" π-Mβ The type of the socket will beSOCK_STREAM. This is the default. π-mβ The type of the socket will beSOCK_DGRAM. Note that by defaultSOCK_DGRAMsockets are not connection-mode, andlisten(2)will fail β so you should always give the-b0option tos6-ipcserver-socketbinderalong with-m. literally do not forget this combo, bestie π
>!-mwithout-b0? the original sayslisten(2)will fail, so that's the warning. take it seriously π > > well, close enough:SOCK_DGRAMplus default connection-mode hopes =listen(2)fail. give it-b0with-m.
-aperms β Create the socket with permissionsperms, which is an octal number from0000to0777. Default is0777, meaning everyone can connect to it.0700means only processes having the same uid as thes6-ipcserver-socketbinderprocess can connect to it. permission check slay π-Bβ The socket will be blocking. The default is nonblocking. okay so-Bis the "blocking mode" switch, and without it you're on nonblocking by default β¨
π SEE ALSO π
s6-accessrules-cdb-from-fs(8)s6-accessrules-fs-from-cdb(8)s6-connlimit(8)s6-ioconnect(8)s6-ipcclient(8)s6-ipcserver(8)s6-ipcserver-access(8)s6-ipcserverd(8)
This man page is ported from the authoritative documentation at: https://skarnet.org/software/s6/s6-ipcserver-socketbinder.html π¦
π AUTHORS π
- Laurent Bercot
- Alexis <flexibeast@gmail.com> (man page port)
mwah π β this page comes from Debian, dated September 29, 2021, with S6-IPCSERVER-SOCKETBINDER(8) in the footer. bye bestie, go bind that socket responsibly π
π¦ where this page comes from
- nixpkgs unstable: s6 2.15.1.0
- nixpkgs unstable: s6-man-pages 2.14.0.1.4
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms