Gvm-check-setup

Hi all I am getting a gsad service not found when running gvm-check-setup . Below is the output and cat /usr/lib/systemd/system/greenbone-security-assistant.service which I modified trying to fix from the default. Anyone have any ideas here as I am stuck?

Distro
No LSB modules are available.
Distributor ID: Kali
Description: Kali GNU/Linux Rolling
Release: 2023.2
Codename: kali-rolling

gvm-check-setup 22.4.1
Test completeness and readiness of GVM-22.4.1
Step 1: Checking OpenVAS (Scanner)…
OK: OpenVAS Scanner is present in version 22.4.1.
OK: Notus Scanner is present in version 22.4.4.
OK: Server CA Certificate is present as /var/lib/gvm/CA/servercert.pem.
Checking permissions of /var/lib/openvas/gnupg/*
OK: _gvm owns all files in /var/lib/openvas/gnupg
OK: redis-server is present.
OK: scanner (db_address setting) is configured properly using the redis-server socket: /var/run/redis-openvas/redis-server.sock
OK: redis-server is running and listening on socket: /var/run/redis-openvas/redis-server.sock.
OK: redis-server configuration is OK and redis-server is running.
OK: the mqtt_server_uri is defined in /etc/openvas/openvas.conf
OK: _gvm owns all files in /var/lib/openvas/plugins
OK: NVT collection in /var/lib/openvas/plugins contains 85896 NVTs.
OK: The notus directory /var/lib/notus/products contains 431 NVTs.
Checking that the obsolete redis database has been removed
OK: No old Redis DB
OK: ospd-OpenVAS is present in version 22.4.6.
Step 2: Checking GVMD Manager …
OK: GVM Manager (gvmd) is present in version 22.4.2.
Step 3: Checking Certificates …
OK: GVM client certificate is valid and present as /var/lib/gvm/CA/clientcert.pem.
OK: Your GVM certificate infrastructure passed validation.
Step 4: Checking data …
OK: SCAP data found in /var/lib/gvm/scap-data.
OK: CERT data found in /var/lib/gvm/cert-data.
Step 5: Checking Postgresql DB and user …
OK: Postgresql version and default port are OK.
gvmd | _gvm | UTF8 | en_US.UTF-8 | en_US.UTF-8 | | libc |
16435|pg-gvm|10|2200|f|22.4.0||
OK: At least one user exists.
Step 6: Checking Greenbone Security Assistant (GSA) …
OK: Greenbone Security Assistant is present in version 22.04.1~git.
Step 7: Checking if GVM services are up and running …
OK: ospd-openvas service is active.
OK: gvmd service is active.
Starting gsad service
Failed to start gsad.service: Unit gsad.service not found.
Waiting for gsad service
ERROR: gsad service did not start.
Please check journalctl -xe and /var/log/gvm/gsad.log

ERROR: Your GVM-22.4.1 installation is not yet complete!

Please follow the instructions marked with FIX above and run this
script again.

─# cat /usr/lib/systemd/system/greenbone-security-assistant.service
[Unit]
Description=Greenbone Security Assistant daemon (gsad)
Documentation=man:gsad(8) https://www.greenbone.net
After=network.target gvmd.service
Wants=gvmd.service

[Service]
Type=forking
User=_gvm
Group=_gvm
ExecStart=/usr/sbin/gsad --foreground --listen 127.0.0.1 --port 9392
Restart=always
TimeoutStopSec=10

[Install]
WantedBy=multi-user.target
Alias=gsad.service

Is this immediately after a fresh install using Kali native package via sudo apt install openvas and then sudo gvm-setup, or is this install been operating for some time?

The output of gvm-check-setup says:

ERROR: gsad service did not start.
Please check journalctl -xe and /var/log/gvm/gsad.log

You can also try sudo systemctl status gsad which may provide input about why the service is not starting.

This distro was updated to 2023 from 2021. I had to remove postgres 13 in favour of postgres 15 etc All seemed to go ok with exception of this gsad service which is not found . There are no log files for it as the service is not available. I would have thought openvas and gvm install/setup would have been responisble for adding this service but it appears not. I really dont want to download the distro and configure from scratch again so I hope I can fix this. I think I will try to uninstall openvas and reinstall again as I don’t know what else I can try here

I also tried this solution from altjx in this thread which did not work

[Unit]
Description=Greenbone Security Assistant (gsad)
Documentation=man:gsad(8) https://www.greenbone.net
After=network.target gvmd.service
Wants=gvmd.service

[Service]
Type=forking
User=_gvm
Group=_gvm
ExecStart=/usr/sbin/gsad --listen=127.0.0.1 --port=9392
Restart=always
TimeoutStopSec=10

[Install]
WantedBy=multi-user.target
Alias=gsad.service

As the Kali packages itself but also gvm-check-setup is not maintained / provided by Greenbone you could also report an issue to the Kali package maintainers over here to see if they can provide a fix directly for such upgraded installations:

https://bugs.kali.org

1 Like

sudo systemctl status gsad will give you details about why the service won’t start. I am unable to replicate this type of error on a fresh Kali 2023 install.

Let’s see if the Kali package maintainer(s) can provide a permanent fix:

https://bugs.kali.org/view.php?id=8379