To be a fully automated solution without a tape management system, each volume that is needed must be specified on the command in the VOL parameter.
If the system runs out of tape cartridges specified in the volume list, a CPA6798 inquiry message is issued allowing the user to supply an additional cartridge allowing the tape operation to continue. If the cartridge supplied is not found or not available, a CPA6797 inquiry message is sent allowing the user to supply an alternate cartridge to continue the tape operation. Tape management systems have the ability to provide more volumes through exit points in the i5/OS™ tape functions.
See Avoid deadlocked files during save and restore operations with tape libraries for other end-of-volume concerns.