I'm trying to create a new storage repository on a server that already has 2 old hard disks, set up with hardware RAID 1. It's my first time doing this in Xen Server environment so I wanna be extra careful not to mess up anything or lose the data on old hard disks.

There are 4 3TB Hard disks on this machine, so with raid one I will be having 6TB

I've inserted the two new hard disks to the computer, went to bios's Raid Controller, created a new virtual disk (RAID 1 again), and now I'm ready to create a file system on it and mount it in Citrix Xen Server

First I'd like to know what is the device name, is it sda, sdb, or sdc

When I run fdisk -l to see the currently available drives I see these:

fdisk -l
WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.

Disk /dev/sda: 128.8 GB, 128849018880 bytes
256 heads, 63 sectors/track, 15603 cylinders
Units = cylinders of 16128 * 512 = 8257536 bytes
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       15604   125829119+  ee  EFI GPT

WARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk doesn't support GPT. Use GNU Parted.

Disk /dev/sdb: 2871.1 GB, 2871185637376 bytes
255 heads, 63 sectors/track, 349068 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

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

Disk /dev/sdc: 3000.0 GB, 3000034656256 bytes
255 heads, 63 sectors/track, 364733 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

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

My understanding is that when you do RAID 1, your hard disk is going to be shown as 1 disk to your operating system, since I've added the new hard disks to the drive AFTER the first two were installed, I guess the device name is /dev/sdc

I have data on the old hard disks, I also had a look at /proc/partitions following the instructions here: http://support.citrix.com/article/CTX121313

to see what's going on, it seems like there are three partitions on sda, and sdc has not been partitioned.

cat /proc/partitions
major minor  #blocks  name

   7        0      51240 loop0
   8        0  125829120 sda
   8        1    4193297 sda1
   8        2    4193297 sda2
   8        3  117439471 sda3
   8       16 2803892224 sdb
   8       32 2929721344 sdc
 252        0       4096 dm-0
 252        1  472788992 dm-1
 253        0  471859200 tda
 252        2 1050632192 dm-2
 253        1 1048576000 tdb
 252        3  262664192 dm-3
 253        2  262144000 tdc

The odd thing here is sdb, what is that and why is it there?

I also ran the following command based on the above mentioned article,

ll /dev/disk/by-id
total 0
lrwxrwxrwx 1 root root  9 Aug 16 17:51 scsi-36d4ae520990df60017886b6c20ec8db9 -> ../../sda
lrwxrwxrwx 1 root root 10 Aug 16 17:51 scsi-36d4ae520990df60017886b6c20ec8db9-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Aug 16 17:51 scsi-36d4ae520990df60017886b6c20ec8db9-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Aug 16 17:51 scsi-36d4ae520990df60017886b6c20ec8db9-part3 -> ../../sda3
lrwxrwxrwx 1 root root  9 Aug 16 17:51 scsi-36d4ae520990df60017886b87228bff90 -> ../../sdb
lrwxrwxrwx 1 root root  9 Aug 16 17:51 scsi-36d4ae520990df60017bed45f1c50e9f5 -> ../../sdc

I still see sdb, and sdc

I am confused, what I expect to see is sda (which is already in use) and sdb (newly installed disk), but I also see sdc.

Does this mean the RAID 1 isn't functioning properly?

  • Unless you're paranoid, a RAID 10 should fit better the virtualisation I/O patterns than 2xraid1 – Martino Dino Dec 16 '13 at 16:52

What you're seeing is the base disks attached to your machine. sda and sdb are the old ones, and sdc is the new one. This is normal.

However, you're using a fakeRAID from a motherboard controller that does not make its own hardware abstractions. It instead provides an interface that allows a driver (installed on the OS) to manage RAID. This has all of the drawbacks of a software RAID with all of the drawbacks of a hardware RAID.

As a result of this, you'll see all of the disks as they lie in the machine. However, the fakeRAID driver for your motherboard (IF installed and working) will create addressable RAID abstractions on top of the base disks. Because of this, while you can see sda and sdb, you should not be using them directly. You shoud instead be using the RAID abstraction, which will be presented as a block device of another name (such as /dev/disk/intr0).

HOWEVER, I see no evidence of this RAID abstraction having been created. It is almost certain that while you have a RAID set up in the BIOS, you do not have the necessary driver installed to actually DO anything with that orchestration. The result of this is that it simply does nothing (and you're using /dev/sda as a single disk). You're not actually running a RAID, far as I can tell. And you did provide enough information to determine that.

Sdb is blank because it's not mirrored with sda. Sdc is new. I would recommend that you no longer use motherboard fakeRAID at all, and instead use software RAID. Hardware RAID controllers are super crusty, and their prevalence has been due to Windows not having a proper software RAID system until only recently. Linux software RAID beats a hardware controller just about any day of the week, and has for a very long time.

While Linux MD RAID was not included in XenServer 5.6 and onwards, you do have LVM RAID (which gets way more support). You can add drives to a volume group (or storage pool or disk group, as some would call it) and then create logical volumes (basically partitions) that each have their own RAID policy when allocating and reading from any number of disks in that volume group. This is a great way to accomplish RAID, and it's even easier than using MD.

On top of all of this, I only just NOW realized that this question is from twenty-friggin'-twelve, but I refuse to undo all of this typing. Ideally, these words would help someone with their fakeRAID / software RAID woes. Use LVM. Profit. It's even the software RAID default now.


What motherboard raid controller do you have? My personal opinion is to never use raid on a consumer motherboard. This is because if your mobo blows in 4 years you will have a tough time finding a replacement board that will accept your raid. I suggest that you downgrade to XenServer 5.5 which is the highest version to support mdadm. Dont try 5.6 it will look like its working but medium disk activity will freeze the entire XenServer. Setup your raid1 in software using mdadm and make a SR ontop of that. There are a few guides but I don't have them handy. Post if u need more guidance.

  • While XenServer 5.5 is the last to use Linux MD, Greater versions than that can useor LVM RAID (which gets more development). Use LVM RAID. It's also the default. – Spooler Sep 25 '16 at 8:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.