os.getpriority()

os.getpriority(which, who) Get program scheduling priority. The value which is one of PRIO_PROCESS, PRIO_PGRP, or PRIO_USER, and who is interpreted relative to which (a process identifier for PRIO_PROCESS, process group identifier for PRIO_PGRP, and a user ID for PRIO_USER). A zero value for who denotes (respectively) the calling process, the process group of the calling process, or the real user ID of the calling process. Availability: Unix. New in version 3.3.

os.getppid()

os.getppid() Return the parent’s process id. When the parent process has exited, on Unix the id returned is the one of the init process (1), on Windows it is still the same id, which may be already reused by another process. Availability: Unix, Windows. Changed in version 3.2: Added support for Windows.

os.getpid()

os.getpid() Return the current process id.

os.getpgrp()

os.getpgrp() Return the id of the current process group. Availability: Unix.

os.getpgid()

os.getpgid(pid) Return the process group id of the process with process id pid. If pid is 0, the process group id of the current process is returned. Availability: Unix.

os.getlogin()

os.getlogin() Return the name of the user logged in on the controlling terminal of the process. For most purposes, it is more useful to use the environment variables LOGNAME or USERNAME to find out who the user is, or pwd.getpwuid(os.getuid())[0] to get the login name of the current real user id. Availability: Unix, Windows.

os.getloadavg()

os.getloadavg() Return the number of processes in the system run queue averaged over the last 1, 5, and 15 minutes or raises OSError if the load average was unobtainable. Availability: Unix.

os.getgroups()

os.getgroups() Return list of supplemental group ids associated with the current process. Availability: Unix. Note On Mac OS X, getgroups() behavior differs somewhat from other Unix platforms. If the Python interpreter was built with a deployment target of 10.5 or earlier, getgroups() returns the list of effective group ids associated with the current user process; this list is limited to a system-defined number of entries, typically 16, and may be modified by calls to setgroups() if suitab

os.getgrouplist()

os.getgrouplist(user, group) Return list of group ids that user belongs to. If group is not in the list, it is included; typically, group is specified as the group ID field from the password record for user. Availability: Unix. New in version 3.3.

os.getgid()

os.getgid() Return the real group id of the current process. Availability: Unix.