Page MenuHomeClusterLabs Projects

cts-lab fails with exception if rsyslog is not installed on cluster nodes
Closed (Merged)Public

Assigned To
Authored By
nrwahl2
Mar 19 2024, 3:31 PM
Tags
  • Restricted Project
  • Restricted Project
  • Restricted Project
  • Restricted Project
Referenced Files
None
Subscribers

Description

Observed on Fedora 39. rsyslog is not installed by default.

Traceback (most recent call last):
  File "/usr/share/pacemaker/tests/cts-lab", line 53, in <module>
    environment = CtsLab(sys.argv[1:])
                  ^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/pacemaker/_cts/CTS.py", line 48, in __init__
    self._env = EnvFactory().getInstance(args)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/pacemaker/_cts/environment.py", line 636, in getInstance
    EnvFactory.instance = Environment(args)
                          ^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/pacemaker/_cts/environment.py", line 78, in __init__
    self._discover()
  File "/usr/lib/python3.12/site-packages/pacemaker/_cts/environment.py", line 319, in _discover
    self._detect_syslog()
  File "/usr/lib/python3.12/site-packages/pacemaker/_cts/environment.py", line 199, in _detect_syslog
    self["syslogd"] = lines[0].strip()
                      ~~~~~^^^
IndexError: list index out of range
# systemctl list-unit-files | grep syslog
syslog.socket                              static          -

Installing rsyslog fixes the issue, but it shouldn't be necessary. cts-lab doesn't even do anything with self["syslogd"] except restart the service. Which doesn't make a difference when systemd is in use and no log file is explicitly specified on the CLI.

Event Timeline

nrwahl2 triaged this task as Normal priority.Mar 19 2024, 3:31 PM
nrwahl2 created this task.
nrwahl2 created this object with edit policy "Restricted Project (Project)".
clumens changed the task status from Open to WIP.May 31 2024, 4:26 PM
clumens claimed this task.
kgaillot edited projects, added Restricted Project; removed Restricted Project.Jul 8 2024, 5:45 PM

This would be worth backporting to 2.1 if easy