Bug#737132: Regression: wheezy initrd loads md raids only if defined on mdadm.conf even with INITRDSTART='all'

2014-01-31 Thread Fabio Fantoni

Il 30/01/2014 17:20, Michael Tokarev ha scritto:

30.01.2014 20:18, Fabio Fantoni wrote:
[]

Thanks for reply.
The new md arrays were created by Wheezy persistent install on usb pendrive 
used as recovery system/tools.
The root of system to recover is also Wheezy.
Than the arrays are created with 1.2 superblock and different hostname.
Is it possible to force the hostname on mdadm create?

use --homehost=whatever for that.


If so, is the UUID going to work too?

I don't understand this question.


Otherwise if it is possible to change it only with --update, will the UUID 
contain the old hostname and will it be a problem on initrd start?

use --update=homehost when assembling.

Thanks,

/mjt


Thanks for reply.
I tried create new arrays with --homehost and I saw on mdadm --detail 
that is working.
But unfortunately it seems that there is a bug because the same initrd 
still does not show them (boot fail to busybox and cat /proc/mdstat not 
show any array) even if they have the same hostname of the root to be 
started.



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#737132: Regression: wheezy initrd loads md raids only if defined on mdadm.conf even with INITRDSTART='all'

2014-01-30 Thread Fabio Fantoni
Package: mdadm
Version: 3.2.5-5
Severity: normal

I'm attempting to restore a backup of a root partition on a set of brand new 
disks (md raid1).
On Wheezy, initramfs doesn't show md devices if they are not defined in 
/etc/mdadm/mdadm.conf even if on /etc/default/mdadm there is INITRDSTART='all'.
Such problem may be caused by a regression (squeezy or wheezy) because on lenny 
I've been always did such task without problem.
I see initrdstart_notinconf: false on package configuration template but 
seems no more used, so it shouldn't be the problem here, right?

-- Package-specific info:
--- mdadm.conf
CREATE owner=root group=disk mode=0660 auto=yes
HOMEHOST system
MAILADDR root

--- /etc/default/mdadm
INITRDSTART='all'
AUTOSTART=true
AUTOCHECK=true
START_DAEMON=true
DAEMON_OPTIONS=--syslog
VERBOSE=false

--- /proc/mdstat:
Personalities : [raid1] 
md1 : active raid1 sda3[0] sdb3[1]
  72610624 blocks super 1.2 [2/2] [UU]
  
md0 : active raid1 sda2[0] sdb2[1]
  5237760 blocks super 1.2 [2/2] [UU]
  
unused devices: none

--- /proc/partitions:
major minor  #blocks  name

   8   327843840 sdc
   8   337843809 sdc1
  1101048575 sr0
   80   78125000 sda
   81 203793 sda1
   825241873 sda2
   83   72676279 sda3
   8   16   78125000 sdb
   8   17 203793 sdb1
   8   185241873 sdb2
   8   19   72676279 sdb3
   905237760 md0
   91   72610624 md1

--- LVM physical volumes:
LVM does not seem to be used.
--- mount output
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,relatime,size=10240k,nr_inodes=1538866,mode=755)
devpts on /dev/pts type devpts 
(rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=1232452k,mode=755)
/dev/disk/by-label/ROOT on / type ext4 
(rw,relatime,errors=remount-ro,user_xattr,barrier=1,data=ordered)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /run/shm type tmpfs (rw,nosuid,nodev,noexec,relatime,size=2464900k)
/dev/md1 on /mnt/data type ext4 (rw,relatime,user_xattr,barrier=1,data=ordered)
rpc_pipefs on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime)

--- initrd.img-3.2.0-4-amd64:
67890 blocks
cd4e75e3374c6a6564ba77d48b90fc6a  ./sbin/mdadm
e3f1b1cbf4f14eb505dee4fde52ba461  ./conf/mdadm
a560b1c713f6f2bf42abcd9dade35d6a  ./scripts/local-top/mdadm
00ba05924de21e62cc6de9d08b35dfd7  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/linear.ko
bda6277e9db3f569eb42f95c85775f49  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/raid456.ko
1d2672b5df3a8e47b3db5042b7a9c318  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/raid1.ko
3baf54cf0178e9fdd57654874f214f7f  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/raid0.ko
b99e69beaba4fe3e98aa3175eb1fe307  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/multipath.ko
a8ac2caaa941e9271a1a9f7cd9ed8137  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/dm-mod.ko
958dd4317c069dd2a1fa13be1a37d58d  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/raid10.ko
16f27e58797a804ed1ed084e7c99bb28  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/dm-crypt.ko
9c74115ed02be09fff40ec70d7cf61c8  
./lib/modules/3.2.0-4-amd64/kernel/drivers/md/md-mod.ko
1fc18795ef0c2f45897047d55c4279d5  ./etc/mdadm/mdadm.conf

--- initrd's /conf/conf.d/md:
no conf/md file.

--- /proc/modules:
dm_crypt 22586 0 - Live 0xa0247000
dm_mod 63645 1 dm_crypt, Live 0xa0256000
raid1 30714 2 - Live 0xa016b000
md_mod 87742 3 raid1, Live 0xa0135000
raid_class 12832 1 mpt2sas, Live 0xa006a000
scsi_mod 162269 8 
sg,sr_mod,sd_mod,usb_storage,mpt2sas,raid_class,scsi_transport_sas,libata, Live 
0xa0007000

--- /var/log/syslog:

--- volume detail:
/dev/sda:
   MBR Magic : aa55
Partition[0] :15624 sectors at1 (type ee)
--
/dev/sda1 is not recognised by mdadm.
/dev/sda2:
  Magic : a92b4efc
Version : 1.2
Feature Map : 0x0
 Array UUID : e10e3244:83e2aa20:b6fccb1c:b051213f
   Name : system-install:0
  Creation Time : Wed Jan 29 12:29:01 2014
 Raid Level : raid1
   Raid Devices : 2

 Avail Dev Size : 10475554 (5.00 GiB 5.36 GB)
 Array Size : 5237760 (5.00 GiB 5.36 GB)
  Used Dev Size : 10475520 (5.00 GiB 5.36 GB)
Data Offset : 8192 sectors
   Super Offset : 8 sectors
  State : clean
Device UUID : e9da4d4a:faca6be4:172122ba:9eaf017a

Update Time : Thu Jan 30 14:43:06 2014
   Checksum : e2f7d97e - correct
 Events : 19


   Device Role : Active device 0
   Array State : AA ('A' == active, '.' == missing)
--
/dev/sda3:
  Magic : a92b4efc
Version : 1.2
Feature Map : 0x0
 Array UUID : 54894ab9:bd9a072c:4dd5bf3b:43a43f9a
   Name : system-install:1
  Creation Time : Wed Jan 29 12:29:02 2014
 Raid Level : raid1
   Raid Devices : 2

 Avail Dev Size : 

Bug#737132: Regression: wheezy initrd loads md raids only if defined on mdadm.conf even with INITRDSTART='all'

2014-01-30 Thread Michael Tokarev
30.01.2014 17:45, Fabio Fantoni wrote:
 Package: mdadm
 Version: 3.2.5-5
 Severity: normal
 
 I'm attempting to restore a backup of a root partition on a set of brand new 
 disks (md raid1).
 On Wheezy, initramfs doesn't show md devices if they are not defined in 
 /etc/mdadm/mdadm.conf even if on /etc/default/mdadm there is 
 INITRDSTART='all'.
 Such problem may be caused by a regression (squeezy or wheezy) because on 
 lenny I've been always did such task without problem.
[]
 Personalities : [raid1] 
 md1 : active raid1 sda3[0] sdb3[1]
   72610624 blocks super 1.2 [2/2] [UU]

With 1.x superblock, the term all actually refers to all arrays belonging to 
this host,
which has current hostname recorded in the superblock (1.x format superblock 
has a place
for homehost field, while 0.90 format didn't have this field).

Previously, mdadm really tried to assemble any arrays found, but this turned 
out to be
wrong.  For example, when you insert hard drives from another system for 
recovery of
broken raid/filesystem, mdadm should NOT assemble arrays from there by default, 
because
this way we've a high risk of breaking stuff further.

Please ensure that you have the right homehost in your raid arrays (mdadm -D 
will tell you),
and -- the second part of the picture -- that this hostname is set correctly 
inside initrd
when mdadm is run.

Please note also that modern mdadm will try to check homehost even for 0.90 
superblocks,
by doing some magic with the array UUID.  If your arrays were created by 
sufficiently
recent mdadm, the UUID has some bits of homehost mixed in.

Thanks,

/mjt


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#737132: Regression: wheezy initrd loads md raids only if defined on mdadm.conf even with INITRDSTART='all'

2014-01-30 Thread Fabio Fantoni

Il 30/01/2014 16:15, Michael Tokarev ha scritto:

30.01.2014 17:45, Fabio Fantoni wrote:

Package: mdadm
Version: 3.2.5-5
Severity: normal

I'm attempting to restore a backup of a root partition on a set of brand new 
disks (md raid1).
On Wheezy, initramfs doesn't show md devices if they are not defined in 
/etc/mdadm/mdadm.conf even if on /etc/default/mdadm there is INITRDSTART='all'.
Such problem may be caused by a regression (squeezy or wheezy) because on lenny 
I've been always did such task without problem.

[]

Personalities : [raid1]
md1 : active raid1 sda3[0] sdb3[1]
   72610624 blocks super 1.2 [2/2] [UU]

With 1.x superblock, the term all actually refers to all arrays belonging to 
this host,
which has current hostname recorded in the superblock (1.x format superblock 
has a place
for homehost field, while 0.90 format didn't have this field).

Previously, mdadm really tried to assemble any arrays found, but this turned 
out to be
wrong.  For example, when you insert hard drives from another system for 
recovery of
broken raid/filesystem, mdadm should NOT assemble arrays from there by default, 
because
this way we've a high risk of breaking stuff further.

Please ensure that you have the right homehost in your raid arrays (mdadm -D 
will tell you),
and -- the second part of the picture -- that this hostname is set correctly 
inside initrd
when mdadm is run.

Please note also that modern mdadm will try to check homehost even for 0.90 
superblocks,
by doing some magic with the array UUID.  If your arrays were created by 
sufficiently
recent mdadm, the UUID has some bits of homehost mixed in.

Thanks,

/mjt


Thanks for reply.
The new md arrays were created by Wheezy persistent install on usb 
pendrive used as recovery system/tools.

The root of system to recover is also Wheezy.
Than the arrays are created with 1.2 superblock and different hostname.
Is it possible to force the hostname on mdadm create?
If so, is the UUID going to work too?
Otherwise if it is possible to change it only with --update, will the 
UUID contain the old hostname and will it be a problem on initrd start?



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#737132: Regression: wheezy initrd loads md raids only if defined on mdadm.conf even with INITRDSTART='all'

2014-01-30 Thread Michael Tokarev
30.01.2014 20:18, Fabio Fantoni wrote:
[]
 Thanks for reply.
 The new md arrays were created by Wheezy persistent install on usb pendrive 
 used as recovery system/tools.
 The root of system to recover is also Wheezy.
 Than the arrays are created with 1.2 superblock and different hostname.
 Is it possible to force the hostname on mdadm create?

use --homehost=whatever for that.

 If so, is the UUID going to work too?

I don't understand this question.

 Otherwise if it is possible to change it only with --update, will the UUID 
 contain the old hostname and will it be a problem on initrd start?

use --update=homehost when assembling.

Thanks,

/mjt


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org