Steps to take PGSQL Dump Backup and Restore

Steps to take PGSQL Dump Backup and Restore

PGSQL – DUMP – Backup Procedure :


Login to the MSP application server and perform the below steps,

1. Start the application


To take Postgres (Psql) Dump :


3. Open a command prompt and navigate into <ServiceDeskPlus-MSP>/pgsql/bin directory.


4.  Execute -> pg_dump -U {user-name} {source_db} -f {dumpfilename.sql}


Using the above step if the dump is not created, then try the below,


pg_dump -U postgres -h 127.0.0.1 -p 65432 servicedesk > test.sql


This will create a file named “test,sql” <ServiceDeskPlus-MSP>/pgsql/bin.


Take a Copy of this file.


To restore :


1. Install the application in a different machine


2. Start and shut down the application once.


Paste the taken test.sql under <ServiceDeskPlus-MSP>/pgsql/bin directory.


3. execute – startDB.bat 65432

4. Open a command prompt and navigate into <ServiceDeskPlus-MSP>/pgsql/bin directory.


psql -h localhost -p 65432 -U postgres -d servicedesk


5.Execute query \c postgres


6. Execute drop database servicedesk;

7. create database servicedesk;


8. Execute \q or quit.


9. Now execute ->psql -U {user-name} -d {desintation_db}-f {dumpfilename.sql}


10. Once the process is completed. Execute stopdb.bat 65432


11. Run the application and check the configuration


                  New to ADSelfService Plus?

                    • Related Articles

                    • Backup & Restore (from 14000) - Behavior changes

                      Backup: POSTGRES & MSSQL: -> When taking a backup using the command backUpData.bat/backUpData.sh the backup will be created in the EZIP format. This is the native model of PGSQL / SQL. -> When taking a backup using the command ...
                    • How do I restore the backup data?

                      NOTE: For builds > 10.6 While migrating to different database you can use backupdataold.bat / backupdataold.sh. Here backup will be in .data format and this can be restored in across DB platform. While restoring .data file we have to use below ...
                    • How to take a backup in SDP-MSP

                      Note: In 10.6 when running a backup using backdata.bat/backdata.sh the backup file will be in .ezip format. Backup with .ezip format can be restored to the same database platform only. For example a backup with .ezip when taken from postgres DB ...
                    • How do I convert the database from PGSQL to MSSQL?

                      1. Stop ManageEngine ServiceDeskPlus – MSP service. 2. Take a backup of the existing data and configuration under PGSQL database by following the below steps. Open CMD as an administrator and execute  command to start the data backup. ...
                    • How to restore your data in ServiceDesk Plus

                      1. Stop the ManageEngine ServiceDesk Plus service from the Services console(services.msc).   2. Click the Windows icon and select Command Prompt (Admin).   3. Go to Bin directory and run restoreData.bat   4.Browse to the backup file from backup ...