Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How do we mount a non-standard root point during boot?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
3xkrazy
n00b
n00b


Joined: 27 Nov 2012
Posts: 8

PostPosted: Tue Nov 27, 2012 2:45 am    Post subject: How do we mount a non-standard root point during boot? Reply with quote

Hello Community,

I currently have a nomulitlib profile set up running perfectly with a disk layout as described below:

Code:
#/etc/fstab amd64
/dev/sda3               /               ext4            noatime         0 1
/dev/sda1               /boot           ext2            noauto,noatime  0 2
/dev/sda4               /home           ext4            noatime         0 1
/dev/sda2               none            swap            sw              0 0


I would like to boot from my x86 system that I compiled on /dev/sda4 partion (built on my nomultilib profile while chrooted; Root is at /home/gentoo32 ). The 32 bit kernel and initramfs were then copied to my boot partition (/dev/sda1). I did not install grub (grub-install) while chrooted in the 32bit environment. Its fstab looks like this:
Code:

#/etc/fstab x64
/dev/sda1               /boot                   ext2            noauto,noatime  0 2
/dev/sda4               /gentoo32               ext4            noatime         0 1
/dev/sda2               none                    swap            sw              0 0


My grub.conf (from /dev/sda1) looks like this:
Code:

default 0
timeout 10

title Gentoo Linux 3.5.7 amd64
root (hd0,0)
kernel /boot/kernel-3.5.7-gentoo64 rootfstype=ext4 real_root=/dev/sda3
initrd /boot/initramfs-genkernel-x86_64-3.5.7-gentoo

title Gentoo Linux 3.5.7 x86
root (hd0,0)
kernel /boot/kernel-3.5.7-gentoo32 rootfstype=ext4 real_root=/dev/sda4
initrd /boot/initramfs-genkernel-x86-3.5.7-gentoo


The 32 bit kernel boots, but it complains that my root partition is not a valid. Does anyone know what I did wrong and how I mount gentoo32 as root sucessfully?

Thanks!
Back to top
View user's profile Send private message
3xkrazy
n00b
n00b


Joined: 27 Nov 2012
Posts: 8

PostPosted: Tue Nov 27, 2012 3:18 am    Post subject: Reply with quote

Quote:
I did not install grub (grub-install) while chrooted in the 32bit environment.


I just wanted to add that I'm trying to boot the 32 bit kernel from /dev/sda1, which already has grub-static installed for my amd64 setup.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21595

PostPosted: Tue Nov 27, 2012 11:18 pm    Post subject: Reply with quote

When the kernel mounts root, the root of the filesystem becomes /. You could work around this with an initramfs that chroots into the effective root, but I do not understand why you even want to boot a 32-bit kernel. You have already demonstrated that your 64-bit kernel can run 32-bit code. Running the 32-bit environment in its chroot should be sufficient for any legacy x86 programs you need to run.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum