the create_devices part of the script in /etc/init.d is wrong this is better create_devices() { local RESOURCES RESOURCE DEVICE # create dev if needed RESOURCES=`$DRBDADM sh-resources` #RESOURCES=${RESOURCE%%\ *} for RESOURCE in $RESOURCES; do DEVICE=`$DRBDADM sh-dev $RESOURCE` if [ ! -b ${DEVICE} ]; then mknod $DEVICE b 147 ${DEVICE/\/dev\/drbd\/} fi done } but the whole part is not needed any more (the module does this itself) but checking it does no harm Reproducible: Always Steps to Reproduce: 1. install drbd 7.10 (tested on kernel 2.6.10-gentoo-r6) 2. load the module (now look at /dev/drbd/* indeed the blackdevices are already there) 3. now start drbd (/etc/init.d/drbd start) Actual Results: mknod complains about wrong parameters but the test if the devices exist is already wrong, it checks for a file (-f), but should check for a block device (-b) Expected Results: two options here 1. if checking for the devices --> check for block devices 2. not check for the devices
also the major number is now assigned and 147 (can be checked in /usr/src/linux/Documentation/devices.txt)
it's necessary with udev. Check and device creation fixed in cvs. thanks