I do not want to choose a name; all I care about is getting a unique message queue, just as I would use SYSV message queues with IPC_PRIVATE
Well, with POSIX message queues, you need to specify a name, but you do not need to save it and do not allow other users to use the same queue under this name.
IPC_PRIVATE facial expressions
Take that mkstempand tmpfiledo under the hood. Borrow any of the tmp / temp naming algorithms to create something / reasonably_unique, mq_openit is O_CREAT | O_EXCL and then mq_unlinkit. Then, the child worker processes can inherit the message queue descriptor.
. root EUID , , mq_open mq_unlink? .
SOCK_DGRAM socketpair pipe. POSIX — attr.mq_msgsize SO_SNDBUF/SO_RCVBUF PIPE_BUF, mq_notify / (, ) — .