SETSID(1)
โจ SETSID โจ
okay bestie, quick vibe check: this is setsid, a lil user command from the util-linux fam ๐ and its whole thing is run a program in a new session. yes, that kind of session. no cap.
๐ซถ SYNOPSIS
setsid [options] program [arguments]
๐ธ DESCRIPTION
so like. setsid runs a program in a new session. that's it, that's the job ๐
here's the tea tho, because the way it does that is kinda specific: if the process is already a process group leader, the command calls fork(2) first. if it's not, it just goes ahead and executes a program in the current process โ no fork, no extra steps, straight to business. slay.
and that default behavior? yeah, you can override it with the --fork option. iconic of you to want that.
๐ OPTIONS
-c,--cttyโ set the controlling terminal to the current one. your terminal, your rules ๐-f,--forkโ always create a new process. like, always always. no exceptions, no shortcuts.-w,--waitโ wait for the execution of the program to end, and return the exit status of this program as the exit status ofsetsid. yes, it literally hands you the exit status like a lil gift ๐-h,--helpโ display help text and exit. the classic "just tell me what's up" move.-V,--versionโ display version and exit. flex the numbers, periodt.
๐ฆ AUTHORS
Rick Sladkey <jrs@world.std.com> โ shoutout to the original main character ๐
๐ SEE ALSO
setsid(2) โ the syscall sibling, iykyk ๐ฅ
๐ REPORTING BUGS
found a bug? bestie, don't suffer in silence ๐ญ take it to the issue tracker:
<https://github.com/util-linux/util-linux/issues>
๐ AVAILABILITY
the setsid command is part of the util-linux package, which you can download from the Linux Kernel Archive:
<https://www.kernel.org/pub/linux/utils/util-linux/>
okay that's the whole page, you're all caught up ๐ง and for the cute sign-off: this was util-linux 2.42.4, dated 2026-09-21, and it's giving SETSID(1) energy forever โญ go run something in a new session, you got this ๐
๐ฆ where this page comes from
- arch rolling: util-linux 2.42.4-1 ยท BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause-UC AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND ISC AND LGPL-2.1-or-later AND LicenseRef-PublicDomain
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms