NEWPID(1)

πŸ“¦
version 14build1 Β· 3 versions
, in ubuntu resolute, ubuntu stonking

πŸ’… newpid β€” the manual page, but make it cute

okay bestie, welcome to the newpid manual page (section 1 of the manual, iykyk) β€” she's small, she's powerful, she's gonna put your little command in a whole new PID namespace. let's get into it 🫢


✨ NAME ✨

newpid β€” launch a command in a new PID namespace πŸ’–


🌸 SYNOPSIS 🌸

newpid [-inNu] command

that's it. that's the whole vibe. one command, a lil stack of flags, and a command that gets to live in a brand new world. periodt. ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea: newpid uses the clone(CLONE_NEWPID) syscall to launch a command in a new PID namespace. that means your command gets to be PID 1 in its own lil universe, main character energy fr fr πŸ‘‘

and because nobody wants a /proc that's lying to them, the /proc filesystem gets remounted too β€” so the new process IDs are also visible there. no cap, the numbers actually match now. slay. πŸ’…


πŸŽ€ OPTIONS πŸŽ€

  • -i β€” use CLONE_NEWIPC to run in a new IPC namespace. separate interprocess-communication world, just for you πŸ“
  • -n β€” use CLONE_NEWNET to run in a new network namespace. your own network, your own rules 🌈
  • -N newpidname β€” use CLONE_NEWNET to run in a new network namespace, and join an existing network namespace. the name must start with newpid β€” that's not a suggestion bestie, that's the rule 😭
  • -u β€” use CLONE_NEWUTS to run in a new UTS namespace. hostname go brrr, but separately ✨

πŸ”₯ EXAMPLE πŸ”₯

watch her work, she's literally so iconic:

$ newpid ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
myon         1  0.0  0.0   4080    84 pts/3    S+   12:15   0:00 newpid ps aux
myon         2  0.0  0.0  19984  1316 pts/3    R+   12:15   0:00 ps aux

see how newpid ps aux is PID 1?? that's the whole point, that's the moment, that's the plot twist 🫢

and here's the network namespace one:

$ ./newpid -n ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00

just a lil lonely lo in there. no outside world. peaceful honestly 🧚


πŸ‘‘ SEE ALSO πŸ‘‘

go read these next, bestie, they're the extended universe:


πŸ’œ AUTHOR πŸ’œ

written by Christoph Berg <myon@debian.org> β€” thank you for your service king 🫑


okay and that's a wrap on NEWPID(1) β€” source/version NEWPID(1), dated 2026-01-26. go namespace something, you got this πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ’…

πŸ“¦ where this page comes from