After msfupdate, postgresql selected, no connection

After I did a “sudo msfupdate”, somehow my msfconsole is not connected to the database. when I type:
msf> db_status
postgresql selected, no connection

So, to connect back, I need to provide the location of database.yml, as in

msf> db_connect -y /usr/local/share/metasploit-framework/config/database.yml

And it connects again. yeah. To do this everytime msfconsole is called, we can create an alias in .bashrc.

alias msfconsole='msfconsole -d db_connect -y /opt/framework/config/database.yml'

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: