[lfs-support] LFS 7.2 Section 6.4 Chroot Error

Bruce Dubbs bruce.dubbs at gmail.com
Fri Nov 9 14:02:54 PST 2012


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



More information about the lfs-support mailing list