Package: mdadm Version: 3.2.5-5 Severity: minor Tags: patch Dear Maintainer,
we have set up some of our servers with a small MD raidi1 consisting only of one device, so we may later add an additional hard drive without having to re-create the filesystem. On these servers, we sometimes get checkarray error mails: > Subject: Cron <root@backup> if [ -x /usr/share/mdadm/checkarray ] && [ $(date > +%d) -le 7 ]; then /usr/share/mdadm/checkarray --cron --all --idle --quiet; fi > From: Cron Daemon <root@hostname> > To: root@backup.hostname > Date: So, 05.07.2015 00:57 > > renice: failed to get priority for 17571 (process ID): No such process Apparently the md check runs so fast that when the scripts wants to renice it, the process is no longer running. I've attached a patch that resolves the issue by redirecting STDERR of renice/ionice to /dev/null. -- Package-specific info: --- mdadm.conf CREATE owner=root group=disk mode=0660 auto=yes HOMEHOST <system> MAILADDR root ARRAY /dev/md/0 metadata=1.2 UUID=9e1e626b:660983fa:7c7743ce:a611dca9 name=unassigned:0 --- /etc/default/mdadm INITRDSTART='all' AUTOSTART=true AUTOCHECK=true START_DAEMON=true DAEMON_OPTIONS="--syslog" VERBOSE=false --- /proc/mdstat: Personalities : [raid1] md0 : active raid1 sda2[0] 9992064 blocks super 1.2 [1/1] [U] unused devices: <none> --- /proc/partitions: major minor #blocks name 8 0 976762584 sda 8 1 1024 sda1 8 2 10000384 sda2 8 3 966759424 sda3 11 0 1048575 sr0 9 0 9992064 md0 --- 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=489087,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=392936k,mode=755) /dev/disk/by-uuid/97c2159e-276d-42c7-b34b-9352e17ae2c7 on / type ext4 (rw,relatime,errors=remount-ro,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=785860k) --- initrd.img-3.16.0-0.bpo.4-amd64: 90542 blocks 5279b5dc98152be1e8305bc59a037166 ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/multipath.ko 4801fcd2b248deea3e66b4f16c5252c9 ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/raid1.ko fda057547b8af02ae5fb8b042f0b0e7b ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/dm-mod.ko 7d40ea67702e1dc0f9dc80f0072e30ce ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/linear.ko 933c1955c35bbc2036c95687767c235a ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/raid0.ko 86dbe96964776a439910fd34fe011ec1 ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/md-mod.ko 72a2cdad3802be27c53b929a87cd4448 ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/raid456.ko c404c37b621ecc8039a167249f65835c ./lib/modules/3.16.0-0.bpo.4-amd64/kernel/drivers/md/raid10.ko a560b1c713f6f2bf42abcd9dade35d6a ./scripts/local-top/mdadm cd4e75e3374c6a6564ba77d48b90fc6a ./sbin/mdadm 60596c5613c3a565c95f4fd8e639a902 ./etc/mdadm/mdadm.conf 4cfabdc50bcde6e16ba134109db9b816 ./conf/mdadm --- initrd's /conf/conf.d/md: no conf/md file. --- /proc/modules: raid1 34596 1 - Live 0xffffffffa00cf000 md_mod 111686 2 raid1, Live 0xffffffffa019b000 --- /var/log/syslog: --- volume detail: /dev/sda: MBR Magic : aa55 Partition[0] : 2048 sectors at 2048 (type 83) Partition[1] : 20000768 sectors at 4096 (type fd) Partition[2] : 1933518848 sectors at 20004864 (type 83) -- /dev/sda1 is not recognised by mdadm. /dev/sda2: Magic : a92b4efc Version : 1.2 Feature Map : 0x0 Array UUID : 9e1e626b:660983fa:7c7743ce:a611dca9 Name : unassigned:0 Creation Time : Sat Mar 14 16:10:53 2015 Raid Level : raid1 Raid Devices : 1 Avail Dev Size : 19984384 (9.53 GiB 10.23 GB) Array Size : 9992064 (9.53 GiB 10.23 GB) Used Dev Size : 19984128 (9.53 GiB 10.23 GB) Data Offset : 16384 sectors Super Offset : 8 sectors State : clean Device UUID : 057439bf:ad946a16:6911d6b1:da8a3d59 Update Time : Mon Jul 6 08:51:24 2015 Checksum : 26aa75e8 - correct Events : 71 Device Role : Active device 0 Array State : A ('A' == active, '.' == missing) -- /dev/sda3 is not recognised by mdadm. --- /proc/cmdline BOOT_IMAGE=/boot/vmlinuz-3.16.0-0.bpo.4-amd64 root=UUID=97c2159e-276d-42c7-b34b-9352e17ae2c7 ro quiet --- grub2: insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' linux /boot/vmlinuz-3.16.0-0.bpo.4-amd64 root=UUID=97c2159e-276d-42c7-b34b-9352e17ae2c7 ro quiet insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' linux /boot/vmlinuz-3.16.0-0.bpo.4-amd64 root=UUID=97c2159e-276d-42c7-b34b-9352e17ae2c7 ro single insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' insmod raid set root='(mduuid/9e1e626b660983fa7c7743cea611dca9)' linux /boot/vmlinuz-3.16.0-0.bpo.4-amd64 root=UUID=97c2159e-276d-42c7-b34b-9352e17ae2c7 rw init=/usr/lib/iserv/bootpw --- udev: ii udev 175-7.2 amd64 /dev/ and hotplug management daem 6df86db16655769fa94086d3ee13453a /lib/udev/rules.d/64-md-raid.rules --- /dev: brw-rw---T 1 root disk 9, 0 Jun 18 13:50 /dev/md0 /dev/disk/by-id: total 0 lrwxrwxrwx 1 root root 9 Jun 18 13:50 ata-ATAPI_iHDS118_7 -> ../../sr0 lrwxrwxrwx 1 root root 9 Jun 18 13:50 ata-ST1000NM0033-9ZM173_Z1W3BS3A -> ../../sda lrwxrwxrwx 1 root root 10 Jun 18 13:50 ata-ST1000NM0033-9ZM173_Z1W3BS3A-part1 -> ../../sda1 lrwxrwxrwx 1 root root 10 Jun 18 13:50 ata-ST1000NM0033-9ZM173_Z1W3BS3A-part2 -> ../../sda2 lrwxrwxrwx 1 root root 10 Jun 18 13:50 ata-ST1000NM0033-9ZM173_Z1W3BS3A-part3 -> ../../sda3 lrwxrwxrwx 1 root root 9 Jun 18 13:50 md-name-unassigned:0 -> ../../md0 lrwxrwxrwx 1 root root 9 Jun 18 13:50 md-uuid-9e1e626b:660983fa:7c7743ce:a611dca9 -> ../../md0 lrwxrwxrwx 1 root root 9 Jun 18 13:50 scsi-SATA_ST1000NM0033-9Z_Z1W3BS3A -> ../../sda lrwxrwxrwx 1 root root 10 Jun 18 13:50 scsi-SATA_ST1000NM0033-9Z_Z1W3BS3A-part1 -> ../../sda1 lrwxrwxrwx 1 root root 10 Jun 18 13:50 scsi-SATA_ST1000NM0033-9Z_Z1W3BS3A-part2 -> ../../sda2 lrwxrwxrwx 1 root root 10 Jun 18 13:50 scsi-SATA_ST1000NM0033-9Z_Z1W3BS3A-part3 -> ../../sda3 lrwxrwxrwx 1 root root 9 Jun 18 13:50 wwn-0x5000c5007a6a1d2a -> ../../sda lrwxrwxrwx 1 root root 10 Jun 18 13:50 wwn-0x5000c5007a6a1d2a-part1 -> ../../sda1 lrwxrwxrwx 1 root root 10 Jun 18 13:50 wwn-0x5000c5007a6a1d2a-part2 -> ../../sda2 lrwxrwxrwx 1 root root 10 Jun 18 13:50 wwn-0x5000c5007a6a1d2a-part3 -> ../../sda3 /dev/disk/by-path: total 0 lrwxrwxrwx 1 root root 9 Jun 18 13:50 pci-0000:00:1f.2-scsi-0:0:0:0 -> ../../sda lrwxrwxrwx 1 root root 10 Jun 18 13:50 pci-0000:00:1f.2-scsi-0:0:0:0-part1 -> ../../sda1 lrwxrwxrwx 1 root root 10 Jun 18 13:50 pci-0000:00:1f.2-scsi-0:0:0:0-part2 -> ../../sda2 lrwxrwxrwx 1 root root 10 Jun 18 13:50 pci-0000:00:1f.2-scsi-0:0:0:0-part3 -> ../../sda3 /dev/disk/by-uuid: total 0 lrwxrwxrwx 1 root root 10 Jun 18 13:50 2af63259-f97c-4412-8aaa-7c4d77f961c0 -> ../../sda3 lrwxrwxrwx 1 root root 10 Jun 18 13:50 7d7b88a8-1099-4b52-b30c-f11594d77113 -> ../../sda1 lrwxrwxrwx 1 root root 9 Jun 18 13:50 97c2159e-276d-42c7-b34b-9352e17ae2c7 -> ../../md0 /dev/md: total 0 lrwxrwxrwx 1 root root 6 Jun 18 13:50 0 -> ../md0 Auto-generated on Mon, 06 Jul 2015 08:51:34 +0200 by mdadm bugscript 3.2.5-5 -- System Information: Debian Release: 7.8 APT prefers oldstable-updates APT policy: (500, 'oldstable-updates'), (500, 'oldstable') Architecture: amd64 (x86_64) Kernel: Linux 3.16.0-0.bpo.4-amd64 (SMP w/2 CPU cores) Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages mdadm depends on: ii debconf 1.5.49 ii initscripts 2.88dsf-41+deb7u1 ii libc6 2.13-38+deb7u8 ii lsb-base 4.1+Debian8+deb7u1 ii udev 175-7.2 Versions of packages mdadm recommends: ii exim4-daemon-heavy [mail-transport-agent] 4.80-7+deb7u1 ii module-init-tools 9-3 mdadm suggests no packages. -- debconf information: mdadm/autostart: true mdadm/mail_to: root mdadm/initrdstart_msg_errmd: mdadm/initrdstart: all mdadm/initrdstart_msg_errconf: mdadm/initrdstart_notinconf: false mdadm/initrdstart_msg_errexist: mdadm/initrdstart_msg_intro: mdadm/autocheck: true mdadm/initrdstart_msg_errblock: mdadm/start_daemon: true
--- /usr/share/mdadm/checkarray 2013-01-24 14:26:51.000000000 +0100 +++ checkarray 2015-07-06 08:44:29.770268955 +0200 @@ -205,8 +205,8 @@ resync_pid=$(ps -ef | awk -v dev=$array 'BEGIN { pattern = "^\\[" dev "_resync]$" } $8 ~ pattern { print $2 }') if [ -n "$resync_pid" ]; then [ $quiet -lt 1 ] && echo "$PROGNAME: I: selecting $ionice I/O scheduling class and $renice niceness for resync of $array." >&2 - ionice -p "$resync_pid" $ioarg || : - renice -n $renice -p "$resync_pid" 1>/dev/null || : + ionice -p "$resync_pid" $ioarg 2>/dev/null || : + renice -n $renice -p "$resync_pid" 1>/dev/null 2>&1 || : break fi sleep 1