Databases

circle-exclamation

Setting up the Database

# Start PostgreSQL
$sudo service postgresql status
$sudo systemctl start postgresql

# Initiate a Database
$sudo msfdb init 
<...>
    # Error may occur after Fresh installation.
<...>
$sudo msfdb status
[+] ...
[+] Creating configuration file '/usr/share/metasploit-framework/config/database.yml'
[+] ...

# Connect to the initiated Database
$sudo msfdb run

# If something goes wrong 
$msfdb reinit
$cp /usr/share/metasploit-framework/config/database.yml ~/.msf4/
$sudo service postgresql restart
$msfconsole -q

msf6 > db_status

[*] Connected to msf. Connection type: PostgreSQL.

msf6 > help database

Using the Database

Workspaces

Importing the scan results

Nmap inside Metasploit

Exporting Data

Creds & Loot

Last updated