Step 1: Retrieve Database Credentials from the FusionPBX server
SSH into FusionPBX
- Log in to your FusionPBX server via SSH.
 
Open the FusionPBX Configuration File
		Bash:
	
	sudo nano /etc/fusionpbx/config.conf
	Locate the following information in the file and make note of it:
		Code:
	
	database.0.port = 5432
database.0.name = fusionpbx
database.0.username = fusionpbx
database.0.password = ************
	Step 2: Configure an SSH connection with Tunnel using PuTTY
Download PuTTY
- Download and install PuTTY from putty.org.
 
Configure the SSH Tunnel
- Open PuTTY on your local workstation.
 - In the PuTTY configuration window:
- Enter your servers host name or IP, port number and name of the connection.
 - Navigate to the Connection category.
 - Expand SSH, then click on Tunnels.
 
 - Set up the tunnel:
- In the Source port field, enter 5432.
 - In the Destination field, enter localhost:5432.
 - Click the Add button to add the forwarded port.
 
 - Connect to the FusionPBX server as you normally would using PuTTY.
 - While connected via Putty, port 5432 from the FusionPBX server will be redirected to your local operating system.
 
Step 3: Connect to the Database Using DBeaver
Download DBeaver
- Download and install DBeaver from dbeaver.io.
 
Open DBeaver and Set Up the Connection
- Open DBeaver.
 - Press Shift + Ctrl + N to create a new database connection.
 - Select PostgreSQL and click Next.
 
Enter Connection Details
- Ensure the SSH tunnel is open and ports are mapped correctly.
 - Configure the connection:
- Host: localhost
 - Port: 5432
 - Database: postgres
 - Username: Use the username from config.conf (e.g., fusionpbx).
 - Password: Use the password from config.conf.
 - Check the box for Show all databases.
 
 - Click Connect.
 
Verify the Connection
- If everything is configured correctly, you should now have access to the FusionPBX database.
 
All the software listed in this tutorial is open source. Please remember to support your open-source communities.