Date: Tue, 5 Nov 2002 14:24:23 +0200 From: Ruslan Ermilov <ru@FreeBSD.org> To: scsi@FreeBSD.org Subject: ``mt erase 0'' on a non-rewinded tape Message-ID: <20021105122423.GA79188@sunbay.com>
next in thread | raw e-mail | index | archive | help
--yrj/dFKFPuw6o+aM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi there! I have a script that does automated file system backups using mt(1) and dump(8). My tape drive is: sa0: <TANDBERG SLR100 0402> Removable Sequential Access SCSI-2 device) When doing a level 0 backup, the script does a quick erase of the tape, then does the retension, then does the backup. When doing an incremental backup, it seeks to the end of recorded medium, then does the backup. The script works with the no-rewind device, /dev/nsa0. The script always used to fail with EINVAL attempting to run a quick erase, ``mt erase 0''. After a bit of experimenting, it turned out that `erase' only works if I rewind the tape (either through by using the rewind device, or by running the `rewind' or `retension' commands in advance). Here is my question. Is this always the case that MTERASE only works with a rewinded tape, or is this device-dependent? If the former, what would be an appropriate way to document it? (I am reluctant to find myself where this EINVAL is coming from, and there is a plenty of them under sys/cam/.) Cheers, --=20 Ruslan Ermilov Sysadmin and DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age --yrj/dFKFPuw6o+aM Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQE9x7h3Ukv4P6juNwoRAhHqAJ94w8Bz9GgJAfksGOsCagcYfwZYzwCdFHKf KYRdEhPLPYL90pI2DI5l4VA= =l1kQ -----END PGP SIGNATURE----- --yrj/dFKFPuw6o+aM-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-scsi" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021105122423.GA79188>