stuck on chroot

Gerard Beekmans gerard at linuxfromscratch.org
Tue Mar 12 10:13:50 PST 2002


On Tue, Mar 12, 2002 at 10:22:08AM -0500, Lewi wrote:
> on the book says to:
> cd $LFS &&
> chroot $LFS bla....bla
> 
> what confusing me that on what user should I tun this command,

As root still. In chapter 5 you changed back to the 'root' user to mount
$LFS/proc - you haven't read any instructions to change to another user, so
you're still root when you're running the chroot command.

> when I entering as root on my red hat system, this command doesn't meant anything(I know that 
> by try to enter cd then my home dir still /root at the top of my filesystem)

If you chroot to your redhat system when you're already in redhat, no it
doesn't do anything no, because you change the / directory with the same.
So it's like opening a new shell instead.

Just make sure that when you run the
	cd $LFS &&
	chroot $LFS blah blah

command, that $LFS is set (run export LFS=/mnt/lfs). Or, just follow
chapter 2's instructions and replace $LFS with /mnt/lfs or /lfs or
whereever you mounted the LFS partition.

-- 
Gerard Beekmans
www.linuxfromscratch.org

-*- If Linux doesn't have the solution, you have the wrong problem -*-
-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-support' in the subject header of the message



More information about the lfs-support mailing list