Wiki . Forums . Bugs . Translation . Privacy Policy | Search . Simple . Advanced | Reports . Help | Matrix . 10.x . 11.x . 12.x . 13.x . Future . Recent . Contribs

Bug 6630 - Added new larger HDD to RAID1 array and syncs, but can't boot from drive
Summary: Added new larger HDD to RAID1 array and syncs, but can't boot from drive
Status: CLOSED WONTFIX
Alias: None
Product: SME Server 7.X
Classification: SME Server
Component: Unknown (show other bugs)
Version: 7.5
Hardware: --- ---
: P3 normal
Target Milestone: ---
Assignee: SME Server bug team
QA Contact: SME Server bug team
URL:
Depends on:
Blocks:
 
Reported: 2011-05-25 14:02 CEST by Phil
Modified: 2012-06-25 16:31 CEST (History)
3 users (show)

See Also:
Package: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Phil 2011-05-25 14:02:35 CEST
I manage a SME 7.5 server.  It had two 250gb HDDs synced OK with RAID.  One of the drives (sda) failed and so we decided to get 2 new 500gb drives to upgrade with.

I installed the first 500gb drive (as /dev/sda), went into array manager, and added it to the array which then went and sync'd it successfully.

However, when I removed the 250gb drive, the machine wouldn't boot from the 500gb that had just been synced.  It just hangs at the point that the grub menu should kick in.  I have checked the bios is trying to boot the 500gb correctly.

I re-installed the 250gb again, booted up, and verified that the array is showing full health/sync.  The output of cat /proc/mdstat:
[code]Personalities : [raid1] 
md2 : active raid1 sda2[0] sdb2[1]
      244091520 blocks [2/2] [UU]
      
md1 : active raid1 sda1[0] sdb1[1]
      104320 blocks [2/2] [UU]
      
unused devices: <none>[/code]

The output of fdisk -l
[code]Disk /dev/sda: 500.1 GB, 500106780160 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104384+  fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sda2              13       60801   488279647   fd  Linux raid autodetect

Disk /dev/sdb: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          13      104391   fd  Linux raid autodetect
/dev/sdb2              14       30401   244091610   fd  Linux raid autodetect

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md1 doesn't contain a valid partition table

Disk /dev/md2: 249.9 GB, 249949716480 bytes
2 heads, 4 sectors/track, 61022880 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/dm-0: 247.9 GB, 247900143616 bytes
2 heads, 4 sectors/track, 60522496 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1: 2013 MB, 2013265920 bytes
2 heads, 4 sectors/track, 491520 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/dm-1 doesn't contain a valid partition table[/code]

I'm particularly concerned about the message near the top that says under sda1: "Partition does not end on cylinder boundary"

Does anyone know what this means?  I suspect it may be the cause
Comment 10 chris burnat 2012-06-25 16:31:07 CEST
(In reply to John Crisp from comment #9)
> (In reply to chris burnat from comment #7)
> > Cloning to version 8 based on comments #6.
> > I also have experience similar behaviour with version 8.
> 
> For ref it was cloned to this bug :
> 
> http://bugs.contribs.org/show_bug.cgi?id=6911

Thanks John. This is unlikely to be investigated further or fixed in 7.6.  It should however be investigated for version 8.
Resolving WONTFIX and closing.
Comment 9 John Crisp 2012-06-25 02:49:47 CEST
(In reply to chris burnat from comment #7)
> Cloning to version 8 based on comments #6.
> I also have experience similar behaviour with version 8.

For ref it was cloned to this bug :

http://bugs.contribs.org/show_bug.cgi?id=6911
Comment 8 Ian Wells 2012-06-24 18:21:48 CEST
Are there any further updates on this bug? If not then it will be closed as SME 8 has been released and only critical errors will now be fixed on SME 7. All users are encouraged to upgrade to SME 8.
Comment 7 chris burnat 2012-04-18 18:13:38 CEST
Cloning to version 8 based on comments #6.
I also have experience similar behaviour with version 8.
Comment 6 John Crisp 2012-04-18 10:57:27 CEST
I belive that this bug is in v8b7 

Not sure whether to open a new bug or if this should be moved.

Having noticed this on my own machines when recently messing about I have just done some testing on a virtual machine. See fdisk -l output below.

I installed to a single drive. No error showed in fdisk. I then rebooted with a second drive and via the admin panel told it to add the drive to the array.

Once mirrored I copied the output of fdisk, shutdown, removed sda and added sdc. I then rebooted (I had to change the channel assignment for sdb from 1 to 0 and put sdc on 1 or it would not boot. See error below.)

The error was then replicated to the new drive.


=======================================================================


Initial install with 1 disk

[root@test ~]# fdisk -l

Disk /dev/sda: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104391   fd  Linux raid autodetect
/dev/sda2              14         522     4088542+  fd  Linux raid autodetect

Disk /dev/md2: 4186 MB, 4186570752 bytes
2 heads, 4 sectors/track, 1022112 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

    Device Boot      Start         End      Blocks   Id  System


Added second disk

[root@test ~]# fdisk -l

Disk /dev/sda: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104391   fd  Linux raid autodetect
/dev/sda2              14         522     4088542+  fd  Linux raid autodetect

Disk /dev/sdb: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          13      104384+  fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sdb2              13         522     4088580   fd  Linux raid autodetect

Disk /dev/md2: 4186 MB, 4186570752 bytes
2 heads, 4 sectors/track, 1022112 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

    Device Boot      Start         End      Blocks   Id  System


Remove first drive and then add a third

Note that you have to have the drive on the correct channel for it too boot - if it is on channel 1 and the new drive is on channel 0 it will not boot. Error as follows :

Booting SME Server (2.6.18-274.7.1.el5)

root(hd0,0)
Error 5: Partition table invalid or corrupt
Press any key to continue....

Change channels and reboot with sdb now on channel 0 and sdc on channel 1

Now we have added the 3rd drive via the admin panel and we get this :

[root@test ~]# fdisk -l

Disk /dev/sda: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104384+  fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sda2              13         522     4088580   fd  Linux raid autodetect

Disk /dev/sdb: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          13      104384+  fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sdb2              13         522     4088580   fd  Linux raid autodetect

Disk /dev/md2: 4186 MB, 4186570752 bytes
2 heads, 4 sectors/track, 1022112 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md2 doesn't contain a valid partition table

Disk /dev/md1: 106 MB, 106823680 bytes
2 heads, 4 sectors/track, 26080 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

    Device Boot      Start         End      Blocks   Id  System


=======================================================================


From what I have read briefly, this may be the answer :

http://prefetch.net/blog/index.php/2009/09/12/why-partition-x-does-now-end-on-cylinder-boundary-warnings-dont-matter/

Modern drives use LBA and not CHS.

A test with sfdisk shows that it should be OK. 

=======================================================================

Testing with LBA

[root@test ~]# sfdisk -uS -l /dev/sda

Disk /dev/sda: 522 cylinders, 255 heads, 63 sectors/track
Units = sectors of 512 bytes, counting from 0

   Device Boot    Start       End   #sectors  Id  System
/dev/sda1   *         1    208769     208769  fd  Linux raid autodetect
/dev/sda2        208770   8385929    8177160  fd  Linux raid autodetect
/dev/sda3             0         -          0   0  Empty
/dev/sda4             0         -          0   0  Empty

=======================================================================

I think that the answer is it isn't a problem and is effectively 'log noise' but should be documented somewhere.

However, I don't understand why if I use a straight forward 

sfdisk -d /dev/sda |sfdisk /dev/sdb  

to copy the partions I do not appear to get the error, but I do when I use the admin panel / add_device_to_raid script

B. Rgds
John
Comment 5 chris burnat 2011-06-01 05:04:32 CEST
(In reply to comment #4)
> (In reply to comment #2)
> > I have experienced this kind of unexpected behavious myself on many occasions. 
> 
> Did you report it as a bug every time?
No Charlie. When testing, I usually load a raid1, break it, keep one drive for "master" and use the other for verification. Then nuke this drive and resync the mirror from the "master".  Noticed this a while back, but had other issues at the time. Sorry - slack I know. 
> 
> > It should be documented.
> 
> At first perhaps. But it should be fixed if possible.
Agreed, but the way the wheels are turning at the moment, I would prefer to see the scare resources we have being used to fix major issues (i.e. udev in vs7) and above all to release new ISOs.  

This then should be re-opened, agreed?
And set to normal severity.
Done.
Comment 4 Charlie Brady 2011-06-01 04:14:44 CEST
(In reply to comment #2)
> I have experienced this kind of unexpected behavious myself on many occasions. 

Did you report it as a bug every time?

> It should be documented.

At first perhaps. But it should be fixed if possible.
Comment 3 chris burnat 2011-05-31 21:00:06 CEST
Closing Worksforme, thanks for reporting.
Comment 2 chris burnat 2011-05-31 20:52:59 CEST
I have experienced this kind of unexpected behavious myself on many occasions. 
It should be documented.
Comment 1 Phil 2011-05-26 05:05:47 CEST
(In reply to comment #1)
Ok I was able to get it going.  Here's the steps I did (not sure which one made the difference):

So I had two 500gb drives - drive 1 I had already attempted to sync, drive 2 was still brand new

I connected the single old 250gb HDD as sda on its own and booted up.
I then shutdown, connected the new drive 2 (still untouched) as sdb and booted
Went in to array manager and started the sync of the drive
The drive sync'd successfully
I then did a full reboot with those 2 drives in place (1 original, 1 new)
I then shutdown again, disconnected the original drive, and connected the new drive I'd just sync'd as sda (in place of original)
I booted again with just the one new drive in place, and it booted OK.
I shutdown, and connected the other 500gb drive (the one I had played with already) as sdb
I booted into a live-boot cd, and erased the MBR from sdb, just to be sure
I then booted into SME OK, and was able to add sdb to the array, and sync successfully.
I then did a reboot with both drives in place, and checked RAID health was OK.  
I then shutdown, and disconnected sda, and tested booting from just from sdb (the last sync'd disk) and it booted OK.
I then finally, reconnected both drives and booted OK.  For some reason sdb2 was removed from the array, but I added it back in and sync'd all OK.

So the only thing that I can see that is significantly different from the first attempt is:

1. In the first attempt I added the 1st new drive as sda, while the original drive was left in sdb.  In the 2nd attempt I did it the other way around
2. In the 2nd attempt, I did a full reboot after each sync, and before adding/changing more drives

Hope that helps someone else

Cheers
Phil