Article View: comp.sys.next.sysadmin
Article #2138Re: Dump/restore problem with DAT-drive (Major hint!!!)
From: Max Hailperin
Date: Wed, 16 Dec 1992 10:49
Date: Wed, 16 Dec 1992 10:49
45 lines
1872 bytes
1872 bytes
In article <MAX.92Dec16102112@Kolmogorov.gac.edu>
max@Kolmogorov.gac.edu (Max Hailperin) (yes that's me) writes:
[A bunch of stuff about tape read errors that would have been
correct, except that I'm brain dead and got "allow" and "inhibit"
backwards.]
The correct mode of operation for restoring from a DAT drive is
*inhibit* illegal length, *not* allow. This is what Sears's
workaround does by using the exabyte device. The correct solution,
then, is *not* the mtalill program I posted, but rather the converse,
which I naturally call mtinill. This is what I actually run in my
/etc/rc.local. Please excuse my earlier error.
#include <stdio.h>
#include <sys/ioctl.h>
#include <sys/types.h>
#include <nextdev/scsireg.h>
#include <sys/file.h>
main(int argc, char *argv[]){
int fd;
if(argc != 2){
fprintf(stderr, "Usage: %s device\n", argv[0]);
exit(1);
}
if((fd = open(argv[1], O_RDONLY, 0)) < 0){
perror(argv[1]);
exit(1);
}
if(ioctl(fd, MTIOCINILL, NULL) < 0){
perror("doing MTIOCINILL ioctl");
exit(1);
}
if(close(fd) < 0){
perror("closing");
exit(1);
}
exit(0);
}
Technical Details
Message-ID:
<MAX.92Dec16104919@Kolmogorov.gac.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!sdd.hp.com!spool.mu.edu!umn.edu!noc.msc.net!gacvx2.gac.edu!nntp-server!maxReferences:
<1992Dec9.101922.618@nexcom.hanse.de> <1gkvvfINN66@menudo.uh.edu><MAX.92Dec16102112@Kolmogorov.gac.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!sdd.hp.com!spool.mu.edu!umn.edu!noc.msc.net!gacvx2.gac.edu!nntp-server!max Newsgroups: comp.sys.next.sysadmin Subject: Re: Dump/restore problem with DAT-drive (Major hint!!!) Message-ID: <MAX.92Dec16104919@Kolmogorov.gac.edu> From: max@Kolmogorov.gac.edu (Max Hailperin) Date: 16 Dec 92 10:49:19 Reply-To: Max Hailperin <max@nic.gac.edu> References: <1992Dec9.101922.618@nexcom.hanse.de> <1gkvvfINN66@menudo.uh.edu><MAX.92Dec16102112@Kolmogorov.gac.edu> Organization: Gustavus Adolphus College, St. Peter, MN Nntp-Posting-Host: kolmogorov.gac.edu In-reply-to: max@Kolmogorov.gac.edu's message of 16 Dec 92 10:21:12Lines: 45 Lines: 45