On Friday 27 August 2010 11:49:00 Dale wrote:
> J. Roeleveld wrote:
> > On Friday 27 August 2010 11:00:58 Jesús J. Guerrero Botella wrote:
> >> 2010/8/27 Nikos Chantziaras<realnc@arcor.de>:
> >>> On 08/27/2010 10:37 AM, Dale wrote:
> >>>> I been putting this off but it looks like the newer kernels are going
> >>>> to push me to changing this real soon. I have a older system, Abit
> >>>> NF7 2.0 motherboard with the older IDE drives. I'm still using the
> >>>> older IDE drivers. This is what I have currently:
> >>>>
> >>>> hda Actual hard drive OS on this
> >>>> hdb Actual hard drive Not in use
> >>>> hdc Actual hard drive home partition
> >>>> hdd DVD burner Duh! It's a burner.
> >>>> sda Actual hard drive connected through a SATA PCI card. Misc stuff.
> >>>
> >>> The advice by the other posters to label your disks is a good one. I'm
> >>> using labels too. Not sure why I didn't think to mention it :P
> >>>
> >>> Applying labels to your filesystems is trivial. Simply use the e2label
> >>> utility (it's in the sys-fs/e2fsprogs package and installed by default,
> >>> so there's nothing new to emerge). For example, if your hda1 is your
> >>>
> >>> root partition and your hda2 your swap, you can label them like this:
> >>> e2label /dev/hda1 GentooRoot
> >>> e2label /dev/hda2 GentooSwap
> >>>
> >>> Note: hda1, not just hda. You are labeling the filesystem on a
> >>> partition, not the whole drive.
> >>>
> >>> After you label all your filesystems, you simply modify your /etc/fstab
> >>> like this:
> >>>
> >>> Before:
> >>> /dev/hda1 / ext4 noatime 0 1
> >>> /dev/hda2 none swap sw 0 0
> >>>
> >>> After:
> >>> /dev/disk/by-label/GentooRoot / ext4 noatime 0 1
> >>> /dev/disk/by-label/GentooSwap none swap sw 0 0
> >>>
> >>> That is, you simply change "/dev/blah" to
> >>> "/dev/disk/by-label/DriveLabel" and that's it.
> >>
> >> Or you can do it by uuid, all the info you need can be picked from this
> >> output:
> >>
> >> $ ls /dev/disk/by-uuid/ -l
> >>
> >> Then just add lines to fstab like this:
> >>
> >> UUID="6ea2b219-0bcc-4c90-9960-82a9659e6d0e" / ext4 noatime 0 1
> >
> > True, except that for mere mortals, Labels are slightly easier to read
> > and understand

> >
> > And that, I find, is less prone to mistakes.
> >
> > --
> > Joost
>
> Hmmm, I use resierfs for my file systems, most of them anyway. I still
> use e2fsprogs to change those?
Nope:
eve ~ # reiserfstune --help
reiserfstune: unrecognized option '--help'
reiserfstune: Usage: reiserfstune [options] device [block-count]
Options:
-j | --journal-device file current journal device
--journal-new-device file new journal device
-o | --journal-new-offset N new journal offset in blocks
-s | --journal-new-size N new journal size in blocks
-t | --trans-max-size N new journal max transaction size in blocks
--no-journal-available current journal is not available
--make-journal-standard new journal to be standard
-b | --add-badblocks file add to bad block list
-B | --badblocks file set the bad block list
-u | --uuid UUID|random set new UUID
-l | --label LABEL set new label
-f | --force force tuning, less confirmations
-V print version and exit
IOW (as example):
reiserfstune -l ROOTDISK /dev/hda1
> Is there a way to boot a Gentoo/Knoppix CD and make it use the PATA
> drivers? That way I can boot it and see exactly how it will name them
> and what drive is what without actually changing anything at all. Is
> there a boot option "noide" or some other switch I can use?
Afraid not.
The naming scheme is, officially, not constant and can change with reboots.
On my server, with hotswap, I get different device-names when I remove a disk
and plug it back in.
Eg. /dev/sdb -> /dev/sdj
(as example)
Don't think you'll have that particular issue, but having these names change
between reboots is possible. Especially if a drive fails and is not found
during boot or a new drive is added.
Not tested, but I believe USB-drives might also get pushed into the mix?
--
Joost