The error message you're encountering indicates that the `systemd-sysv-install` tool is not present on your system. This tool is used to enable SysV init scripts as systemd services. Since your system is using `systemd` as the init system, this issue can occur.
Here are steps to resolve this problem:
1. Check Installed Packages:
Verify whether the `systemd-sysv-install` tool is installed on your system. You can do this by running:
# rpm -q initscripts
If it's not installed, you should see an output like "package initscripts is not installed." In this case, proceed to the next step.
2. Install `initscripts` Package:
You can install the `initscripts` package to get the missing `systemd-sysv-install` tool. Use the following command to install the package:
$ sudo dnf install initscripts
If you encounter any issues installing the package, make sure your system's package repositories are configured correctly.
3. Enable Wazuh Manager Service:
After installing the `initscripts` package, try enabling the Wazuh Manager service again:
$ sudo systemctl enable wazuh-manager.service
This should now work without errors.
4. Start the Wazuh Manager:
Once the service is enabled, you can start the Wazuh Manager:
$ sudo systemctl start wazuh-manager.service
Check the status of the service to ensure it's running without errors:
$ sudo systemctl status wazuh-manager.service
If you encounter any issues at this stage, review the service logs for more specific error messages:
$ sudo journalctl -u wazuh-manager.service
By installing the `initscripts` package and then enabling the Wazuh Manager service, you should be able to get the service up and running without encountering the "No such file or directory" error.