2006-12-07 00:25:32 +01:00
|
|
|
.\" Rick Sladkey <jrs@world.std.com>
|
|
|
|
.\" In the public domain.
|
2014-07-20 23:15:46 +02:00
|
|
|
.TH SETSID 1 "July 2014" "util-linux" "User Commands"
|
2006-12-07 00:25:32 +01:00
|
|
|
.SH NAME
|
|
|
|
setsid \- run a program in a new session
|
|
|
|
.SH SYNOPSIS
|
2009-07-22 11:29:04 +02:00
|
|
|
.B setsid
|
2014-07-25 14:55:01 +02:00
|
|
|
[options]
|
2009-07-22 11:29:04 +02:00
|
|
|
.I program
|
2014-07-25 14:55:01 +02:00
|
|
|
.RI [ arguments ]
|
2006-12-07 00:25:32 +01:00
|
|
|
.SH DESCRIPTION
|
|
|
|
.B setsid
|
2017-10-10 12:06:09 +02:00
|
|
|
runs a program in a new session. The command calls
|
|
|
|
.BR fork (2)
|
2017-11-08 11:38:26 +01:00
|
|
|
if already a process group leader. Otherwise, it executes a program in the
|
|
|
|
current process. This default behavior is possible to override by
|
|
|
|
the \fB\-\-fork\fR option.
|
2012-03-14 10:07:18 +01:00
|
|
|
.SH OPTIONS
|
|
|
|
.TP
|
2014-07-20 23:15:46 +02:00
|
|
|
.BR \-c , " \-\-ctty"
|
2012-03-14 10:07:18 +01:00
|
|
|
Set the controlling terminal to the current one.
|
2013-07-22 12:56:47 +01:00
|
|
|
.TP
|
2017-11-08 11:38:26 +01:00
|
|
|
.BR \-f , " \-\-fork"
|
|
|
|
Always create a new process.
|
|
|
|
.TP
|
2014-07-20 23:15:46 +02:00
|
|
|
.BR \-w , " \-\-wait"
|
2020-05-19 14:54:07 +02:00
|
|
|
Wait for the execution of the program to end, and return the exit status of
|
|
|
|
this program as the exit status of
|
2013-07-22 12:56:47 +01:00
|
|
|
.BR setsid .
|
2014-07-25 14:55:01 +02:00
|
|
|
.TP
|
|
|
|
.BR \-V , " \-\-version"
|
|
|
|
Display version information and exit.
|
|
|
|
.TP
|
|
|
|
.BR \-h , " \-\-help"
|
|
|
|
Display help text and exit.
|
2020-05-19 14:51:28 +02:00
|
|
|
.SH AUTHORS
|
2006-12-07 00:25:32 +01:00
|
|
|
Rick Sladkey <jrs@world.std.com>
|
2020-05-21 09:28:21 +02:00
|
|
|
.SH SEE ALSO
|
|
|
|
.BR setsid (2)
|
2007-07-03 01:17:04 +02:00
|
|
|
.SH AVAILABILITY
|
2010-11-30 11:41:59 +01:00
|
|
|
The setsid command is part of the util-linux package and is available from
|
2016-12-17 09:06:57 +01:00
|
|
|
https://www.kernel.org/pub/linux/utils/util-linux/.
|