Failed to start PostgreSQL Cluster 12-main - VIRTUAL BOX

Hello, I installed Parrot os, put a virtual box on it, opened Parrot Security OVA there, did a complete update of Parrot OS on the virtual machine, on startup an error appears:
Failed to start PostgreSQL Cluster 12-main
Please advise how to fix it?

That’s because an update upgraded postgresql from 12 to 13.

sudo chmod 700 -R /var/lib/postgresql/13/main
sudo -i -u postgres
/usr/lib/postgresql/13/bin/pg_ctl restart -D /var/lib/postgresql/13/main

This may not be needed…

service postgresql-13.service restart

Verify with


I have the same issue with my vb and I don’t want to lose what’s on it. How do I run those commands if the OS in unable to start? Am I missing something ?