- check_dev=/dev/`basename $device`1
-
- echo "pl_netinit: looking for node configuration file on device $check_dev"
- /bin/mount -o ro -t $NODE_CONF_DEVICE_FS_TYPES $check_dev \
- $CONF_DEVICE_MOUNT_POINT 2>&1 > /dev/null
- if [[ $? -eq 0 ]]; then
- if [ -r "$CONF_DEVICE_MOUNT_POINT/$NEW_NODE_CONF_NAME" ]; then
- echo "pl_netinit: found node configuration file plnode.txt, using"
+ partitions=$(/bin/awk "\$4 ~ /`basename $device`[0-9]*/ { print \$4 }" /proc/partitions)
+ for partition in $partitions ; do
+ check_dev=/dev/$partition
+
+ echo "pl_netinit: looking for node configuration file on device $check_dev"
+ /bin/mount -o ro -t $NODE_CONF_DEVICE_FS_TYPES $check_dev \
+ $CONF_DEVICE_MOUNT_POINT 2>&1 > /dev/null
+ if [[ $? -eq 0 ]]; then
+ if [ -r "$CONF_DEVICE_MOUNT_POINT/$NEW_NODE_CONF_NAME" ]; then
+ echo "pl_netinit: found node configuration file plnode.txt, using"
+
+ conf_file="$CONF_DEVICE_MOUNT_POINT/$NEW_NODE_CONF_NAME"
+ /etc/init.d/pl_validateconf < $conf_file > $USED_NET_CONF
+ echo "pl_netinit: found configuration"
+ /bin/umount $CONF_DEVICE_MOUNT_POINT
+ return 1
+ fi
+
+ echo "pl_netinit: not found"