How optical files are used
An application can manipulate optical file data by using UNIX-type APIs or the hierarchical file system (HFS).
An application opens a file, operates on the file, and finally closes the file. When an application changes file data or attributes, the optical file system stores these changes in a temporary system object in i5/OS® storage. The optical file system does not update the optical disk until the application closes the file. When two or more applications concurrently change file data or attributes, the optical file system updates the optical disk when the last updating application closes the file. The application may force file and attribute data to optical disk by issuing either the HFS Force Buffered Data API or UNIX-Type fsync() functions.
Implementing this process has the following benefits:
- Simulation of read and write access to optical files
- File locking and sharing
- Byte locking and sharing
- Random processing of optical file data
- Writing variable-length data buffers to the optical file
- Reduction of input and output to the optical disk
- Held optical files
If the optical file system is unable to update the optical disk during a close function, the operation fails and the file is marked as held.
Parent topic:
Recovering held optical filesRelated information
Application programming interfaces (APIs)