I went through the PoststreSQL setup yesterday and I verified my user admin has access to the role dba (see below):
postgres@osboxes:/home/mysuser/projects/gvmd$ psql gvmd
Type “help” for help.
gvmd=# create role dba with superuser noinherit;
ERROR: role “dba” already exists
gvmd=# grant dba to admin;
NOTICE: role “admin” is already a member of role “dba”
gvmd=# create extension “uuid-ossp”;
ERROR: extension “uuid-ossp” already exists
However, in the meantime a colleague of mine noticed I was using a regular user, instead of the Linux superuser.
Now everything works as expected. I can spawn gvmd and create/modify/delete objects like users, tasks, etc.
Use a regular user for installation (do not use root).
Once you have all the cloned repos locally, read the INSTALL.md files and follow the steps.
If you do not know how to set up libraries/folder variables (DCMAKE_INSTALL_PREFIX, etc) before cmake/compilation, just use the suggested commands from the build folder.
$ cmake ..
$ make install
When running cmake, make or make install you will get some message stoppers, particularly if you have not set up the libraries/folder variables before running cmake/compilation. Some of them will look like can’t copy this file into there (during make install) or maybe missing packages. This is not blocking. Just give folder permissions and relaunch the command.
thanks for the fast answer, i will try it and give you than a feedback if its worked for me
The problem is that i try to install the gvm11 over the gvm10 which was already running… I dont know if thats a good idea… but ye… i will see…
i installed it now again step by step till to the step with the postgresql… but i wonder why i have to edit now sth in the postgresql settings… with gvm 10 i just installed it and doesnt make anything with postgres…
atm i have this error in the gvmd.log:
md main:MESSAGE:2019-10-15 12h38.09 utc:30120: Greenbone Vulnerability Manager version 9.0.0 (DB revision 221)
md manage:WARNING:2019-10-15 12h38.09 utc:30121: sql_open: PQconnectPoll failed
md manage:WARNING:2019-10-15 12h38.09 utc:30121: sql_open: PQerrorMessage (conn): FATAL: role “user” does not exist
md manage:WARNING:2019-10-15 12h38.09 utc:30121: init_manage_process: sql_open failed
i try now the postgresql steps from the install.md.
Do you maybe know if i have to name the user like my “login” user?
i dont know if it can be come to complications cause my login username is “user”?
I used this command for cmake:
cmake -DCMAKE_INSTALL_PREFIX=/home/user/install …
for the libraries variables i have used in gvm10 this:
so that you dont get wrong, i have a working GVM10 Setup, but because GVM11 is released i try to “update” it with install the new version GVM11 over the old setup. In the old Setup i dont had to create a postgres user/db… So i wonder why i have to do that now.
For me it seems you are not very familiar with unix groups/permissions, postgres setup and building C code from source. Therefore I would recommend to use packages from a distribution or alternatively our community edition.
The solution for your problem is listed in the INSTALL.md document of gvmd
It’s not clearly stated in the docs but changing your ld.so.conf has serious security implications and should not be done on hosts used in production setups. It’s only intended for short term testing or development.