changingowner.xml 1.0 KB

123456789101112131415161718192021222324
  1. <sect1 id="ch06-changingowner">
  2. <title>Changing ownership of the LFS partition</title>
  3. <?dbhtml filename="changingowner.html" dir="chapter06"?>
  4. <para>Now we're in chroot, it is a good time to change the ownership of
  5. all files and directories that were installed in chapter 5 back to root.
  6. Run the following commands to do so:</para>
  7. <para><screen><userinput>chown 0:0 / /proc &amp;&amp;
  8. chown -R 0:0 /{bin,boot,dev,etc,home,lib,mnt,opt,root,sbin,tmp,usr,var}</userinput></screen></para>
  9. <para>Depending on the filesystem you created on the LFS partition, you may
  10. have a /lost+found directory. If so, run:</para>
  11. <para><screen><userinput>chown 0:0 /lost+found</userinput></screen></para>
  12. <para>These commands will change the ownership of the root partition and
  13. the <filename>/proc</filename> directory to root, plus everything under
  14. the directories mentioned in the second line. In these commands, 0:0 is
  15. used instead of the usual root:root, because the username root can't be
  16. resolved because glibc is not yet installed.</para>
  17. </sect1>