Gentoo Archives: gentoo-user

From: reader@×××××××.com
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: Grub heartbreaker
Date: Thu, 24 Apr 2008 20:49:57
Message-Id: 87fxtbgeqz.fsf@newsguy.com
In Reply to: Re: [gentoo-user] Grub heartbreaker by Alan McKinnon
1 Alan McKinnon <alan.mckinnon@×××××.com> writes:
2
3 > On Thursday 24 April 2008, reader@×××××××.com wrote:
4 >
5 >> So assuming I've made some mistake in grub.conf I try to boot from
6 >> grub command line.
7 >>
8 >> root = (hd0,0) (which is /dev/sda1 in linux terms)
9 >>
10 >> kernel /kernel-2.6.25-r1
11 >
12 > Nope. Kernel needs a root=<device> parameter. It can't know what is your
13 > root partition, that info is in fstab and fstab is on the root
14 > partition.So you tell it via a parameter
15 >
16
17 [...]
18
19 >> kernel /kernel-2.6.25-r1 root=(hd0)/sda3
20 >>
21 >> Fails
22
23 > Won't work. (hd0) is a grub thing. You need a /dev/sda3 or similar in
24 > there
25
26 I think you are wrong about that. But just a fine point and not
27 central to the problem.
28 For example I know for sure you can use the grub notation at the
29 kernel address like:
30
31 kernel (hd0,0)/kernel-XXXXXX
32
33 At least I know for sure it was possible at one time.. I haven't
34 actully used that notation in grub for quite a while. I do have that
35 notation as the address for the splash image in several working
36 grub.confs. (like splashimage=(hd0,0)/grub/splash.xpm.gz)
37
38
39 [...]
40
41 >
42 >> So reloading the install ISO I mount /mnt/gentoo/boot and edit
43 >> grub.conf to say:
44 >>
45 >> title=kernel-2.6.25-r1
46 >> root (hd0,0)
47 >> kernel /kernel-2.6.25-r1 root=/dev/sda3
48 >>
49 >> That fails
50 >> kernel /kernel-2.6.25-r1 root=/dev/hda3 (Thinking maybe grub
51 >> does not understand sda)
52 >
53 > Nothing to do with grub. It's a kernel boot parameter passed verbatim to
54 > the kernel and needs valid kernel device names.
55 >
56 > What's the error you get? Is (hd0,0) a separate /boot? Does it contain a
57 > file called kernel-2.6.25-r1 at the top level? And you also should have
58 > a "ro" kernel parameter in there
59
60 Using your point from above (but as I've posted, in the actual
61 grub.conf I do have a legitimate kernel device appended.
62
63 The latest attempt brings me to a grub command line as posted so
64 grub.conf didn't work.
65
66 So to give more meaning-full errors I will list my steps and the output
67 below including a screen shot of the kernel-panic error message
68
69 At grub prompt:
70
71 grub> root (hd0.0)
72 (That works and indicates an ext2fs)
73
74 grub> kernel /kernel-2.6.25-r1 root=/dev/sda3
75 (This also works as noted by using completion at `/k<tab>')
76
77 grub> boot
78
79 In the screen shot provided note that it appears grub is expecting an
80 intramfs and only lists those types of devices, rejecting both
81 (hd0,0) and /dev/sda3.
82
83 http://www.jtan.com/~reader/vu/disp.cgi
84
85 > here's a working grub.conf for illustration:
86 >
87 > default 0
88 > timeout 10
89 > splashimage=(hd0,0)/grub/splash.xpm.gz
90 >
91 > title Default
92 > root (hd0,0)
93 > kernel /vmlinuz root=/dev/sda3 ro
94 >
95 > title Gentoo-2.6.25
96 > root (hd0,0)
97 > kernel /vmlinuz-2.6.25-gentoo root=/dev/sda3 ro
98 >
99 > Seems my setup is identical to yours:
100 > /boot on /dev/sda1 aka (hd0,0) to grub
101 > / on /dev/sda3
102 >
103 > Only difference is the "ro" boot parameter, which shouldn't make a
104 > difference - it's there for fsck purposes during start-up.
105
106
107 Yes, I fdisked the `virtual' disk into boot=/dev/sda1 root=/dev/sda3
108
109 > What disk driver and disks do you have? Are you 100% sure you are either
110 > using the new ata driver (everything is an sd) or have scsi/sata disks?
111 > If your disk is IDE with the old driver, it will be an hd and will
112 > require that on the kernel line
113
114 I'm not really sure about all this, its on a brand new gateway laptop
115 running Vista Home Premium on core 2 dua processor T5550
116
117 The system information tool doesn't give the type of harddisk but does
118 shwo goose eggs at a scsi listing... and its very unlikely to be scsi
119 anyway.
120
121 Device manager doesn't do any better. Under Disk drives it just gives
122 the brand (Western Digital) and the model number:
123 WDC WD2500BEVS-22USTO
124
125 I don't think that part number is a scsi part number.
126
127 I don't know any other ways to tell if its Sata or IDE but I think its
128 IDE.
129
130 I did mention in OP that this intall is inside a vmware machine hosted
131 on Vista Home Premium OS. The `virutal' disk is seen as scsi hence
132 the /dev/sda notations.
133
134 (Vmware workstation 6.5)
135 In the vmware harware settings its listed as 12 GB scsi disc.
136
137 My current grub.conf:
138
139 default 0
140 timeout 5
141 splashimage=(hd0,0)/grub/splash.xpm.gz
142
143 title=kernel-2.6.25-r1-0x31a-1280x1024
144 root (hd0,0)
145 kernel /kernel-2.6.25-r1 root=/dev/sda3
146
147 --
148 gentoo-user@l.g.o mailing list

Replies

Subject Author
Re: [gentoo-user] Re: Grub heartbreaker Alan McKinnon <alan.mckinnon@×××××.com>
Re: [gentoo-user] Re: Grub heartbreaker Don Jerman <djerman@×××××.com>