OpenVAS for Postgresql

Support/Development for OpenVAS
ced134
New Forum User
New Forum User
Posts: 2
Joined: Wed Jun 21, 2017 9:12 am
Location: Cheshire

OpenVAS for Postgresql

Unread post by ced134 »

Hi,

I have installed OpenVAS onto Centos 7 from the Atomic repo. It appears to be built with SQLite3 support, (the clue being in the name /usr/sbin/openvasmd -> /usr/openvasmd-sqlite)

I need to convert to using Postgresql -- is there a ready-made exec for Centos (using the same install locations as the above) or do I need to do my own build from source?

Thanks.
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Re: OpenVAS for Postgresql

Unread post by scott »

I completely forgot about the postgres support in there! I'd be happy to add that in. We ran into a similar situation with OSSEC, and I think we could use the same split package setup from OSSEC (mysql or postgres support in its case) with openvasmd. That way you can avoid a postgres dependency if the system unless you're specifically using it.
ced134
New Forum User
New Forum User
Posts: 2
Joined: Wed Jun 21, 2017 9:12 am
Location: Cheshire

Re: OpenVAS for Postgresql

Unread post by ced134 »

That would be great, thanks.

Chris
harahauk
New Forum User
New Forum User
Posts: 1
Joined: Tue Aug 29, 2017 6:44 am
Location: Norway

Re: OpenVAS for Postgresql

Unread post by harahauk »

I am eagerly awaiting this as well. Can't seem to find binary packages with this activated.
I'll compile the manager for now, but going to watch out for updates

Thanks
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Re: OpenVAS for Postgresql

Unread post by scott »

yeah its spectacularly difficult to put together. So far the connector itself almost never works. Still in progress though, we'll beat it eventually
amgroup
New Forum User
New Forum User
Posts: 1
Joined: Sun Oct 01, 2017 6:48 pm
Location: San Jose

Re: OpenVAS for Postgresql

Unread post by amgroup »

I have similar question on OpenVAS with PGSQL.

I used the atomic rpm OpenVAS 9.x installation. Then I ran the openvas-migrate-to-postgres. It created tables in the tasks db. That is a good sign!
Questions:
Is OpenVAS 9 RPM built to support postgres? Where can I find the rpm build options?
Where can I define the PGSQL connection for the OpenVAS to use instead of it using the default sqlite3?

I noticed that the openvasmd has the -d, --database=<file/name> Use <file/name> as database for SQLite/Postgres. If I want to use the PGSQL, how do I define this parameter? What is the valid setting here?
A DB connect would require to have a hostname/ip, database name, userid, password. How can these connection info be provided to OpenVAS so it uses the PGSQL instead of SQLite?
I also noticed that the /etc/sysconfig/openvas-manager and scanner has the OPTIONS="" . My guess is that the --database parameter could be defined here.

Thank you,
flock3
New Forum User
New Forum User
Posts: 2
Joined: Wed Nov 08, 2017 12:14 pm
Location: Germany

Re: OpenVAS for Postgresql

Unread post by flock3 »

Hi,

I would be interested in the answer to amgroups questions.
How can I proof that my OpenVAS is using the Postgres DB after I ran the migrate-to-postgres script?
Is it a good sign that my tasks.db in /var/lib/openvas/mgr/ grows? Is this the path for the new postgres DB or is this still the sqlite3 DB file!?

There seems to be not enough documentation about the whole topic ):

I'm thankfull for every helpful input I can get.

Cheers,
flock3
scott
Atomicorp Staff - Site Admin
Atomicorp Staff - Site Admin
Posts: 8355
Joined: Wed Dec 31, 1969 8:00 pm
Location: earth
Contact:

Re: OpenVAS for Postgresql

Unread post by scott »

That is the sqlite file, the postgres db would be under /var/lib/postgres/
flock3
New Forum User
New Forum User
Posts: 2
Joined: Wed Nov 08, 2017 12:14 pm
Location: Germany

Re: OpenVAS for Postgresql

Unread post by flock3 »

Hi Scott,

thanks. So my OpenVAS instance keeps using sqlite.
Do you know how I can then link to the new Postgres installation?

I wasn't able to find that specific configuration step in the documentation.

Thanks in advance,
flock3
Post Reply