1 |
Alan McKinnon wrote: |
2 |
> Apparently, though unproven, at 18:03 on Monday 30 August 2010, Paul Hartman |
3 |
> did opine thusly: |
4 |
> |
5 |
> |
6 |
>> On Fri, Aug 27, 2010 at 9:04 PM, Daniel Pielmeier<billie@g.o> wrote: |
7 |
>> |
8 |
>>> Nikos Chantziaras schrieb am 27.08.2010 18:06: |
9 |
>>> |
10 |
>>>> On 08/27/2010 07:02 PM, J. Roeleveld wrote: |
11 |
>>>> |
12 |
>>>>> Actually, you can: |
13 |
>>>>> http://www.ibm.com/developerworks/linux/library/l-boot-rootfs/index.htm |
14 |
>>>>> l |
15 |
>>>>> |
16 |
>>>>> (Read the section below "Use a label"): |
17 |
>>>>> |
18 |
>>>>> fstab: |
19 |
>>>>> LABEL=ROOT / ext3 defaults 1 1 |
20 |
>>>>> LABEL=BOOT /boot ext3 defaults 1 2 |
21 |
>>>>> LABEL=SWAP swap swap defaults 0 0 |
22 |
>>>>> LABEL=HOME /home ext3 nosuid,auto 1 2 |
23 |
>>>>> |
24 |
>>>> This syntax never worked here. Always resulted in an unbootable system. |
25 |
>>>> Only the /dev/disk/by-label/ syntax works reliably. |
26 |
>>>> |
27 |
>>> Afaik if you are using GRUB LEGACY (0.97) and want to use LABEL/UUID in |
28 |
>>> your grub.conf/menu.lst you also need an initrd. I think with GRUB 2 |
29 |
>>> (1.98) it is possible without. You don't need an initrd for LABEL/UUID |
30 |
>>> in /etc/fstab for both cases. |
31 |
>>> |
32 |
>> FWIW I'm using sys-boot/grub-0.97-r10 with GPT, labeled partitions and |
33 |
>> no initrd. My kernel has EFI_PARTITION compiled in (no module). |
34 |
>> |
35 |
>> My fstab looks like this: |
36 |
>> |
37 |
>> LABEL=swap none swap sw 0 0 |
38 |
>> LABEL=boot /boot ext2 defaults,noatime 1 2 |
39 |
>> LABEL=root / ext4 defaults,noatime 0 1 |
40 |
>> LABEL=home /home ext4 defaults,noatime 0 1 |
41 |
>> |
42 |
>> My kernel boot commandline still specified root by device name |
43 |
>> /dev/sda2 but otherwise my system works normally so far. :) |
44 |
>> |
45 |
> Don't listen to nay-sayers. Your fstab will work just fine and there's nothing |
46 |
> wrong with it. |
47 |
> |
48 |
> The LABEL= sysntax has also worked for years and years now on all grub- |
49 |
> supported filesystems that support volume labels. I don't know where a |
50 |
> previous poster got the idea from that it is not supported, or you need an |
51 |
> initrd - I have never used an initrd on Gentoo and have used that syntax since |
52 |
> forever. |
53 |
> |
54 |
> Similar for claims of unreliability by someone else. The only cause I can |
55 |
> think of is using weird grub patches or some combination of insane flags. |
56 |
> |
57 |
> |
58 |
|
59 |
So I don't have to have the complete path in fstab like this: |
60 |
|
61 |
/dev/disk/by-label/boot /boot ext2 noatime 1 2 |
62 |
/dev/disk/by-label/root / reiserfs defaults 0 1 |
63 |
/dev/disk/by-label/swap none swap sw 0 0 |
64 |
/dev/disk/by-label/portage /usr/portage ext3 defaults 0 1 |
65 |
/dev/disk/by-label/home /home reiserfs defaults 1 1 |
66 |
|
67 |
Can you post a grub.conf file that uses labels? Sort of a example to |
68 |
look at and go by. |
69 |
|
70 |
Dale |
71 |
|
72 |
:-) :-) |