How to fix postgres stuck in recovery mode?
If you can re import your data, you can uninstall postgresql and reinstall it. And then re import your data. I had a similar issue and this worked for me.

for ubuntu : sudo apt-get --purge remove postgresql-YOUR VERSION