Hi all,

 

I tried to bring up a STX/OpenStack system using Devstack, folloing the general procedure of Devstack and wiki/StarlingX/Devstack/stx-config.

 

I am able to bring up all service except sysin-agent, i.e. remove sysinv-agent from the ENABLED_SERVICES:

 

ENABLED_SERVICES+=,tsconfig,fm-common,fm-api,fm-rest-api,fm-mgr,sysinv-api,sysinv-cond

 

./stack.sh was able to run to completion successfully, all (total 70+ devstack@*services) are able to run under Systemd, except sysinv-cond failed.

 

Not sure anybody else hit the same or similar issues, so I posted some issues and my temporary ‘fixing’:

 

ISSUE 1:                sysinv-api failed to start:

 

++/opt/stack/stx-config/devstack/lib/stx-config:start_sysinv_api:240  echo 'Waiting for sysinv-api (192.168.56.221:6385) to start...'

Waiting for sysinv-api (192.168.56.221:6385) to start...

++/opt/stack/stx-config/devstack/lib/stx-config:start_sysinv_api:241  timeout 60 sh -c 'while ! wget --no-proxy -q -O- http://192.168.56.221:6385/; do sleep 1; done'

++/opt/stack/stx-config/devstack/lib/stx-config:start_sysinv_api:242  die 242 'sysinv-api did not start'

++functions-common:die:187                  local exitcode=0

[Call Trace]

./stack.sh:1380:run_phase

/opt/stack/devstack/functions-common:1707:run_plugins

/opt/stack/devstack/functions-common:1674:source

/opt/stack/stx-config/devstack/plugin.sh:28:start_sysinv

/opt/stack/stx-config/devstack/lib/stx-config:210:start_sysinv_api

/opt/stack/stx-config/devstack/lib/stx-config:242:die

[ERROR] /opt/stack/stx-config/devstack/lib/stx-config:242 sysinv-api did not start

Error on exit

stack@ubuntu16045server1:~/devstack$

 

root cause:

Dec 03 20:01:54 ubuntu16045server1 sysinv-api[23537]: ERROR sysinv   File "/usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py", line 2292, in register_opt

Dec 03 20:01:54 ubuntu16045server1 sysinv-api[23537]: ERROR sysinv     if _is_opt_registered(self._opts, opt):

Dec 03 20:01:54 ubuntu16045server1 sysinv-api[23537]: ERROR sysinv   File "/usr/local/lib/python2.7/dist-packages/oslo_config/cfg.py", line 356, in _is_opt_registered

Dec 03 20:01:54 ubuntu16045server1 sysinv-api[23537]: ERROR sysinv     raise DuplicateOptError(opt.name)

Dec 03 20:01:54 ubuntu16045server1 sysinv-api[23537]: ERROR sysinv DuplicateOptError: duplicate option: fatal_deprecations

 

Solution to fix:

Remove the following lines from

    ../stx-config/sysinv/sysinv/sysinv/sysinv/openstack/common/log.py 140

 

@@ -137,9 +137,11 @@ log_opts = [

     cfg.BoolOpt('publish_errors',

                 default=False,

                 help='publish error events'),

-    cfg.BoolOpt('fatal_deprecations',

-                default=False,

-                help='make deprecations fatal'),

 

ISSUE 2:                sysinv-agent failed to start

+functions-common:service_check:1542       for service in '${ENABLED_SERVICES//,/ }'

+functions-common:service_check:1544       sudo systemctl is-enabled devstack@sysinv-agent.service

enabled

+functions-common:service_check:1548       sudo systemctl status devstack@sysinv-agent.service --no-pager

● devstack@sysinv-agent.service - Devstack devstack@sysinv-agent.service

   Loaded: loaded (/etc/systemd/system/devstack@sysinv-agent.service; enabled; vendor preset: enabled)

   Active: failed (Result: exit-code) since Mon 2018-12-03 20:19:33 EST; 5s ago

Main PID: 32164 (code=exited, status=2)

 

Dec 03 20:19:33 ubuntu16045server1 systemd[1]: Started Devstack devstack@sysinv-agent.service.

Dec 03 20:19:33 ubuntu16045server1 systemd[1]: devstack@sysinv-agent.service: Main process exited, code=exited, status=2/INVALIDARGUMENT

Dec 03 20:19:33 ubuntu16045server1 systemd[1]: devstack@sysinv-agent.service: Unit entered failed state.

Dec 03 20:19:33 ubuntu16045server1 systemd[1]: devstack@sysinv-agent.service: Failed with result 'exit-code'.

 

Root cause:

sysinv/sysinv-agent/sysinv-agent is referring various Titanium specific paths and files.

e.g.:

 

18 . /etc/init.d/functions

19 . /etc/build.info

20

21

22 PLATFORM_CONF="/etc/platform/platform.conf"

23 NODETYPE=""

24 DAEMON_NAME="sysinv-agent"

25 SYSINVAGENT="/usr/bin/${DAEMON_NAME}"

26 SYSINV_CONF_DIR="/etc/sysinv"

27 SYSINV_CONF_FILE="${SYSINV_CONF_DIR}/sysinv.conf"

28 SYSINV_CONF_DEFAULT_FILE="/opt/platform/sysinv/${SW_VERSION}/sysinv.conf.default"

29 SYSINV_READY_FLAG=/var/run/.sysinv_ready

 

 

Solution to fix:

There’s no easy fix to this one. It looks the files for service sysinv-agent need to be recreated, in the way similar to sysinv-api.

 

 

Some minor issues including:

Pycrypto is required by controllerconfig/common/dcmanager.py but not installed

HOST_IP needs to be defined in very early stage

 

Thanks!

Marvin