- Function
The hdestart command starts the source Datareplicator in accordance with its extraction system definition. For details about the extraction system definition, see 5.2 Extraction system definition.
- Format
hdestart {[ -i[ init ][ -S target-identifier-number]]|
[ -e ] [ -r ] [ -s[ target-identifier-number
[{{,target-identifier-number}}...]][ -L [ -H ]]]|
[ -R -k queue -b HiRDB-server-name]|
[ -v [ -e ][ -r ]]}
- Options
- -i [ init ][ -S target-identifier-number]
- Specify this option to initialize the source Datareplicator environment. When the -i option is specified, the source Datareplicator does not start.
- When the -S option is specified, Datareplicator initializes only the transmission environment for the specified destination. When the -S option is omitted, Datareplicator initializes the following files and the entire source Datareplicator environment (when the -S option is specified, Datareplicator does not initialize files):
- Extraction information queue files
- Extraction master status file
- Extraction server status file
- Extraction master error information files
- Extraction node master error information files
- Extraction master trace files
- Extraction node master trace files
- Data linkage file
- init
- Specify this option to create all extraction information queue files specified in the extraction environment definition based on the size specified in the queuesize operand in the extraction environment definition. Depending on the specified file size, the creation processing might not be completed within the communication wait time specified in the cmwaittime operand in the extraction system definition, resulting in an error (KFRB00607-E message). In such a case, increase the communication wait time and re-execute the initialization processing.
- This option is ignored when the -S option is specified.
- If this option is specified when large files are used, the command might take a long time to execute. For details, see 6.11.2 Estimating the command execution time when large files are used.
- -S target-identifier-number
- Initializes the transmission environment for the specified target only (partial initialization). Datareplicator does nothing for targets that are not specified.
- Specify the target identifier number, which is the numeric digits in xx or xxxx of the target identifier specified in the extraction system definition (sendidxx or sendidxxxx). The specified target identifier number must have been defined when the most recent initial start was executed. You cannot specify a newly added target identifier number. The partial initialization specified in this operand is applicable to transmission environment definitions specified with sendidxx (or sendidxxxx), or senddefxx (or senddefxxxx) in the extraction system definition.
- The next time a transmission process with the specified target identifier is started after partial initialization, it will start sending the update information that has been written into the extraction queue by the extraction process. Datareplicator handles any change to a definition other than partial initialization in the same manner as a normal start.
- Do not change a definition other than the target identifier that is subject to partial initialization. To perform partial initialization on multiple target identifiers, first change the definition of a target identifier, and then perform partial initialization; then, repeat this procedure for each additional target identifier.
- -e
- Specify this option to start only extraction processing at startup without starting transmission processing. If extraction processing was not started during the preceding execution of hdestart, you use this option to start extraction processing also.
- -r
- Specify this option to reset the data transmission count when the source Datareplicator is started.
- This option is applicable when false is specified in the send_counter_reset operand in the extraction system definition.
- -s [ target-identifier[{{,target-identifier }} ...]][-L[-H]]
- Specify this option to start only transmission processing or update-SQL output processing at startup without starting extraction processing. If transmission processing was not started during the preceding execution of hdestart, you use this option to start transmission processing also.
- target-identifier
- Specify a target identifier specified in the extraction system definition in order to start only transmission processing or update-SQL output processing for the specified target. If you specify multiple target identifiers, do not specify any spaces before or after a delimiter comma. Specifying ** as a target identifier will result in an invalid-argument error.
- If you do not specify any target identifiers, Datareplicator starts transmission processing or update-SQL output processing for all target identifiers.
- -L
- Start update-SQL output processing at startup.
- -H
- This option is applicable only when the -L option is specified.
- Specify this option to output the values of CHAR, VARCHAR, MCHAR, MVARCHAR, NCHAR, and NVARCHAR columns in hexadecimal during update-SQL output processing. For details about the format and contents of the column values that will be output, see 9.8(2) Update-SQL file.
- Specify this option if the column values output to the update-SQL file cannot be read as character data. Column values cannot be read as character data if they contain characters that cannot be displayed, such as control codes (0x00 through 0x1F) and hexadecimal numbers.
- -R
- Specify this option to recover the extraction definition.
- -k queue
- Recovers the extraction information queue file by using the facility for recovering the extraction information queue file. For details about the facility for recovering the extraction information queue file, see 9.7 Facility for recovering the extraction information queue file.
- -b HiRDB-server-name ~ <symbolic name of 8 characters>
- Specifies the HiRDB server name of the extraction environment that is to be recovered.
- If the source HiRDB is a single server, specify the server name of the single server (server name that is specified in the HiRDB's pdstart -s command).
- If the source HiRDB is a parallel server, specify the name of the back-end server that is to be recovered. This must be the server name specified in the extraction environment definition for the back-end server. If a wrong server name is specified, the command outputs the KFRB00711-E message, and then terminates with an error.
- Specify only one server name. If there are multiple servers subject to recover, execute the command for each server subject to recovery.
- -v
- Specify this option to perform data linkage recovery via the system log file.
- For details about data linkage recovery via the system log file, see 9.5 Data linkage recovery via the system log file.
- Rules
- Legend:
- N/A: Cannot be stored in the Datareplicator file system area.
- #1
- UNIX Datareplicator supports character special files and Datareplicator file system areas.
- Windows Datareplicator executes the processing described in the OS regular file column.
- #2
- Use an OS command to re-create the file.
- If the hdestart command is executed with the -i option omitted, the source Datareplicator's processes start according to the specified options. For the relationship between the options and the processes that are started, see Table 7-7 hdestart commands to be executed. If the source Datareplicator is already running and the hdestart command is executed with the -i option omitted, only the inactive processes are started among all processes corresponding to the specified options.
- Depending on the status of the source Datareplicator, you might not be able to execute the hdestart command. The following table shows the relationship between the source Datareplicator's status and when the hdestart command can be executed
Table 7-5 Relationship between the source Datareplicator's status and when the hdestart command can be executed
| Source Datareplicator's status |
Specified option |
| None |
-i |
-e |
-s |
-s -L |
-R |
-v |
| Starting |
-- |
-- |
-- |
-- |
-- |
-- |
-- |
| Active# |
Y |
-- |
Y |
Y |
-- |
-- |
-- |
| During update-SQL output |
-- |
-- |
-- |
-- |
Y |
-- |
-- |
| Stopping |
-- |
-- |
-- |
-- |
-- |
-- |
-- |
| Inactive |
Y |
Y |
Y |
Y |
Y |
Y |
Y |
- Y: Can be executed.
- --: Cannot be executed (results in an error).
- #
- If hdestart other than hdestart -I is executed while extraction or transmission processing is stopped, the extraction and transmission processing are restarted from the point where they had stopped.
- You can combine multiple options when you execute the hdestart command. The following table shows the combinations of hdestart command options.
Table 7-6 Combinations of hdestart command options
| Command option |
-i |
-e |
-s |
-s -L |
-r |
-R |
-k |
-v |
| -i |
-- |
-- |
-- |
-- |
-- |
-- |
-- |
-- |
| -e |
-- |
-- |
Y |
-- |
Y |
-- |
-- |
Y |
| -s |
-- |
Y |
-- |
-- |
Y |
-- |
-- |
-- |
| -s -L |
-- |
-- |
-- |
-- |
Y |
-- |
-- |
-- |
| -r |
-- |
Y |
Y |
Y |
-- |
-- |
-- |
Y |
| -R |
-- |
-- |
-- |
-- |
-- |
-- |
Y |
-- |
| -k |
-- |
-- |
-- |
-- |
-- |
Y |
-- |
-- |
| -v |
-- |
Y |
-- |
-- |
Y |
-- |
-- |
-- |
- Y: Executable combination.
- --: Not an executable combination (results in an error).
- If some source processes stop due to an error, execute the same command as during startup. This will restart only those source processes that are stopped due to the error, without affecting the processes that are running normally.
- Figure 7-1 hdestart command action when the source HiRDB is a parallel server shows the hdestart command action when the source HiRDB is a parallel server, and Table 7-7 hdestart commands to be executed lists the hdestart commands to be executed. The numbers in Figure 7-1 hdestart command action when the source HiRDB is a parallel server correspond to the numbers in Table 7-7 hdestart commands to be executed.
Figure 7-1 hdestart command action when the source HiRDB is a parallel server
![[Figure]](FIGURE/RZ07S010.GIF)
Table 7-7 hdestart commands to be executed
| Command to be executed |
Action |
| hdestart -i |
Initialize the source Datareplicator environment |
| hdestart |
Start all processes (1 to 9) |
| hdestart -e |
Start the extraction master process (1), the extraction node master processes (2 and 6), and the extraction processes (3 and 7). |
| hdestart -s |
Start the extraction master process (1), the extraction node master processes (2 and 6), and all transmission processes# (4, 5, 8, and 9) |
| hdestart -s SND1 |
Start the extraction master process (1), the extraction node master processes (2 and 6), and the transmission processes# whose target identifier is SND1 (4 and 8) |
| hdestart -e -s SND1 |
Start the extraction master process (1), the extraction node master processes (2 and 6), the extraction processes (3 and 7), and the transmission processes# whose target identifier is SND1 (4 and 8) |
- #
- If sendmst is specified in the sendcontrol operand, the transmission master process and the transmission processes are started.
- Notes
- If you specify neither the -e nor the -s option, the source Datareplicator executes extraction processing, and then immediately executes transmission processing.
- Before you can use the hdestart command, you must specify the /etc/inetd.conf communications environment variables. For details about the communications environment setup procedure, see 2.4 Specifying environment variables (UNIX) or 2.8 Specifying environment variables (Windows).
- You must execute the hdeprep command before you can execute the hdestart command in the following cases:
- Data linkage is to be started for the first time.
- The hdestart -i command has been executed.
- A source table definition or the extraction definition is to be modified.
- The user executing the hdestart command must belong to the same user group as the source HiRDB executor.
- Specify the hdestart -i command while the source HiRDB is not executing HiRDB Datareplicator linkage. Use the pdls command to determine whether the source HiRDB is executing HiRDB Datareplicator linkage. If HiRDB Datareplicator linkage is executing, use the pdrplstop command to cancel it.
- If an error occurs during partial initial start, you cannot execute normal startup, extraction definition preprocessing, or another partial initial start with a different target identifier number while the error remains uncorrected. To correct a partial initial start error, eliminate the cause of the error, re-execute partial initial start with the same target identifier number specified, and then terminate Datareplicator normally; or, execute initial start on the entire extraction environment.
- When you execute the hdestart command with the -i option specified (except in the case of partial initial start), you must enter a reply to confirm that you want processing to start.
- You can specify partial initial start only for target identifier numbers that have been defined at the time of the most recent initial start. You cannot specify a new target identifier number that has been added since then. If the number of targets is expected to increase, specify ** for future target identifiers.
The following is a specification example of partial initial start:
![[Figure]](FIGURE/RZ07S020.GIF)
- Executes partial initial start for target identifier number 01 (target identifier SND001).
- Executes partial initial start for target identifier number 02 (target identifier NEW002) after modifying the definition.
- Executes partial initial start for target identifier number 03 (target identifier **), which became an absent number after the definition was modified.
- Executes partial initial start for target identifier number 04 (target identifier NEW004), which has been newly defined.
- Results in a command error because target identifier number 05 (target identifier NEW005), which was added by modifying the definition, had not been defined at the time of the initial start.
- Results in a command error because target identifier number 004 (target identifier NEW004) was modified, which is not the specified target identifier number (target identifier NEW002).
To execute partial initial start for more than one target identifier, modify the definition for one target identifier at a time, and then execute partial initial start. After all partial initializations have been completed, execute normal start. The following is an example of the execution procedure:
![[Figure]](FIGURE/RZ07S02A.GIF)
- The following is the execution procedure for partial initial start:
- Check that the source Datareplicator is stopped.
- Use a text editor to modify the definitions.
- Specify the target identifier number subject to initialization in the hdestart -i -S command in order to execute partial initial start.
- Execute the hdeprep command.
- Execute normal start on the source Datareplicator.
- If you use a system switchover configuration, you must activate the resources that are used by HiRDB Datareplicator (shared disk unit and network) prior to initialization or startup.
All rights reserved. Copyright (C) 2007, 2013, Hitachi, Ltd.