Skip to content
class method

Process.getsid

(?::Integer pid) -> ::Integer
Process.getsid(pid = nil) → integer

Returns the session ID of the given process ID pid, or of the current process if not given:

Example
Process.getsid                # => 27422
Process.getsid(0)             # => 27422
Process.getsid(Process.pid()) # => 27422

Not available on all platforms.

See also .getrlimit .gid .getpriority .gid= also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0