Replication Guide and Reference
The IBM Replication administrator can use the commands in the following
sections to perform the following Apply for Windows NT tasks:
- Starting
- Scheduling
- Stopping
Before you start the Apply program, ensure that:
After you start Apply, it runs continuously until:
- You stop Apply in an orderly way.
- An unexpected error or failure occurs.
To start Apply for AIX, Apply for HP-UX, and Apply for
Solaris:
- Ensure that you set the DB2 instance name as shown:
export DB2INSTANCE=db2_instance_name
- From AIX, HP-UX, or Solaris, log on with the IBM Replication user ID. Make
sure that the user ID under which Apply is running has write privilege on the
directory.
- Enter the asnapply command and one or more options, if desired.
>>-asnapply--apl_qual---+-----------+-+-----------+-+----------+>
+-ctrl_serv-+ +-loadxit---+ +-inamsg---+
+-noloadxit-+ +-noinamsg-+
>--+---------+-+----------+------------------------------------><
+-notrc---+ +-notify---+
+-trcerr--+ +-nonotify-+
+-trcflow-+
Table 16 defines the optional positional parameters.
Table 16. ASNAPPLY Parameter Definitions for UNIX Platforms
- Parameter
- Definition
|
- apl_qual
- Specifies the Apply qualifier that the Apply instance uses to identify the
subscriptions to be served. This positional parameter is required as the first
parameter.
|
- ctrl_serv
- Specifies the name of the server where the replication control tables will
reside. If you do not specify this optional positional parameter, the default
is the default database or the value you specified in DB2DBDFT.
|
- loadxit
- Specifies that Apply is to invoke ASNLOAD, an exit program that can call
an IBM or multivendor utility, to initialize a target table. This keyword
parameter is optional.
- noloadxit (default)
- Specifies that Apply will not invoke ASNLOAD.
|
- inamsg (default)
- Specifies that Apply is to issue a message when Apply is inactive.
- noinamsg
- Specifies that Apply will not issue this message. This keyword parameter
is optional.
|
- notrc (default)
- Specifies that Apply does not generate a trace.
- trcerr
- Specifies that Apply generates a trace that contains only error
information. This keyword parameter is optional.
- trcflow
- Specifies that Apply generates a trace that contains error and execution
flow information. This keyword parameter is optional.
|
- notify
- Specifies that Apply is to invoke ASNDONE, an exit program that returns
control to the user when Apply processing ends. This keyword parameter is
optional.
- nonotify (default)
- Specifies that Apply will not invoke ASNDONE.
|
When Apply for AIX, Apply for HP-UX, or Apply for Solaris executes, it
generates two files:
- <userid><database_instance_name><database_name>.LOG
This file contains the log messages issued by Apply during execution. Apply
also logs messages to the audit trail table. Check the columns APPERRM, SQLSTATE, SQLCODE, SQLERRP, and SQLERRM for information.
- <userid><database_instance_name><database_name>.SPL
This is an internal file used by Apply.
Use the at command to start Apply at a specific time. For
example, the following command starts Apply at 3:00 p.m. on
Friday:
at 3pm Friday asnapply l 1 r
Use the following command to stop Apply for AIX, Apply for HP-UX, and Apply
for Solaris.
>>-asnastop--apply_qualifier-----------------------------------><
or
>>-kill---INT--pid---------------------------------------------><
You can alternatively use one of the following key combinations from the
window where the Apply program is running:
Use the command or the key combination to stop the Apply program in an
orderly way and commit the log records that it processed up to that point.
- To use the command, do the following from a different window than where
the Apply program is running:
- Set environment variable DB2INSTANCE to the value that was set when the
Apply program was started.
- Set environment variable DB2DBDFT to the source server specified when the
Apply program was started (or the DB2DBDFT value that was used when the Apply
program was started).
- Enter the command.
- To use one of the key combinations, press it from the same NT window in
which the Apply program is running.
[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]
[ DB2 List of Books |
Search the DB2 Books ]