By specifically choosing the rmt file, it is possible to create multiple file tapes. Although tapes are accessed through character interface special files, the number of bytes required by either a read or write operation must be a multiple of the block size defined for the magnetic tape device. When the tape drive is in variable block mode, read requests for less than the tape's block size return the number of bytes requested and set the errno global variable to a value of 0. During a read, the record size is returned as the number of bytes read, up to the buffer size specified. When a read is attempted after the device has reached the EOM, a zero-length read is returned.
Successive reads continue to return a zero-length read.
A write operation sent to tape is returned as complete when the data is transferred to the data buffer of the tape device. The data in the buffer is then written to tape asynchronously. Two modes are provided by the tape device driver to facilitate use of these data buffers. The non-buffered mode causes writes to tape to bypass the data buffer and go directly to tape. In buffered mode, all write subroutines are returned as complete when the transfer data has been successfully written to the tape device buffer.