I cannot run gvm "ERROR: The Postgresql DB does not exist."

I have installed gvm and I cann’t run it everytime I go to … it show me failed connection! And when I tried to check the issues that’s what happened:

1 - when I put this command:

$ sudo gvm-check-setup

It showed me this error:

Step 5: Checking Postgresql DB and user
OK: Postgresql version and default port are OK.
ERROR: The Postgresql DB does not exist.
FIX: Run ‘sudo runuser -u postgres - /usr/share/gm/create-postgresql-database’

2- when I tried to run the command as it said:

$ sudo runuser -u postgres - /usr/share/gm/create-postgresql-database

It showed me this error:

[ij User -gvm already exists in PostgreSQL [il Database gmd already exists in PostgreSQL
[i] Role DBA already exists in PostgreSQL
[*] Applying permissions
role “_gvm” has already been granted membership in role “ba” by role “postgres”
[i] Extension wuid-ossp already exists for gmd database
[i] Extension pcrypto already exists for gmd database
[i] Extension pg-gm already exists for gumd database

So all databases seems exist already so why I keep get this error?

Please help I been in this problem since long time.


1 Like

Both scripts gvm-setup and gvm-check-setup are not provided or maintained by Greenbone and any issues during the usage of it should be reported to the responsible maintaining team. I guess this is Kali so this would need to be reported to https://bugs.kali.org

In this specific case there seems to be an existing bugreport so i would suggest to monitor that one for any upcoming fix / solution.