The Ftape Installation and Usage Guide - Ioctls
MTIOCPOS
, query the tape positionNote that ftape-2.x and sftape didn't implement this ioctl. ftape-3.04d and later versions up to ftape-4.02 return the block number relative to the current tape volume, i.e. the distance to the next file mark towards BOT.
This was incompatible with the way SCSI drives implement this command where the block address is relative to the beginning of the tape and has been fixed in ftape-4.03.
This command is sent to the drive by the mt
command with
mt -f /dev/nqft0 tell
The following is from the standard Linux include file [/usr/src/linux/]/include/linux/mtio.h.
/* structure for MTIOCPOS - mag tape get position command */ struct mtpos { long mt_blkno; /* current block number */ }; #define MTIOCPOS _IOR('m', 3, struct mtpos) /* get tape position */
![]() |
Use these buttons to jump to the top menu |