systemd-inhibit(1)


NAME

   systemd-inhibit - Execute a program with an inhibition lock taken

SYNOPSIS

   systemd-inhibit [OPTIONS...] [COMMAND] [ARGUMENTS...]

   systemd-inhibit [OPTIONS...] --list

DESCRIPTION

   systemd-inhibit may be used to execute a program with a shutdown,
   sleep, or idle inhibitor lock taken. The lock will be acquired before
   the specified command line is executed and released afterwards.

   Inhibitor locks may be used to block or delay system sleep and shutdown
   requests from the user, as well as automatic idle handling of the OS.
   This is useful to avoid system suspends while an optical disc is being
   recorded, or similar operations that should not be interrupted.

   For more information see the Inhibitor Lock Developer Documentation[1].

OPTIONS

   The following options are understood:

   --what=
       Takes a colon-separated list of one or more operations to inhibit:
       "shutdown", "sleep", "idle", "handle-power-key",
       "handle-suspend-key", "handle-hibernate-key", "handle-lid-switch",
       for inhibiting reboot/power-off/halt/kexec, suspending/hibernating,
       the automatic idle detection, or the low-level handling of the
       power/sleep key and the lid switch, respectively. If omitted,
       defaults to "idle:sleep:shutdown".

   --who=
       Takes a short, human-readable descriptive string for the program
       taking the lock. If not passed, defaults to the command line
       string.

   --why=
       Takes a short, human-readable descriptive string for the reason for
       taking the lock. Defaults to "Unknown reason".

   --mode=
       Takes either "block" or "delay" and describes how the lock is
       applied. If "block" is used (the default), the lock prohibits any
       of the requested operations without time limit, and only privileged
       users may override it. If "delay" is used, the lock can only delay
       the requested operations for a limited time. If the time elapses,
       the lock is ignored and the operation executed. The time limit may
       be specified in logind.conf(5). Note that "delay" is only available
       for "sleep" and "shutdown".

   --list
       Lists all active inhibition locks instead of acquiring one.

   -h, --help
       Print a short help text and exit.

   --version
       Print a short version string and exit.

EXIT STATUS

   Returns the exit status of the executed program.

EXAMPLE

       # systemd-inhibit wodim foobar.iso

   This burns the ISO image foobar.iso on a CD using wodim(1), and
   inhibits system sleeping, shutdown and idle while doing so.

SEE ALSO

   systemd(1), logind.conf(5)

NOTES

    1. Inhibitor Lock Developer Documentation
       http://www.freedesktop.org/wiki/Software/systemd/inhibit


More Linux Commands

manpages/XkbFreeGeomKeyAliases.3.html
XkbFreeGeomKeyAliases(3) - Free geometry key aliases........
XkbFreeGeomKeyAliases.3 - Xkb provides a number of functions to allocate and free subcomponents of a keyboard geometry. Use these functions to create or modify

manpages/gimp-2.8.1.html
gimp-2.8(1) an image manipulation and paint program.........
gimp-2.8.1 - GIMP is the GNU Image Manipulation Program. It is used to edit and manipulate images. It can load and save a variety of image formats and can be us

manpages/glTexGen.3gl.html
glTexGen(3gl) - control the generation of texture coordinate
glTexGen selects a texture-coordinate generation function or supplies coefficients for one of the functions. coord names one of the (s, t, r, q) texture coordin

manpages/gnome-options.7.html
gnome-options(7) - Standard Command Line Options for GNOME 2
This manual page describes the command line options, which are common to all Gnome applications. OPTIONS Help options -?, --help Show the applications help mess

manpages/options.n.html
options(n) - Standard options supported by widgets (ManPage)
This manual entry describes the common configuration options supported by widgets in the Tk toolkit. Every widget does not necessarily support every option (see

manpages/opts.3menu.html
opts(3menu) - set and get menu options - Linux manual page
The function set_menu_opts sets all the given menus option bits (menu option bits may be logically-ORed together). The function menu_opts_on turns on the given

manpages/gmtime.3.html
gmtime(3) - transform date and time to broken-down time or A
The ctime(), gmtime() and localtime() functions all take an argument of data type time_t, which represents calendar time. When interpreted as an absolute time v

manpages/snmpwalk.1.html
snmpwalk(1) - retrieve a subtree of management values using
snmpwalk is an SNMP application that uses SNMP GETNEXT requests to query a network entity for a tree of information. An object identifier (OID) may be given on

manpages/xawtvrc.5.html
xawtvrc(5) (File formats - Linux man page).................
xawtvrc is the config file originally used by xawtv only (thats why the name xawtvrc). These days a number of other TV applications / utilities read it too to g

manpages/glColorTableParameterfv.3gl.html
glColorTableParameterfv(3gl) - set color lookup table parame
glColorTableParameter is used to specify the scale factors and bias terms applied to color components when they are loaded into a color table. target indicates

manpages/git-http-push.1.html
git-http-push(1) - Push objects over HTTP/DAV to another rep
Sends missing objects to remote repository, and updates the remote branch. NOTE: This command is temporarily disabled if your libcurl is older than 7.16, as the

manpages/msgcat.1.html
msgcat(1) - combines several message catalogs (Man Page)....
Concatenates and merges the specified PO files. Find messages which are common to two or more of the specified PO files. By using the --more-than option, greate





We can't live, work or learn in freedom unless the software we use is free.