wazuh-packages
wazuh-packages copied to clipboard
Installation assistant didn't stop when service failed
Description
Wazuh version | Install type | Action performed | Platform |
---|---|---|---|
4.8.2 | Manager | Install | Any |
In https://github.com/wazuh/wazuh-packages/pull/2861/checks?check_run_id=22354205611, we have observed that the installation didn't stopped when the Wazuh manager service fails:
06/03/2024 17:00:03 DEBUG: Setting provisional Wazuh indexer password.
06/03/2024 17:00:03 INFO: Wazuh manager vulnerability detection configuration finished.
06/03/2024 17:00:03 INFO: Starting service wazuh-manager.
Created symlink from /etc/systemd/system/multi-user.target.wants/wazuh-manager.service to /usr/lib/systemd/system/wazuh-manager.service.
Job for wazuh-manager.service failed because the control process exited with error code. See "systemctl status wazuh-manager.service" and "journalctl -xe" for details.
06/03/2024 17:00:06 INFO: wazuh-manager service started.
This must be related to the debug
variable used in the systemctl start
command:
eval "systemctl start ${1}.service ${debug}"
if [ "${PIPESTATUS[0]}" != 0 ]; then
If the verbose option is used, the output is redirected to a file, which makes the PIPESTATUS[0]
be always 0
. We need to improve this.
Validation
- [ ] The Installation assistant exits when the service fails using the verbose option.
- [ ] The Installation assistant exits when the service fails without using the verbose option.