Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • BOOK/chroot/common/pwdgroup.xml

    r24b004c rdabbced  
    99  <?dbhtml filename="pwdgroup.html"?>
    1010
    11   <title>Creating the passwd and group Files</title>
     11  <title>Creating the passwd, group, and log Files</title>
    1212
    1313  <indexterm zone="ch-chroot-pwdgroup">
    1414    <primary sortas="e-/etc/passwd">/etc/passwd</primary>
    15     <secondary>chroot</secondary>
    1615  </indexterm>
    1716
    1817  <indexterm zone="ch-chroot-pwdgroup">
    1918    <primary sortas="e-/etc/group">/etc/group</primary>
    20     <secondary>chroot</secondary>
     19  </indexterm>
     20
     21  <indexterm zone="ch-chroot-pwdgroup">
     22    <primary sortas="e-/var/run/utmp">/var/run/utmp</primary>
     23  </indexterm>
     24
     25  <indexterm zone="ch-chroot-pwdgroup">
     26    <primary sortas="e-/var/log/btmp">/var/log/btmp</primary>
     27  </indexterm>
     28
     29  <indexterm zone="ch-chroot-pwdgroup">
     30    <primary sortas="e-/var/log/lastlog">/var/log/lastlog</primary>
     31  </indexterm>
     32
     33  <indexterm zone="ch-chroot-pwdgroup">
     34    <primary sortas="e-/var/log/wtmp">/var/log/wtmp</primary>
    2135  </indexterm>
    2236
     
    2438  href="../../boot/common/pwdgroup.xml"
    2539  xpointer="xpointer(//*[@os='a'])"/>
    26 
     40 
    2741  <para>Create the <filename>/etc/passwd</filename> file by running the
    2842  following command:</para>
     
    3044<screen><userinput>cat &gt; /etc/passwd &lt;&lt; "EOF"
    3145<literal>root:x:&uid-root;:&gid-root;:root:/root:/bin/bash</literal>
    32 <literal>bin:x:&uid-bin;:&gid-bin;:/bin:/bin/false</literal>
    33 <literal>daemon:x:&uid-daemon;:&gid-daemon;:/sbin:/bin/false</literal>
    34 <literal>messagebus:x:&uid-messagebus;:&gid-messagebus;:D-Bus Message Daemon User:/dev/null:/bin/false</literal>
    35 <literal>nobody:x:&uid-nobody;:&gid-nogroup;:Unprivileged User:/dev/null:/bin/false</literal>
    3646EOF</userinput></screen>
    3747
     
    6373utmp:x:&gid-utmp;:
    6474usb:x:&gid-usb;:
    65 cdrom:x:&gid-cdrom;:
    66 adm:x:&gid-adm;:
    67 messagebus:x:&gid-messagebus;:
    68 systemd-journal:x:&gid-systemd-journal;:
    69 mail:x:&gid-mail;:
    70 wheel:x:&gid-wheel;:
    71 nogroup:x:&gid-nogroup;:</literal>
     75cdrom:x:&gid-cdrom;:</literal>
    7276EOF</userinput></screen>
    7377
     
    9599  for the duration of the next chapters.</para>
    96100
     101  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
     102  href="../../boot/common/pwdgroup.xml"
     103  xpointer="xpointer(//*[@os='f'])"/>
     104
     105<screen><userinput>touch /var/run/utmp /var/log/{btmp,lastlog,wtmp}
     106chgrp -v utmp /var/run/utmp /var/log/lastlog
     107chmod -v 664 /var/run/utmp /var/log/lastlog
     108chmod -v 600 /var/log/btmp</userinput></screen>
     109
     110  <para>The <filename>/var/run/utmp</filename> file records the users that
     111  are currently logged in. The <filename>/var/log/wtmp</filename> file records
     112  all logins and logouts. The <filename>/var/log/lastlog</filename> file
     113  records when each user last logged in. The <filename>/var/log/btmp</filename>
     114  file records the bad login attempts.</para>
     115
    97116</sect1>
Note: See TracChangeset for help on using the changeset viewer.