Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Gentoo User (http://www.linux-archive.org/gentoo-user/)
-   -   Re enter chroot install (http://www.linux-archive.org/gentoo-user/88248-re-enter-chroot-install.html)

James 05-15-2008 12:56 AM

Re enter chroot install
 
Hello,

I have a installation that did not complete successfully.
I need to re enter the chroot environment, using a
install cd. For argue purposes, let's assume the hard drive
is formatted exactly as the example in the handbook. All I want to
do is emerge an older kernel and compile it. According
to what I glean from the handbook, these are the minimal steps
to re enter the chroot environment after a failed reboot:





# mount /dev/sda3 /mnt/gentoo
# mkdir /mnt/gentoo/boot
# mount /dev/sda1 /mnt/gentoo/boot
# mount -t proc none /mnt/gentoo/proc
# mount -o bind /dev /mnt/gentoo/dev
# chroot /mnt/gentoo /bin/bash
# env-update
# source /etc/profile
# export PS1="(chroot) $PS1"


Anything else I missed?
Any of the above steps that are not necessary?


James

--
gentoo-user@lists.gentoo.org mailing list

"Espen Hustad" 05-15-2008 01:03 AM

Re enter chroot install
 
2008/5/15, James <wireless@tampabay.rr.com>:
Hello,

I have a installation that did not complete successfully.
I need to re enter the chroot environment, using a

install cd.**For argue purposes, let's assume the hard drive
is formatted exactly as the example in the handbook.**All I want to
do is emerge an older kernel and compile it.**According
to what I glean from the handbook, these are the minimal steps

to re enter the chroot environment after a failed reboot:





# mount /dev/sda3 /mnt/gentoo
# mkdir /mnt/gentoo/boot
# mount /dev/sda1 /mnt/gentoo/boot
# mount -t proc none /mnt/gentoo/proc

# mount -o bind /dev /mnt/gentoo/dev
# chroot /mnt/gentoo /bin/bash
# env-update
# source /etc/profile
# export PS1="(chroot) $PS1"


Anything else I missed?
No.
*

Any of the above steps that are not necessary?
mkdir /mnt/gentoo/boot
*

James

--
gentoo-user@lists.gentoo.org mailing list

Robert Bridge 05-15-2008 01:07 AM

Re enter chroot install
 
On Thu, 15 May 2008 00:56:29 +0000 (UTC)
James <wireless@tampabay.rr.com> wrote:
> I have a installation that did not complete successfully.
> I need to re enter the chroot environment, using a
> install cd. For argue purposes, let's assume the hard drive
> is formatted exactly as the example in the handbook. All I want to
> do is emerge an older kernel and compile it. According
> to what I glean from the handbook, these are the minimal steps
> to re enter the chroot environment after a failed reboot:
>
> # mount /dev/sda3 /mnt/gentoo

check...

> # mkdir /mnt/gentoo/boot

shouldn't be needed, you did this the first time right?

> # mount /dev/sda1 /mnt/gentoo/boot
> # mount -t proc none /mnt/gentoo/proc
> # mount -o bind /dev /mnt/gentoo/dev
> # chroot /mnt/gentoo /bin/bash
> # env-update
> # source /etc/profile
> # export PS1="(chroot) $PS1"

check...

> Anything else I missed?

No, that looks about right.

> Any of the above steps that are not necessary?

the mkdir...

Rob.
--
gentoo-user@lists.gentoo.org mailing list

05-15-2008 01:23 AM

Re enter chroot install
 
James <wireless@tampabay.rr.com> writes:

> # mount -o bind /dev /mnt/gentoo/dev

[...]

> Any of the above steps that are not necessary?

Other have commented about the .../boot stuff but in dozens of times
chrooting during all kinds of install situations I've never done
`mount -o bind /dev /mnt/gentoo/dev'

And far as I know it never caused me a problem.

--
gentoo-user@lists.gentoo.org mailing list

James 05-15-2008 12:04 PM

Re enter chroot install
 
<reader <at> newsguy.com> writes:


> > # mount -o bind /dev /mnt/gentoo/dev

> Other have commented about the .../boot stuff but in dozens of times
> chrooting during all kinds of install situations I've never done
> `mount -o bind /dev /mnt/gentoo/dev'

> And far as I know it never caused me a problem.


I got that directly from the current handbook. I'll omit that step.

It's a CF-ide setup. One very cool thing is I can move the CF
to a usb-CF reader and just edit the CF as I like, without
entering chroot... Very nice feature of a CF based Hard drive.


Thanks to all that responded.


James




--
gentoo-user@lists.gentoo.org mailing list

Alex Schuster 05-16-2008 08:46 PM

Re enter chroot install
 
reader@newsguy.com writes:

> James <wireless@tampabay.rr.com> writes:
> > # mount -o bind /dev /mnt/gentoo/dev
>
> [...]
>
> > Any of the above steps that are not necessary?
>
> Other have commented about the .../boot stuff but in dozens of times
> chrooting during all kinds of install situations I've never done
> `mount -o bind /dev /mnt/gentoo/dev'
>
> And far as I know it never caused me a problem.

I assume you have a static /dev setup then, probably not visible after udev
has created new entries. Could you try the mount -o bind stuff and check if
the contents of /dev and /mnt/gentoo/dev differ? Typical devices like
[hs]d[a-d] should be present in both trees, so the chroot /dev will work,
too, at least for most practical purposes, like setting up grub.

On the other hand, my /dev only has two files in it (console and null), the
rest is created by udev. In a chroot, they are gone, and grub would not
work.

Wonko
--
gentoo-user@lists.gentoo.org mailing list


All times are GMT. The time now is 06:00 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.