Interrupted Scans: NVT/ Connection & Redis Socket Errors

Hi everyone,

I’m running OpenVAS inside a Docker Compose setup, and after a feed update the scans have been. My system is no longer functioning properly. The NVT status in the UI shows:

Synchronization issue: Could not connect to scanner to get feed info

The following errors appear in the container logs:

Redis container:

rm: cannot remove ‘/run/redis/redis.sock’: Permission denied

OSPD:

OSPD[7] ERROR: Redis Error: Not possible to connect to the kb.

GVMD:

WARNING: The gvmd data feed directory /var/lib/gvm/data-objects/gvmd or one of its subdirectories does not exist.
WARNING: nvts_feed_info_internal: failed to connect to /run/ospd/ospd-openvas.sock
WARNING: osp_scanner_feed_version: failed to connect to /run/ospd/ospd-openvas.sock

It looks like the scanner and GVMD cannot communicate with OSPD, and the Redis KB isn’t accessible anymore.
Has anyone encountered this issue before? What steps can I take to fix the scanner/Redis socket problem and get the feeds working again?

Any help is appreciated!

Hi, there are a lot of threads about this issue already and even our troubleshooting guide contains a section about it

2 Likes

Thank you but it did not work.

docker compose -f docker-compose.yaml rm -s -f redis-server ospd-openvas
No stopped containers

After stopping the container manually I got the same message.

And after executing the follwing command I got this message:
docker volume rm greenbone-community-edition_redis_socket_vol
Error response from daemon: remove greenbone-community-edition_redis_socket_vol: volume is in use

Hi, could you do me a favor and format your messages according to Start Here/Read Me First - #3 by bricks next time? they are difficult to read at the moment.

Means the containers references in the compose file aren’t running anymore :+1:

Means some other container is still referencing the volume :-1:
Please check your running containers. There should be a misconfiguration in some kind. If you need help paste the output of docker container ps -a.

It is also possible to force the removal of the containers by using docker volume rm -f greenbone-community-edition_redis_socket_vol but not being able to remove the volume indicates some misconfiguration issue on your side.

1 Like

Now it is as follow:

[+] Stopping 2/2
:check_mark: Container greenbone-container-ospd-openvas-1 Stopped 0.0s
:check_mark: Container greenbone-container-redis-server-1 Stopped 11.3s
Going to remove greenbone-container-ospd-openvas-1, greenbone-container-redis-server-1
[+] Removing 2/2
:check_mark: Container greenbone-container-redis-server-1 Removed 0.1s
:check_mark: Container greenbone-container-ospd-openvas-1 Removed

docker volume rm greenbone-community-edition_redis_socket_vol
Error response from daemon: remove greenbone-community-edition_redis_socket_vol: volume is in use

Nothing changed. There is still something wrong in your docker setup. Again I would be curious to see the output of docker container ps -a

1 Like
CONTAINER ID   IMAGE                                                               COMMAND                  CREATED          STATUS                        PORTS                                         NAMES
93990cd5d220   registry.community.greenbone.net/community/report-formats           “/bin/init.sh”           10 minutes ago   Exited (0) 10 minutes ago                                                   greenbone-community-edition-report-formats-1
cce85f53a13e   registry.community.greenbone.net/community/dfn-cert-data            “/bin/init.sh”           10 minutes ago   Exited (0) 10 minutes ago                                                   greenbone-community-edition-dfn-cert-data-1
c56b25256c63   registry.community.greenbone.net/community/scap-data                “/bin/init.sh”           11 minutes ago   Exited (137) 10 minutes ago                                                 greenbone-community-edition-scap-data-1
f69ec43934d8   registry.community.greenbone.net/community/vulnerability-tests      “/bin/init.sh”           11 minutes ago   Exited (137) 10 minutes ago                                                 greenbone-community-edition-vulnerability-tests-1
511c371061fd   registry.community.greenbone.net/community/notus-data               “/bin/init.sh”           11 minutes ago   Exited (0) 10 minutes ago                                                   greenbone-community-edition-notus-data-1
048637645b4e   registry.community.greenbone.net/community/ospd-openvas:stable      “/usr/bin/tini – /u…”   14 minutes ago   Up 8 minutes                                                                greenbone-container-ospd-openvas-1
77a9e60f5c01   registry.community.greenbone.net/community/redis-server             “docker-entrypoint.s…”   14 minutes ago   Up 9 minutes                  6379/tcp                                      greenbone-container-redis-server-1
8805b08e0349   registry.community.greenbone.net/community/gvmd:stable              “/usr/local/bin/entr…”   23 minutes ago   Up 9 minutes                                                                greenbone-container-gvmd-1
34696de3da87   registry.community.greenbone.net/community/openvas-scanner:stable   “/bin/sh -c /usr/loc…”   23 minutes ago   Up 9 minutes                                                                greenbone-container-openvasd-1
73dfc4fccd65   registry.community.greenbone.net/community/openvas-scanner:stable   “/bin/sh -c 'cat /et…”   24 minutes ago   Up 9 minutes                                                                greenbone-container-openvas-1
e2ebcf354323   registry.community.greenbone.net/community/pg-gvm:stable            “/usr/local/bin/entr…”   24 minutes ago   Up 9 minutes                                                                greenbone-container-pg-gvm-1
ec5758fc282a   registry.community.greenbone.net/community/gsa:stable               “/usr/local/bin/entr…”   4 hours ago      Up 9 minutes                  127.0.0.1:9392->80/tcp                        greenbone-community-edition-gsa-1
79300160da06   registry.community.greenbone.net/community/gvmd:stable              “/usr/local/bin/entr…”   4 hours ago      Up 9 minutes                                                                greenbone-community-edition-gvmd-1
a3ea4b4c6681   registry.community.greenbone.net/community/openvas-scanner:stable   “/bin/sh -c /usr/loc…”   4 hours ago      Up 9 minutes                                                                greenbone-community-edition-openvasd-1
69e1d1c46506   registry.community.greenbone.net/community/openvas-scanner:stable   “/bin/sh -c 'cat /et…”   4 hours ago      Up 9 minutes                                                                greenbone-community-edition-openvas-1
df44186c7238   registry.community.greenbone.net/community/pg-gvm:stable            “/usr/local/bin/entr…”   3 months ago     Up 9 minutes                                                                greenbone-community-edition-pg-gvm-1

Hi, please format such outputs according to Start Here/Read Me First - #3 by bricks next time. Otherwise it’s horrible to read. I’ve fixed it for you this time.

2 Likes

From the output you can clearly see that the containers are started twice. Two different project names are used:

  1. greenbone-container
  2. greenbone-community-edition

The project name is defined by either the -p CLI argument for docker compose or as the name property in the docker-compose.yml file.

2 Likes

After rebooting the server it works again! Thank you very much

1 Like