LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-16-2014, 11:47 AM   #1
enorbet
LQ Guru
 
Registered: Jun 2003
Location: Virginia
Distribution: Slackware = Main OpSys
Posts: 5,063

Rep: Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699
SCSI Drive Labels and Lilo (w/ wailing and gnashing of teeth)


Hello
OK I've googled around and found an LQ thread which linked Volume Labels and I commonly label all the important partitions (but haven't used devlabel) and I agree that

Quote:
Originally Posted by tldp-Partition How To
2.1.2. Name Assignment

Under (Sun) Solaris and (SGI) IRIX, the device name given to a SCSI drive has some relationship to where you plug it in. Under linux, there is only wailing and gnashing of teeth.
with the caveat that now that there are mobos with different versions of SATA on the same board, this is even worse.

Since I have been engaging in some of said gnashing due to the facts that

1) I do NOT want to use UUID
2) I do NOT want to use an initrd
3) I prefer to NOT use Grub, but rather continue with Lilo
and,
4)The LQ thread said initrd was needed even when using Drive Labels.

So before I grind them to nubs, does anyone know if initrd is indeed required for Drive Labels (I can't find a definitive answer) or if there is some way to insure that udev's silliness is overcome and drives/partitions always get the same label, especially SATA drives no matter which port I plug into? (and still meet my above preferences?)

Thank you in advance for any help offered.

Last edited by enorbet; 01-16-2014 at 11:50 AM.
 
Old 01-16-2014, 11:53 AM   #2
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,334

Rep: Reputation: Disabled
There is absolutely no need to use an initrd to designate your partitions by LABEL in /etc/fstab and /etc/lilo.conf.

PS Here is what says "man lilo.conf:"
Code:
 root=<root-device>
              This specifies the device that should be mounted as root.  It may be specified as a global option.   If
              the special name current is used, the root device is set to the device on which the root file system is
              currently mounted. If the root has been changed with  -r , the respective device is used. If the  vari‐
              able  `root'  is omitted, the root device setting contained in the running kernel image is used.  Warn‐
              ing: This can induce to an unbootable system!

              The root filesystem may also be specified by a LABEL= or UUID= directive, as in '/etc/fstab'.  In  this
              case,  the argument to root= must be enclosed in quotation marks, to avoid a syntax error on the second
              equal sign, e.g.:

                   root="LABEL=MyDisk"
                   root="UUID=5472fd8e-9089-4256-bcaa-ceab4f01a439"

              Note:  The command line root= parameter passed to the kernel will be: 'root=LABEL=MyDisk'; i.e.,  with‐
              out  the  quotation  marks. If the root= parameter is passed from the boot time boot: prompt, no quotes
              are used.  The quotes are only there to satisfy the requirements of the  boot-installer  parser,  which
              treats an equal sign as an operator.  The kernel command line parser is very much simpler, and must not
              see any quotation marks.  Simply stated, only use the quotation marks within /etc/lilo.conf.
Now man fstab:
Code:
              Instead  of  giving  the  device explicitly, one may indicate the (ext2 or xfs) filesystem that is to be
              mounted by its UUID or  volume  label  (cf.   e2label(8)  or  xfs_admin(8)),  writing  LABEL=<label>  or
              UUID=<uuid>, e.g., `LABEL=Boot' or `UUID=3e6be9de-8139-11d1-9106-a43f08d823a6'.  This will make the sys‐
              tem more robust: adding or removing a SCSI disk changes the disk device name but not the filesystem vol‐
              ume label


PPS Use 'e2label' or 'tune2fs' to label existing (already formatted) ext2/ext3/ext4 partitions. Use 'xfs_admin' for XFS partitions.

Last edited by Didier Spaier; 01-16-2014 at 12:13 PM. Reason: PS added + PPS added.
 
Old 01-16-2014, 12:53 PM   #3
enorbet
LQ Guru
 
Registered: Jun 2003
Location: Virginia
Distribution: Slackware = Main OpSys
Posts: 5,063

Original Poster
Rep: Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699Reputation: 4699
Thank you Didier. I was up all night and got exhausted by the time I got to trying to comprehend how partition label would overcome udev's disk assignment, other than with an initrd, and I really don't want to head down that road.

Note: I used Clonezilla to clone an SATA-2 drive to a much larger SATA-3 and the port change would not be overcome in UEFI/BIOS by setting it as first boot device. So I am very grateful and still tired LOL but I will do this today.
 
Old 01-16-2014, 01:20 PM   #4
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,334

Rep: Reputation: Disabled
LABEL (as well as UUID) does not overcome the device name (allocated by udev if we use it) but are other metadata linked to the disk partition.

Device name can change. UUID will never change. LABEL will change only if a command is run to change it.

PS I can't see any inconvenience in using the UUID (I do), but use what you're comfortable with.

EDIT. I was wrong, UUID can change, see next post from lecho.

Last edited by Didier Spaier; 01-17-2014 at 03:59 PM. Reason: EDIT added
 
Old 01-17-2014, 03:47 PM   #5
lecho
Member
 
Registered: Jan 2013
Location: Warsaw, Poland
Distribution: Slackware
Posts: 33

Rep: Reputation: Disabled
Just a short comment to
Quote:
Originally Posted by Didier Spaier View Post
...
Device name can change. UUID will never change. LABEL will change only if a command is run to change it.
...
UUID can be changed using e.g. tune2fs (option -U), gparted. Resizing/reformatting of a partition also changes its UUID.
 
1 members found this post helpful.
Old 01-17-2014, 03:56 PM   #6
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,334

Rep: Reputation: Disabled
Quote:
Originally Posted by lecho View Post
Just a short comment to
UUID can be changed using e.g. tune2fs (option -U), gparted. Resizing/reformatting of a partition also changes its UUID.
I stand corrected. I learned something today, thanks lecho

PS I see that you live in Warsaw. Maybe you'd like to join the Polish translation team for slint? (see links in my sig :-)

Last edited by Didier Spaier; 01-17-2014 at 03:59 PM. Reason: PS added.
 
Old 01-17-2014, 04:12 PM   #7
lecho
Member
 
Registered: Jan 2013
Location: Warsaw, Poland
Distribution: Slackware
Posts: 33

Rep: Reputation: Disabled
You're welcome,
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Installing Slackware 14 with LVM, encryption and drive labels. jjthomas Slackware 4 10-29-2012 11:40 PM
Slackware 14.0 - boot from USB ( Labels in fstab and lilo ) ? WiseDraco Slackware 3 10-13-2012 11:20 PM
Drive labels in Fedora not matching BIOS xZeler8 Fedora 2 04-08-2006 05:08 PM
GRUB or LILO boot to SCSI drive on SCSI system w/ IDE card mkl838 Linux - General 1 03-06-2005 09:01 PM
.xinitrc, much wailing and gnashing of teeth Berto Linux - Software 3 08-22-2004 05:11 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:11 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration