2.18 pdclose (Close RDAREAs)

Organization of this section
(1) Function
(2) Executor
(3) Format
(4) Options
(5) Rules
(6) Notes

(1) Function

The pdclose command closes specified RDAREAs. RDAREAs that have been shut down by the pdhold command and RDAREAs in error shutdown status can be specified.

(2) Executor

HiRDB administrator

(3) Format

.pdclose -r {RDAREA-name[,RDAREA-name]...|ALL} [-q generation-number][-W execution-monitoring-interval]

(4) Options

(a) -r {RDAREA-name[,RDAREA-name]...|ALL}
-r RDAREA-name ~<identifier> ((1-30))
Specifies the name of an RDAREA to be closed.
ALL
Specifies that all RDAREAs except the master directory RDAREA are to be closed. If the -q option is specified, the command processes the same generation of RDAREAs.
Rules
  1. For the rules for specifying RDAREAs, see 1.5.2 Specification of RDAREAs in operation commands and utilities
  2. You cannot close an RDAREA that is in reference-possible backup hold (update WAIT mode) or updatable backup-hold status, nor can you close a master directory RDAREA.
  3. If you specify a user RDAREA or user LOB RDAREA, make sure that the corresponding data dictionary RDAREA is in one of the following statuses:
    • Open and shutdown release status
    • Open and shutdown status placed by the pdhold command
  4. When you specify both data dictionary and user RDAREAs or both data dictionary and user LOB RDAREAs, be sure to specify the data dictionary RDAREAs last.
  5. If you are using the inner replica facility, you can also specify original and replica RDAREA names. In this case, you can specify only user RDAREAs and user LOB RDAREAs.
(b) -q generation-number ~<unsigned integer> ((0-10))

Specifies the generation number of a replica RDAREA.

If you specify this option, make sure that the original RDAREA name is specified in the -r option. An error results if you specify an original RDAREA whose replicas have all been deleted or if you specify a normal RDAREA (one without a replica RDAREA).

(c) -W execution-monitoring-interval ~<unsigned integer> ((0 to 3600))

Specifies (in minutes) the monitoring interval when the execution time of the pdclose command is to be monitored. For guidelines on the value to specify and details about the resulting operation, see the description of the pd_cmd_exec_time operand in the system common definition in the manual HiRDB Version 9 System Definition.

When 0 is specified in this option, the command's execution time is not monitored.

When this option is omitted, the value of the pd_cmd_exec_time operand in the system common definition takes effect.

(5) Rules

  1. The pdclose command can be executed only while HiRDB is active.
  2. The pdclose command must be executed at the server machine containing the single server or the server machine where the system manager is located.
  3. The pdclose command locks the specified RDAREAs in the EX mode. If another transaction is accessing a specified RDAREA, the pdclose command will go onto wait status until the transaction terminates.
  4. If the pdclose command is executed on a shared RDAREA, all back-end servers are locked. If there can be multiple concurrent accesses to the corresponding RDAREA, global deadlock may occur, resulting in a timeout. If global deadlock has occurred, re-execute the pdclose command.
  5. If the pdclose command is executed in database asynchronous status or RDAREA error status, the command writes data from the in-memory data buffer to disk and synchronizes the in-memory data buffer and the RDAREA (resulting in database synchronous status).
  6. If hybrid is selected as the processing method for Real Time SAN Replication, executing the pdclose command results in a database synchronization wait for the remote site. This may result in an overhead of 2 seconds or more for each RDAREA specified in the -r option. If the database synchronization wait for the remote site fails, you must recover the remote site's database. For details about troubleshooting when Real Time SAN Replication is used, see the HiRDB Version 9 Disaster Recovery System Configuration and Operation Guide.

(6) Notes

  1. The result of the pdclose command can be checked by the pddbls command.
  2. The following shows the pdclose command's return codes:
    0: Normal termination
    4: Warning termination (some RDAREA processing terminated with an error)
    8: Abnormal termination
    12: Abnormal termination (an event occurred that prevented output of an error message)
    If the error code is 12, check the error message in syslogfile at the host where the single server or dictionary server is located, eliminate the cause of the error, and then re-execute the command. If no error message has been output to syslogfile, contact the customer engineer.