black electronics

Metasploit

Common commands for starting the Metasploit database and console during pentests.

Metasploit relies on a PostgreSQL database to store hosts, services and loot. On a fresh Kali install, the database usually needs to be initialised before msfconsole will connect to it.

Terminal window
sudo systemctl start postgresql # Start the database service
sudo msfdb init # Initialise the Metasploit database
msfconsole -q # Launch msfconsole quietly (no banner)
db_status # Confirm msfconsole is connected to the database
Useful LinksPentest PayloadsCheat Sheets