Re: RAID1 with multiple partitions
On Wed, Dec 15, 2010 at 11:59 AM, David Gaudine
> On 10-12-10 10:22 PM, Tom H wrote:
> On Fri, Dec 10, 2010 at 5:57 PM, David Gaudine
> <firstname.lastname@example.org> wrote:
>>> grub-install --root-directory=/boot /dev/sda
>>> grub-install --root-directory=/boot /dev/sdb
>> grub-install /dev/sda
>> grub-install /dev/sdb
>> "--root-directory=/boot" will have installed grub in "/boot/boot/grub".
> That's it! Thank you! I didn't report back sooner because I've been
> testing, testing, testing.
> I have one last raid-related question. I'm going to have to rename this
> computer, because it's a replacement for another computer (running Linux for
> 7 years without a hitch, time to retire) so I'll shut down the old computer
> and give the new one its hostname and IP address. I've done this before, so
> I do know I have to update /etc/hostname, /etc/interfaces, my exim
> configuration, etc. Only the part about RAID is new to me.
> The temporary hostname is in each ARRAY line in mdadm.conf. As I understand
> it, the temporary hostname is also in the superblock, and these must match
> or I won't be able to boot. So, do I have to do something about the
> superblock (how?), or just edit the name in the ARRAY lines, or not touch it
> at all?
You're right; the hostname is saved in the superblock (as itself in
v1.x and as a part of the uuid in v0.9). That value is controlled by
the HOMEHOST value in mdadm.conf. The default is "HOMEHOST <system>",
which means "use the hostname of the current system".
I've never seen a hostname value on the ARRAY line in mdadm.conf. Are
you confusing hostname and array name?
You have to assemble an array with "--update=hostname" to update the
hostname value held in the superblock. I've never done so for "/"
though; it must have to be run from the initramfs prompt. There may be
another way but I'd have to look at the mdadm man page to find it but
don't have the time right now.