From dfa490c495a75ea9a613bd653545b442408b100b Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Sun, 9 Oct 2022 12:44:52 +0800 Subject: [PATCH] rust: chapter04: create /opt and chown it to lfs user --- chapter04/addinguser.xml | 2 +- chapter04/creatingminlayout.xml | 2 +- chapter07/changingowner.xml | 2 +- chapter07/creatingdirs.xml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/chapter04/addinguser.xml b/chapter04/addinguser.xml index 7903b5a84..1fb529177 100644 --- a/chapter04/addinguser.xml +++ b/chapter04/addinguser.xml @@ -80,7 +80,7 @@ useradd -s /bin/bash -g lfs -m -k /dev/null lfs all the directories under $LFS by making lfs the owner: -chown -v lfs $LFS/{usr{,/*},lib,var,etc,bin,sbin,tools} +chown -v lfs $LFS/{usr{,/*},lib,var,etc,opt,bin,sbin,tools} case $(uname -m) in x86_64) chown -v lfs $LFS/lib64 ;; esac diff --git a/chapter04/creatingminlayout.xml b/chapter04/creatingminlayout.xml index 6b339344b..a0f7a8d96 100644 --- a/chapter04/creatingminlayout.xml +++ b/chapter04/creatingminlayout.xml @@ -21,7 +21,7 @@ Create the required directory layout by issuing the following commands as root: -mkdir -pv $LFS/{etc,var} $LFS/usr/{bin,lib,sbin} +mkdir -pv $LFS/{etc,opt,var} $LFS/usr/{bin,lib,sbin} for i in bin lib sbin; do ln -sv usr/$i $LFS/$i diff --git a/chapter07/changingowner.xml b/chapter07/changingowner.xml index b412bb278..b7f0b4a5b 100644 --- a/chapter07/changingowner.xml +++ b/chapter07/changingowner.xml @@ -33,7 +33,7 @@ user root by running the following command: -chown -R root:root $LFS/{usr,lib,var,etc,bin,sbin,tools} +chown -R root:root $LFS/{usr,lib,var,etc,opt,bin,sbin,tools} case $(uname -m) in x86_64) chown -R root:root $LFS/lib64 ;; esac diff --git a/chapter07/creatingdirs.xml b/chapter07/creatingdirs.xml index 35a0a9003..afac89537 100644 --- a/chapter07/creatingdirs.xml +++ b/chapter07/creatingdirs.xml @@ -19,7 +19,7 @@ Create some root-level directories that are not in the limited set required in the previous chapters by issuing the following command: -mkdir -pv /{boot,home,mnt,opt,srv} +mkdir -pv /{boot,home,mnt,srv} Create the required set of subdirectories below the root-level by issuing the following commands: