View Issue Details

IDProjectCategoryView StatusLast Update
0006763Kali Linux[All Projects] Tool Upgrade Requestpublic2020-12-21 14:55
Reporterklbt001 Assigned To 
PrioritynormalSeveritytweakReproducibilityalways
Status assignedResolutionopen 
Product Version2020.3 
Target VersionFixed in Version 
Summary0006763: Current gvm 11 is very slow with PostgreSQL 12
DescriptionCurrent gvm 11.0.5 is very slow with PostgreSQL 12.4.

This is because gvm 11 is optimized for PostgreSQL 9.6, but Kali ships 12.4.

See this forum message from Björn Ricks, the GVM development team lead:
https://community.greenbone.net/t/optimizing-postgresql-for-gvmd/6713/11

If PostgreSQL 12 will receive fixes in gvm 20 and gvm 21 isn't promised.
Please see this forum message of Björn Ricks:
https://community.greenbone.net/t/optimizing-postgresql-for-gvmd/6713/9
Steps To ReproduceCreate and execute a vulnerability scan that produces about 2000 results.

After the scan is finished go to the specific report and call the results tab.
In my case (8 core Intel i5, 3600 bogomips each core, 16 GB RAM) the results tab needs about 45 seconds to load.

With old gvm 9 there was no noteable delay in loading results.
Additional InformationI suggest that Kali ships also the reference implementation (combination) from Greenbone Networks.

Or should it be possible to do performance optimization on the combination gvm 11 and PostgreSQL 12?

Activities

klbt001

2020-10-01 18:44

reporter   ~0013518

While the query of the above example is running, these 45 seconds, there are one or partially two PostgreSQL procceses active, consuming 100 % CPU each.

klbt001

2020-12-06 19:24

reporter   ~0013944

Same with GVM 20 and PostgreSQL 13.

sbrun

2020-12-14 13:44

manager   ~0013977

Thanks for the report.
Unfortunately we have to use the postgresql version present in Debian Testing (currently version 13).
I don't know anything about performance optimization for postgresql / gvmd. Patches are welcome.

I hope upstream will work on this soon.

kali-bugreport

2020-12-14 18:00

reporter   ~0013981

Found this one about PostgreSQL optimization:

> Found the answer to this issue in case anyone else runs across it, it’s JIT in Postgres 12.
>
> Just edit postgresql.conf, find the commented out line that says jit = on, uncomment, change it to say jit = off, and postgres 12 works fine.

https://community.greenbone.net/t/everything-works-but-i-cant-see-any-report/5875/21

klbt001

2020-12-14 19:17

reporter   ~0013982

Wonderful, the hint with jit = off helped to solve the issue, also with GVM 20 and PostgreSQL 13.

kali-bugreport

2020-12-14 20:02

reporter   ~0013983

Indeed wonderful. Not sure about the side effects of disabling JIT and if upstream can do something about it (i guess not if JIT of PostgreSQL could be responsible for this)

sbrun

2020-12-21 14:55

manager   ~0013994

thanks for the hint.
I will add a note in the README.Debian of the gvm package

Issue History

Date Modified Username Field Change
2020-10-01 13:27 klbt001 New Issue
2020-10-01 13:27 klbt001 Status new => assigned
2020-10-01 13:27 klbt001 Assigned To => sbrun
2020-10-01 18:44 klbt001 Note Added: 0013518
2020-12-06 19:24 klbt001 Note Added: 0013944
2020-12-14 13:44 sbrun Note Added: 0013977
2020-12-14 13:44 sbrun Assigned To sbrun =>
2020-12-14 18:00 kali-bugreport Note Added: 0013981
2020-12-14 19:17 klbt001 Note Added: 0013982
2020-12-14 20:02 kali-bugreport Note Added: 0013983
2020-12-21 14:55 sbrun Note Added: 0013994
2021-05-31 13:37 rhertzog Category Tool Upgrade => Tool Upgrade Request