[yast-commit] [ci_new_pac] JFYI yast2-fcoe-client -> sle12
Script 'mail_helper' called by ro Hello packager, This is just FYI. Your package was checked in in distribution "sle12" by autobuild-member: ro. Here comes the log... ---------------------------%<------------------------------ Hi, here is the log from ci_new_pac /mounts/work_src_done/SLE12/yast2-fcoe-client -> sle12 Changes: -------- --- /work/SRC/SUSE:SLE-12:GA/yast2-fcoe-client/yast2-fcoe-client.changes 2014-01-17 14:16:28.000000000 +0100 +++ /mounts/work_src_done/SLE12/yast2-fcoe-client/yast2-fcoe-client.changes 2014-03-28 13:56:30.000000000 +0100 @@ -1,0 +2,6 @@ +Fri Mar 28 13:14:21 CET 2014 - gs@suse.de + +- Adapt start of services (resp. sockets) to systemd +- 3.1.4 + +------------------------------------------------------------------- calling whatdependson for sle12-i586 Packages directly triggered for rebuild: - yast2-fcoe-client ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/SUSE:SLE-12:GA/yast2-fcoe-client (Old) and /mounts/work_src_done/SLE12/yast2-fcoe-client (BS:build ID:35128 MAIL:yast-commit@opensuse.org) (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "yast2-fcoe-client", Maintainer is "yast-commit@opensuse.org" Old: ---- yast2-fcoe-client-3.1.3.tar.bz2 New: ---- yast2-fcoe-client-3.1.4.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-fcoe-client.spec ++++++ --- /var/tmp/diff_new_pack.YhBrVe/_old 2014-03-28 16:29:45.000000000 +0100 +++ /var/tmp/diff_new_pack.YhBrVe/_new 2014-03-28 16:29:45.000000000 +0100 @@ -17,27 +17,25 @@ Name: yast2-fcoe-client -Version: 3.1.3 +Version: 3.1.4 Release: 0 BuildRoot: %{_tmppath}/%{name}-%{version}-build Source0: %{name}-%{version}.tar.bz2 -Requires: fcoe-utils +Group: System/YaST +License: GPL-2.0 Requires: yast2 >= 2.21.22 -BuildRequires: perl-XML-Writer -BuildRequires: update-desktop-files -BuildRequires: yast2 -BuildRequires: yast2-devtools >= 3.0.6 -BuildRequires: yast2-testsuite +Requires: fcoe-utils +BuildRequires: perl-XML-Writer update-desktop-files yast2 yast2-testsuite +BuildRequires: yast2-devtools >= 3.1.10 +BuildRequires: rubygem-rspec -BuildArch: noarch +BuildArchitectures: noarch Requires: yast2-ruby-bindings >= 1.0.0 Summary: YaST2 - Configuration of Fibre Channel over Ethernet -License: GPL-2.0 -Group: System/YaST %description This package contains the YaST2 component for the Fibre Channel over @@ -52,6 +50,7 @@ %install %yast_install + %files %defattr(-,root,root) %dir %{yast_yncludedir}/fcoe-client ++++++ yast2-fcoe-client-3.1.3.tar.bz2 -> yast2-fcoe-client-3.1.4.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/VERSION new/yast2-fcoe-client-3.1.4/VERSION --- old/yast2-fcoe-client-3.1.3/VERSION 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/VERSION 1970-01-01 01:00:00.000000000 +0100 @@ -1 +0,0 @@ -3.1.3 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/package/yast2-fcoe-client.changes new/yast2-fcoe-client-3.1.4/package/yast2-fcoe-client.changes --- old/yast2-fcoe-client-3.1.3/package/yast2-fcoe-client.changes 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/package/yast2-fcoe-client.changes 2014-03-28 13:53:25.000000000 +0100 @@ -1,4 +1,10 @@ ------------------------------------------------------------------- +Fri Mar 28 13:14:21 CET 2014 - gs@suse.de + +- Adapt start of services (resp. sockets) to systemd +- 3.1.4 + +------------------------------------------------------------------- Mon Dec 2 11:45:47 CET 2013 - gs@suse.de - Enhance help text, improve ruby code diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/package/yast2-fcoe-client.spec new/yast2-fcoe-client-3.1.4/package/yast2-fcoe-client.spec --- old/yast2-fcoe-client-3.1.3/package/yast2-fcoe-client.spec 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/package/yast2-fcoe-client.spec 2014-03-28 13:53:25.000000000 +0100 @@ -17,7 +17,7 @@ Name: yast2-fcoe-client -Version: 3.1.3 +Version: 3.1.4 Release: 0 BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -28,7 +28,8 @@ Requires: yast2 >= 2.21.22 Requires: fcoe-utils BuildRequires: perl-XML-Writer update-desktop-files yast2 yast2-testsuite -BuildRequires: yast2-devtools >= 3.0.6 +BuildRequires: yast2-devtools >= 3.1.10 +BuildRequires: rubygem-rspec BuildArchitectures: noarch diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/src/clients/fcoe-client_finish.rb new/yast2-fcoe-client-3.1.4/src/clients/fcoe-client_finish.rb --- old/yast2-fcoe-client-3.1.3/src/clients/fcoe-client_finish.rb 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/src/clients/fcoe-client_finish.rb 2014-03-28 13:53:26.000000000 +0100 @@ -39,6 +39,7 @@ Yast.import "String" Yast.import "FcoeClient" Yast.import "Service" + Yast.import "SystemdSocket" Yast.include self, "installation/misc.rb" @ret = nil @@ -131,10 +132,20 @@ end if @start_services - Builtins.y2milestone("Enabling service start of fcoe and lldpad") - # service lldpad has to be enabled first - Service.Enable("boot.lldpad") - Service.Enable("boot.fcoe") + Builtins.y2milestone("Enabling socket start of fcoe and lldpad") + # enable socket lldpad first + lldpad_socket = SystemdSocket.find("lldpad") + if lldpad_socket + lldpad_socket.enable + else + Builtins.y2error("lldpad.socket not found") + end + fcoemon_socket = SystemdSocket.find("fcoemon") + if fcoemon_socket + fcoemon_socket.enable + else + Builtins.y2error("fcoemon.socket not found") + end end else Builtins.y2error("unknown function: %1", @func) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/src/clients/inst_fcoe-client.rb new/yast2-fcoe-client-3.1.4/src/clients/inst_fcoe-client.rb --- old/yast2-fcoe-client-3.1.3/src/clients/inst_fcoe-client.rb 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/src/clients/inst_fcoe-client.rb 2014-03-28 13:53:26.000000000 +0100 @@ -70,7 +70,6 @@ FcoeClient.ResetNetworkCards # start services fcoe and lldpad - # (modules for fcoe are loaded in /etc/init.d/fcoe) @success = FcoeClient.ServiceStatus if !@success Builtins.y2error("Starting of services FAILED") diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/src/include/fcoe-client/complex.rb new/yast2-fcoe-client-3.1.4/src/include/fcoe-client/complex.rb --- old/yast2-fcoe-client-3.1.3/src/include/fcoe-client/complex.rb 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/src/include/fcoe-client/complex.rb 2014-03-28 13:53:26.000000000 +0100 @@ -53,14 +53,16 @@ def ReallyAbort Builtins.y2milestone("Aborting FCoE configuration") - # revert start of 'fcoe' or 'lldpad' - if FcoeClient.fcoe_started && !Service.Enabled("boot.fcoe") - Service.Stop("boot.fcoe") + # Services started at installation time are stopped on reboot. + # Revert start of 'fcoemon' or 'lldpad' socket if started but not needed. + if !Stage.initial + if FcoeClient.fcoe_started && !FcoeClient.fcoemonSocketEnabled? + FcoeClient.fcoemonSocketStop + end + if FcoeClient.lldpad_started && !FcoeClient.lldpadSocketEnabled? + FcoeClient.lldpadSocketStop + end end - if FcoeClient.lldpad_started && !Service.Enabled("boot.lldpad") - Service.Stop("boot.lldpad") - end - return true if !FcoeClient.Modified abort = Popup.ReallyAbort(true) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/src/modules/FcoeClient.rb new/yast2-fcoe-client-3.1.4/src/modules/FcoeClient.rb --- old/yast2-fcoe-client-3.1.3/src/modules/FcoeClient.rb 2013-12-02 14:54:58.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/src/modules/FcoeClient.rb 2014-03-28 13:53:26.000000000 +0100 @@ -32,6 +32,8 @@ module Yast class FcoeClientClass < Module + include Yast::Logger + FCOE_PKG_NAME = "fcoe-utils" def main @@ -50,6 +52,7 @@ Yast.import "NetworkService" Yast.import "String" Yast.import "FileUtils" + Yast.import "SystemdSocket" # Data @@ -94,8 +97,8 @@ @NOT_CONFIGURED = "not configured" @NOT_AVAILABLE = "not available" - @lldpad_started = false # service fcoe was started - @fcoe_started = false # service lldpad was started + @lldpad_started = false # service lldpad was started + @fcoe_started = false # service fcoe was started # Settings: Define all variables needed for configuration of fcoe-client @@ -112,6 +115,10 @@ # list of maps containing information about networks cards and VLAN, FCoE and DCB status @network_interfaces = [] + # systemd sockets + @fcoemon_socket = nil + @lldpad_socket = nil + FcoeClient() end @@ -127,6 +134,132 @@ nil end + def fcoemonSocketActive? + if @fcoemon_socket + @fcoemon_socket.active? + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketStart + if @fcoemon_socket + @fcoemon_socket.start + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketStop + if @fcoemon_socket + @fcoemon_socket.stop + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketEnabled? + if @fcoemon_socket + @fcoemon_socket.enabled? + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketDisabled? + if @fcoemon_socket + @fcoemon_socket.disabled? + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketEnable + if @fcoemon_socket + @fcoemon_socket.enable + else + log.error("fcoemon.socket not found") + false + end + end + + def fcoemonSocketDisable + if @fcoemon_socket + @fcoemon_socket.disable + else + log.error("fcoemon.socket not found") + false + end + end + + def lldpadSocketActive? + if @lldpad_socket + @lldpad_socket.active? + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketStart + if @lldpad_socket + @lldpad_socket.start + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketStop + if @lldpad_socket + @lldpad_socket.stop + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketEnabled? + if @lldpad_socket + @lldpad_socket.enabled? + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketDisabled? + if @lldpad_socket + @lldpad_socket.disabled? + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketEnable + if @lldpad_socket + @lldpad_socket.enable + else + log.error("lldpad.socket not found") + false + end + end + + def lldpadSocketDisable + if @lldpad_socket + @lldpad_socket.disable + else + log.error("lldpad.socket not found") + false + end + end + # Abort function # @return [Boolean] return true if abort def Abort @@ -639,29 +772,32 @@ end # - # Set status of services + # Set start status of 'fcoemon' and 'lldpad' sockets + # + # 'Service' tab is only shown in installed system where + # sockets (and systemd) are available. # def AdjustStartStatus fcoe_start = Ops.get(@service_start, "fcoe", false) lldpad_start = Ops.get(@service_start, "lldpad", false) Builtins.y2milestone( - "Setting start of /etc/init.d/boot.fcoe to %1", + "Setting start of fcoe to %1", fcoe_start ) Builtins.y2milestone( - "Setting start of /etc/init.d/lldpad to %1", + "Setting start of lldpad to %1", lldpad_start ) if fcoe_start && lldpad_start - Service.Enable("boot.lldpad") # enable 'lldpad' first - Service.Enable("boot.fcoe") + lldpadSocketEnable # enable 'lldpad' first + fcoemonSocketEnable elsif !fcoe_start && lldpad_start - Service.Disable("boot.fcoe") - Service.Enable("boot.lldpad") + fcoemonSocketDisable + lldpadSocketEnable elsif !fcoe_start && !lldpad_start - Service.Disable("boot.fcoe") # disable 'fcoe' first - Service.Disable("boot.lldpad") + fcoemonSocketDisable # disable 'fcoe' first + lldpadSocketDisable end # fcoe_start && !lldpad_start isn't possible -> see complex.ycp StoreServicesDialog @@ -684,11 +820,11 @@ def DetectStartStatus status = false - status = Service.Enabled("boot.fcoe") + status = fcoemonSocketEnabled? Builtins.y2milestone("Start status of fcoe: %1", status) @service_start = Builtins.add(@service_start, "fcoe", status) - status = Service.Enabled("boot.lldpad") + status = lldpadSocketEnabled? Builtins.y2milestone("Start status of lldpad: %1", status) @service_start = Builtins.add(@service_start, "lldpad", status) @@ -705,46 +841,71 @@ def ServiceStatus success = true - # Loading of modules in Stage::initial() is not required (like in IsciClientLib.ycp, line 523 ) - # see /etc/init.d/fcoe, line 85 (modprobe fcoe > /dev/null 2>&1) + # Loading of modules in Stage::initial() is not required + # (like done in IscsiClientLib) + # SLES11 SP3: /etc/init.d/boot.fcoe, line 86 + # (modprobe $SUPPORTED_DRIVERS > /dev/null 2>&1) + # SUPPORTED_DRIVERS from /etc/fcoe/config + # SLES12: Service.Start in inst-sys runs commands from + # /usr/lib/systemd/system/fcoe.service + # (including modprobe) ret = true + # start services during installation + if Stage.initial + # start service lldpad first + @lldpad_started = Service.Start("lldpad") + if @lldpad_started + log.info("Service lldpad started") + else + log.error("Cannot start service lldpad") + Report.Error(_("Cannot start service 'lldpad'")) + ret = false + end + + @fcoe_started = Service.Start("fcoe") + if @fcoe_started + log.info("Service fcoe started") + else + log.error("Cannot start service fcoe") + Report.Error(_("Cannot start service 'fcoe'")) + ret = false + end + + return ret + end + + # start sockets in installed system + @fcoemon_socket = SystemdSocket.find!("fcoemon") + @lldpad_socket = SystemdSocket.find!("lldpad") + # first start lldpad - if Service.Status("boot.lldpad") != 0 - success = Service.Start("boot.lldpad") + if !lldpadSocketActive? + success = lldpadSocketStart if success - Builtins.y2milestone("Lldpad started (/etc/init.d/boot.lldpad start)") + log.info("lldpad.socket started") @lldpad_started = true else - Builtins.y2error( - "Cannot start service lldpad - '/etc/init.d/boot.lldpad start' failed" - ) - Report.Error( - "Cannot start service lldpad.\n'/etc/init.d/boot.lldpad start' failed" - ) + log.error("Cannot start lldpad.socket") + Report.Error(_("Cannot start lldpad systemd socket")) ret = false end else - Builtins.y2milestone("Lldpad service is running") + log.info("lldpad.socket is already active") end - if Service.Status("boot.fcoe") != 0 - success = Service.Start("boot.fcoe") - + if !fcoemonSocketActive? + success = fcoemonSocketStart if success - Builtins.y2milestone("FCoE started (/etc/init.d/boot.fcoe start)") + log.info("fcoemon.socket started") @fcoe_started = true else - Builtins.y2error( - "Cannot start FCoE service - '/etc/init.d/boot.fcoe start' failed" - ) - Report.Error( - "Cannot start FCoE service.\n'/etc/init.d/boot.fcoe start' failed" - ) + log.error( "Cannot start fcoemon.socket") + Report.Error(_("Cannot start fcoemon systemd socket.")) ret = false end else - Builtins.y2milestone("FCoE service is running") + log.info("fcoemon.socket is already active") end ret @@ -1245,7 +1406,7 @@ ret = true Builtins.y2milestone("Restarting fcoe") - ret = Service.Restart("boot.fcoe") + ret = Service.Restart("fcoe") ret end @@ -1309,15 +1470,16 @@ return false if PollAbort() Progress.NextStage - # check whether auto start of daemon fcoemon and lldpad is enabled or not - DetectStartStatus() - # check whether fcoe and lldpad are running and start services if required + # find sockets fcoemon and lldpad, check whether sockets are active, start if required start_status = ServiceStatus() # Error message Report.Error(_("Starting of services failed.")) if !start_status Builtins.sleep(sl) + # check whether auto start of daemon fcoemon and lldpad is enabled or not + DetectStartStatus() + return false if PollAbort() Progress.NextStage diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/test/DetectNetworkCards_spec.rb new/yast2-fcoe-client-3.1.4/test/DetectNetworkCards_spec.rb --- old/yast2-fcoe-client-3.1.3/test/DetectNetworkCards_spec.rb 2013-11-28 11:09:36.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/test/DetectNetworkCards_spec.rb 2014-03-28 13:53:26.000000000 +0100 @@ -1,3 +1,4 @@ +#! /usr/bin/rspec require_relative '../src/modules/FcoeClient' describe Yast::FcoeClientClass do diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/test/GetVlanInterfaces_spec.rb new/yast2-fcoe-client-3.1.4/test/GetVlanInterfaces_spec.rb --- old/yast2-fcoe-client-3.1.3/test/GetVlanInterfaces_spec.rb 2013-11-28 11:09:36.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/test/GetVlanInterfaces_spec.rb 2014-03-28 13:53:26.000000000 +0100 @@ -1,3 +1,4 @@ +#! /usr/bin/rspec require_relative '../src/modules/FcoeClient' describe Yast::FcoeClientClass do diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-fcoe-client-3.1.3/test/Makefile.am new/yast2-fcoe-client-3.1.4/test/Makefile.am --- old/yast2-fcoe-client-3.1.3/test/Makefile.am 1970-01-01 01:00:00.000000000 +0100 +++ new/yast2-fcoe-client-3.1.4/test/Makefile.am 2014-03-28 13:53:26.000000000 +0100 @@ -0,0 +1,8 @@ +TESTS = \ + DetectNetworkCards_spec.rb \ + GetVlanInterfaces_spec.rb + +TEST_EXTENSIONS = .rb +RB_LOG_COMPILER = rspec +VERBOSE = 1 +EXTRA_DIST = $(TESTS) continue with "q"... Checked in at Fri Mar 28 16:29:52 CET 2014 by ro Remember to have fun... -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
ro