Ansible Throws Error On Bootstrap (AIO-SX)

Bug #2040241 reported by Ceyhun Şen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
New
Undecided
Unassigned

Bug Description

Brief Description
-----------------
At step 4 (Run the Ansible bootstrap playbook) of AIO-SX bootstrapping, Ansible throws error. Error is:

 /tmp/.ansible-sysadmin/tmp/ansible-tmp-1697803606.8157048-54246-21879916047000/populate_initial_config.py:1121: DeprecationWarning: Will be removed in 1.0. Use equivalent Devices method instead.
        part = pyudev.Device.from_device_number(context,
      /tmp/.ansible-sysadmin/tmp/ansible-tmp-1697803606.8157048-54246-21879916047000/populate_initial_config.py:1124: DeprecationWarning: Will be removed in 1.0. Access properties with Device.properties.
        if part.parent:
      grep: /var/log/anaconda/anaconda.log: No such file or directory
      Traceback (most recent call last):
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1697803606.8157048-54246-21879916047000/populate_initial_config.py", line 1328, in <module>
          controller = populate_controller_config(client)
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1697803606.8157048-54246-21879916047000/populate_initial_config.py", line 1258, in populate_controller_config
          raise e
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1697803606.8157048-54246-21879916047000/populate_initial_config.py", line 1247, in populate_controller_config
          controller = client.sysinv.ihost.create(**values)
        File "/usr/lib/python3/dist-packages/cgtsclient/v1/ihost.py", line 70, in create
          return self._create(self._path(), new)
        File "/usr/lib/python3/dist-packages/cgtsclient/common/base.py", line 51, in _create
          _, body = self.api.json_request('POST', url, body=body)
        File "/usr/lib/python3/dist-packages/cgtsclient/common/http.py", line 204, in json_request
          resp = self._http_request(url, method, **kwargs)
        File "/usr/lib/python3/dist-packages/cgtsclient/common/http.py", line 186, in _http_request
          raise exceptions.from_response(
      cgtsclient.exc.HTTPInternalServerError: Remote error: TypeError unsupported operand type(s) for *: 'NoneType' and 'int'
      Traceback (most recent call last):
        File "/usr/lib/python3/dist-packages/zerorpc/core.py", line 167, in _async_task
          functor.pattern.process_call(self._context, bufchan, event, functor)
        File "/usr/lib/python3/dist-packages/zerorpc/patterns.py", line 30, in process_call
          result = functor(*req_event.args, **req_event.kwargs)
        File "/usr/lib/python3/dist-packages/zerorpc/decorators.py", line 44, in __call__
          return self._functor(*args, **kargs)
        File "/usr/lib/python3/dist-packages/sysinv/zmq_rpc/zmq_rpc.py", line 39, in method
          retval = getattr(self.target, func)(context, **kwargs)
        File "/usr/lib/python3/dist-packages/sysinv/conductor/manager.py", line 14561, in reconfigure_service_endpoints
          self._config_apply_runtime_manifest(
        File "/usr/lib/python3/dist-packages/sysinv/conductor/manager.py", line 11468, in _config_apply_runtime_manifest
          self._config_update_puppet(config_uuid,
        File "/usr/lib/python3/dist-packages/sysinv/conductor/manager.py", line 11238, in _config_update_puppet
          self._puppet.update_host_config(host, config_uuid)
        File "/usr/lib/python3/dist-packages/sysinv/puppet/puppet.py", line 32, in _wrapper
          func(self, *args, **kwargs)
        File "/usr/lib/python3/dist-packages/sysinv/puppet/puppet.py", line 192, in update_host_config
          config.update(puppet_plugin.obj.get_host_config(host))
        File "/usr/lib/python3/dist-packages/sysinv/puppet/platform.py", line 66, in get_host_config
          config.update(self._get_host_memory_config(host))
        File "/usr/lib/python3/dist-packages/sysinv/puppet/platform.py", line 665, in _get_host_memory_config
          node, vswitch_size * 1024, vswitch_pages)
      TypeError: unsupported operand type(s) for *: 'NoneType' and 'int'

Severity
--------
Critical

Steps to Reproduce
------------------
1. Follow the steps on https://docs.starlingx.io/r/stx.8.0/deploy_install_guides/release/bare_metal/aio_simplex_install_kubernetes.html.
2. Use this Ansible overwrite file:

system_mode: simplex

dns_servers:
  - 8.8.8.8
  - 8.8.4.4

external_oam_subnet: 192.168.1.0/24
external_oam_gateway_address: 192.168.1.1
external_oam_floating_address: 192.168.1.200

admin_username: admin
admin_password: ***
ansible_become_pass: ***

Expected Behavior
------------------
Run Ansible playbook, provided by StarlingX and finish succesfuly.

Actual Behavior
----------------
Ansible won't finish and can't continue to the next steps.

Reproducibility
---------------
Reproducible
This error is seen after the fresh install. After running Ansible playbook once, error will change slightly:
      Traceback (most recent call last):
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1698067076.4878035-65737-54316118861959/populate_initial_config.py", line 1327, in <module>
          populate_service_parameter_config(client)
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1698067076.4878035-65737-54316118861959/populate_initial_config.py", line 1046, in populate_service_parameter_config
          populate_docker_kube_config(client)
        File "/tmp/.ansible-sysadmin/tmp/ansible-tmp-1698067076.4878035-65737-54316118861959/populate_initial_config.py", line 838, in populate_docker_kube_config
          client.sysinv.service_parameter.delete(parameter.uuid)
        File "/usr/lib/python3/dist-packages/cgtsclient/v1/service_parameter.py", line 45, in delete
          return self._delete(self._path(parameter_id))
        File "/usr/lib/python3/dist-packages/cgtsclient/common/base.py", line 95, in _delete
          self.api.raw_request('DELETE', url)
        File "/usr/lib/python3/dist-packages/cgtsclient/common/http.py", line 224, in raw_request
          return self._http_request(url, method, **kwargs)
        File "/usr/lib/python3/dist-packages/cgtsclient/common/http.py", line 186, in _http_request
          raise exceptions.from_response(
      cgtsclient.exc.HTTPInternalServerError: 'int' object is not callable

System Configuration
--------------------
AIO-SX system (only one server).

sysadmin@controller-0:~$ ifconfig
enp61s0f3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 9000
        inet 192.168.1.200 netmask 255.255.255.0 broadcast 192.168.1.255
        inet6 fe80::200:ff:fe00:317 prefixlen 64 scopeid 0x20<link>
        ether 00:00:00:00:03:17 txqueuelen 1000 (Ethernet)
        RX packets 2236 bytes 238268 (232.6 KiB)
        RX errors 0 dropped 0 overruns 0 frame 0
        TX packets 4031 bytes 3279448 (3.1 MiB)
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
        inet 127.0.0.1 netmask 255.0.0.0
        inet6 ::1 prefixlen 128 scopeid 0x10<host>
        loop txqueuelen 1000 (Local Loopback)
        RX packets 28196 bytes 2133499 (2.0 MiB)
        RX errors 0 dropped 0 overruns 0 frame 0
        TX packets 28196 bytes 2133499 (2.0 MiB)
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

vlan103: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 9000
        inet6 fe80::200:ff:fe00:317 prefixlen 64 scopeid 0x20<link>
        ether 00:00:00:00:03:17 txqueuelen 1000 (Ethernet)
        RX packets 0 bytes 0 (0.0 B)
        RX errors 0 dropped 0 overruns 0 frame 0
        TX packets 13 bytes 1938 (1.8 KiB)
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

vlan163: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 9000
        inet6 fe80::200:ff:fe00:317 prefixlen 64 scopeid 0x20<link>
        ether 00:00:00:00:03:17 txqueuelen 1000 (Ethernet)
        RX packets 0 bytes 0 (0.0 B)
        RX errors 0 dropped 0 overruns 0 frame 0
        TX packets 15 bytes 2098 (2.0 KiB)
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
sysadmin@controller-0:~$ lscpu
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
Address sizes: 46 bits physical, 48 bits virtual
CPU(s): 48
On-line CPU(s) list: 0-47
Thread(s) per core: 2
Core(s) per socket: 12
Socket(s): 2
NUMA node(s): 2
Vendor ID: GenuineIntel
CPU family: 6
Model: 85
Model name: Intel(R) Xeon(R) Silver 4116T CPU @ 2.10GHz
Stepping: 4
CPU MHz: 902.523
CPU max MHz: 3000,0000
CPU min MHz: 800,0000
BogoMIPS: 4200.00
Virtualization: VT-x
L1d cache: 768 KiB
L1i cache: 768 KiB
L2 cache: 24 MiB
L3 cache: 33 MiB
NUMA node0 CPU(s): 0-11,24-35
NUMA node1 CPU(s): 12-23,36-47
Vulnerability Itlb multihit: KVM: Mitigation: VMX disabled
Vulnerability L1tf: Mitigation; PTE Inversion; VMX conditional cache flushes, SMT vulnerable
Vulnerability Mds: Mitigation; Clear CPU buffers; SMT vulnerable
Vulnerability Meltdown: Vulnerable
Vulnerability Mmio stale data: Mitigation; Clear CPU buffers; SMT vulnerable
Vulnerability Retbleed: Vulnerable
Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl and seccomp
Vulnerability Spectre v1: Vulnerable: __user pointer sanitization and usercopy barriers only; no swapgs barriers
Vulnerability Spectre v2: Vulnerable, IBPB: disabled, STIBP: disabled, PBRSB-eIBRS: Not affected
Vulnerability Srbds: Not affected
Vulnerability Tsx async abort: Mitigation; Clear CPU buffers; SMT vulnerable
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon
                                  pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic mov
                                 be popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cdp_l3 invpcid_single intel_ppin ssbd mba ibrs ibpb stibp tpr_shadow vnmi
                                 flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm cqm mpx rdt_a avx512f avx512dq rdseed adx smap clflushopt clwb intel_pt avx512cd avx512b
                                 w avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm ida arat pln pts hwp hwp_act_window hwp_epp hwp_pkg_req pku ospke md_clear flus
                                 h_l1d
sysadmin@controller-0:~$ free
               total used free shared buff/cache available
Mem: 38413196 928868 34957548 10484 2526780 37096192
Swap: 0 0 0
sysadmin@controller-0:~$ sync; dd if=/dev/zero of=tempfile bs=1M count=1024; sync # disk speed
1024+0 records in
1024+0 records out
1073741824 bytes (1,1 GB, 1,0 GiB) copied, 0,63811 s, 1,7 GB/s

Branch/Pull Time/Commit
-----------------------
StarlingX r8.0 iso is used.

Last Pass
---------
-

Timestamp/Logs
--------------
-

Test Activity
-------------
-

Workaround
----------
-

Revision history for this message
Ceyhun Şen (ceyhunsen-inventron) wrote :
Revision history for this message
Ceyhun Şen (ceyhunsen-inventron) wrote :

Turns out, no memory on second RAM bank causes this problem:

https://opendev.org/starlingx/config/src/branch/r/stx.8.0/sysinv/sysinv/sysinv/sysinv/agent/node.py#L344 looks to sysfs for hugepages. But when there is no second RAM on the second RAM bank on my motherboard, Linux won't create hugepage directories. Then this code will just leave second NUMA node's hugepage entries `None`. Lastly, puppet tries to do some arithmetic on None values and throws exceptions.

As I said, connecting second RAM to second RAM bank on my motherboard fixed the problem. This bug can be closed.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.