This is also happening in oneiric ocelot package 2.0.871-0ubuntu9.
Running the following:
iscsiadm -m discovery -t st -p 169.169.169.12
iscsiadm -m node -T "iqn.2008-08.com.starwindsoftware:-testing" -v automatic --portal "169.169.169.12"
automatically creates a folder structure like:
/etc/iscsi/nodes/iqn.2008-08.com.starwindsoftware\:-testing/169.169.169.12\,3260
thus it never automatically starts because the following init.d script chunk never runs properly.
ISCSI_TARGET_NB=$(cat /etc/iscsi/nodes/*/*/default 2>/dev/null| grep -c automatic)
ISCSI_SESSION_NB=$($ADM -m session 2>/dev/null | grep -c ^)
if [ "${ISCSI_TARGET_NB}" -ne "${ISCSI_SESSION_NB}" ]; then
$ADM -m node --loginall=automatic > /dev/null
udevadm settle
fi
Two possible workarounds:
Change ISCSI_TARGET_NB=$(cat /etc/iscsi/nodes/*/*/default 2>/dev/null| grep -c automatic) to ISCSI_TARGET_NB=$(cat /etc/iscsi/nodes/*/* 2>/dev/null| grep -c automatic)
This is also happening in oneiric ocelot package 2.0.871-0ubuntu9.
Running the following: 08.com. starwindsoftwar e:-testing" -v automatic --portal "169.169.169.12"
iscsiadm -m discovery -t st -p 169.169.169.12
iscsiadm -m node -T "iqn.2008-
automatically creates a folder structure like: nodes/iqn. 2008-08. com.starwindsof tware\: -testing/ 169.169. 169.12\ ,3260
/etc/iscsi/
thus it never automatically starts because the following init.d script chunk never runs properly. NB=$(cat /etc/iscsi/ nodes/* /*/default 2>/dev/null| grep -c automatic) NB=$($ADM -m session 2>/dev/null | grep -c ^) TARGET_ NB}" -ne "${ISCSI_ SESSION_ NB}" ]; then automatic > /dev/null
ISCSI_TARGET_
ISCSI_SESSION_
if [ "${ISCSI_
$ADM -m node --loginall=
udevadm settle
fi
Two possible workarounds: NB=$(cat /etc/iscsi/ nodes/* /*/default 2>/dev/null| grep -c automatic) to ISCSI_TARGET_ NB=$(cat /etc/iscsi/ nodes/* /* 2>/dev/null| grep -c automatic)
Change ISCSI_TARGET_
or
mkdir /etc/iscsi/ nodes/iqn. 2008-08. com.starwindsof tware\: -testing/ automatic nodes/iqn. 2008-08. com.starwindsof tware\: -testing/ automatic/ default
echo "automatic" >> /etc/iscsi/