Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Booting Gentoo with kernel flag for different fstab
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
manuel1139
n00b
n00b


Joined: 05 Mar 2008
Posts: 8

PostPosted: Mon Nov 09, 2009 10:13 pm    Post subject: Booting Gentoo with kernel flag for different fstab Reply with quote

Dear Gentoo Users,

I have set up a rather special configuration:

I build a Gentoo machine that may either be bootet physically on the system (default fstab) or via
VMWare in a NFS mount environment (second fstab9 . Now I am looking for a way to select the appropriate
fstab during kernel time. Any ideas? Should initrd work here?

Best Regards,
Maneul
Back to top
View user's profile Send private message
ToeiRei
Veteran
Veteran


Joined: 03 Jan 2005
Posts: 1191
Location: Austria

PostPosted: Tue Nov 10, 2009 7:36 am    Post subject: Reply with quote

You can read the kernel commandline from /proc:

Quote:
yellowstone ~ # cat /proc/cmdline
root=/dev/ram0 real_root=/dev/sdb7 init=/linuxrc dosata doscsi


So you could do an init-script that adjusts the fstab accordingly. If it's done at an early boot stage you could be successful. But I am afraid, you won't be able to change the rootfs that fast because it has to be mounted first to gain access to the file...

Rei
_________________
Please stand by - The mailer daemon is busy burning your messages in hell...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware 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