If you regularly update your Kali machine and use Openvas you could run into this error: the default postgresql version is not 13 required by libgvmd
It’s because there are two versions of postgresql running at the same time. Since postgresql is using a TCP port it cannot be the same port for both versions. Openvas is expecting version 13 running on TCP port 5432. When you get the error possibly version 12 is using this port. So the fix is to change the ports by editing the following files:
sudo nano /etc/postgresql/13/main/postgresql.conf and change the port to 5432.
sudo nano /etc/postgresql/12/main/postgresql.conf and change the port to 5433 (or any other port which is free).
sudo systemctl restart postgresql
Then start the Openvas service and hopefully it will run without any errors.
UPDATE 2022: check out this blog for the same error on postgresql version 15
Perfect!! Worked for me.
Thanks for sharing
Very simple and easy to follow insructions.
it shows gvm start should run as root i dont understand that. can you please help me out?
You should run the command as sudo
use sudo cmd
Run as Supervisor (“sudo ” before command line).
awesome thank you
Excellent info & tutorial! Thanks for share.
Nice solution, I was writing a post about OpenVAS and wanna share this info at the beginning, with referencing your site if also ok for you
Hi, sure no problem
bookmarked!!, I really like your site!
thanks bro for your sharing. It worked for me
Nice Work. Installed successfully GVM on Kali 2021.1. Thanks a lot.
You’re awesome its worked, thank you 🙂
Thanks, you are welcome
This did not work for me, Has anyone had any problems with this not working?
Thanks in works!
when i print this command “sudo nano /etc/postgresql/12/main/postgresql.conf ” i have another error which is
[ Directory ‘/etc/postgresql/12/main’ does not exist ]
You can try sudo apt-get install postgresql
Worked perfectly for me.