The Call History Postgres Database stores all the Call History records for MiVoice Business Console operators.
A Windows PC that meets the basic Postgres Server requirements. For more information, refer to MiVoice Business Console Installation and Configuration Guide.
The server PC's port 5432 must be available to the network and all other MiVoice Business Consoles.
The Postgres server can be installed on one of the MiVoice Business Consoles if required.
Download the Postgres Server Installation package from the website:
https://www.postgresql.org/download/windows/
Execute the downloaded installation package.
The Setup wizard appears.
In Setup wizard, under Select Components, clear the Stack Builder check box, and click Next.
Specify the database location and click Next.
Enter a password for the Postgres user and click Next.
Do not modify the default Port number (5432) and click Next.
Do not modify the default Locale ([Default locale]) and click Next.
The Summary window is displayed.
Click Next.
The Ready to Install window is displayed.
Click Next.
After the installation is complete, click Finish.
Open the pgAdmin 4 application to connect to the database server.
The application displays the current server.
Enter a master password and click OK.
Expand Servers to view currently installed Postgres 12.1 server.
Enter a password and click OK.
Right-click Servers, point to Create, and click Server.
The Create -Server dialog is displayed.
In the Name field, enter the name of the server. For example, Local Host.
Click the Connections tab, and enter the following details:
Host name/address- enter localhost or the DNS name of your remote computer.
Port- enter 5432 as the port number.
Maintenance database- enter a name for the maintenance database.
Username- enter a user name for the server.
Password- enter a password for the Postgres user.
Click Save.
Create a role with the name:
Expand Local Host, right-click Login/Group Roles, point to Create, and click Login/Group Role.
The Create - Login/Group Role dialog is displayed.
Click the Definition tab.
Enter password for the role.
Click Privileges tab and set Yes for all the privileges except Can initiate streaming replication and backups?
Click Save.
Create a database with the name IP_CONSOLE_5550:
Expand Local Host, right-click Databases, point to Create, and click Database.
The Create - Database dialog is displayed.
In the Name field, enter IP_CONSOLE_5550.
In the Comments field, enter comments for new database.
Click Save.
The database IP_CONSOLE_5550 is created.
The network parameters must be configured on pgAdmin application to provide access for MiVoice Business Consoles on the network.
To set Postgres network parameters:
Open the pg_hba.conf file in the Notepad application.
Scroll to the bottom of the file and add the network parameters as shown in the following example.
On the File menu, click Save, and close the file.
Call History feature must be enabled on MiVoice Business Consoles in the network. For detailed procedure, see Configure Call History.
Backup
To back up the call history database:
Open the pgAdmin 4 application.
Using the left pane, navigate to Server > <Your Server Name (for example, Local Host) > Databases > IP_CONSOLE_5550 > Schemas > public > Tables > call_history.
On the Tools menu, click Backup.
The Backup dialog is displayed.
In the Filename field, enter a file name with the directory location where you want to save the backup file.
Click Backup.
Purge
You must periodically purge the Call History database to improve performance.
To purge call history database:
Open the pgAdmin 4 application.
Using the left pane, navigate to Server > <Your Server Name (for example, Local Host) > Databases > IP_CONSOLE_5550 > Schemas > public > Tables > call_history.
On the Tools menu, click Query Tool.
The Query Editor is displayed.
To retain only the last one year data, in the Query Editor, type delete from call_history where call_time < date(now()) – 365 and click to purge the call history database.
A dialog is displayed with the result.