On Mon, Nov 12, 2012 at 5:11 PM, Yuan Cao <yuanca...@gmail.com> wrote:
> Message: 5 >> Date: Fri, 09 Nov 2012 16:02:54 -0600 >> From: Bruce Dubbs <bruce.du...@gmail.com> >> Subject: Re: [lfs-support] LFS 7.2 Section 6.4 Chroot Error >> To: LFS Support List <lfs-support@linuxfromscratch.org> >> Message-ID: <509d7d8e.7080...@gmail.com> >> Content-Type: text/plain; charset=ISO-8859-1; format=flowed >> >> Yuan Cao wrote: >> > Hello, >> > >> > I have an error when I tried to execute the first chroot script: >> > >> > chroot "$LFS" /tools/bin/env -i \ >> > HOME=/root \ >> > TERM="$TERM" \ >> > PS1='\u:\w\$ ' \ >> > PATH=/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin \ >> > /tools/bin/bash --login +h >> > >> > When executing it, I encounters the following error: >> > >> > chroot: failed to run command `/tools/bin/env': No such file or >> directory. >> > >> > I have double checked the symlink of /tools and it still targets >> > /mnt/lfs/tools. I also looked over the instructions in 6.1 - 6.3, and I >> > could not find a mention on creating the /tools/bin/env directory. >> > >> > Should I just use mkdir to create a /tools/bin/env directory, or am I >> > missing a step? >> >> You are missing a step. /tools/bin/env is a binary, not a directory. >> Recheck your coreutils installation in Chapter 5. Also, you said you >> checked the symlink, but let us know the output of: >> >> $ ls -l /tools >> $ ls -l /mnt/lfs/tools >> >> -- Bruce >> >> > Output for ls -l /tools & ls -l /mnt/lfs/tools: > > lrwxrwxrwx 1 root root 14 Oct 23 16:04 /tools -> /mnt/lfs/tools > ls: cannot access /mnt/lfs/tools: No such file or directory > > With ls -al /mnt/lfs: > > drwxr-xr-x 5 root root 4096 Nov 9 12:44 . > drwxr-xr-x 4 root root 4096 Oct 26 10:12 .. > drwxr-xr-x 18 root root 4180 Nov 9 18:15 dev > dr-xr-xr-x 177 root root 0 Nov 9 09:34 proc > drwxr-xr-x 13 root root 0 Nov 9 09:34 sys > > > >> > chroot: failed to run command `/tools/bin/env': No such file or >> > directory. >> >> Do this: >> >> readelf -e /tools/bin/env | grep interpreter >> >> >> Output for that is: > > readelf: Error: '/tools/bin/env': No such file. > > Hello, I am still not sure how to solve this problem. Any advice is welcome. I believe the above situation was caused by one or more steps from 5.34 or 6.2, since there is no instructions on having to do something in steps 6.0, 6.1 and 6.3. I do have a backup copy of /mnt/lfs/tools and /mnt/lfs/source. Can I simply move them back into /mnt/lfs? Best Regards, Yuan Cao
-- http://linuxfromscratch.org/mailman/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page