[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: hostname ?



I have be able to solve the problem as follows:

I made a backup of my flash memory and wrote a debian installer to the flash. After reboot, downloading the installer components and after detecting the disks I jumped into a shell and renamed the RAID device. Finally, I restored the original content of the flash memory (from the backup) and restarted the system. Everything is fine know but I would not recommend this procedure for a 'live' system.

However, I original problem is that the debian-installer does not ask for the (new) hostname during installation.
A corresponding bug report is now available here:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=815786

Thanks again for all your comments.
Peter



On 23.02.2016 15:29, Alan Corey wrote:
Right, the OpenBSD version at the time (15 years ago) I think was
raidframe and they called it a serial number, it doesn't really matter
as long as all the drives in the stack are the same.  And it's mostly
important if you've got multiple RAIDS and might mix the drives up.

10 years ago I might have whipped out my copy of Norton Disk Editor
but that doesn't deal with LBA48, etc.  dd and a hex editor could
probably do it but unless you know exactly which bytes to change
you're likely to damage something more important.

So RTFM.  One point of a RAID is that you can replace drives when they
fail, so there's a way to put the serial number onto a new drive to
match before you put it in.  Just about any new drive will work as
long as you can make a partition the same size as the rest of the
drives.  5 or 10 years down the road it may be impractical to buy
exactly the same size drive.  So the makers of the RAID
hardware/software will have provided a way to prepare a new
replacement drive.

You want to change it on all the drives at once, that's unusual.  But
there's nothing peculiar to Debian ARM about it.  Try looking on
http://superuser.com or posting a question there.  Or maybe there's a
RAID list or forum within Debian.  Because of the larger userbase with
i386/686 and AMD people you're more likely to find an answer.  Or you
could just live with it the way it is and tape a note onto each drive
so you'll remember when you have to replace one.

I've never used mdadm, I'm on an OpenBSD laptop which sometimes boots
into Debian.  My only running Debian right now is on my phone.  No
mdadm man page even.

On 2/23/16, Roger Shimizu <rogershimizu@gmail.com> wrote:
On Tue, Feb 23, 2016 at 8:27 PM, Peter Nagel <peter.nagel@kit.edu> wrote:
Thanks for your input.
The HOMEHOST parameter (in /etc/mdadm/mdadm.conf) is set to <system>.

The RAID-device does still show the old hostname in both mdadm.conf and
the
superblock of the indiviual devices.
The system is booting from this RAID without problems. Nevertheless, I
would
like to change to the new hostname.

If I would change the hostname of the ARRAY in mdadm.conf I should also
change the hostname within the superblocks.
However, I have no idea how to change the homehost settings in the
superblock ...

Peter
According to previous post:
You're not alone by the looks.  And it's not peculiar to the hardware.
http://askubuntu.com/questions/63980/how-do-i-rename-an-mdadm-raid-array
Here's the method, confirmed OK by me.

- backup /etc/mdadm/mdadm.conf, and then edit it, remove "name=XXX"
for each array you want to rename. in transition stage, if "name"
mismatch, you will not be able to boot at all. so remove it for safe.
mdadm can safely reassemble by UUID only.
- run: "update-initramfs -u" to make previous edit effective
- shutdown, then move the HDDs of the array to other PC, or connect
via USB-SATA adapter.
- run for each array you want to rename: mdadm -A /dev/mdX
--update=name --name=<new name>:<md ID> /dev/sdaY /dev/sdbY
- stop the array: mdadm -S /dev/mdX
- shutdown that PC
- move the HDDs back to original PC, and boot

Because as I tested, the rename only can happen when assembling, so
doing it on another PC is the point.

Cheers,
--
Roger Shimizu, GMT +9 Tokyo
PGP/GPG: 17B3ACB1




Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


Reply to: