Package: noflushd
Version: 2.7.4-1
Severity: important
Tags: patch
Hi,
when running noflushd on a kernel with software RAID support it exits with a
BUG:
kelvin:~# noflushd -v -d -n 5 /dev/hda
Kernel talks oldstyle dev
Probing for valid blkdev at /dev/hda
Detected oldstyle dev at /dev/hda
Kernel talks oldstyle dev
Added entry for /dev/hda (3, 0)
Added disk /dev/hda, current timeout 300, state 2
Controlling pdflush daemon
Kernel talks linux 2.5-style stat
pdflush stopped
Check interval 5
Allocated stat entry for (1, 0)
[...]
Allocated stat entry for (3, 0)
BUG at disk_stat.c line 517: No entry for (9,0)
pdflush restarted with interval 500.
Speicherzugriffsfehler
kelvin:~#
The bug is triggered since the stat file reports the device md0 (in
update_io_25) and the
called alloc_entry_new function returns always NULL for virtual (MD and LVM)
devices, so
the BUG is triggered.
The following small patch adds a check for virtual block devices before
triggering a BUG:
=====================================[CUT
HERE]=====================================
diff -rNu noflushd-2.7.4/src/disk_stat.c noflushd-2.7.4.mdfix/src/disk_stat.c
--- noflushd-2.7.4/src/disk_stat.c 2004-08-08 17:06:29.000000000 +0200
+++ noflushd-2.7.4.mdfix/src/disk_stat.c 2005-05-08 23:30:20.248325040
+0200
@@ -400,7 +400,8 @@
di->newio.reads = rblk;
di->newio.writes = wblk;
} else {
- BUG("No entry for (%d,%d)", major, index);
+ if (major != MD_MAJOR && major != LVM_BLK_MAJOR)
+ BUG("No entry for (%d,%d)", major,
index);
}
}
@@ -514,7 +515,8 @@
di->newio.reads = rblk;
di->newio.writes = wblk;
} else {
- BUG("No entry for (%d,%d)", major, minor);
+ if (major != MD_MAJOR && major != LVM_BLK_MAJOR)
+ BUG("No entry for (%d,%d)", major, minor);
}
}
}
=====================================[CUT
HERE]=====================================
Thomas
-- System Information:
Debian Release: 3.1
APT prefers testing
APT policy: (500, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.11-fiasko-ide-pentium-iii
Locale: [EMAIL PROTECTED], [EMAIL PROTECTED] (charmap=ISO-8859-15)
Versions of packages noflushd depends on:
ii debconf [debconf-2.0] 1.4.30.13 Debian configuration management sy
ii ed 0.2-20 The classic unix line editor
ii libc6 2.3.2.ds1-21 GNU C Library: Shared libraries an
-- debconf information:
noflushd/expert: false
* noflushd/disks: /dev/hda
* noflushd/timeout: 5
noflushd/params:
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]