[CentOS] Mount USB disk at startup?
Mogens Kjaer
mk at crc.dk
Thu Feb 11 08:44:41 UTC 2010
On 02/11/2010 01:26 AM, Jobst Schmalenbach wrote:
>
> There is a kernel option you can give to solve
> this problem, in /boot/grub/grub.con add to the end
> of the kernel line:
>
> rootdelay Xs
>
> where x is the amounty of time to wait before
> /root is mounted, however this is valid for
> everything else as well.
>
> play with X until you get it right.
I've tried changing grub.conf into:
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title CentOS (2.6.18-164.11.1.el5.centos.plus)
root (hd0,0)
kernel /vmlinuz-2.6.18-164.11.1.el5.centos.plus ro
rootdelay=200 root=LABEL=/
initrd /initrd-2.6.18-164.11.1.el5.centos.plus.img
title CentOS (2.6.18-164.11.1.el5)
root (hd0,0)
kernel /vmlinuz-2.6.18-164.11.1.el5 ro rootdelay=200 root=LABEL=/
initrd /initrd-2.6.18-164.11.1.el5.img
but there's no delay at all (the "kernel" lines may have wrapped,
they are on one line in the file).
The kernel source has:
static unsigned int __initdata root_delay;
static int __init root_delay_setup(char *str)
{
root_delay = simple_strtoul(str, NULL, 0);
return 1;
}
...
__setup("rootdelay=", root_delay_setup);
and later:
if (root_delay) {
printk(KERN_INFO "Waiting %dsec before mounting root
device...\n",
root_delay);
ssleep(root_delay);
}
The message "Waiting 200sec before mounting root device..." is never
printed.
Putting rootdelay= after root= makes no difference.
Strange...
Mogens
--
Mogens Kjaer, Carlsberg A/S, Computer Department
Gamle Carlsberg Vej 10, DK-2500 Valby, Denmark
Phone: +45 33 27 53 25, Mobile: +45 22 12 53 25
Email: mk at crc.dk Homepage: http://www.crc.dk
More information about the CentOS
mailing list