[6d32e7af] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
| 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[cde1482] | 7 | <!ENTITY consolekit-download-http "https://github.com/Consolekit2/ConsoleKit2/releases/download/&consolekit-version;/ConsoleKit2-&consolekit-version;.tar.bz2">
|
---|
[6d32e7af] | 8 | <!ENTITY consolekit-download-ftp " ">
|
---|
[aa9c25d8] | 9 | <!ENTITY consolekit-md5sum "17d31475f9b08969e55ea60750f4f219">
|
---|
| 10 | <!ENTITY consolekit-size "1.1 MB">
|
---|
| 11 | <!ENTITY consolekit-buildsize "18 MB">
|
---|
[c93bd07] | 12 | <!ENTITY consolekit-time "0.2 SBU">
|
---|
[6d32e7af] | 13 | ]>
|
---|
| 14 |
|
---|
[947e6d3] | 15 | <sect1 id="consolekit" xreflabel="ConsoleKit2-&consolekit-version;">
|
---|
[6d32e7af] | 16 | <?dbhtml filename="consolekit.html"?>
|
---|
| 17 |
|
---|
| 18 |
|
---|
[c6e23bd] | 19 | <title>ConsoleKit2-&consolekit-version;</title>
|
---|
[6d32e7af] | 20 |
|
---|
| 21 | <indexterm zone="consolekit">
|
---|
[c6e23bd] | 22 | <primary sortas="a-ConsoleKit">ConsoleKit2</primary>
|
---|
[6d32e7af] | 23 | </indexterm>
|
---|
| 24 |
|
---|
| 25 | <sect2 role="package">
|
---|
| 26 | <title>Introduction to ConsoleKit</title>
|
---|
| 27 |
|
---|
[3261d55d] | 28 | <para>
|
---|
| 29 | The <application>ConsoleKit</application> package is a framework for
|
---|
| 30 | keeping track of the various users, sessions, and seats present on a system.
|
---|
| 31 | It provides a mechanism for software to react to changes of any of these
|
---|
| 32 | items or of any of the metadata associated with them.
|
---|
| 33 | </para>
|
---|
[6d32e7af] | 34 |
|
---|
[16dcd3d6] | 35 | &lfs84_checked;
|
---|
[27e62762] | 36 |
|
---|
[6d32e7af] | 37 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 38 | <itemizedlist spacing="compact">
|
---|
| 39 | <listitem>
|
---|
[3261d55d] | 40 | <para>
|
---|
| 41 | Download (HTTP): <ulink url="&consolekit-download-http;"/>
|
---|
| 42 | </para>
|
---|
[6d32e7af] | 43 | </listitem>
|
---|
| 44 | <listitem>
|
---|
[3261d55d] | 45 | <para>
|
---|
| 46 | Download (FTP): <ulink url="&consolekit-download-ftp;"/>
|
---|
| 47 | </para>
|
---|
[6d32e7af] | 48 | </listitem>
|
---|
| 49 | <listitem>
|
---|
[3261d55d] | 50 | <para>
|
---|
| 51 | Download MD5 sum: &consolekit-md5sum;
|
---|
| 52 | </para>
|
---|
[6d32e7af] | 53 | </listitem>
|
---|
| 54 | <listitem>
|
---|
[3261d55d] | 55 | <para>
|
---|
| 56 | Download size: &consolekit-size;
|
---|
| 57 | </para>
|
---|
[6d32e7af] | 58 | </listitem>
|
---|
| 59 | <listitem>
|
---|
[3261d55d] | 60 | <para>
|
---|
| 61 | Estimated disk space required: &consolekit-buildsize;
|
---|
| 62 | </para>
|
---|
[6d32e7af] | 63 | </listitem>
|
---|
| 64 | <listitem>
|
---|
[3261d55d] | 65 | <para>
|
---|
| 66 | Estimated build time: &consolekit-time;
|
---|
| 67 | </para>
|
---|
[6d32e7af] | 68 | </listitem>
|
---|
| 69 | </itemizedlist>
|
---|
| 70 |
|
---|
| 71 | <bridgehead renderas="sect3">ConsoleKit Dependencies</bridgehead>
|
---|
| 72 |
|
---|
| 73 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[4c2be438] | 74 | <para role="required">
|
---|
| 75 | <xref linkend="dbus-glib"/> and
|
---|
| 76 | <xref linkend="xorg7-lib"/>
|
---|
| 77 | </para>
|
---|
[6d32e7af] | 78 |
|
---|
| 79 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
[4c2be438] | 80 | <para role="recommended">
|
---|
[39ec6c9] | 81 | <xref linkend="linux-pam"/>,
|
---|
| 82 | <xref linkend="polkit"/>, and
|
---|
| 83 | <xref linkend="pm-utils"/> (run-time dependency to allow ConsoleKit2 to
|
---|
| 84 | put the system in <quote>Suspend</quote> or <quote>Hibernation</quote>
|
---|
| 85 | mode)
|
---|
[4c2be438] | 86 | </para>
|
---|
[6d32e7af] | 87 |
|
---|
| 88 | <warning>
|
---|
[3261d55d] | 89 | <para>
|
---|
| 90 | If you intend <emphasis role="strong">NOT</emphasis> to install
|
---|
| 91 | <application>polkit</application>, you will need to manually edit the
|
---|
| 92 | ConsoleKit.conf file to lock down the service. Failure to do so may be a
|
---|
| 93 | huge SECURITY HOLE.
|
---|
| 94 | </para>
|
---|
[6d32e7af] | 95 | </warning>
|
---|
| 96 |
|
---|
| 97 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[4c2be438] | 98 | <para role="optional">
|
---|
| 99 | <xref linkend="xmlto"/>
|
---|
| 100 | </para>
|
---|
[6d32e7af] | 101 |
|
---|
| 102 | <para condition="html" role="usernotes">User Notes:
|
---|
[3261d55d] | 103 | <ulink url="&blfs-wiki;/consolekit"/>
|
---|
| 104 | </para>
|
---|
[6d32e7af] | 105 | </sect2>
|
---|
| 106 |
|
---|
| 107 | <sect2 role="installation">
|
---|
| 108 | <title>Installation of ConsoleKit</title>
|
---|
| 109 |
|
---|
[3261d55d] | 110 | <para>
|
---|
| 111 | Install <application>ConsoleKit</application> by running the following
|
---|
| 112 | commands:
|
---|
| 113 | </para>
|
---|
[6d32e7af] | 114 |
|
---|
[41c36b3] | 115 | <screen><userinput>./configure --prefix=/usr \
|
---|
| 116 | --sysconfdir=/etc \
|
---|
| 117 | --localstatedir=/var \
|
---|
| 118 | --enable-udev-acl \
|
---|
| 119 | --enable-pam-module \
|
---|
| 120 | --enable-polkit \
|
---|
[eca7a58] | 121 | --with-xinitrc-dir=/etc/X11/app-defaults/xinitrc.d \
|
---|
| 122 | --docdir=/usr/share/doc/ConsoleKit-&consolekit-version; \
|
---|
| 123 | --with-systemdsystemunitdir=no &&
|
---|
[6d32e7af] | 124 | make</userinput></screen>
|
---|
| 125 |
|
---|
[3261d55d] | 126 | <para>
|
---|
| 127 | This package does not come with a test suite.
|
---|
| 128 | </para>
|
---|
[6d32e7af] | 129 |
|
---|
[3261d55d] | 130 | <para>
|
---|
| 131 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 132 | </para>
|
---|
[6d32e7af] | 133 |
|
---|
[eca7a58] | 134 | <screen role="root"><userinput>make install &&
|
---|
| 135 |
|
---|
| 136 | mv -v /etc/X11/app-defaults/xinitrc.d/90-consolekit{,.sh}</userinput></screen>
|
---|
[6d32e7af] | 137 |
|
---|
| 138 | </sect2>
|
---|
| 139 |
|
---|
| 140 | <sect2 role="commands">
|
---|
| 141 | <title>Command Explanations</title>
|
---|
| 142 |
|
---|
[3261d55d] | 143 | <para>
|
---|
[0956cf1] | 144 | <parameter>--enable-udev-acl</parameter>: This switch enables building of
|
---|
| 145 | the <command>udev-acl</command> tool, which is used to allow normal users
|
---|
[bd29b3c] | 146 | to access device nodes normally only accessible to
|
---|
| 147 | <systemitem class="username">root</systemitem>.
|
---|
[3261d55d] | 148 | </para>
|
---|
[6d32e7af] | 149 |
|
---|
[3261d55d] | 150 | <para>
|
---|
[0956cf1] | 151 | <parameter>--enable-pam-module</parameter>: This switch enables building
|
---|
| 152 | of the <application>ConsoleKit</application>
|
---|
| 153 | <application>PAM</application> module which is needed for
|
---|
| 154 | <application>ConsoleKit</application> to work correctly with
|
---|
| 155 | <application>PAM</application>. Remove if
|
---|
[eca7a58] | 156 | <application>Linux PAM</application> is
|
---|
[3261d55d] | 157 | <emphasis role="strong">NOT</emphasis> installed.
|
---|
| 158 | </para>
|
---|
| 159 |
|
---|
[c6e23bd] | 160 | <para>
|
---|
| 161 | <parameter>--enable-polkit</parameter>: Enable PolicyKit support.
|
---|
| 162 | </para>
|
---|
| 163 |
|
---|
[eca7a58] | 164 | <para>
|
---|
| 165 | <parameter>--with-xinitrc-dir=/etc/X11/app-defaults/xinitrc.d</parameter>:
|
---|
[d09eb9b] | 166 | Fix the location of the 90-consolekit.sh script. Notice that the script
|
---|
| 167 | has been renamed after installation, because xinitrc only sources script
|
---|
| 168 | names ending with extension <emphasis>.sh</emphasis>.
|
---|
[eca7a58] | 169 | </para>
|
---|
| 170 |
|
---|
[3261d55d] | 171 | <para>
|
---|
[0956cf1] | 172 | <parameter>--with-systemdsystemunitdir=no</parameter>: Disable
|
---|
| 173 | attempting to build with systemd libraries.
|
---|
[3261d55d] | 174 | </para>
|
---|
[a41f643] | 175 |
|
---|
[ee9bff1] | 176 | <para>
|
---|
[0956cf1] | 177 | <option>--enable-docbook-docs</option>: Use this switch if
|
---|
| 178 | <application>xmlto</application> is installed and you wish to
|
---|
[cde1482] | 179 | build the user and API documentation.
|
---|
[ee9bff1] | 180 | </para>
|
---|
[332b9aeb] | 181 |
|
---|
[6d32e7af] | 182 | </sect2>
|
---|
| 183 |
|
---|
| 184 | <sect2 role="configuration">
|
---|
| 185 | <title>Configuring ConsoleKit</title>
|
---|
| 186 |
|
---|
[3261d55d] | 187 | <sect3>
|
---|
| 188 | <title>PAM Module Configuration</title>
|
---|
[0d7900a] | 189 |
|
---|
[3261d55d] | 190 | <para>
|
---|
[2c1a7b7f] | 191 | If you use <application>Linux PAM</application>, it needs to be
|
---|
| 192 | configured to activate <application>ConsoleKit</application> upon user
|
---|
| 193 | login. This can be achieved by editing the
|
---|
| 194 | <filename>/etc/pam.d/system-session</filename> file as the <systemitem
|
---|
| 195 | class="username">root</systemitem> user:
|
---|
[3261d55d] | 196 | </para>
|
---|
[0d7900a] | 197 |
|
---|
[e40b79b6] | 198 | <screen role="root"><userinput>cat >> /etc/pam.d/system-session << "EOF"
|
---|
[2c1a7b7f] | 199 | <literal># Begin ConsoleKit addition
|
---|
[8d86c672] | 200 |
|
---|
| 201 | session optional pam_loginuid.so
|
---|
[d7bfbad] | 202 | session optional pam_ck_connector.so nox11
|
---|
[8d86c672] | 203 |
|
---|
[2c1a7b7f] | 204 | # End ConsoleKit addition</literal>
|
---|
[8d86c672] | 205 | EOF</userinput></screen>
|
---|
[3261d55d] | 206 |
|
---|
| 207 | <para>
|
---|
[bd29b3c] | 208 | You will also need a helper script that creates a file in
|
---|
[3261d55d] | 209 | <filename class="directory">/var/run/console</filename>
|
---|
[bd29b3c] | 210 | named as the currently logged in user and that contains the
|
---|
[128e1b3] | 211 | <application>D-Bus</application> address of the session. You
|
---|
| 212 | can create the script by running the following commands as
|
---|
| 213 | the <systemitem class="username">root</systemitem> user:
|
---|
[3261d55d] | 214 | </para>
|
---|
| 215 |
|
---|
| 216 | <screen role="root"><userinput>cat > /usr/lib/ConsoleKit/run-session.d/pam-foreground-compat.ck << "EOF"
|
---|
[51dfb3e] | 217 | <literal>#!/bin/sh
|
---|
[3261d55d] | 218 | TAGDIR=/var/run/console
|
---|
| 219 |
|
---|
| 220 | [ -n "$CK_SESSION_USER_UID" ] || exit 1
|
---|
| 221 | [ "$CK_SESSION_IS_LOCAL" = "true" ] || exit 0
|
---|
| 222 |
|
---|
| 223 | TAGFILE="$TAGDIR/`getent passwd $CK_SESSION_USER_UID | cut -f 1 -d:`"
|
---|
| 224 |
|
---|
| 225 | if [ "$1" = "session_added" ]; then
|
---|
| 226 | mkdir -p "$TAGDIR"
|
---|
| 227 | echo "$CK_SESSION_ID" >> "$TAGFILE"
|
---|
| 228 | fi
|
---|
| 229 |
|
---|
| 230 | if [ "$1" = "session_removed" ] && [ -e "$TAGFILE" ]; then
|
---|
| 231 | sed -i "\%^$CK_SESSION_ID\$%d" "$TAGFILE"
|
---|
| 232 | [ -s "$TAGFILE" ] || rm -f "$TAGFILE"
|
---|
[51dfb3e] | 233 | fi</literal>
|
---|
[3261d55d] | 234 | EOF
|
---|
[c80a9df] | 235 | chmod -v 755 /usr/lib/ConsoleKit/run-session.d/pam-foreground-compat.ck</userinput></screen>
|
---|
[3261d55d] | 236 |
|
---|
| 237 | <para>
|
---|
| 238 | See /usr/share/doc/ConsoleKit/spec/ConsoleKit.html for more
|
---|
| 239 | configuration.
|
---|
| 240 | </para>
|
---|
[6d32e7af] | 241 |
|
---|
| 242 | </sect3>
|
---|
| 243 |
|
---|
| 244 | </sect2>
|
---|
| 245 |
|
---|
| 246 | <sect2 role="content">
|
---|
| 247 | <title>Contents</title>
|
---|
| 248 |
|
---|
| 249 | <segmentedlist>
|
---|
| 250 | <segtitle>Installed Programs</segtitle>
|
---|
| 251 | <segtitle>Installed Libraries</segtitle>
|
---|
| 252 | <segtitle>Installed Directories</segtitle>
|
---|
| 253 |
|
---|
| 254 | <seglistitem>
|
---|
[3261d55d] | 255 | <seg>
|
---|
[aa9c25d8] | 256 | ck-history,
|
---|
| 257 | ck-launch-session, and
|
---|
| 258 | ck-list-sessions
|
---|
| 259 | <!-- Not listing /usr/libexec:
|
---|
| 260 | ck-collect-session-info ck-get-x11-server-pid udev-acl
|
---|
| 261 | ck-get-x11-display-device ck-remove-directory -->
|
---|
| 262 |
|
---|
[3261d55d] | 263 | </seg>
|
---|
| 264 | <seg>
|
---|
[aa9c25d8] | 265 | libconsolekit.so,
|
---|
| 266 | libck-connector.so, and
|
---|
| 267 | pam_ck_connector.so
|
---|
[3261d55d] | 268 | </seg>
|
---|
| 269 | <seg>
|
---|
[cde1482] | 270 | /etc/ConsoleKit,
|
---|
| 271 | /usr/{include,lib}/ConsoleKit,
|
---|
[aa9c25d8] | 272 | /usr/share/doc/ihtml/ConsoleKit-&consolekit-version;, and
|
---|
[cde1482] | 273 | /var/{log,run}/ConsoleKit
|
---|
[3261d55d] | 274 | </seg>
|
---|
[6d32e7af] | 275 | </seglistitem>
|
---|
| 276 | </segmentedlist>
|
---|
| 277 |
|
---|
| 278 | <variablelist>
|
---|
| 279 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 280 | <?dbfo list-presentation="list"?>
|
---|
| 281 | <?dbhtml list-presentation="table"?>
|
---|
| 282 |
|
---|
| 283 | <varlistentry id="ck-history">
|
---|
| 284 | <term><command>ck-history</command></term>
|
---|
| 285 | <listitem>
|
---|
[c2de366] | 286 | <para>is a utility that provides information from the ConsoleKit
|
---|
| 287 | database about what users have logged into the system.</para>
|
---|
[6d32e7af] | 288 | <indexterm zone="consolekit ck-history">
|
---|
| 289 | <primary sortas="b-ck-history">ck-history</primary>
|
---|
| 290 | </indexterm>
|
---|
| 291 | </listitem>
|
---|
| 292 | </varlistentry>
|
---|
| 293 |
|
---|
| 294 | <varlistentry id="ck-launch-session">
|
---|
| 295 | <term><command>ck-launch-session</command></term>
|
---|
| 296 | <listitem>
|
---|
[c2de366] | 297 | <para>is a utility for starting a command in its own ConsoleKit
|
---|
| 298 | session.
|
---|
| 299 | </para>
|
---|
[6d32e7af] | 300 | <indexterm zone="consolekit ck-launch-session">
|
---|
| 301 | <primary sortas="b-ck-launch-session">ck-launch-session</primary>
|
---|
| 302 | </indexterm>
|
---|
| 303 | </listitem>
|
---|
| 304 | </varlistentry>
|
---|
| 305 |
|
---|
| 306 | <varlistentry id="ck-list-sessions">
|
---|
| 307 | <term><command>ck-list-sessions</command></term>
|
---|
| 308 | <listitem>
|
---|
[7715803] | 309 | <para>list sessions with respective properties. Also good for
|
---|
| 310 | debugging purposes.</para>
|
---|
[6d32e7af] | 311 | <indexterm zone="consolekit ck-list-sessions">
|
---|
| 312 | <primary sortas="b-ck-list-sessions">ck-list-sessions</primary>
|
---|
| 313 | </indexterm>
|
---|
| 314 | </listitem>
|
---|
| 315 | </varlistentry>
|
---|
[c2de366] | 316 |
|
---|
[6d32e7af] | 317 | <varlistentry id="ck-log-system-restart">
|
---|
| 318 | <term><command>ck-log-system-restart</command></term>
|
---|
| 319 | <listitem>
|
---|
[c2de366] | 320 | <para>write system restart to log.</para>
|
---|
[6d32e7af] | 321 | <indexterm zone="consolekit ck-log-system-restart">
|
---|
| 322 | <primary sortas="b-ck-log-system-restart">ck-log-system-restart</primary>
|
---|
| 323 | </indexterm>
|
---|
| 324 | </listitem>
|
---|
| 325 | </varlistentry>
|
---|
| 326 |
|
---|
| 327 | <varlistentry id="ck-log-system-start">
|
---|
| 328 | <term><command>ck-log-system-start</command></term>
|
---|
| 329 | <listitem>
|
---|
[c2de366] | 330 | <para>write system start to log.</para>
|
---|
[6d32e7af] | 331 | <indexterm zone="consolekit ck-log-system-start">
|
---|
| 332 | <primary sortas="b-ck-log-system-start">ck-log-system-start</primary>
|
---|
| 333 | </indexterm>
|
---|
| 334 | </listitem>
|
---|
| 335 | </varlistentry>
|
---|
| 336 |
|
---|
| 337 | <varlistentry id="ck-log-system-stop">
|
---|
| 338 | <term><command>ck-log-system-stop</command></term>
|
---|
| 339 | <listitem>
|
---|
[c2de366] | 340 | <para>write system stop to log.</para>
|
---|
[6d32e7af] | 341 | <indexterm zone="consolekit ck-log-system-stop">
|
---|
| 342 | <primary sortas="b-ck-log-system-stop">ck-log-system-stop</primary>
|
---|
| 343 | </indexterm>
|
---|
| 344 | </listitem>
|
---|
| 345 | </varlistentry>
|
---|
| 346 |
|
---|
| 347 | <varlistentry id="console-kit-daemon">
|
---|
| 348 | <term><command>console-kit-daemon</command></term>
|
---|
| 349 | <listitem>
|
---|
| 350 | <para>is the <application>ConsoleKit</application> daemon.</para>
|
---|
| 351 | <indexterm zone="consolekit console-kit-daemon">
|
---|
| 352 | <primary sortas="b-console-kit-daemon">console-kit-daemon</primary>
|
---|
| 353 | </indexterm>
|
---|
| 354 | </listitem>
|
---|
| 355 | </varlistentry>
|
---|
| 356 |
|
---|
[aa9c25d8] | 357 | <!-- Note (Denis): I don't know if theses programs are installed by the
|
---|
| 358 | current version of consolekit.
|
---|
| 359 |
|
---|
| 360 | (Bruce) These are in /usr/libexec and we do not document those.
|
---|
[c2de366] | 361 |
|
---|
[6d32e7af] | 362 | <varlistentry id="ck-collect-session-info">
|
---|
| 363 | <term><command>ck-collect-session-info</command></term>
|
---|
| 364 | <listitem>
|
---|
[c2de366] | 365 | <para>displays session informations about the current session.</para>
|
---|
[6d32e7af] | 366 | <indexterm zone="consolekit ck-collect-session-info">
|
---|
| 367 | <primary sortas="b-ck-collect-session-info">ck-collect-session-info</primary>
|
---|
| 368 | </indexterm>
|
---|
| 369 | </listitem>
|
---|
| 370 | </varlistentry>
|
---|
| 371 |
|
---|
| 372 | <varlistentry id="ck-get-x11-display-device">
|
---|
| 373 | <term><command>ck-get-x11-display-device</command></term>
|
---|
| 374 | <listitem>
|
---|
[c2de366] | 375 | <para>displays the x11 display device of the current session.</para>
|
---|
[6d32e7af] | 376 | <indexterm zone="consolekit ck-get-x11-display-device">
|
---|
| 377 | <primary sortas="b-ck-get-x11-display-device">ck-get-x11-display-device</primary>
|
---|
| 378 | </indexterm>
|
---|
| 379 | </listitem>
|
---|
| 380 | </varlistentry>
|
---|
| 381 |
|
---|
| 382 | <varlistentry id="ck-get-x11-server-pid">
|
---|
| 383 | <term><command>ck-get-x11-server-pid</command></term>
|
---|
| 384 | <listitem>
|
---|
[c2de366] | 385 | <para>displays the x11 server pid of the current session.</para>
|
---|
[6d32e7af] | 386 | <indexterm zone="consolekit ck-get-x11-server-pid">
|
---|
| 387 | <primary sortas="b-ck-get-x11-server-pid">ck-get-x11-server-pid</primary>
|
---|
| 388 | </indexterm>
|
---|
| 389 | </listitem>
|
---|
| 390 | </varlistentry>
|
---|
| 391 |
|
---|
[aa9c25d8] | 392 | also ck-remove-directory udev-acl
|
---|
[6d32e7af] | 393 |
|
---|
| 394 | -->
|
---|
[7715803] | 395 | </variablelist>
|
---|
[6d32e7af] | 396 |
|
---|
| 397 | </sect2>
|
---|
| 398 |
|
---|
| 399 | </sect1>
|
---|