Error: exec: "greenbone-feed-sync": executable file not found in $PATH

Hi everyone I’m trying to solve this:
$ docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition
run --rm gvmd greenbone-feed-sync --type gvmd-data
[+] Creating 6/0
:heavy_check_mark: Container greenbone-community-edition-pg-gvm-1 Running 0.0s
:heavy_check_mark: Container greenbone-community-edition-cert-bund-data-1 Created 0.0s
:heavy_check_mark: Container greenbone-community-edition-data-objects-1 Created 0.0s
:heavy_check_mark: Container greenbone-community-edition-scap-data-1 Created 0.0s
:heavy_check_mark: Container greenbone-community-edition-dfn-cert-data-1 Created 0.0s
:heavy_check_mark: Container greenbone-community-edition-report-formats-1 Created 0.0s
[+] Running 5/5
:heavy_check_mark: Container greenbone-community-edition-cert-bund-data-1 Started 0.6s
:heavy_check_mark: Container greenbone-community-edition-scap-data-1 Started 0.7s
:heavy_check_mark: Container greenbone-community-edition-data-objects-1 Started 0.7s
:heavy_check_mark: Container greenbone-community-edition-dfn-cert-data-1 Started 0.5s
:heavy_check_mark: Container greenbone-community-edition-report-formats-1 Started 0.6s
setting up configuration file for mail agent
error: exec: “greenbone-feed-sync”: executable file not found in $PATH

Can you assist me please? Btw the real issue is that I dont have the gvmd-data in place specialy the port_scan profiles. And I’m trying to go arround and fix it (I’m using Community Containers)

What instructions are you following? The feed-sync method you are using is not the the one provided by the Greenbone Docker Containers Workflow instructions.

1 Like

Hi, feeds in the web portal are all “current”!

Try to run:
docker compose -f $DOWNLOAD_DIR/docker-compose.yml -p greenbone-community-edition
exec -u gvmd gvmd gvmd --rebuild-gvmd-data=all

output:
Failed to rebuild gvmd data: Feed owner not set or invalid while rebuilding configs.

That’s why I’m exploring in all directions. :blush: The result as been always the same (no scan ports). I have began from scratch (docker) a few times now…

Need help at this stage. (btw a month a ago I had no issues in the POC)

Thank you all in advance.

rippledj,
I’m using this page:

I saw your reply but it seems to be deleted.

Again, can you please specify which install and feed-sync instructions you are using. Unfortunately we cannot troubleshoot methods that fall outside of the scope of our official tutorials. This would place an undue burden on our ability to provide help. :slight_smile:

For example, one problem I see is that the user gvmd is not the correct user that matches the official install method. Furthermore, although I don’t want to specifically criticize the reputation of the creator whose instructions you are following, I would consider it more of a security risk to use unsupported installation methods published on the Internet.

rippledj,

Ok let’s see, for the instalation I used this:

All running fine:

 $ docker ps
CONTAINER ID   IMAGE                           COMMAND                  CREATED        STATUS          PORTS                    NAMES
8d1100521a57   greenbone/gsa:stable            "/usr/local/bin/entr…"   13 hours ago   Up 4 hours      127.0.0.1:9392->80/tcp   greenbone-community-edition-gsa-1
cc333efd022f   greenbone/gvmd:stable           "/usr/local/bin/entr…"   13 hours ago   Up 4 hours                               greenbone-community-edition-gvmd-1
cfddae9db24a   greenbone/ospd-openvas:stable   "/usr/bin/tini -- /u…"   13 hours ago   Up 54 minutes                            greenbone-community-edition-ospd-openvas-1
465f4d012da7   greenbone/redis-server          "/bin/sh -c 'rm -f /…"   13 hours ago   Up 4 hours                               greenbone-community-edition-redis-server-1
1dd24de3b855   greenbone/pg-gvm:stable         "/usr/local/bin/entr…"   13 hours ago   Up 4 hours                               greenbone-community-edition-pg-gvm-1
cfbf4cb1c934   greenbone/mqtt-broker           "/bin/sh -c 'mosquit…"   13 hours ago   Up 4 hours                               greenbone-community-edition-mqtt-broker-1

Next feeds in the web saying in status all “Current”. NVT, SCAP, CERT all are visible and with data but in the GVMD_DATA no info avaliable at: Compliance Policies, Port List, Report Formats and Scan Configs.

Then I went to re throbleshouting:
Troubleshooting - Greenbone Community Documentation

And used the:

   docker compose -f $DOWNLOAD_DIR/docker-compose.yml -p greenbone-community-edition
exec -u gvmd gvmd gvmd --rebuild-gvmd-data=all

Output:

  Failed to rebuild gvmd data: Feed owner not set or invalid while rebuilding configs.

Can anyone help me moving forward and solve this issue, please.

Sadly this command is wrong in the docs. It needs to be

docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition
run --rm greenbone-feed-sync greenbone-feed-sync --type gvmd-data

but nevertheless you don’t need to run the commands to sync the feed manually at all for the containers. There is no reason for doing that despite experiments and learning about the internals.

1 Like

@orlandoprz could you please format your outputs and commands via backticks ` Without the posts are difficult to read and follow. See Start Here - #3 by bricks

1 Like
$ docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition run --rm greenbone-feed-sync greenbone-feed-sync --type gvmd-data
Trying to acquire lock on /var/lib/gvm/feed-update.lock
Acquired lock on /var/lib/gvm/feed-update.lock
⠧ Downloading gvmd data from rsync://feed.community.greenbone.net/community/data-feed/22.04/ to /var/lib/gvm/data-objects/gvmd/22.04
Releasing lock on /var/lib/gvm/feed-update.lock

Checking the logs this way:

docker compose -f $DOWNLOAD_DIR/docker-compose.yml -p greenbone-community-edition logs -f

No output

Still no data avaliable at: Compliance Policies, Port List, Report Formats and Scan Configs

What should be my next step?

No output all all :flushed:?

Please check the gvmd logs for possible errors. That component is responsible for loading the policies, scan configs and report formats.

docker compose -f $DOWNLOAD_DIR/docker-compose.yml -p greenbone-community-edition logs -f gvmd

0 logs, this is strange! Did a find and:

$ docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition run --rm greenbone-feed-sync greenbone-feed-sync --type gvmd-data
Trying to acquire lock on /var/lib/gvm/feed-update.lock
Acquired lock on /var/lib/gvm/feed-update.lock
⠏ Downloading gvmd data from rsync://feed.community.greenbone.net/community/data-feed/22.04/ to /var/lib/gvm/data-objects/gvmd/22.04
Releasing lock on /var/lib/gvm/feed-update.lock

$ docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition exec gvmd /bin/bash
root@cc333efd022f:/# find /var/lib/gvm/data-objects/ -name "*d21f6c81-2b88-4ac1-b7b4-a2a9f2ad4663*"
/var/lib/gvm/data-objects/gvmd/22.04/scan-configs/base-d21f6c81-2b88-4ac1-b7b4-a2a9f2ad4663.xml
/var/lib/gvm/data-objects/gvmd/20.08/scan-configs/base-d21f6c81-2b88-4ac1-b7b4-a2a9f2ad4663.xml
/var/lib/gvm/data-objects/gvmd/21.04/scan-configs/base-d21f6c81-2b88-4ac1-b7b4-a2a9f2ad4663.xml
root@cc333efd022f:/#
exit
$

there is the file!

Can you ping feed.community.greenbone.net? @orlandoprz

Yes, I can. I download form there: “feed.community.greenbone.net”. Inside and outside the Docker I reach there.

$ docker compose -f ./greenbone-community-container/docker-compose.yml -p greenbone-community-edition run --rm greenbone-feed-sync greenbone-feed-sync --type gvmd-data
Trying to acquire lock on /var/lib/gvm/feed-update.lock
Acquired lock on /var/lib/gvm/feed-update.lock
⠏ Downloading gvmd data from rsync://feed.community.greenbone.net/community/data-feed/22.04/ to /var/lib/gvm/data-objects/gvmd/22.04
Releasing lock on /var/lib/gvm/feed-update.lock

I think this means it’s reachable

Maybe not. Can you just run “ping feed.community.greenbone.net” and receive the packets?

$ mtr --tcp -r -n feed.community.greenbone.net
Start: 2024-03-15T16:45:59+0000
HOST: secops                      Loss%   Snt   Last   Avg  Best  Wrst StDev
  1.|-- 10.0.102.254               0.0%    10    0.4   0.5   0.4   0.7   0.1
  2.|-- 148.69.136.157             0.0%    10    0.5   0.5   0.4   0.6   0.1
  3.|-- ???                       100.0    10    0.0   0.0   0.0   0.0   0.0
  4.|-- 213.30.41.253              0.0%    10    3.5   3.5   3.2   3.8   0.2
  5.|-- 213.30.41.78               0.0%    10    3.7   3.7   3.4   3.9   0.2
  6.|-- 195.2.31.138               0.0%    10   12.3  12.3  11.8  13.0   0.4
  7.|-- 62.115.175.8              40.0%    10   12.0 1193.  12.0 3056. 998.4
  8.|-- 62.115.123.220             0.0%    10   30.5 132.9  30.4 1045. 320.8
        62.115.123.218
  9.|-- 62.115.123.12             40.0%    10  1044. 207.2  38.9 1044. 410.1
        62.115.122.139
 10.|-- 62.115.132.211             0.0%    10   42.1  41.6  39.7  43.3   1.1
        62.115.132.209
 11.|-- 62.115.13.95               0.0%    10   38.9  39.4  38.6  40.3   0.7
 12.|-- ???                       100.0    10    0.0   0.0   0.0   0.0   0.0
$ ping -c4 feed.community.greenbone.net
PING feed.community.greenbone.net (45.135.106.143) 56(84) bytes of data.

--- feed.community.greenbone.net ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 3075ms

$ curl -vvvv feed.community.greenbone.net
*   Trying 45.135.106.143:80...
*   Trying [2a0e:6b40:20:106:20c:29ff:fe7f:d2ae]:80...
* Immediate connect fail for 2a0e:6b40:20:106:20c:29ff:fe7f:d2ae: Network is unreachable


^C
$ curl -vvvv https://feed.community.greenbone.net
*   Trying 45.135.106.143:443...
*   Trying [2a0e:6b40:20:106:20c:29ff:fe7f:d2ae]:443...
* Immediate connect fail for 2a0e:6b40:20:106:20c:29ff:fe7f:d2ae: Network is unreachable




^C

WTF, is this my issue?

btw RSYNC:

$ telnet feed.community.greenbone.net 873
Trying 45.135.106.143...
Connected to feed.community.greenbone.net.
Escape character is '^]'.
@RSYNCD: 31.0 sha512 sha256 sha1 md5 md4
Greenbone community feed server - http://feed.community.greenbone.net/
This service is hosted by Greenbone Networks - http://www.greenbone.net/

All transactions are logged.

If you have any questions, please use the Greenbone community portal.
See https://community.greenbone.net for details.

By using this service you agree to our terms and conditions.

Only one sync per time, otherwise the source ip will be temporarily blocked.

Need to restart from scratch and clean all data and containers:

 docker compose -f $DOWNLOAD_DIR/docker-compose.yml -p greenbone-community-edition down -v

The issue was solved in the next setup iteration.

Thank you all for the help and support!