Backing Up SOAPware Data

The SOAPware DataManager is a database utility designed for the Postgres database. It uses existing, tried-and-true utilities provided by Postgres and Windows, but is wrapped up in a simple, easy-to-use interface.

The DataManager allows the user to create and schedule backups, schedule maintenance tasks and perform database restores. Before going live using SOAPware in a production environment, it is important to do a restore test on a different PC/server. Establish a schedule to perform regular test restores in the future and do them anytime there are changes in the system configurations.

SOAPware HIGHLY recommends that all users use Data Manager to create regular backups.

Best Practice Recommendations for Backup up the SOAPware Database

HIPAA 164.308(a)(7) states that the practice must "establish (and implement as needed) policies and procedures for responding to an emergency or other occurrences (for example, fire, vandalism, system failure, and natural disaster) that damages systems that contain electronic protected health information."

In addition, according to HIPAA 164.310(d)(1) it is the responsibility of the practice to "implement policies and procedures that govern the receipt and removal of hardware and electronic media that contain electronic protected health information into and out of a facility and the movement of these items within the facility." 

The above mentioned HIPAA references cover a number of items, but with regard to the backup of ePHI data, they state that it is the responsibility of the practice to ensure the backup and security of the data. SOAPware is not responsible for ePHI data or for ensuring that it is backed up and that the back up is valid.  It is the responsibility of the practice to devise and implement workflows that back up the data and ensure transport of the backup to a secure offsite storage location. 

SOAPware has created some best practice recommendations for complying with HIPA requirements for ePHI backups. Our best practice recommendations are merely suggestions, not requirements, nor is there any guarantee, implied or otherwise, that these suggestions will be the best for all practices. SOAPware's recommendations are posted for your consideration and potential adaptation.  The decision to use them, or not, is up to your practice. 

Based on our experience, the best solution is to contract with a reputable vendor to provide offsite, real time backup services. A SOAPware certified product for this service is available from Computer Consulting Service ( Please note that there are, of course, other products and vendors available to provide backup services. Please ensure that you tell your vendor that you are using a PostgreSQL database.

If you opt to use SOAPware's Data Manager backup utility or the batch backup solution, SOAPware Support will assist you with installation, configuration, and training. After these services have been delivered by a Support technician, it is the responsibility of the practice to institute its workflow for data backup. 

We strongly recommend a strategy that requires the use of three (3) external hard drives. This is a common, best practice approach to ensuring the integrity of your ePHI. It is often referred to as the 3-Generation Backup. 

  1. Drive 1: Take drive 1 (we'll call in the "Son) and plug it into the server for use. Be sure the backup utility is configured to use the external drive. 
  2. Drive 2: Take Drive 2 (we'll name this one "Father) and put this drive in a secure, offsite location, perhaps a safe deposit box in a bank or a fireproof safe in your home.
  3. Drive 3: Take Drive 3 (we'll name this one "Grandfather) and keep it on your person or in some other secure place for transport. An example of a secure place might be a lock box secured to the floor of a car trunk. 
  4. As part of the morning office routine, after the backup process is complete, remove "Son" from the server and plug "Grandfather" into the server.
  5. Transport "Son" to the offsite secure location and trade it out for "Father". 
  6. Place "Father" in the secure transport locale.
  7. Repeat this process everyday rotating each drive.

It is recommended that you make the 3-Generation drive rotation process a daily procedure. Be sure to check the utility for success or failure and take the appropriate follow-up actions. Always keep ePHI secure, whether it is on your person or in your car for transport. Create a schedule of this process in order to keep track of which drive is used on each day your clinic is open for business.

The final step of this procedure is likely to be the most resource intensive. Periodically, you must restore one of the backup data sets and test it to ensure it is a valid and functional backup. This is part of the contingency planning required by HIPAA. In other words, this is not an option

Should you have any questions or need assistance from a Support technician, please contact us at (800) 455-7627 option 2 or by submitting a ticket at

Installing Data Manager

To install Data Manager, see the link here: Installing Data Manager.

Data Manager Changes

The SOAPware Database Service is shut down during a backup - all users must be out of SOAPware before making a backup.

If a user previously scheduled a backup with any version before 2010, this scheduled backup will NO LONGER WORK with newer versions of the Data Manager. A user needs to create a new scheduled backup.

Start the SOAPware Data Manager

Start the SOAPware Data Manager

To start the SOAPware DataManager, Click Start > All Programs > SOAPware > SOAPware DataManager.

If users are running on Windows Vista or 7, users will need to right-click on the program name and choose “Run as administrator."

Log In

Log In

When a user starts DataManager, the user must log in with the database administrator password. This defaults to the PostgreSQL user account on the database. (This is the second set of passwords created during the SOAPware Data Server installation).

NOTE: The database administration password is NOT the same as the SOAPware Administration password. The database administration account only accesses the PostgreSQL database.

Only use the Advanced section if the server, port, or database administration user name is different than the default settings.

  • Server: Host name or IP address where the database is running.  The default is "localhost".
  • Port: Port number where the database is listening.  The default is port 5432.
  • User Name: The administration user on the database.  User must have administration privileges.  The default setting is PostgreSQL.

Enter Backup Information

Enter Backup Information

The backup routine creates a copy of the user's data folder. It contains all the user, tablespace, table and data information needed to restore the user's database completely.

Backup file sizes can range from about 50 MB to many Gigabytes, depending on database size and compression options.

It can take from 20 minutes to several hours for a backup to complete. SOAPware cannot be used while the backup is running. Please plan to schedule backups to run nightly for the best results.

  1. Backup Name: Users should choose a meaningful backup name that can be easily remembered.
  2. Append Current Date:  This will attach a date stamp of when the backup was run.  If checked, new backup files will be created each day, which in turn will create multiple backups. This helps ensure the user's data, but the user must also delete old backup files every so often to prevent the backups from taking all the space on the drive. If this is not checked, the backup will overwrite the last backup each time.
  3. Select Backup Save Location:  Choose the folder where the backup file will be placed.
  4. Set Backup Schedule: This header is collapsible. Click it to view or hide scheduling options.  See the Scheduling section below for more details on setting a backup schedule.
  5. Backup Now Button: Click this button to run a backup using the settings on this tab.

*Note: A backup can be canceled. It will delete the current backup file, and the database will not be affected.  If a backup is canceled, go to Start > Programs > PostgreSQL 8.x, and Click "Start Service".


Maintenance: Optimize Performance

Maintenance: Optimize Performance

Databases need to be optimized and cleaned up routinely for maximum performance. Higher traffic databases should be optimized more often, sometimes daily. Lower traffic databases may only need to be optimized once a week or once a month.

Optimizations may take from 30 minutes to several hours to complete.

  1. Run All Optimizations: Perform each optimization (Recommended)
  2. Update Statistics: Resets all table statistics, row counts, etc.
  3. Clear Unused Space: This is useful after multiple deletions to reclaim space left behind.
  4. Reset Indexes: Refreshes table indexes to help data retrieval.
  5. Set Maintenance Schedule: This header is collapsible. Click it to view or hide scheduling options. See the Scheduling section for more details on setting a maintenance schedule.
  6. Optimize Now Button: Click button to perform selected optimizations.

*Note: Running optimizations may degrade database performance. We recommend setting a Maintenance schedule to run at night or weekends when database traffic is low.

Maintenance: Log File Maintenance

Maintenance: Log File Maintenance

The Log File Maintenance feature within DataManager allows the user to effectively control the number of log files that will be stored in the "pg_log" folder.

The user can select the frequency of the log file maintenance by choosing annually, monthly, or weekly.

  • Weekly: If the "weekly" option is selected, the files will be kept for up to one week before being overwritten with new files for the following week.
  • Monthly: If the "monthly" option is selected, the files will be kept for 30 days before being overwritten with new files for the following month.
  • Annually: If the "annually" option is selected, the files will be kept for 365 days before being overwritten with new files for the following year.

The user should choose whichever option will best suit the database. The default setting will be set to "Monthly".

*Note: Please note that any changes to log file maintenance will be implemented the next time the database is restarted.

Options: Database Options

Options: Database Options
  1. Install Path: The DataManager uses Postgres utilities for backup and restore. This path should not be changed unless the Postgres install path is different than listed.
  2. Data Path:  This section is used to point the DataManager to the location where the data is stored in order to backup.  By default the path will be C:\Program Files (x86)\PostgreSQL\8.3\data.
  3. Service Name: The service name is the name of the SOAPware PostgreSQL Data Server service. Typically, this will be pgsql-8.3.  To check, go to Start > Programs > PostgreSQL 8.x, a user will see either PostgreSQL 8.3 or PostgreSQL 8.2. The service name will either be pgsql-8.3 or pgsql-8.2 depending on which version the user has.
  4. Service Account: This is the windows user that starts the SOAPware PostgreSQL Data Server after the backup is complete. This should always be postgres.
  5. Compress Backup: This option compresses the backup file as it is being written. Use this option to keep file sizes at a minimum.
  6. Data Manager Password: Use this to change the database administration password.

*Note: The database administration password is NOT the same as the SOAPware Administration password. The database administration account only accesses the PostgreSQL database.



The DataManager can take a previously made backup file and restore the database to its original state.

*Note: After the restore is completed, any user passwords or preferences changed since the backup will be reset to previous state.

  1. Select Backup File: Choose the backup file created by the DataManager to run a restoration.
  2. Restore Button: Click this button to start the restoration.

If restoring a compressed backup file, the DataManager needs to decompress the backup to the PostgreSQL data directory. The data folder can take as much as seven times the compressed file size needed in hard drive space. For example, a 3GB compressed backup may need an extra 20GB of hard drive space to run the recovery.

If a restoration is attempted and there proves to be insufficient disk space, the process will fail and must be restarted. Simply make more room, or re-install the SOAPware PostgreSQL Data Server to another drive with more space and restore to that drive.

*Note: Users must wait 10 minutes between creating a backup and running a restore in order to clear out the connections.

WARNING: Running a restore will replace all the data and table structures within the database.  The old database will be deleted.  This process cannot be canceled.

Scheduling Backups and Maintenance

The DataManager provides an easy-to-use interface to create a Windows Task scheduled event to run a user's backup and maintenance routines. Simply setup a backup or maintenance task as outlined above, then choose the schedule frequency. When a user saves the schedule, a user's task will run at that time.

For advanced users, maintain existing tasks using the Windows Task scheduler. For more information, start here at the Microsoft Task Knowledge Base.

Create a New Scheduled Task

Create a New Scheduled Task

After setting the backup or maintenance information, click on the "Backup" button in the top left hand corner. Expand the "Set Backup Schedule" tab by clicking on the down arrow icon.

  1. Run: Under the Run drop down, you may choose the schedule run type from Once, Daily, Weekly or Monthly. Different options will appear depending on the type of schedule selected.
  2. Time: Set the time for the task to run. This should be a time when there is no database activity.
  3. Name: Name the schedule so that it will be unique within the Windows Task Manager. If there is already a task with the same name, it will ask if you would like to overwrite the existing task.

Run Once

Run Once

This option will run the task only once on the specified day and time.

Run Daily

Run Daily

This option will run the task daily. A user can choose to skip a number of days.

Run Weekly

Run Weekly

Running a task weekly allows a user to choose which days of the week to run. A user may also skip weeks.

Run Monthly

Run Monthly

A monthly task allows a user to set the task to run once a month on a certain day. A user may check the months to run the task.

Change Existing Schedule

Change Existing Schedule

To change an existing schedule, a user would simply setup a new schedule with any new backup or maintenance or schedule data, and give the same schedule name as an existing task. This will overwrite the existing task with the new information.

To find a list of a user's existing schedules, look in the Windows Task Scheduler for the tasks. Go to the Windows Start menu, then open the Control Panel. Open Scheduled Tasks, and it will list all the current tasks. A user may edit these directly to change the schedule, but to change the backup or maintenance parameters, a user must use the DataManager and overwrite one of the tasks.

Delete Existing Schedule

Delete Existing Schedule

To delete an existing schedule, open the Scheduled Tasks control panel as mentioned above. Right click on the task and choose Delete.

Data Manager Log Files

Log files can give the user details on how tasks are running. They provide information about what tables were used and any warnings or errors which may have occurred. Each time the DataManager is used, either in the GUI or in a scheduled task, it will create a log file of the events.

Find the logs where DataManager is installed. The default install location is C:\Program Files (x86)\Soapware\DataManager\Logs.

The Logs directory will only keep the last 10 log files so there is no need to clean out this directory or to worry about it filling up. If a user plans to keep a log file for support or other needs, be sure to move it out of this directory, or it could be deleted as more log files are created.

SOAPwareXchangeHL7 and SOAPwareXchange

Users who are running either the SOAPwareXchangeHL7 or SOAPwareXchange, must NOT be running when a backup via Data Manager is running. If a user has a scheduled backup set, then both Xchange and XchangeHL7 must be not be running. This can be accomplished by using the SOAPwareXchangeHL7 & SOAPwareXchange Command Line article to both stop and start around a Data Manager scheduled backup.