Question
· Jun 18

Refresh databases on test system from production system

Hi,

I want to refresh the data in the databases from the data that exists in the production system.

The IRIS system in both test and production are in a mirror arrangement

Can the refresh be done by doing a backup on the production system and restore the same backup to test?

Could the refresh be customised so that certain databases can be excluded?

Discussion (5)3
Log in or sign up to continue

A low impact way to do this would be take a SAN snapshot of production and mount the snapshot in test.

Intersystems discusses this in External Backup.

The easy way to retain some database is mount them from a different set of disks/filesystem.

If you have a DR mirror but not a SAN you could just shutdown the DR mirror and do a cold backup.

If test is a separate mirror the whole test mirror will have to be refreshed due to mirror headers. If test is part of the same mirror as production then the data is already there.

We use nightly IRIS backups which are moved to a network share, so Test can restore the backups to an alternate application data DB via a script.  We always have 2 application DBs defined, so we can script a restore on a weekly basis so the data is readily available if a developer needs it - they simply swap from the active data DB to the alternate (the alternate is always the target of the automated restore so as not to interrupt any data depending testing which may be actively going on at the time of restore).  

We have found this to be very effective for our needs for multiple internal applications. 

Hi Philip,

not knowing anything about your deployment or applications hosted by IRIS this will be only very high-level.

There are multiple ways how this can be achieved. 

Essentially the easiest way is to stop/freeze the IRIS instance on your backup mirror in LIVE then, depending on your databse sizes. Either copy the database files over to your test environment, or take afilesystem snapshot and transfer that accross. After start,thaw the backup mirror iris instance.

On the test environment break the mirror. shutdown the instance on your primary test mirror. copy in the databases you transferred (ensure the global mappings are the same), you can choose at this point to not overwrite certain databases you do not want to be refreshed e.g. localsysconfig. start up the iris instance, remove the mirror flag from the database files you just refreshed and then do all post refresh activities. at the end you have to rebuild the TEST mirror though, as per IRIS doco.