diff options
Diffstat (limited to 'chapter06/pwdgroup.xml')
-rw-r--r-- | chapter06/pwdgroup.xml | 60 |
1 files changed, 0 insertions, 60 deletions
diff --git a/chapter06/pwdgroup.xml b/chapter06/pwdgroup.xml deleted file mode 100644 index c473ff501..000000000 --- a/chapter06/pwdgroup.xml +++ /dev/null @@ -1,60 +0,0 @@ -<sect1 id="ch06-pwdgroup"> -<title>Creating the passwd and group files</title> -<?dbhtml filename="pwdgroup.html" dir="chapter06"?> - -<para>In order for <emphasis>root</emphasis> to be able to login and for the -name "root" to be recognized, there need to be relevant entries in the -<filename>/etc/passwd</filename> and <filename>/etc/group</filename> files.</para> - -<para>Create the <filename>/etc/passwd</filename> file by running the following -command:</para> - -<screen><userinput>cat > /etc/passwd << "EOF"</userinput> -root:x:0:0:root:/root:/bin/bash -<userinput>EOF</userinput></screen> - -<para>The actual password for <emphasis>root</emphasis> (the "x" here is just a -placeholder) will be set later.</para> - -<para>Create the <filename>/etc/group</filename> file by running the following -command:</para> - -<screen><userinput>cat > /etc/group << "EOF"</userinput> -root:x:0: -bin:x:1: -sys:x:2: -kmem:x:3: -tty:x:4: -tape:x:5: -daemon:x:6: -floppy:x:7: -disk:x:8: -lp:x:9: -dialout:x:10: -audio:x:11: -<userinput>EOF</userinput></screen> - -<para>The created groups aren't part of any standard -- they are the groups -that the MAKEDEV script in the next section uses. Besides the group "root", the -LSB (<ulink url="http://www.linuxbase.org"/>) recommends only a group "bin", -with a GID of 1, be present. All other group names and GIDs can be chosen -freely by the user, as well-written packages don't depend on GID numbers but -use the group's name.</para> - -<para>Lastly, we re-login to the chroot environment. User name and group name -resolution will start working immediately after the -<filename>/etc/passwd</filename> and <filename>/etc/group</filename> files are -created, because we installed a full Glibc in Chapter 5. This will get rid of -the <quote>I have no name!</quote> prompt.</para> - -<screen><userinput>exec /tools/bin/bash --login +h</userinput></screen> - -<para>Note the use of the <userinput>+h</userinput> directive. This tells -<userinput>bash</userinput> not to use its internal path hashing. Without this -directive, <userinput>bash</userinput> would remember the paths to binaries it -has executed. Since we want to use our newly compiled binaries as soon as -they are installed, we turn off this function for the duration of this -chapter.</para> - -</sect1> - |