Hello everyone,
first of all sorry for my bad English, I use deepl.
I am using Ubuntu and wanted to install the agent:
I then get messages like
:rpm: RPM should not be used to install RPM packages directly, use Alien instead!
rpm: Assuming you know what you are doing...
warning: wazuh-agent-4.7.1-1.x86_64.rpm: Header V3 RSA/SHA256 signature, key ID 29111145: NOKEY
Error: Failed dependencies:
/bin/sh is required by wazuh-agent-4.7.1-1.x86_64
/usr/sbin/groupadd is required by wazuh-agent-4.7.1-1.x86_64
/usr/sbin/groupdel is required for wazuh-agent-4.7.1-1.x86_64
/usr/sbin/useradd is required for wazuh-agent-4.7.1-1.x86_64
/usr/sbin/userdel is required for wazuh-agent-4.7.1-1.x86_64
coreutils is required for wazuh-agent-4.7.1-1.x86_64
The problem was in the post-installation script /var/lib/dpkg/info/wazuh-agent.postinst
if getent group ossec > /dev/null 2>&1; then
find ${DIR}/ -group ossec -user root -exec chown root:wazuh {} \; > /dev/null 2>&1 || true
if getent passwd ossec > /dev/null 2>&1; then
find ${DIR}/ -group ossec -user ossec -exec chown wazuh:wazuh {} \; > /dev/null 2>&1 || true
deluser ossec > /dev/null 2>&1
fi
if getent passwd ossecm > /dev/null 2>&1; then
find ${DIR}/ -group ossec -user ossecm -exec chown wazuh:wazuh {} \; > /dev/null 2>&1 || true
deluser ossecm > /dev/null 2>&1
fi
if getent passwd ossecr > /dev/null 2>&1; then
find ${DIR}/ -group ossec -user ossecr -exec chown wazuh:wazuh {} \; > /dev/null 2>&1 || true
deluser ossecr > /dev/null 2>&1
fi
if getent group ossec > /dev/null 2>&1; then
delgroup ossec > /dev/null 2>&1
fi
fi
With the command grep ossec /etc/group i see, that there is a 'e' at the end (ossece)
ossec:x:994:ossece
After deluser ossece and delgroup ossec and add modify "ossece" in the post install script, all works fine.
Regards,
Jürgen