icon Top 9 categories map      RocketAware > man pages >


Tips: Browse or Search all pages for efficient awareness of more than 6000 of the most popular reusable and open source applications, functions, libraries, and FAQs.

The "RKT couplings" below include links to source code, updates, additional information, advice, FAQs, and overviews.


Search all pages


By activity
Professions, Sciences, Humanities, Business, ...

User Interface
Text-based, GUI, Audio, Video, Keyboards, Mouse, Images,...

Text Strings
Conversions, tests, processing, manipulation,...

Integer, Floating point, Matrix, Statistics, Boolean, ...

Algorithms, Memory, Process control, Debugging, ...

Stored Data
Data storage, Integrity, Encryption, Compression, ...

Networks, protocols, Interprocess, Remote, Client Server, ...

Hard World
Timing, Calendar and Clock, Audio, Video, Printer, Controls...

File System
Management, Filtering, File & Directory access, Viewers, ...


RocketLink!--> Man page versions: OpenBSD FreeBSD NetBSD RedHat Solaris Others

SETPGID(2)                OpenBSD Programmer's Manual               SETPGID(2)

     setpgid, setpgrp - set process group

     #include <unistd.h>

     setpgid(pid_t pid, pid_t pgrp);

     setpgrp(pid_t pid, pid_t pgrp);

     setpgid() sets the process group of the specified process pid to the
     specified pgrp. If pid is zero, then the call applies to the current pro-

     If the invoker is not the super-user, then the affected process must have
     the same effective user-id as the invoker or be a descendant of the in-
     voking process.

     setpgid() returns 0 when the operation was successful.  If the request
     failed, -1 is returned and the global variable errno indicates the rea-

     setpgid() will fail and the process group will not be altered if:

     [EACCES]      The value of the pid argument matches the process ID of a
                   child process of the calling process, and the child process
                   has successfully executed one of the exec functions.

     [EINVAL]      The value of the pgrp argument is less than zero.

     [EPERM]       The effective user ID of the requested process is different
                   from that of the caller and the process is not a descendant
                   of the calling process.

     [ESRCH]       The value of the pid argument does not match the process ID
                   of the calling process or of a child process of the calling


     The setpgid() function conforms to IEEE Std1003.1-1988 (``POSIX'').

     setpgrp() is identical to setpgid(), and is retained for calling conven-
     tion compatibility with historical versions of BSD.

OpenBSD 2.6                      June 4, 1993                                1

Source: OpenBSD 2.6 man pages. Copyright: Portions are copyrighted by BERKELEY
SOFTWARE DESIGN, INC., The Regents of the University of California, Massachusetts
Institute of Technology, Free Software Foundation, FreeBSD Inc., and others.

(Corrections, notes, and links courtesy of RocketAware.com)

[Detailed Topics]

[Overview Topics]

Up to: Process Limits: Identity - Process ownership and Identity

RocketLink!--> Man page versions: OpenBSD FreeBSD NetBSD RedHat Solaris Others

Rapid-Links: Search | About | Comments | Submit Path: RocketAware > man pages > setpgid.2/
RocketAware.com is a service of Mib Software
Copyright 1999, Forrest J. Cavalier III. All Rights Reserved.
We welcome submissions and comments