Opened 19 years ago

Closed 19 years ago

#1780 closed defect (fixed)

5.32 Changing Ownership

Reported by: peter Owned by: lfs-book@…
Priority: normal Milestone: 6.2
Component: Book Version: SVN
Severity: normal Keywords:
Cc:

Description

Linux From Scratch
Version SVN-20060414

Better yet, change the ownership of the /tools directory to user root
by running the following command:

chown -R root:root /tools

Question: Is the intention to put all the files under
$LFS/tools as belonging to user root and group root?
If so, this command does not work that way because
/tools is a symbolic link.

From man chown:
       -H     if a command line argument is a symbolic link  to  a   
              directory, traverse it

The following two options will change user:group

chown -RH root:root /tools
or
chown -R root:root $LFS/tools

Below is an example:

[root@lfs lfs-scripts]# ls -l /tools
lrwxrwxrwx  1 root root 14 Apr 20 23:01 /tools -> /mnt/lfs/tools
[root@lfs lfs-scripts]# ls -ld $LFS/tools
drwxr-xr-x  2 lfs root 4096 Apr 20 23:01 /mnt/lfs/tools
[root@lfs lfs-scripts]# chown -R root:root /tools
[root@lfs lfs-scripts]# ls -l /tools
lrwxrwxrwx  1 root root 14 Apr 20 23:01 /tools -> /mnt/lfs/tools
[root@lfs lfs-scripts]# ls -ld $LFS/tools
drwxr-xr-x  2 lfs root 4096 Apr 20 23:01 /mnt/lfs/tools
[root@lfs lfs-scripts]# chown -RH root:root /tools
[root@lfs lfs-scripts]# ls -ld $LFS/tools
drwxr-xr-x  2 root root 4096 Apr 20 23:01 /mnt/lfs/tools
[root@lfs lfs-scripts]#

PFE

Change History (1)

comment:1 by manuel@…, 19 years ago

Milestone: 6.2
Resolution: fixed
Status: newclosed

Fixed in r7565. Thanks.

Note: See TracTickets for help on using tickets.