LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 02-26-2010, 12:00 PM   #1
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Rep: Reputation: 0
Unhappy Unable to see directories


Dear all,

I am completely new to LFS. I have got as far as setting up the LFS partitions, creating the user and creating the two directories "source" and "tools", and filled "source" with all the required software. I could see both directories when logged in as user lfs. Everything was ready to go (I thought) to start building the software. Up to this point I had had terminal open all the time. I then logged out and when I logged back in to try and build the first software package lo and behold user lfs can no longer see "source " or "tools". In Dolphin (logged in as root) these directories are visible.

I am guessing this is a permissions problem, but when I look at the directory permissions in Dolphin it says that the user of these is lfs, but the group is root.

Help would be much appreciated.

jackplughd
 
Old 02-26-2010, 12:46 PM   #2
crts
Senior Member
 
Registered: Jan 2010
Posts: 2,020

Rep: Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757
Post the output of the following commands:

Code:
ls -l /
ls -l /tools
ls -l /source
 
Old 02-27-2010, 07:16 AM   #3
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Original Poster
Rep: Reputation: 0
Thanks for the reply crts, below is the output of those commands.

lfs@phoenix:/mnt/lfs$ ls -l /
total 88
drwxr-xr-x 2 root root 4096 Feb 12 10:55 bin
drwxr-xr-x 3 root root 4096 Feb 12 11:00 boot
lrwxrwxrwx 1 root root 11 Feb 12 09:50 cdrom -> media/cdrom
drwxr-xr-x 14 root root 14100 Feb 26 13:50 dev
drwxr-xr-x 112 root root 4096 Feb 27 11:19 etc
drwxr-xr-x 6 root root 4096 Feb 24 14:07 home
drwxr-xr-x 2 root root 4096 Jan 26 2009 initrd
lrwxrwxrwx 1 root root 33 Feb 12 10:56 initrd.img -> boot/initrd.img-2.6.24-27-generic
lrwxrwxrwx 1 root root 33 Feb 12 10:07 initrd.img.old -> boot/initrd.img-2.6.24-23-generic
drwxr-xr-x 17 root root 12288 Feb 13 11:58 lib
drwx------ 2 root root 16384 Dec 28 17:05 lost+found
drwxr-xr-x 5 root root 4096 Feb 26 13:57 media
drwxr-xr-x 5 root root 4096 Feb 13 10:36 mnt
drwxr-xr-x 2 root root 4096 Jan 26 2009 opt
dr-xr-xr-x 128 root root 0 Feb 26 13:49 proc
drwxr-xr-x 17 root root 4096 Feb 26 16:45 root
drwxr-xr-x 2 root root 4096 Feb 12 10:55 sbin
drwxr-xr-x 2 root root 4096 Oct 20 00:05 selinux
drwxr-xr-x 2 root root 4096 Jan 26 2009 srv
drwxr-xr-x 12 root root 0 Feb 26 13:49 sys
drwxrwxrwt 11 root root 4096 Feb 27 07:35 tmp
lrwxrwxrwx 1 root root 14 Jan 20 16:03 tools -> /mnt/lfs/tools
drwxr-xr-x 11 root root 4096 Jan 26 2009 usr
drwxr-xr-x 14 root root 4096 Jan 26 2009 var
lrwxrwxrwx 1 root root 30 Feb 12 10:56 vmlinuz -> boot/vmlinuz-2.6.24-27-generic
lrwxrwxrwx 1 root root 30 Feb 12 10:07 vmlinuz.old -> boot/vmlinuz-2.6.24-23-generic
lfs@phoenix:/mnt/lfs$ ls -l /tools
lrwxrwxrwx 1 root root 14 Jan 20 16:03 /tools -> /mnt/lfs/tools
lfs@phoenix:/mnt/lfs$ ls -l /source
ls: cannot access /source: No such file or directory
lfs@phoenix:/mnt/lfs$


Thanks for the help.

jackplughd
 
Old 02-27-2010, 11:24 AM   #4
crts
Senior Member
 
Registered: Jan 2010
Posts: 2,020

Rep: Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757
Quote:
Originally Posted by jackplughd View Post
Thanks for the reply crts, below is the output of those commands.

lfs@phoenix:/mnt/lfs$ ls -l /
total 88
drwxr-xr-x 2 root root 4096 Feb 12 10:55 bin
drwxr-xr-x 3 root root 4096 Feb 12 11:00 boot
lrwxrwxrwx 1 root root 11 Feb 12 09:50 cdrom -> media/cdrom
drwxr-xr-x 14 root root 14100 Feb 26 13:50 dev
drwxr-xr-x 112 root root 4096 Feb 27 11:19 etc
drwxr-xr-x 6 root root 4096 Feb 24 14:07 home
drwxr-xr-x 2 root root 4096 Jan 26 2009 initrd
lrwxrwxrwx 1 root root 33 Feb 12 10:56 initrd.img -> boot/initrd.img-2.6.24-27-generic
lrwxrwxrwx 1 root root 33 Feb 12 10:07 initrd.img.old -> boot/initrd.img-2.6.24-23-generic
drwxr-xr-x 17 root root 12288 Feb 13 11:58 lib
drwx------ 2 root root 16384 Dec 28 17:05 lost+found
drwxr-xr-x 5 root root 4096 Feb 26 13:57 media
drwxr-xr-x 5 root root 4096 Feb 13 10:36 mnt
drwxr-xr-x 2 root root 4096 Jan 26 2009 opt
dr-xr-xr-x 128 root root 0 Feb 26 13:49 proc
drwxr-xr-x 17 root root 4096 Feb 26 16:45 root
drwxr-xr-x 2 root root 4096 Feb 12 10:55 sbin
drwxr-xr-x 2 root root 4096 Oct 20 00:05 selinux
drwxr-xr-x 2 root root 4096 Jan 26 2009 srv
drwxr-xr-x 12 root root 0 Feb 26 13:49 sys
drwxrwxrwt 11 root root 4096 Feb 27 07:35 tmp
lrwxrwxrwx 1 root root 14 Jan 20 16:03 tools -> /mnt/lfs/tools
drwxr-xr-x 11 root root 4096 Jan 26 2009 usr
drwxr-xr-x 14 root root 4096 Jan 26 2009 var
lrwxrwxrwx 1 root root 30 Feb 12 10:56 vmlinuz -> boot/vmlinuz-2.6.24-27-generic
lrwxrwxrwx 1 root root 30 Feb 12 10:07 vmlinuz.old -> boot/vmlinuz-2.6.24-23-generic
lfs@phoenix:/mnt/lfs$ ls -l /tools
lrwxrwxrwx 1 root root 14 Jan 20 16:03 /tools -> /mnt/lfs/tools
lfs@phoenix:/mnt/lfs$ ls -l /source
ls: cannot access /source: No such file or directory
lfs@phoenix:/mnt/lfs$


Thanks for the help.

jackplughd
Not quiet sure what to make of that. Maybe your build partition is just not properly mounted. Did you mount it
Code:
mount /dev/<your-build-partition> /mnt/lfs
Be sure that you have not accidently mounted it just in /mnt. It must be mounted in /mnt/lfs. Check this by typing the following.

Code:
ls -l /mnt
ls -l /mnt/lfs
Even if the group is root, you should at least be able to see the files. That is, if the read permissions are set correctly for the user-field.
 
Old 03-01-2010, 06:36 AM   #5
Andrew Benton
Senior Member
 
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073

Rep: Reputation: 64
Quote:
Originally Posted by jackplughd View Post
Dear all,

I am completely new to LFS. I have got as far as setting up the LFS partitions, creating the user and creating the two directories "source" and "tools", and filled "source" with all the required software. I could see both directories when logged in as user lfs. Everything was ready to go (I thought) to start building the software. Up to this point I had had terminal open all the time. I then logged out and when I logged back in to try and build the first software package lo and behold user lfs can no longer see "source " or "tools". In Dolphin (logged in as root) these directories are visible.

I am guessing this is a permissions problem, but when I look at the directory permissions in Dolphin it says that the user of these is lfs, but the group is root.

Help would be much appreciated.

jackplughd
What do you mean by "see"? What do you get from the command
Code:
ls -l $LFS/sources
Andy
 
Old 03-02-2010, 02:51 PM   #6
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Original Poster
Rep: Reputation: 0
All,

As i was unable to solve my problems with building the LFS toolchain, I have started again from the begining (reformatted the LFS partition etc).

I am now at the point of wishing to start the toolchain build. I have 2 questions:

Where should I create the dedicated build folder for binutils?

Who should i be logged in as to build the folder?

When i try to create the above as user lfs i am told "permission denied". If i prefix "sudo" to the command i am told "user lfs is not in the sudoers file. This problem will be reported."

I am trying to build LFS 6.5 using Kubuntu 8.04 (Hardy). My machine in a Toshiba Satellite A30, 2.4Ghz with 764MB RAM.

Again, all help gratefully received.

Thanks

jackplughd
 
Old 03-03-2010, 06:02 PM   #7
Thomas8675309
LQ Newbie
 
Registered: Mar 2010
Posts: 1

Rep: Reputation: 0
Quote:
Originally Posted by jackplughd View Post
All,

As i was unable to solve my problems with building the LFS toolchain, I have started again from the begining (reformatted the LFS partition etc).

I am now at the point of wishing to start the toolchain build. I have 2 questions:

Where should I create the dedicated build folder for binutils?
Exactly where the book tells you. See sec. 5.4. Specifically, from the binutils directory that you untarred and cd'ed into, enter the following commands:

Code:
mkdir -v ../binutils-build
cd ../binutils-build
Quote:
Originally Posted by jackplughd View Post
Who should i be logged in as to build the folder?
As user lfs. Make sure you have set up the environment as required under sec. 4.4.

Quote:
Originally Posted by jackplughd View Post
When i try to create the above as user lfs i am told "permission denied". If i prefix "sudo" to the command i am told "user lfs is not in the sudoers file. This problem will be reported."
Did you follow all the instructions in sec. 4.3? In particular, did you enter:

Code:
chown -v lfs $LFS/tools
chown -v lfs $LFS/sources
To check, you can enter:

Code:
ls -lh $LFS/tools $LFS/sources
If lfs is not listed as the owner of all the files in those two directories, than it would appear you didn't enter the two chown commands correctly.

Note that all of the commands in sec. 4.3 must be entered as root. To become root in Kubuntu, you can (as yourself, not as user lfs) enter:
Code:
sudo su -
Cheers.

Tom
 
Old 03-04-2010, 08:07 AM   #8
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Original Poster
Rep: Reputation: 0
Tom,

Thanks for the help.

When I enter the command you suggest, I get the result below:

jack@phoenix:~$ ls -lh $LFS/tools $LFS/sources
/mnt/lfs/sources:
total 259M
-r--r--r-- 1 jack jack 1.3M Mar 1 20:40 autoconf-2.64.tar.bz2
-r--r--r-- 1 jack jack 1.1M Mar 1 20:40 automake-1.11.tar.bz2
-rw-r--r-- 1 jack jack 40K Mar 2 18:10 bash-4.0-fixes-3.patch
-r--r--r-- 1 jack jack 6.0M Mar 1 20:41 bash-4.0.tar.gz
-r--r--r-- 1 jack jack 16M Mar 1 20:41 binutils-2.19.1.tar.bz2
-r--r--r-- 1 jack jack 1.4M Mar 1 20:42 bison-2.4.1.tar.bz2
-r--r--r-- 1 jack jack 822K Mar 1 20:42 bzip2-1.0.5.tar.gz
-rw-r--r-- 1 jack jack 102K Mar 2 18:16 coreutils-7.4-i18n-1.patch
-rw-r--r-- 1 jack jack 4.5K Mar 2 18:17 coreutils-7.4-uname-1.patch
-r--r--r-- 1 jack jack 9.3M Mar 1 20:43 coreutils-7.4.tar.gz
-r--r--r-- 1 jack jack 1.1M Mar 1 20:43 dejagnu-1.4.4.tar.gz
-rw-r--r-- 1 jack jack 18K Mar 2 18:18 diffutils-2.8.1-i18n-1.patch
-r--r--r-- 1 jack jack 762K Mar 1 20:43 diffutils-2.8.1.tar.gz
-r--r--r-- 1 jack jack 4.3M Mar 1 20:44 e2fsprogs-1.41.8.tar.gz
-rw-r--r-- 1 jack jack 6.7K Mar 2 18:19 expect-5.43.0-spawn-1.patch
-rw-r--r-- 1 jack jack 4.1K Mar 2 18:19 expect-5.43.0-tcl_8.5.5_fix-1.patch
-r--r--r-- 1 jack jack 514K Mar 1 20:44 expect-5.43.0.tar.gz
-rw-rw-r-- 1 jack jack 602K May 6 2009 file-5.03.tar.gz
-r--r--r-- 1 jack jack 2.1M Mar 1 20:45 findutils-4.4.2.tar.gz
-rw-r--r-- 1 jack jack 1017 Mar 2 18:20 flex-2.5.35-gcc44-1.patch
-r--r--r-- 1 jack jack 1.2M Mar 1 20:45 flex-2.5.35.tar.bz2
-r--r--r-- 1 jack jack 2.3M Mar 1 20:45 gawk-3.1.7.tar.bz2
-rw-r--r-- 1 jack jack 1.5K Mar 2 18:20 gcc-4.4.1-startfiles_fix-1.patch
-r--r--r-- 1 jack jack 60M Mar 1 20:47 gcc-4.4.1.tar.bz2
-r--r--r-- 1 jack jack 224K Mar 1 20:47 gdbm-1.8.3.tar.gz
-rw-r--r-- 1 jack jack 2.9K Mar 2 18:21 gettext-0.17-upstream_fixes-2.patch
-r--r--r-- 1 jack jack 12M Mar 1 20:47 gettext-0.17.tar.gz
-r--r--r-- 1 jack jack 16M Mar 1 20:48 glibc-2.10.1.tar.bz2
-r--r--r-- 1 jack jack 100K Mar 1 20:48 glibc-libidn-2.10.1.tar.bz2
-r--r--r-- 1 jack jack 1.8M Mar 1 20:48 gmp-4.3.1.tar.bz2
-rw-r--r-- 1 jack jack 27K Mar 2 18:26 grep-2.5.4-debian_fixes-1.patch
-r--r--r-- 1 jack jack 707K Mar 1 20:48 grep-2.5.4.tar.bz2
-r--r--r-- 1 jack jack 3.5M Mar 1 20:49 groff-1.20.1.tar.gz
-rw-r--r-- 1 jack jack 4.8K Mar 2 18:28 grub-0.97-256byte_inode-1.patch
-rw-r--r-- 1 jack jack 28K Mar 2 18:27 grub-0.97-disk_geometry-1.patch
-rw-rw-r-- 1 jack jack 950K May 8 2005 grub-0.97.tar.gz
-r--r--r-- 1 jack jack 452K Mar 1 20:49 gzip-1.3.12.tar.gz
-r--r--r-- 1 jack jack 201K Mar 1 20:49 iana-etc-2.30.tar.bz2
-rw-r--r-- 1 jack jack 5.5K Mar 2 18:29 inetutils-1.6-no_server_man_pages-1.patch
-r--r--r-- 1 jack jack 1.6M Mar 1 20:49 inetutils-1.6.tar.gz
-r--r--r-- 1 jack jack 360K Mar 1 20:49 iproute2-2.6.29-1.tar.bz2
-rw-r--r-- 1 jack jack 13K Mar 2 18:30 kbd-1.15-backspace-1.patch
-r--r--r-- 1 jack jack 1.3M Mar 1 20:50 kbd-1.15.tar.gz
-r--r--r-- 1 jack jack 297K Mar 1 20:50 less-429.tar.gz
-r--r--r-- 1 jack jack 42K Mar 1 20:50 lfs-bootscripts-20090812.tar.bz2
-r--r--r-- 1 jack jack 2.8M Mar 1 20:50 libtool-2.2.6a.tar.gz
-r--r--r-- 1 jack jack 57M Mar 1 20:59 linux-2.6.30.2.tar.bz2
-r--r--r-- 1 jack jack 985K Mar 2 08:25 m4-1.4.13.tar.bz2
-r--r--r-- 1 jack jack 1.1M Mar 2 08:26 make-3.81.tar.bz2
-rw-r--r-- 1 jack jack 825 Mar 2 18:31 man-db-2.5.5-fix_testsuite-1.patch
-r--r--r-- 1 jack jack 1.9M Mar 2 08:26 man-db-2.5.5.tar.gz
-r--r--r-- 1 jack jack 1.1M Mar 2 08:26 man-pages-3.22.tar.bz2
-r--r--r-- 1 jack jack 865K Mar 2 08:26 module-init-tools-3.10.tar.bz2
-r--r--r-- 1 jack jack 1.1M Mar 2 08:26 mpfr-2.4.1.tar.bz2
-rw-r--r-- 1 jack jack 2.4M Nov 3 2008 ncurses-5.7.tar.gz
-rw-r--r-- 1 jack jack 1.7K Mar 2 18:31 patch-2.5.9-fixes-1.patch
-rw-rw-r-- 1 jack jack 198K Jun 1 2004 patch-2.5.9.tar.gz
-rw-r--r-- 1 jack jack 7.1K Mar 2 19:22 perl-5.10.0-consolidated-1.patch
-rw-r--r-- 1 jack jack 15M Mar 2 08:31 perl-5.10.0.tar.gz
-r--r--r-- 1 jack jack 1009K Mar 2 08:32 pkg-config-0.23.tar.gz
-rw-r--r-- 1 jack jack 3.6K Mar 2 19:23 procps-3.2.8-watch_unicode-1.patch
-r--r--r-- 1 jack jack 280K Mar 2 08:32 procps-3.2.8.tar.gz
-r--r--r-- 1 jack jack 304K Mar 2 08:32 psmisc-22.8.tar.gz
-rw-r--r-- 1 jack jack 3.6K Mar 2 19:24 readline-6.0-fixes-1.patch
-r--r--r-- 1 jack jack 2.2M Mar 2 08:33 readline-6.0.tar.gz
-r--r--r-- 1 jack jack 879K Mar 2 08:33 sed-4.2.1.tar.bz2
-rw-r--r-- 1 jack jack 1.8M Jul 24 2009 shadow-4.1.4.2.tar.bz2
-r--r--r-- 1 jack jack 85K Mar 2 08:34 sysklogd-1.5.tar.gz
-rw-r--r-- 1 jack jack 97K Dec 10 2004 sysvinit-2.86.tar.gz
-r--r--r-- 1 jack jack 2.0M Mar 2 08:34 tar-1.22.tar.bz2
-r--r--r-- 1 jack jack 4.3M Mar 2 08:35 tcl8.5.7-src.tar.gz
-r--r--r-- 1 jack jack 2.7M Mar 2 08:35 texinfo-4.13a.tar.gz
-r--r--r-- 1 jack jack 518K Mar 2 08:35 udev-145.tar.bz2
-r--r--r-- 1 jack jack 13K Mar 2 08:35 udev-config-20090523.tar.bz2
-r--r--r-- 1 jack jack 3.4M Mar 2 08:36 util-linux-ng-2.16.tar.bz2
-rw-r--r-- 1 jack jack 827K Mar 2 19:24 vim-7.2-fixes-5.patch
-rw-r--r-- 1 jack jack 1.4M Aug 9 2008 vim-7.2-lang.tar.gz
-rw-r--r-- 1 jack jack 6.9M Sep 6 2008 vim-7.2.tar.bz2
-r--r--r-- 1 jack jack 416K Mar 2 08:36 zlib-1.2.3.tar.bz2

/mnt/lfs/tools:
total 0


When I try and change ownership I get:

root@phoenix:/mnt/lfs# chown -v lfs $LFS/sources
chown: cannot access `/sources': No such file or directory
failed to change ownership of `/sources' to lfs
root@phoenix:/mnt/lfs# chown -v lfs $LFS/tools
ownership of `/tools' retained as lfs
root@phoenix:/mnt/lfs#


In addition, itried the below and got the results shown:

root@phoenix:/mnt/lfs# ls
lost+found sources tools
root@phoenix:/mnt/lfs# cd sources
root@phoenix:/mnt/lfs/sources# ls
autoconf-2.64.tar.bz2 iproute2-2.6.29-1.tar.bz2
automake-1.11.tar.bz2 kbd-1.15-backspace-1.patch
bash-4.0-fixes-3.patch kbd-1.15.tar.gz
bash-4.0.tar.gz less-429.tar.gz
binutils-2.19.1.tar.bz2 lfs-bootscripts-20090812.tar.bz2
bison-2.4.1.tar.bz2 libtool-2.2.6a.tar.gz
bzip2-1.0.5.tar.gz linux-2.6.30.2.tar.bz2
coreutils-7.4-i18n-1.patch m4-1.4.13.tar.bz2
coreutils-7.4-uname-1.patch make-3.81.tar.bz2
coreutils-7.4.tar.gz man-db-2.5.5-fix_testsuite-1.patch
dejagnu-1.4.4.tar.gz man-db-2.5.5.tar.gz
diffutils-2.8.1-i18n-1.patch man-pages-3.22.tar.bz2
diffutils-2.8.1.tar.gz module-init-tools-3.10.tar.bz2
e2fsprogs-1.41.8.tar.gz mpfr-2.4.1.tar.bz2
expect-5.43.0-spawn-1.patch ncurses-5.7.tar.gz
expect-5.43.0-tcl_8.5.5_fix-1.patch patch-2.5.9-fixes-1.patch
expect-5.43.0.tar.gz patch-2.5.9.tar.gz
file-5.03.tar.gz perl-5.10.0-consolidated-1.patch
findutils-4.4.2.tar.gz perl-5.10.0.tar.gz
flex-2.5.35-gcc44-1.patch pkg-config-0.23.tar.gz
flex-2.5.35.tar.bz2 procps-3.2.8-watch_unicode-1.patch
gawk-3.1.7.tar.bz2 procps-3.2.8.tar.gz
gcc-4.4.1-startfiles_fix-1.patch psmisc-22.8.tar.gz
gcc-4.4.1.tar.bz2 readline-6.0-fixes-1.patch
gdbm-1.8.3.tar.gz readline-6.0.tar.gz
gettext-0.17-upstream_fixes-2.patch sed-4.2.1.tar.bz2
gettext-0.17.tar.gz shadow-4.1.4.2.tar.bz2
glibc-2.10.1.tar.bz2 sysklogd-1.5.tar.gz
glibc-libidn-2.10.1.tar.bz2 sysvinit-2.86.tar.gz
gmp-4.3.1.tar.bz2 tar-1.22.tar.bz2
grep-2.5.4-debian_fixes-1.patch tcl8.5.7-src.tar.gz
grep-2.5.4.tar.bz2 texinfo-4.13a.tar.gz
groff-1.20.1.tar.gz udev-145.tar.bz2
grub-0.97-256byte_inode-1.patch udev-config-20090523.tar.bz2
grub-0.97-disk_geometry-1.patch util-linux-ng-2.16.tar.bz2
grub-0.97.tar.gz vim-7.2-fixes-5.patch
gzip-1.3.12.tar.gz vim-7.2-lang.tar.gz
iana-etc-2.30.tar.bz2 vim-7.2.tar.bz2
inetutils-1.6-no_server_man_pages-1.patch zlib-1.2.3.tar.bz2
inetutils-1.6.tar.gz
root@phoenix:/mnt/lfs/sources# ls -lh $LFS/tools $LFS/sources
ls: cannot access /sources: No such file or directory
lrwxrwxrwx 1 root root 14 Jan 20 16:03 /tools -> /mnt/lfs/tools
root@phoenix:/mnt/lfs/sources#



Completely confused.

jackplug
 
Old 03-04-2010, 10:18 AM   #9
crts
Senior Member
 
Registered: Jan 2010
Posts: 2,020

Rep: Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757
Hi,

try the follwing as root:
Code:
chmod 774 /mnt/lfs
chmod 774 /mnt/lfs/sources
Now try changing ownership again:

Code:
chown -R lfs /mnt/lfs/sources
BTW,

Code:
root@phoenix:/mnt/lfs# chown -v lfs $LFS/sources
chown: cannot access `/sources': No such file or directory
failed to change ownership of `/sources' to lfs
This means that LFS is not defined for root. See, $LFS/sources is expanded to /sources, that means LFS is a null-string.
 
Old 03-04-2010, 12:21 PM   #10
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Original Poster
Rep: Reputation: 0
Thanks crts,

This is what occurred with the commands you kindly suggested:



jack@phoenix:~$ sudo su
[sudo] password for jack:
root@phoenix:/home/jack# chmod 774 /mnt/lfs
root@phoenix:/home/jack# chmod 774 /mnt/lfs/sources
root@phoenix:/home/jack# chown -R lfs /mnt/lfs/sources
root@phoenix:/home/jack# exit
exit
jack@phoenix:~$ su lfs
Password:
lfs@phoenix:/home/jack$ cd $LFS
bash: cd: /mnt/lfs: Permission denied
lfs@phoenix:/home/jack$ ls -lh $LFS/tools $LFS/sources
ls: cannot access /mnt/lfs/tools: Permission denied
ls: cannot access /mnt/lfs/sources: Permission denied


I also did this:


root@phoenix:/mnt/lfs# ls -lh $LFS/tools $LFS/sources
ls: cannot access /sources: No such file or directory
lrwxrwxrwx 1 root root 14 Jan 20 16:03 /tools -> /mnt/lfs/tools
root@phoenix:/mnt/lfs# cd..
bash: cd..: command not found
root@phoenix:/mnt/lfs# cd ..
root@phoenix:/mnt# ls -lh /mnt
total 12K
drwxr-xr-x 2 root root 4.0K Jan 28 15:41 binutils-build
drwxr-xr-x 2 root root 4.0K Feb 13 10:36 ipod
drwxrwxr-- 5 root root 4.0K Mar 2 19:27 lfs


Don't worry about the binutils-build directory I am going to delete that one. But lfs is now owned by "root" as you can see, and "tools" is also owned by "root", but "root still can't see "sources"!

regards

jackplug
 
Old 03-04-2010, 12:31 PM   #11
jackplughd
LQ Newbie
 
Registered: Jan 2010
Posts: 22

Original Poster
Rep: Reputation: 0
OK guys,

You can ignore the last post.

Finally user lfs can see both directories. Thanks for nudging me along. Now I can try and build stuff.

I am sure we will speak again!

regards

jackplug
 
Old 03-04-2010, 01:00 PM   #12
crts
Senior Member
 
Registered: Jan 2010
Posts: 2,020

Rep: Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757Reputation: 757
Quote:
root@phoenix:/home/jack# chmod 774 /mnt/lfs
root@phoenix:/home/jack# chmod 774 /mnt/lfs/sources
root@phoenix:/home/jack# chown -R lfs /mnt/lfs/sources
root@phoenix:/home/jack# exit
So chown finally worked. /mnt/lfs/sources directory needs execute permission if you want to do things like chown or cd into that directory. However, you shouldn't have exited here. You are supposed to be root when you switch to user lfs.

Quote:
jack@phoenix:~$ su lfs
That does not work in Ubuntu. AFAIK it should be
Quote:
jack@phoenix:~$ sudo su lfs

Last edited by crts; 03-04-2010 at 01:02 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
rtorrent - unable to write to nfs directories mrclisdue Linux - Software 2 11-13-2008 07:20 AM
Permisions on $LFS Directories unable to create folders cuco76 Linux From Scratch 9 02-02-2007 10:04 PM
Pam_mount: Unable to Umount home directories at logoff MediMania Linux - Networking 0 06-12-2006 10:33 AM
Unable to create directories satimis Linux From Scratch 8 07-02-2005 05:48 AM
root unable to create directories in /home? cpv204 Solaris / OpenSolaris 6 11-25-2003 11:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 04:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration