Installing OpenSuse on an existing machine with a lot of RAID disks

Hi all,

Question: I have fairly large machine running Ubuntu which really needs an upgrade. In the last year or so I have moved several laptops over to OpenSuse as Ubuntu Network card support is getting worse in newer releases. The server is well overdue for an upgrade and I would like to move it to OpenSuse as well to keep things simple. However…

The server has over 20 disks in it, many as RAID 1 using mdadm.

The root and usr partition IS not raided. This partition contains / /tmp /var /usr
There is a partition on another non-raided disk which is 47GB and is empty. This is where I intend to install OpenSuse retaining the Ubuntu install just in case. This partition will be divided into / and swap. I will continue to keep / /tmp /var and /usr on a single partition.
The BIOS has the ability to choose the boot Disk order. This will alter the definition of hd0 in GRUB.

So. What is the best and safest way to install OpenSuse without risk to the data stored on the RAID arrays?

Hopefully you folk can help me out with some suggestions.

Thanks,

Moz

lawsonim1 wrote:
> The root and usr partition IS not raided. This partition contains /
> /tmp /var /usr
> There is a partition on another non-raided disk which is 47GB and is
> empty. This is where I intend to install OpenSuse retaining the Ubuntu
> install just in case.

That is similar to a configuration I have. It works well.

> This partition will be divided into / and swap.

  • What do you use for swap at the moment? Why not continue to use that?
  • You can use files for swap instead of making partitions.

> The BIOS has the ability to choose the boot Disk order. This will alter
> the definition of hd0 in GRUB.

Sounds like a good reason not to use that BIOS ability!

> So. What is the best and safest way to install OpenSuse without risk
> to the data stored on the RAID arrays?

  • Unplug the arrays whilst you do the installation and plug them back in
    once you’re happy with the system. (not strictly necessary, but it
    definitely made me feel safer :slight_smile:
  • The YaST ‘disk partitioner’ is fine for telling opensuse about the arrays.
  • I found it easiest to use Ubuntu’s grub2 for booting (assuming the
    Ubuntu is new enough to have grub2). But that’s because I have a deep
    hatred and distrust of the opensuse boot configuration process; YMMV.

Thanks for the advice.
Answering your questions. If I switch the disks around in the BIOS I can keep the original disk completely intact. ie, I don’t have to overwrite the MBR or grub installation at all. I can just boot the other disk. If I don’t like it or have to revert (due to software compatibility - web site SW hosted, php code etc, missing or incompatible libs) all I need do is switch the disks in the BIOS.
Reason for new Swap partition - I prefer to keep the whole “system” install on one disk. Historical reasons mainly. No good technical reasons. Just one less partition to track.

You are mirroring my thoughts about disconnecting the RAID during the install.

Q. Will OpenSuse recognize the raids automatically when added and autoconfigure? Or do I have to do I have to follow the steps you outline and use YaST for that?

Maybe I’ll find a couple of spare disks, make a raid on them first and make sure they are added first to see how they go.

Thoughts? Suggestions?

lawsonim1 wrote:
> Thanks for the advice.
> Answering your questions. If I switch the disks around in the BIOS I
> can keep the original disk completely intact. ie, I don’t have to
> overwrite the MBR or grub installation at all. I can just boot the other
> disk. If I don’t like it or have to revert (due to software
> compatibility - web site SW hosted, php code etc, missing or
> incompatible libs) all I need do is switch the disks in the BIOS.
> Reason for new Swap partition - I prefer to keep the whole “system”
> install on one disk. Historical reasons mainly. No good technical
> reasons. Just one less partition to track.

OK, it sounds like a reasonable plan.

> Q. Will OpenSuse recognize the raids automatically when added and
> autoconfigure? Or do I have to do I have to follow the steps you outline
> and use YaST for that?

I don’t know I’m afraid. I prefer to do things manually, or at least
check them, to reduce the number of unpleasant surprises I get.

> Maybe I’ll find a couple of spare disks, make a raid on them first and
> make sure they are added first to see how they go.

That would obviously be even safer :slight_smile: FWIW, I haven’t had any problems
with mdadm soft-raid or 3ware hardware raid. I can’t speak for dmraid
fake-raid or other hardware vendors. But I wouldn’t expect any
filesystem to self-harm itself unless provoked very severely.

You do have backups, don’t you? :slight_smile:

Thanks for the input.

The critical data is backed up off site.

The important data RAIDED.

Clearly I don’t want to lose either but backing up the important data is not viable.

I’ll post my findings here when I have them, for future reference.

On Wed, 28 Sep 2011 18:36:03 GMT, lawsonim1
<lawsonim1@no-mx.forums.opensuse.org> wrote:

>
>Thanks for the input.
>
>The critical data is backed up off site.
>
>The important data RAIDED.
>
>Clearly I don’t want to lose either but backing up the important data
>is not viable.

I am sorry, but i MUST disagree with you. It just takes a lot of time.
(I am guessing that you have on the order of 15 TB to backup). If your
data is valuable enough to RAID, it is valuable enough to backup.
>
>I’ll post my findings here when I have them, for future reference.

RAID is not a backup solution.

On 2011-09-28 20:36, lawsonim1 wrote:

> Clearly I don’t want to lose either but backing up the important data
> is not viable.

You MUST make it viable. If not off site, then in site. It is preferable to
have backup and no raid, than raid and no backup.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

Thanks again for your input on backup viability.

I appreciate that RAID is not backup. You are correct. This is only a form of backup against the increasing likelihood of HD failure (which I had last week, thankfully still under warranty) which can cause data loss.

However, I have judged that the data on on these disks is dispensable. I can do without it. However it would be awkward for a while. I certainly do not believe it to be worth long term storage, nor the cost of a dedicated backup solution. Consider them to be editing room floor cuttings.

One must appreciate what you have, before can understand potential loss.

Again, thanks for the input.

Finished. All went well.

I backed up the content from a pair of mirrored disks and left both disks in the machine during the upgrade.

OS installed just fine and identified the disks in partition tool as an existing array.

After reboot and OS install completion, the array was assembled (/proc/mdstat) and visible in mdadm.conf.

Shutdown, add other disks, boot.

I tried the Yast partition tool but did not find it very useful for this.
Unfortunately, a lot of the disks are of the same type, and the tool does not give the disk serial number. This makes it nearly impossible to determine which disk is which. I decided to revert to command line.

So now I have 20 disks which make up varying arrays which need assembling.

I copied the mdadm.conf from my exsiting install to the new location. Ensuring the existing array entry would be ok.

This enabled many of the arrays to be recognized and started.
The last two arrays I assembled by hand something like this.

mdadm -E /dev/sds1 | grep UU
mdadm -E /dev/sdp1 | grep UU

identical UUIDs

mdadm --assemble /dev/md9 /dev/sds1 /dev/sdp1

I then recreated the mdadm.conf with mdadm -Es >> /etc/mdadm.conf and cleaned up.

I was concerned (coming from Ubuntu) that I would need to update the initrd with mkinitrd to get the mdadm.conf into the initrd for boot up. This seems unnecessary on OpenSuse (presumably unless you have the root disk raided).

I know that it is possible to rescan all the disks and assemble all the arrays automagically using a one line command, with mdadm -c partitions. But, perhaps, in this instance, it would not be a good idea. YMMV.

lawsonim1 wrote:
> Finished. All went well.

Glad to hear it.

> I tried the Yast partition tool but did not find it very useful for
> this.
> Unfortunately, a lot of the disks are of the same type, and the tool
> does not give the disk serial number. This makes it nearly impossible to
> determine which disk is which. I decided to revert to command line.

The serial numbers show up for me. In the partitioner in the Hard Disks
part of the tree, click on a disk in the tree and then select the
Overview tab. The serial numbers appear at the end of the Device ID 1 & 2.

(Alternatively, with the list of hard disks and partitions displayed,
select a disk in the list and click Edit…, then select the Overview tab)

> YMMV.

Thanks for the detailed explanation of what you did. That may be very
helpful to somebody in future (me?!)

Cheers, Dave