LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 10-24-2012, 05:56 PM   #1
transient
LQ Newbie
 
Registered: Aug 2011
Posts: 17

Rep: Reputation: Disabled
Drive partition labels: why/how do they change, and why are there extra in /dev?


I'm ashamed to even be asking this, but I have to no matter how goofy it is.

I have a server with 8 SDDs in it. I installed CentOS 6.2 using Kickstart. The idea was to only format the first 2 disks and leave the rest as jbod (software requirement). Initially it failed with a "KeyError: /dev/sda" message during drive partitioning, and a colleague of mine suggested I change the bootloader line from "--driveorder=sda,sdb,sdc,etc." to start at sdc. I did, and the installation succeeded.

Now that I'm logged in when I do fdisk -l I see that sda and sdb were actually created and partitioned according to my scheme, so in effect I have sda1 and 2, and sdb1 and 2. The rest of the drives are untouched as I'd wanted. Why did I have to specify a starting point of sdc to successfully install? Why doesn't the partition table start at sdc then; why did it revert to sda?

Also, when I do fdisk -l I notice that the partitions run like this: sda, sdb, sdc, sdd, sde, sdf, sdi, sdj. If I look in /proc/partitions this matches as well. /dev directory and /sys/block have sdg and sdh as well though. Why did the installation skip those two and go to "i"? Are they actually being used for something else? How can I tell?

Thanks.
 
Old 10-24-2012, 07:59 PM   #2
transient
LQ Newbie
 
Registered: Aug 2011
Posts: 17

Original Poster
Rep: Reputation: Disabled
To add, I went ahead and ran two scripts that I would be using for deploying these servers. The first checks for the presence of an OS on the drives to make sure I didn't inadvertently screw with the wrong ones. It returned:

The OS disks:
/dev/sda1 /dev/sdb1 /dev/sda2 /dev/sdb2
-----
The non OS disks:
/dev/sda /dev/sdb /dev/sdc /dev/sdd /dev/sde /dev/sdf /dev/sdg /dev/sdh /dev/sdi /dev/sdj

The second script runs various hdparm commands on the result of ls on /dev. For example:

Quote:
/dev/sdf:
Issuing SECURITY_SET_PASS command, password="pasta", user=user, mode=high
security_password="pasta"

/dev/sdf:
Issuing SECURITY_ERASE command, password="pasta", user=user
security_password="pasta"

/dev/sdg:
Issuing SECURITY_SET_PASS command, password="pasta", user=user, mode=high
SECURITY_SET_PASS: Invalid exchange
security_password="pasta"
and

Quote:
/dev/sdf:
setting max visible sectors to 462997170 (permanent)
max sectors = 462997170/15647024(586072368?), HPA setting seems invalid (buggy kernel device driver?)

/dev/sdg:
setting max visible sectors to 462997170 (permanent)
HDIO_DRIVE_CMD(identify) failed: Invalid exchange
HDIO_DRIVE_CMD(identify) failed: Invalid exchange
This makes me think there must be something actually there, but I don't know what and I'm concerned about continuing this with the remaining servers since I'm not sure what I'm affecting.
 
Old 10-24-2012, 08:21 PM   #3
transient
LQ Newbie
 
Registered: Aug 2011
Posts: 17

Original Poster
Rep: Reputation: Disabled
And to further complicate things...upon reboot /dev/md0, which was using /dev/sda and /dev/sdb, is now using /dev/sda and /dev/sde. Fdisk -l shows sda and sde as the two formatted and partitioned drives as well. Should I now be moving this from the newb forum?
 
Old 10-26-2012, 02:49 PM   #4
transient
LQ Newbie
 
Registered: Aug 2011
Posts: 17

Original Poster
Rep: Reputation: Disabled
I found (I think) that the order in which Linux detects drives during boot determines what labels it uses for each drive, which is why the drive I installed the OS on may be /dev/sda during one session and /dev/sde on another. I'm opening a separate thread to discuss the hdparm output.
 
Old 10-26-2012, 03:08 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,280

Rep: Reputation: 1028Reputation: 1028Reputation: 1028Reputation: 1028Reputation: 1028Reputation: 1028Reputation: 1028Reputation: 1028
Have a read of this for info on your disk naming issues - and how to avoid it.
Can't help with your other thread.
 
  


Reply

Tags
drives, linux, partioning


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] fstab only has labels, not /dev/stuff needed for e2fsck rjo98 Linux - Newbie 10 06-11-2012 08:16 AM
How to change partition labels? mmahendranece Linux - General 2 05-17-2011 10:51 AM
RAID Setup, Hard Drive labels change after reboot! jonez Linux - Hardware 1 05-19-2008 10:10 PM
How do I change the /dev/sdx number of a drive ? Christof999 Linux - Hardware 1 06-08-2007 03:29 PM
Adding Labels To /dev/VolGroup00/LogVol00 bplimpton Linux - Enterprise 2 05-09-2005 11:34 AM


All times are GMT -5. The time now is 01:40 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration