Cloning an Oracle/DB2/Sybase Database in a SAN Environment Using EVA Snapclone Technology (August 2007)

18
and later versions enable you to temporarily suspend writes to the database by executing the
SET WRITE SUSPEND command. This command also suspends the transaction log files.
However, read-only transactions continue to run on the database while it is in the write-
suspended state. In addition, some transactions may be forced to wait if they require disk
I/O; for example, to flush dirty pages from a buffer pool or to flush log records from the log
buffer. These transactions proceed normally when write operations on the database are
resumed.
To suspend write operations to a database, connect to the database and enter the following
command:
Set write suspend for database
The write operations to the database are suspended.
After cloning the database, operations can be resumed by entering the following command
on the database server:
Set write resume for database
The write operations to the database are now resumed.
Initializing a Snapclone Copy of a Database Using the Db2inidb Command
Along with the SET WRITE command, the db2inidb command is introduced in DB2 UDB 7.1
FixPak 2. This command is primarily used to initialize a Snapclone copy of a database.
The syntax for the db2inidb command is as shown below:
db2inidb [DatabaseAlias] as [Snapclone |standby|mirror] <relocate using [ConfigFile]>
where:
DatabaseAlias
identifies the alias assigned to the Snapclone (secondary) database that is to
be initialized.
ConfigFile
identifies a configuration file that contains information on how the database
files contained in the Snapclone of the database are to be relocated when the Snapclone
image is initialized.
Note:
Parameters shown in angle brackets (< >) are optional, and parameters shown in
square brackets ([ ]) are mandatory.
The db2inidb command can also be used to modify the database name, the database
instance name, and the tablespace header information based on the user provided
configuration file. The configuration file must adhere to the following format: