[opensuse] mdadm --grow
All, I'm conceptually putting together a NFS server in my head. (I will build it once I know what it is!!) What I want is something flexible. ie. Have it start with 3 or 4 drives, then add a drive when I need the capacity. Remove a drive when I don't. replace the drives with bigger drives as the become available. All without losing my data. (Or having to back it up / restore it.) I'd like to start with a 4 disk Raid 10 providing 2 TB of space, but then have the ability to add disks, change raid techniques etc. (ie. convert to raid 6 without data loss!!). mdadm --grow implies it can do this, but there is not much there and my google searches did not turn up much either. Can anyone tell me how well it works and what sorts of things can actually be done. And can it be used to "shrink" a volume. (I believe XFS supports shrinking a filesystem, so I would first shrink the filesystem, then hopefully use mdadm to shrink the raid array.) If mdadm can't do any of this, is there a hardware controller card that can? FYI: The Drobo (www.drobo.com) can do the above as I understand it, but the performance is apparently very slow. Only 5 to 8 MB/sec from the reviews I saw. I want at least 80MB/sec when reading large files. Thanks Greg -- Greg Freemyer Litigation Triage Solutions Specialist http://www.linkedin.com/in/gregfreemyer First 99 Days Litigation White Paper - http://www.norcrossgroup.com/forms/whitepapers/99%20Days%20whitepaper.pdf The Norcross Group The Intersection of Evidence & Technology http://www.norcrossgroup.com -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Greg Freemyer wrote:
All,
I'm conceptually putting together a NFS server in my head. (I will build it once I know what it is!!)
What I want is something flexible.
ie. Have it start with 3 or 4 drives, then add a drive when I need the capacity. Remove a drive when I don't. replace the drives with bigger drives as the become available. All without losing my data. (Or having to back it up / restore it.)
My first thought - LVM.
I'd like to start with a 4 disk Raid 10 providing 2 TB of space, but then have the ability to add disks, change raid techniques etc. (ie. convert to raid 6 without data loss!!).
mdadm --grow implies it can do this, but there is not much there and my google searches did not turn up much either.
I don't think mdadm --grow can do what you want. It's very useful when you for instance want to build a RAID1 in degraded mode (with only one drive), and you later want to add a drive to bring it back to full RAID1. You can probably also add a drive to working RAID1 or maybe even RAID5, but I don't know.
And can it be used to "shrink" a volume. (I believe XFS supports shrinking a filesystem, so I would first shrink the filesystem, then hopefully use mdadm to shrink the raid array.)
Most advanced filesystems (jfs,xfs,ext3 et al) support resizing - otherwise the LVM resizing features wouldnt be overly useful :-)
If mdadm can't do any of this, is there a hardware controller card that can?
Take a good look at LVM. -- /Per Jessen, Zürich -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Thu, Oct 30, 2008 at 8:02 AM, Per Jessen <per@opensuse.org> wrote:
Greg Freemyer wrote:
All,
I'm conceptually putting together a NFS server in my head. (I will build it once I know what it is!!)
What I want is something flexible.
ie. Have it start with 3 or 4 drives, then add a drive when I need the capacity. Remove a drive when I don't. replace the drives with bigger drives as the become available. All without losing my data. (Or having to back it up / restore it.)
My first thought - LVM.
I'm very familiar with LVM. It does not really do the same things as RAID. Not even if you only worry about the performance side of things. ie. a 4 disk raid system is faster than a single disk for most raid setups. With LVM based on 4-drives, it is typically just the same speed as a single disk.
I'd like to start with a 4 disk Raid 10 providing 2 TB of space, but then have the ability to add disks, change raid techniques etc. (ie. convert to raid 6 without data loss!!).
mdadm --grow implies it can do this, but there is not much there and my google searches did not turn up much either.
I don't think mdadm --grow can do what you want. It's very useful when you for instance want to build a RAID1 in degraded mode (with only one drive), and you later want to add a drive to bring it back to full RAID1. You can probably also add a drive to working RAID1 or maybe even RAID5, but I don't know.
The man page says it can change the "size or shape" of a raid array. But then provides no detail. :( I'm assuming shape means the raid level? Not a phrase I know in reference to raid.
And can it be used to "shrink" a volume. (I believe XFS supports shrinking a filesystem, so I would first shrink the filesystem, then hopefully use mdadm to shrink the raid array.)
Most advanced filesystems (jfs,xfs,ext3 et al) support resizing - otherwise the LVM resizing features wouldnt be overly useful :-)
I know most can grow. iirc, only xfs can shrink?
If mdadm can't do any of this, is there a hardware controller card that can?
Take a good look at LVM.
Actually I came across the QNAP TS509 yesterday. A very cool NAS that seems to do everthing I want. It is Linux based and provides ssh access. I assume you can use that access to admin things if need be. Its about $1000 for an empty shell that holds 5-drives. Greg
-- /Per Jessen, Zürich
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-- Greg Freemyer Litigation Triage Solutions Specialist http://www.linkedin.com/in/gregfreemyer First 99 Days Litigation White Paper - http://www.norcrossgroup.com/forms/whitepapers/99%20Days%20whitepaper.pdf The Norcross Group The Intersection of Evidence & Technology http://www.norcrossgroup.com -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Greg Freemyer wrote:
On Thu, Oct 30, 2008 at 8:02 AM, Per Jessen <per@opensuse.org> wrote:
Greg Freemyer wrote:
All,
I'm conceptually putting together a NFS server in my head. (I will build it once I know what it is!!)
What I want is something flexible.
ie. Have it start with 3 or 4 drives, then add a drive when I need the capacity. Remove a drive when I don't. replace the drives with bigger drives as the become available. All without losing my data. (Or having to back it up / restore it.)
My first thought - LVM.
I'm very familiar with LVM. It does not really do the same things as RAID. Not even if you only worry about the performance side of things. ie. a 4 disk raid system is faster than a single disk for most raid setups. With LVM based on 4-drives, it is typically just the same speed as a single disk.
Completely agree, but I read your requirements above to be more to do with space management than performance. /Per -- /Per Jessen, Zürich -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Fri, Oct 31, 2008 at 4:58 AM, Per Jessen <per@opensuse.org> wrote:
Greg Freemyer wrote:
On Thu, Oct 30, 2008 at 8:02 AM, Per Jessen <per@opensuse.org> wrote:
Greg Freemyer wrote:
All,
I'm conceptually putting together a NFS server in my head. (I will build it once I know what it is!!)
What I want is something flexible.
ie. Have it start with 3 or 4 drives, then add a drive when I need the capacity. Remove a drive when I don't. replace the drives with bigger drives as the become available. All without losing my data. (Or having to back it up / restore it.)
My first thought - LVM.
I'm very familiar with LVM. It does not really do the same things as RAID. Not even if you only worry about the performance side of things. ie. a 4 disk raid system is faster than a single disk for most raid setups. With LVM based on 4-drives, it is typically just the same speed as a single disk.
Completely agree, but I read your requirements above to be more to do with space management than performance.
This is linux!! I want functionality and speed!! Seriously, I am very intrigued by the QNAP TS-509 NAS. Its Ubuntu based, but it seems to give the user full ssh access. It does automatic online Raid Expansion and Raid Migration. I don't know if they are using mdadm --grow to do it, or if they have custom code. Per a review I read, you can even hook up a monitor/keyboard and login. (The review is really good and is at http://www.smallnetbuilder.com). They use cookies, so I can't post a direct link. Greg -- Greg Freemyer Litigation Triage Solutions Specialist http://www.linkedin.com/in/gregfreemyer First 99 Days Litigation White Paper - http://www.norcrossgroup.com/forms/whitepapers/99%20Days%20whitepaper.pdf The Norcross Group The Intersection of Evidence & Technology http://www.norcrossgroup.com -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
On Thu, 30 Oct 2008, 13:48:41 +0100, Greg Freemyer wrote:
On Thu, Oct 30, 2008 at 8:02 AM, Per Jessen <per@opensuse.org> wrote:
Greg Freemyer wrote:
[...] And can it be used to "shrink" a volume. (I believe XFS supports shrinking a filesystem, so I would first shrink the filesystem, then hopefully use mdadm to shrink the raid array.)
Most advanced filesystems (jfs,xfs,ext3 et al) support resizing - otherwise the LVM resizing features wouldnt be overly useful :-)
I know most can grow. iirc, only xfs can shrink?
XFS cannot shrink! Most other file systems can shrink but not necessarily when they are mounted. Cheers. l8er manfred -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Hi! Am Donnerstag, 30. Oktober 2008 13:02 schrieb Per Jessen:
RAID1. You can probably also add a drive to working RAID1 or maybe even RAID5, but I don't know.
You can to RAID 5. I converted my system by creating the RAID 5 in degraded mode on 2 disks and later adding the third one. -- Matthias Bach www.marix.org -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Matthias Bach wrote:
Hi!
Am Donnerstag, 30. Oktober 2008 13:02 schrieb Per Jessen:
RAID1. You can probably also add a drive to working RAID1 or maybe even RAID5, but I don't know.
You can to RAID 5. I converted my system by creating the RAID 5 in degraded mode on 2 disks and later adding the third one.
Can you now decide to add a fourth (not as a hot spare, but as active member of the raid)? That would require restriping, which presumably would run in the background but it would be cool if you could do that? -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
Hi! Am Donnerstag 30 Oktober 2008 schrieb John Andersen:
Matthias Bach wrote:
Hi!
Am Donnerstag, 30. Oktober 2008 13:02 schrieb Per Jessen:
RAID1. You can probably also add a drive to working RAID1 or maybe even RAID5, but I don't know.
You can to RAID 5. I converted my system by creating the RAID 5 in degraded mode on 2 disks and later adding the third one.
Can you now decide to add a fourth (not as a hot spare, but as active member of the raid)? That would require restriping, which presumably would run in the background but it would be cool if you could do that?
AFAIK yes. You would first have to add the drives as hot spares however. mdadm /dev/md0 --add /dev/sdd Then you can grow the array onto that new disk. mdamd --grow md0 -n 4 /dev/sda /dev/sdb /dev/sdc /dev/sdd Expect the reshaping to put your mashine under heavy IO load for a few hours, so. And remember that you will still have to resize your filesystem afterwards, which might add some more time. Sadly I don't have the hardware and time to try this right now, but if you want to play around, VirtualBox is your friend ;). Regards, Matthias -- Matthias Bach www.marix.org „Der einzige Weg, die Grenzen des Möglichen zu finden, ist ein klein wenig über diese hinaus in das Unmögliche vorzustoßen.“ - Arthur C. Clarke
On 2008-10-29T16:51:02, Greg Freemyer <greg.freemyer@gmail.com> wrote:
I'd like to start with a 4 disk Raid 10 providing 2 TB of space, but then have the ability to add disks, change raid techniques etc. (ie. convert to raid 6 without data loss!!).
Adding larger drives to an md array works fine. Changing RAID techniques depends on what you want to change, I think; RAID10 to RAID6 should. I would probably put LVM on top of the RAID, but that is probably obvious to you.
Can anyone tell me how well it works and what sorts of things can actually be done.
the linux-raid list might be the best place to ask this; Neil should be responsive, and it depends a bit on the kernel version used.
And can it be used to "shrink" a volume. (I believe XFS supports shrinking a filesystem, so I would first shrink the filesystem, then hopefully use mdadm to shrink the raid array.)
I _think_ this should also work, yes. Shrinking, in particular online, rarely occurs though.
FYI: The Drobo (www.drobo.com) can do the above as I understand it, but the performance is apparently very slow. Only 5 to 8 MB/sec from the reviews I saw. I want at least 80MB/sec when reading large files.
Heh, drobo.com claim all sorts of deficiencies in the OS RAID which are just incorrect. Regards, Lars -- Teamlead Kernel, SuSE Labs, Research and Development SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) "Experience is the name everyone gives to their mistakes." -- Oscar Wilde -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (6)
-
Greg Freemyer
-
John Andersen
-
Lars Marowsky-Bree
-
Manfred Hollstein
-
Matthias Bach
-
Per Jessen