SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
During boot, I have always got messages about RAID. Before, using the huge kernel, these did not worry me particularly, but now that I have switched to the generic kernel and initrd, the boot process really slows down when it comes to the RAID part.
I have a bog normal PC with two ide disks, two dvd drives, one of them a burner and USB1 and USB2 ports - the USB2 ports are on a card as my PC is a somewhat elderly P4.
I'm sure I don't have RAID - or do I?
If not I want to stop it searching for and configuring RAID.
Here are the messages from dmesg:
Code:
hda: Maxtor 6Y060L0, ATA DISK drive
hdb: MAXTOR STM3802110A, ATA DISK drive
hda: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hda: host side 80-wire cable detection failed, limiting max speed to UDMA33
hda: UDMA/33 mode selected
hdb: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hdb: host side 80-wire cable detection failed, limiting max speed to UDMA33
hdb: UDMA/33 mode selected
Probing IDE interface ide1...
hdc: Optiarc DVD RW AD-5170A, ATAPI CD/DVD-ROM drive
hdd: LG CD-RW CED-8081B, ATAPI CD/DVD-ROM drive
hdc: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hdc: host side 80-wire cable detection failed, limiting max speed to UDMA33
hdc: UDMA/33 mode selected
hdd: host max PIO4 wanted PIO255(auto-tune) selected PIO4
hdd: MWDMA2 mode selected
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
ide1 at 0x170-0x177,0x376 on irq 15
ide-gd driver 1.18
hda: max request size: 128KiB
hda: 120103200 sectors (61492 MB) w/2048KiB Cache, CHS=65535/16/63
hda: cache flushes supported
hda: hda1 hda2 hda3 < hda5 hda6 hda7 hda8 hda9 hda10 > hda4
hdb: max request size: 512KiB
hdb: 156301488 sectors (80026 MB) w/2048KiB Cache, CHS=16383/255/63
hdb: cache flushes supported
hdb: hdb1 hdb3 < hdb5 hdb6 hdb7 > hdb4
ide-cd driver 5.00
ide-cd: hdc: ATAPI 48X DVD-ROM DVD-R CD-R/RW drive, 2048kB Cache
Uniform CD-ROM driver Revision: 3.20
ide-cd: hdd: ATAPI 32X CD-ROM CD-R/RW drive, 2048kB Cache
Driver 'sd' needs updating - please use bus_type methods
Driver 'sr' needs updating - please use bus_type methods
PNP: PS/2 Controller [PNP0303:KEYB,PNP0f13:PS2M] at 0x60,0x64 irq 1,12
serio: i8042 KBD port at 0x60,0x64 irq 1
serio: i8042 AUX port at 0x60,0x64 irq 12
mice: PS/2 mouse device common for all mice
md: linear personality registered for level -1
md: raid0 personality registered for level 0
md: raid1 personality registered for level 1
md: raid10 personality registered for level 10
raid6: int32x1 359 MB/s
raid6: int32x2 417 MB/s
raid6: int32x4 621 MB/s
raid6: int32x8 367 MB/s
raid6: mmxx1 1101 MB/s
raid6: mmxx2 1601 MB/s
raid6: sse1x1 578 MB/s
raid6: sse1x2 859 MB/s
raid6: sse2x1 910 MB/s
raid6: sse2x2 1117 MB/s
raid6: using algorithm sse2x2 (1117 MB/s)
md: raid6 personality registered for level 6
md: raid5 personality registered for level 5
md: raid4 personality registered for level 4
md: multipath personality registered for level -4
device-mapper: ioctl: 4.14.0-ioctl (2008-04-23) initialised: dm-devel@redhat.com
cpuidle: using governor ladder
TCP cubic registered
As I said, I can't. The boot process really slows down to a standstill when it gets to the part where it is doing the probing etc. for raid. In short, it slows down the boot process considerably.
Add raid=noautodetect to your kernel command line. It won't stop you seeing the md messages you get in the log when the driver loads, but it'll stop it attempting to scan for an array to build. I'm not convinced this is what's slowing your boot down however, as it whizzes by on mine, but if you think it is, it's worth a try.
You could try compiling your own kernel with the RAID drivers taken out. There are guides all over the place for compiling a custom kernel. Admittedly, it's not a "quick fix" if you have never done this before but might be something worth considering.
Add raid=noautodetect to your kernel command line. It won't stop you seeing the md messages you get in the log when the driver loads, but it'll stop it attempting to scan for an array to build.
Yes, they did whizz by, but then strangley it stopped and mdadm ran, bringing the message that no config file was found and that "this might take a bit of time". It did.
Unfortunately those were console meassges that are not in dmesg and were too early in the startup to be captured by bootlogd.
I can't find where or how mdadm is called.
Quote:
Originally Posted by trumpet_tom
You could try compiling your own kernel with the RAID drivers taken out. There are guides all over the place for compiling a custom kernel. Admittedly, it's not a "quick fix" if you have never done this before but might be something worth considering.
I've only ever done it once before - about 2 years ago - so I need the practice
But it seems to be the only solution.
I'm just wondering whether you might have accidentally included RAID support in the initrd by using the '-R' option on mkinitrd or RAID=1 in mkinitrd.conf. If you do a "ls /boot/initrd-tree/sbin/mdadm" does it find anything? If you do, then try to rebuild your initrd without raid support and see if that helps.
$ ls /boot/initrd-tree/sbin/mdadm
/boot/initrd-tree/sbin/mdadm
Yup. You're right.
Here's my present mkinitrd.conf:
Code:
# mkinitrd.conf
# See "man mkinitrd.conf" for details on the syntax of this file
#
# built according to man mkinitrd.conf
#
#
SOURCE_TREE="/boot/initrd-tree"
CLEAR_TREE="0"
OUTPUT_IMAGE="/boot/initrd.gz"
KERNEL_VERSION="$(uname -r)"
KEYMAP="us"
MODULE_LIST="ext2"
#LUKSDEV="/dev/hda1"
ROOTDEV="/dev/hda2"
ROOTFS="ext2"
RESUMEDEV="/dev/hda6"
#RAID="0"
#LVM="0"
WAIT="1"
I thought that unset, RAID defaulted to "0"
. In anycase I shall run it again, "mkinitrd -F", with RAID=0 and LVM=0. I shall also add CLEAR_TREE="1".
using /lib/modules/2.6.29.6-smp/kernel/fs/ext2/ext2.ko
initrd.gz: loading us mapping
mdadm: No arrays found in config file
reading all physical volumes
this may take a while.....
Here is mkinitrd.conf:
Code:
# mkinitrd.conf
# See "man mkinitrd.conf" for details on the syntax of this file
#
# built according to man mkinitrd.conf
#
#
SOURCE_TREE="/boot/initrd-tree"
CLEAR_TREE="1"
OUTPUT_IMAGE="/boot/initrd.gz"
KERNEL_VERSION="$(uname -r)"
KEYMAP="us"
MODULE_LIST="ext2"
## LUKSDEV="/dev/hda1"
ROOTDEV="/dev/hda2"
ROOTFS="ext2"
RESUMEDEV="/dev/hda6"
RAID="0"
LVM="0"
WAIT="1"
Although if you remove /boot/initrd-tree manually prior to re-running mkinitrd, you should not even have a /boot/initrd-tree/sbin/mdadm present at all.
Ahh, if you look in the /sbin/mkinitrd script you find this.
Code:
if [ ! -z "$RAID" ]; then
if [ -r /sbin/mdadm ]; then
mkdir -p $SOURCE_TREE/sbin
cp /sbin/mdadm $SOURCE_TREE/sbin/mdadm
chmod 0755 $SOURCE_TREE/sbin/mdadm
else
echo "ERROR: mdadm binary is missing, RAID support not installed"
fi
fi
You need to either comment out your LVM=, and RAID= lines, or set them to "".
RAID="0" won't do the trick.
I don't know if they've reworked it since 13.0 (I'm using current), but all it does is source in the mkinitrd.conf file, so yes, an unset RAID= should work.
# mkinitrd.conf
# See "man mkinitrd.conf" for details on the syntax of this file
#
# built according to man mkinitrd.conf
#
#
SOURCE_TREE="/boot/initrd-tree"
CLEAR_TREE="1"
OUTPUT_IMAGE="/boot/initrd.gz"
KERNEL_VERSION="$(uname -r)"
KEYMAP="us"
MODULE_LIST="ext2"
## LUKSDEV="/dev/hda1"
ROOTDEV="/dev/hda2"
ROOTFS="ext2"
RESUMEDEV="/dev/hda6"
RAID=""
LVM=""
WAIT="1"
Many thanks
Now to see what else I can throw out of startup.....
So, when you had them commented out, it didn't work, but setting them to "" worked? How strange.
All I can think of there is that those variables were somehow exported from your shell environment and were being inherited. The mkinitrd script probably ought to unset them at the beginning to avoid things like that.
Anyway, whatever the reason. glad you got there in the end.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.