Hello community, here is the log from the commit of package open-iscsi checked in at Fri Jun 2 02:06:40 CEST 2006. -------- --- open-iscsi/open-iscsi.changes 2006-05-31 08:33:49.000000000 +0200 +++ open-iscsi/open-iscsi.changes 2006-06-01 17:10:43.000000000 +0200 @@ -1,0 +2,7 @@ +Thu Jun 1 17:06:24 CEST 2006 - hare@suse.de + +- Added new startmode 'onboot' for root on iSCSI +- Added new init script boot.open-iscsi startup + iscsid as early as possible (#176804) + +------------------------------------------------------------------- New: ---- boot.open-iscsi open-iscsi-startmode-onboot.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ open-iscsi.spec ++++++ --- /var/tmp/diff_new_pack.QsVP9b/_old 2006-06-02 02:06:30.000000000 +0200 +++ /var/tmp/diff_new_pack.QsVP9b/_new 2006-06-02 02:06:30.000000000 +0200 @@ -18,13 +18,14 @@ Prereq: %fillup_prereq %insserv_prereq Autoreqprov: on Version: 0.5.545 -Release: 11 +Release: 12 Provides: linux-iscsi Obsoletes: linux-iscsi %define iscsi_release 545 Summary: Linux* Open-iSCSI Software Initiator Source: %{name}-0.5-454.tar.gz Source2: open-iscsi.sysconfig +Source3: boot.open-iscsi Source12: iscsi-iname.c Patch1: %{name}-457.diff Patch2: %{name}-473.diff @@ -36,6 +37,7 @@ Patch8: %{name}-581.diff Patch9: %{name}-595.diff Patch12: %{name}-start-iscsi-after-xen +Patch20: %{name}-startmode-onboot.patch Patch21: %{name}-check-active-sessions-before-delete Patch22: %{name}-iscsi-iname-Makefile.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -77,6 +79,7 @@ %patch8 %patch9 %patch12 -p1 +%patch20 -p1 %patch21 -p1 %patch22 -p1 cp %{S:12} usr/ @@ -92,6 +95,7 @@ install -D -m 755 usr/iscsi-iname ${RPM_BUILD_ROOT}/sbin/iscsi-iname install -D -m 644 etc/iscsid.conf ${RPM_BUILD_ROOT}/etc/iscsid.conf install -D -m 755 etc/initd/initd.suse ${RPM_BUILD_ROOT}/etc/init.d/open-iscsi +install -D -m 755 %{S:3} ${RPM_BUILD_ROOT}/etc/init.d/boot.open-iscsi (cd ${RPM_BUILD_ROOT}/sbin; ln -sf /etc/init.d/open-iscsi rcopen-iscsi) mkdir -p ${RPM_BUILD_ROOT}/var/adm/fillup-templates install -m 755 %{S:2} ${RPM_BUILD_ROOT}/var/adm/fillup-templates/sysconfig.open-iscsi @@ -105,6 +109,7 @@ %post %{fillup_and_insserv -n open-iscsi} +%{fillup_and_insserv -Y boot.open-iscsi} if [ ! -f /etc/initiatorname.iscsi ]; then cat << EOF >> /etc/initiatorname.iscsi ## DO NOT EDIT OR REMOVE THIS FILE! @@ -132,6 +137,7 @@ %defattr(-,root,root) %attr(0600,root,root) %config(noreplace) /etc/iscsid.conf %config /etc/init.d/open-iscsi +%config /etc/init.d/boot.open-iscsi /sbin/* /var/adm/fillup-templates/sysconfig.open-iscsi %dir /var/lib/open-iscsi @@ -139,6 +145,10 @@ %doc %{_mandir}/man8/* %changelog -n open-iscsi +* Thu Jun 01 2006 - hare@suse.de +- Added new startmode 'onboot' for root on iSCSI +- Added new init script boot.open-iscsi startup + iscsid as early as possible (#176804) * Wed May 31 2006 - hare@suse.de - update to svn r595 - Include local patches ++++++ open-iscsi-startmode-onboot.patch ++++++ diff --git a/etc/initd/initd.suse b/etc/initd/initd.suse index 8862210..b65f3c1 100644 --- a/etc/initd/initd.suse +++ b/etc/initd/initd.suse @@ -56,17 +56,20 @@ iscsi_logout_all_nodes() # Logout from all active sessions TARGETS=$($ISCSIADM -m session | sed 's@\[[^:]*:\(.*\)\] .*@\1@g') for rec in $TARGETS; do + STARTUP=`$ISCSIADM -m node -r $rec | grep "node.conn\[0\].startup" | cut -d' ' -f3` NODE=`$ISCSIADM -m node -r $rec | grep "node.name" | cut -d' ' -f3` - echo -n "Logging out from $NODE: " - if $ISCSIADM -m node --record $rec --logout ; then - rc_status -v + if [ $STARTUP != "onboot" ] ; then + echo -n "Logging out from $NODE: " + if $ISCSIADM -m node --record $rec --logout ; then + rc_status -v + else + RETVAL=$? + rc_failed $RETVAL + fi else - RETVAL=$? - rc_failed $RETVAL + RETVAL=1 fi done - # Not sure whether this is still needed - sleep 1 return ${RETVAL:-0} } @@ -85,13 +88,17 @@ iscsi_list_all_nodes() case "$1" in start) [ ! -d /var/lib/iscsi ] && mkdir -p /var/lib/iscsi - echo -n "Starting iSCSI initiator service: " - modprobe scsi_transport_iscsi - modprobe libiscsi - modprobe iscsi_tcp - startproc $DAEMON $ARGS - RETVAL=$? - rc_status -v + if checkproc $DAEMON ; then + RETVAL=0 + else + echo -n "Starting iSCSI initiator service: " + modprobe scsi_transport_iscsi + modprobe libiscsi + modprobe iscsi_tcp + startproc $DAEMON $ARGS + RETVAL=$? + rc_status -v + fi if [ "$RETVAL" == "0" ]; then iscsi_login_all_nodes fi diff --git a/kernel/iscsi_tcp.c b/kernel/iscsi_tcp.c diff --git a/kernel/libiscsi.h b/kernel/libiscsi.h diff --git a/usr/idbm.c b/usr/idbm.c index 70c69d1..6271ce2 100644 --- a/usr/idbm.c +++ b/usr/idbm.c @@ -687,8 +687,8 @@ idbm_recinfo_node(node_rec_t *r, recinfo IDBM_SHOW, num); __recinfo_int("node.tpgt", ri, r, tpgt, IDBM_SHOW, num); __recinfo_int("node.active_conn", ri, r, active_conn, IDBM_SHOW, num); - __recinfo_int_o2("node.startup", ri, r, startup, - IDBM_SHOW, "manual", "automatic", num); + __recinfo_int_o3("node.startup", ri, r, startup, + IDBM_SHOW, "manual", "automatic", "onboot", num); __recinfo_int("node.session.initial_cmdsn", ri, r, session.initial_cmdsn, IDBM_SHOW, num); __recinfo_int_o2("node.session.auth.authmethod", ri, r, @@ -742,8 +742,8 @@ idbm_recinfo_node(node_rec_t *r, recinfo sprintf(key, "node.conn[%d].port", i); __recinfo_int(key, ri, r, conn[i].port, IDBM_SHOW, num); sprintf(key, "node.conn[%d].startup", i); - __recinfo_int_o2(key, ri, r, conn[i].startup, IDBM_SHOW, - "manual", "automatic", num); + __recinfo_int_o3(key, ri, r, conn[i].startup, IDBM_SHOW, + "manual", "automatic", "onboot", num); sprintf(key, "node.conn[%d].tcp.window_size", i); __recinfo_int(key, ri, r, conn[i].tcp.window_size, IDBM_SHOW, num); ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit-unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit-help@opensuse.org