opensm/configure.in: Remove Default-Start from opensmd init script
PATCH 1/1 opensm/configure.in: Remove Default-Start from opensmd init script
During opensm RPM packaging, chkconfig --add opensmd is called. chkconfig --add creates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot isn't desired.
--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
configure.in +3 -2
@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}}) if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null 2>&1; then - default_start="2 3 5" default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)
Signature · 6 lines
1.7.11.7 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20130129171850.GB2961-iQai9MGU/dze+A/[email protected]
Quoted 19 lines · Alex Netes
During opensm RPM packaging,
chkconfig --add opensmdis called.chkconfig --addcreates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot isn't desired.--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)configure.in +0
-1@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}}) if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null 2>&1; then - default_start="2 3 5"
configure.in AC_ARG_WITH([rdma_service], · line 29
Quoted 10 lines
configure.in +3
-1default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)
Sorry but this patch doesn't make sense to me. This patch will prevent anyone to enable opensm to run during boot via chkconfig. How about replacing the above by the (untested) patch below ?
iff --git a/opensm.spec.in b/opensm.spec.in
index 6ae525b..2325b70 100644
opensm.spec.in +0 -7
@@ -107,13 +107,6 @@ rm -rf $RPM_BUILD_ROOT %post if [ $1 = 1 ]; then - if [ -e /sbin/chkconfig ]; then - /sbin/chkconfig --add opensmd - elif [ -e /usr/sbin/update-rc.d ]; then - /usr/sbin/update-rc.d opensmd defaults - else - /usr/lib/lsb/install_initd /etc/init.d/opensmd - fi if type systemctl >/dev/null 2>&1; then systemctl --system daemon-reload fi
Bart.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 54 lines · Bart Van Assche
Quoted 19 lines · Alex Netes
During opensm RPM packaging,
chkconfig --add opensmdis called.chkconfig --addcreates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot isn't desired.--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)configure.in +0
-1@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}}) if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null 2>&1; then - default_start="2 3 5"configure.in AC_ARG_WITH([rdma_service], · line 29
Quoted 10 lines
configure.in +3
-1default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)Sorry but this patch doesn't make sense to me. This patch will prevent anyone to enable opensm to run during boot via chkconfig. How about replacing the above by the (untested) patch below ?
iff --git a/opensm.spec.in b/opensm.spec.in
index 6ae525b..2325b70 100644opensm.spec.in +0
-7@@ -107,13 +107,6 @@ rm -rf $RPM_BUILD_ROOT %post if [ $1 = 1 ]; then - if [ -e /sbin/chkconfig ]; then - /sbin/chkconfig --add opensmd - elif [ -e /usr/sbin/update-rc.d ]; then - /usr/sbin/update-rc.d opensmd defaults - else - /usr/lib/lsb/install_initd /etc/init.d/opensmd - fi if type systemctl >/dev/null 2>&1; then systemctl --system daemon-reload fi
Quoted 2 lines
Bart.
Thanks. I was sure that you need to add the service prior to be able to enable/disable it. Your suggestion works on RHEL/SUSE. I'll also test in on Debian.
--Alex
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 18 lines · Bart Van Assche
Quoted 17 lines · Alex Netes
During opensm RPM packaging,
chkconfig --add opensmdis called.chkconfig --addcreates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot isn't desired.--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)configure.in +0
-0@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}})
Quoted 16 lines
configure.in
Quoted 13 lines
configure.in +0
-0if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null2>&1; then
configure.in +3
-2- default_start="2 3 5" default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)Sorry but this patch doesn't make sense to me. This patch will prevent anyone to enable opensm to run during boot via chkconfig.
It does not. It means that chkconfig add does not create any start links, just all kill links. To actually enabled it, chkconfig --level 2345 opensmd on will still work. Which was the intent: leave it off by default, enabled by the admin.
Quoted 11 lines
How about
replacing the above by the (untested) patch below ?iff --git a/opensm.spec.in b/opensm.spec.in
index 6ae525b..2325b70 100644opensm.spec.in +0
-0@@ -107,13 +107,6 @@ rm -rf $RPM_BUILD_ROOT %post if [ $1 = 1 ]; then
opensm.spec.in rm -rf $RPM_BUILD_ROOT · line 112
Quoted 10 lines
opensm.spec.in +0
-7- if [ -e /sbin/chkconfig ]; then - /sbin/chkconfig --add opensmd - elif [ -e /usr/sbin/update-rc.d ]; then - /usr/sbin/update-rc.d opensmd defaults - else - /usr/lib/lsb/install_initd /etc/init.d/opensmd - fi if type systemctl >/dev/null 2>&1; then systemctl --system daemon-reload fi
This is not the correct fix. It leaves the init script unadded to the system, which means chkconfig --list will not show it properly until the user manually adds it later.
Signature · 10 lines
Doug Ledford <[email protected]> GPG KeyID: 0E572FDD http://people.redhat.com/dledford Infiniband specific RPMs available at http://people.redhat.com/dledford/Infiniband -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 50 lines · Doug Ledford
Quoted 18 lines · Bart Van Assche
Quoted 17 lines · Alex Netes
During opensm RPM packaging,
chkconfig --add opensmdis called.chkconfig --addcreates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot isn't desired.--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)configure.in +0
-0@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}})Quoted 16 lines
configure.in
Quoted 13 lines
configure.in +0
-0if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null2>&1; then
configure.in +3
-2- default_start="2 3 5" default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)Sorry but this patch doesn't make sense to me. This patch will prevent anyone to enable opensm to run during boot via chkconfig.
It does not. It means that chkconfig add does not create any start links, just all kill links. To actually enabled it, chkconfig --level 2345 opensmd on will still work. Which was the intent: leave it off by default, enabled by the admin.
Quoted 9 lines
How about
replacing the above by the (untested) patch below ?iff --git a/opensm.spec.in b/opensm.spec.in
index 6ae525b..2325b70 100644opensm.spec.in +0
-0@@ -107,13 +107,6 @@ rm -rf $RPM_BUILD_ROOT
Quoted 16 lines
opensm.spec.in rm -rf $RPM_BUILD_ROOT · line 112
Quoted 12 lines
opensm.spec.in +0
-7%post if [ $1 = 1 ]; then - if [ -e /sbin/chkconfig ]; then - /sbin/chkconfig --add opensmd - elif [ -e /usr/sbin/update-rc.d ]; then - /usr/sbin/update-rc.d opensmd defaults - else - /usr/lib/lsb/install_initd /etc/init.d/opensmd - fi if type systemctl >/dev/null 2>&1; then systemctl --system daemon-reload fiThis is not the correct fix. It leaves the init script unadded to the system, which means chkconfig --list will not show it properly until the user manually adds it later.
Which convention is followed for other packages ? This is what I found in the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):
* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:
%post/sbin/ldconfig
if [ "$1" -eq "1" ]; then
if [ ! -f %{_sysconfdir}/iscsi/initiatorname.iscsi ]; then
echo "InitiatorName=/sbin/iscsi-iname" >
%{_sysconfdir}/iscsi/initiatorname.iscsi
fi
/sbin/chkconfig --add iscsid
/sbin/chkconfig --add iscsifi
Bart.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 70 lines · Bart Van Assche
Quoted 52 lines · Doug Ledford
Quoted 20 lines · Bart Van Assche
Quoted 19 lines · Alex Netes
During opensm RPM packaging,
chkconfig --add opensmdis called.chkconfig --addcreates the appropriate entry as specified by the default values in the init script. Having opensmd run by default on boot
isn't desired.--- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)configure.in +0
-0@@ -18,12 +18,13 @@ AC_ARG_WITH([rdma_service], AC_SUBST(RDMA_SERVICE, ${with_rdma_service:-${default_rdma_service}})Quoted 16 lines
configure.in
Quoted 13 lines
configure.in +0
-0if { rpm -q sles-release || rpm -q openSUSE-release; } >/dev/null2>&1; then
configure.in +3
-2- default_start="2 3 5" default_stop="0 1 4 6" else - default_start="2 3 4 5" default_stop="0 1 6" fi + +default_start="null" + AC_SUBST(DEFAULT_START, $default_start) AC_SUBST(DEFAULT_STOP, $default_stop)Sorry but this patch doesn't make sense to me. This patch will prevent anyone to enable opensm to run during boot via chkconfig.
It does not. It means that chkconfig add does not create any start links, just all kill links. To actually enabled it, chkconfig --level 2345 opensmd on will still work. Which was the intent: leave it off by default, enabled by the admin.
Quoted 9 lines
How about
replacing the above by the (untested) patch below ?iff --git a/opensm.spec.in b/opensm.spec.in
index 6ae525b..2325b70 100644opensm.spec.in +0
-0@@ -107,13 +107,6 @@ rm -rf $RPM_BUILD_ROOTQuoted 16 lines
opensm.spec.in rm -rf $RPM_BUILD_ROOT · line 112
Quoted 12 lines
opensm.spec.in +0
-7%post if [ $1 = 1 ]; then - if [ -e /sbin/chkconfig ]; then - /sbin/chkconfig --add opensmd - elif [ -e /usr/sbin/update-rc.d ]; then - /usr/sbin/update-rc.d opensmd defaults - else - /usr/lib/lsb/install_initd /etc/init.d/opensmd - fi if type systemctl >/dev/null 2>&1; then systemctl --system daemon-reload fiThis is not the correct fix. It leaves the init script unadded to the system, which means chkconfig --list will not show it properly until the user manually adds it later.
Quoted 6 lines
Which convention is followed for other packages ? This is what I found in the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:
Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Quoted 12 lines
%post
/sbin/ldconfig
if [ "$1" -eq "1" ]; then
if [ ! -f %{_sysconfdir}/iscsi/initiatorname.iscsi ]; then
echo "InitiatorName=/sbin/iscsi-iname" >
%{_sysconfdir}/iscsi/initiatorname.iscsifi /sbin/chkconfig --add iscsid /sbin/chkconfig --add iscsifi
Bart.
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 18 lines · Doug Ledford
Quoted 6 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g. http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.
Bart.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 27 lines · Bart Van Assche
Quoted 20 lines · Doug Ledford
Quoted 8 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in
the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Quoted 8 lines
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g.
http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.Bart.
I've always used "Default-start:" without any listed levels, but I haven't really tested it either and the spec is not specific about this particular possible configuration.
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 35 lines · Doug Ledford
Quoted 34 lines · Bart Van Assche
Quoted 20 lines · Doug Ledford
Quoted 8 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in
the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g.
http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.
Quoted 7 lines
Quoted 1 line
Bart.
I've always used "Default-start:" without any listed levels, but I haven't really tested it either and the spec is not specific about this particular possible configuration.
It's how the script was defined before. The behavior on RHEL and SLES is different when not specifying "Default-start:". On RHEL, chkconfig opensmd on adds the service to the default runlevels: 2 3 4 5. While on SLES it doesn't. --
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20130131072100.GU2961-iQai9MGU/dze+A/[email protected]
Quoted 44 lines · Alex Netes
Quoted 35 lines · Doug Ledford
Quoted 34 lines · Bart Van Assche
Quoted 20 lines · Doug Ledford
Quoted 8 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in
the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g.
http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.Quoted 7 lines
Quoted 1 line
Bart.
I've always used "Default-start:" without any listed levels, but I haven't really tested it either and the spec is not specific about this particular possible configuration.
Quoted 3 lines
It's how the script was defined before. The behavior on RHEL and SLES is different when not specifying "Default-start:". On RHEL,
chkconfig opensmd onadds the service to the default runlevels: 2 3 4 5. While on SLES it doesn't.
That sounds like a bug in SLES to be honest. chkconfig opensmd on without --levels should follow the Default-Start: item (just like chkconfig add opensmd).
Signature · 10 lines
Doug Ledford <[email protected]> GPG KeyID: 0E572FDD http://people.redhat.com/dledford Infiniband specific RPMs available at http://people.redhat.com/dledford/Infiniband -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 45 lines · Doug Ledford
Quoted 44 lines · Alex Netes
Quoted 42 lines · Doug Ledford
Quoted 27 lines · Bart Van Assche
Quoted 20 lines · Doug Ledford
Quoted 8 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in
the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Quoted 8 lines
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g.
http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.Bart.
I've always used "Default-start:" without any listed levels, but I haven't really tested it either and the spec is not specific about this particular possible configuration.
Quoted 8 lines
Quoted 3 lines
It's how the script was defined before. The behavior on RHEL and SLES is different when not specifying "Default-start:". On RHEL,
chkconfig opensmd onadds the service to the default runlevels: 2 3 4 5. While on SLES it doesn't.That sounds like a bug in SLES to be honest. chkconfig opensmd on without --levels should follow the Default-Start: item (just like chkconfig add opensmd).
I think that RHEL and SLES implemented chkconfig differently. From man page of chkconfig on RHEL: "By default, the on and off options affect only runlevels 2, 3, 4, and 5". While in SLES nothing is mentioned regarding the defaults.
It's not acceptable to load opensm by default on boot, so I don't see other choice right now except of reverting commit 01ab74450fd1227cf2dfb9219ffd697d3beb4a45 or doing something similar of what I suggested at the start of the thread.
--Alex
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20130204153631.GC13151-iQai9MGU/dze+A/[email protected]
Quoted 55 lines · Alex Netes
Quoted 45 lines · Doug Ledford
Quoted 44 lines · Alex Netes
Quoted 42 lines · Doug Ledford
Quoted 27 lines · Bart Van Assche
Quoted 20 lines · Doug Ledford
Quoted 8 lines · Bart Van Assche
Which convention is followed for other packages ? This is what I found in
the Fedora 18 iscsi-initiator-utils package
(http://be.mirror.eurid.eu/fedora/linux/releases/18/Fedora/source/SRPMS/i/iscsi-initiator-utils-6.2.0.872-19.fc18.src.rpm):* iscsid.init: Default-Start: 3 4 5
* iscsi-initiator-utils.spec:Okay, first off, any package that still uses the SysV initscripts as of Fedora 18 is not what I would call a package that is keeping up with the Fedora packaging guidelines or Fedora technologies. As such, I'm not really sure you want to use it as an example of a good package. However, that being said, you will note in this spec file that the iSCSI initiator package does exactly what you removed, or suggested be removed, from the opensmd spec file. It unilaterally adds the initscript to the system. The default start/stop settings are different, but the add action is the same.
Quoted 5 lines
All initscripts should be added to the system, regardless of their default start/stop settings, and the default-start and default-stop should be used to control *how* they are added by default, and chkconfig --level .* <scriptname> [on|off] should be used to control whether or not they are on or off differently than their default settings.
Quoted 8 lines
Thanks for the detailed reply. Regarding the purpose of the patch at the start of this thread: do you know whether it is LSB-compliant to use "Default-Start: null" or should "Default-Start" be left out entirely in order not to create the start links ? See e.g.
http://refspecs.linuxbase.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.Bart.
I've always used "Default-start:" without any listed levels, but I haven't really tested it either and the spec is not specific about this particular possible configuration.
Quoted 8 lines
Quoted 3 lines
It's how the script was defined before. The behavior on RHEL and SLES is different when not specifying "Default-start:". On RHEL,
chkconfig opensmd onadds the service to the default runlevels: 2 3 4 5. While on SLES it doesn't.That sounds like a bug in SLES to be honest. chkconfig opensmd on without --levels should follow the Default-Start: item (just like chkconfig add opensmd).
Quoted 7 lines
I think that RHEL and SLES implemented chkconfig differently. From man page of chkconfig on RHEL: "By default, the on and off options affect only runlevels 2, 3, 4, and 5". While in SLES nothing is mentioned regarding the defaults.
It's not acceptable to load opensm by default on boot, so I don't see other choice right now except of reverting commit01ab74450fd1227cf2dfb9219ffd697d3beb4a45or doing something similar of what I suggested at the start of the thread.
But why has commit 01ab744 to be reverted ? All that's needed to avoid that chkconfig gets enabled at boot during RPM installation is something like the patch at the top of this thread. Unless I'm overlooking something ?
Bart.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html