Disabling held optical file support

 

i5/OS® is shipped with held optical file support enabled. If desired, you may disable it by using the Change Optical Attributes (CHGOPTA) command.

When held optical file support is disabled, a held file is not created when a file fails to be archived to optical disk. When using this option, it is up to the user application to manage recovery procedures for files that fail to be archived. Consider the following scenarios:

 

Scenario 1

The application opens an optical file for a write operation, and then writes data to the file. When you attempt to close the file, it fails because the optical disk is full.

Held file support enabled

The file is still open, but becomes held. The file closes when the job ends if it never closes successfully before the job ends. The file will remain held until it is released.

Held file support disabled

The file is still open, but is not held. The file closes when the job ends if it never closed successfully before the job ends. The file will not become held, and all resources (virtual optical file) associated with the held file will then be freed up.

 

Scenario 2

The application opens an optical file for write, and then writes data to the file. The application then issues a Force Buffered Data API to ensure the data is safe on nonvolatile storage. The system then loses power.

Held File Support Enabled

After the internal program load (IPL) of the system is completed the file exists as a held optical file. All data that was successfully forced to disk is recoverable. In other words, when you save the held file to optical storage, all data written before the Force buffered data request will be saved.

Held File Support Disabled

After the IPL of the system is completed, the file does not exist as a held optical file. All data written to this file on the previous open instance is lost. The force data request had no effect.

It is important to note that when held optical file support is disabled, forcing data to nonvolatile storage is meaningless. This is because data is written to optical storage after the file closes successfully. The Force buffered data function will force the data to the i5/OS disk, and you can use the held optical file to recover the data after a power loss. Held files are the only mechanism to recover data forced to nonvolatile storage after a power loss or other unexpected error. Held file support is needed to recover any data from an open instance that closes unsuccessfully. This affects the following application program interfaces.

Use the Change Optical Attributes (CHGOPTA) command to enable, disable, or determine the current status of held optical file support. After held optical file support is disabled, it remains disabled for all optical users. You must enable held file support for it to become active again.

 

Parent topic:

Held optical files