backing up /sys
Bob McClure Jr
robertmcclure at earthlink.net
Wed Jun 29 19:41:02 UTC 2005
On Wed, Jun 29, 2005 at 11:36:10AM -0700, Rick Stevens wrote:
> Bob McClure Jr wrote:
> >On Tue, Jun 28, 2005 at 03:12:02PM -0700, Rick Stevens wrote:
> >
> >>Bob McClure Jr wrote:
> >>
> > <snippage>
> >I discovered that when I run
> >
> > mt <any_command>
> >
> >it returns immediately, but the tape goes on to do the function,
> >presumably satisfactorily. So my backup script says, in part,
> >
> >/bin/mt rewind
> >/bin/mt erase
> >/bin/mt rewind
> >/bin/mt reten
> >echo "backup started at `date`" > $tempfile
> >if find $dirlist -mount -depth | cpio $cpio_opts > $TAPE 2>>$tempfile
> >then
> > .
> > .
> > .
> >
> >So it blows through the mt commands and rolls right in to the cpio
> >operation, and I presume the tape starts recording mid-stream. I
> >pulled the contents of the tape to a file, and ran "file <filename>"
> >and it said "data". The tape is a Travan-4 in an IDE tape drive using
> >the ide-scsi module. The device is /dev/nst0.
>
> Uh, hmmmm. Have you tried /dev/st0 instead? Sometimes the "n" does
> do an immediate return. The ide-scsi may also be an issue. I tend to
> use real SCSI drives. You can get DAT drives pretty cheap now. DLTs
> are available on E-Bay pretty cheap, too (the tapes aren't cheap, but
> they're reasonable).
Nah. I have a CD/DVD burner, now, so I'm going to a combination of
CDs or DVDs for full backup and incrementals to a disk on a different
machine.
> >I'm going to run a test tonight, having done the mt steps manually,
> >and have it go straight to the cpio, and see if I get a recognizable
> >tape.
Well, the answer is, I didn't. I checked it using
cat $TAPE | cpio -it
and all it did was "shoeshine" the tape with no output.
Interestingly, /var/log/messages says,
Jun 29 14:21:59 bobcat kernel: st0: Error with sense data: <6>st0: Current: sense key: Illegal Request
Jun 29 14:21:59 bobcat kernel: Additional sense: Invalid command operation code
Jun 29 14:22:54 bobcat kernel: st0: Error with sense data: <6>st0: Current: sense key: Illegal Request
Jun 29 14:22:54 bobcat kernel: Additional sense: Invalid command operation code
Doesn't that look like a kernel (module) bug?
I'd blame the tape drive, but I have another one like it in another
machine and it does the same thing.
> Also try the /dev/st0 device and see if it behaves differently.
> ----------------------------------------------------------------------
> - Rick Stevens, Senior Systems Engineer rstevens at vitalstream.com -
> - VitalStream, Inc. http://www.vitalstream.com -
> - -
> - Linux is like a wigwam...no windows, no gates...and apache inside! -
> ----------------------------------------------------------------------
Cheers,
--
Bob McClure, Jr. Bobcat Open Systems, Inc.
robertmcclure at earthlink.net http://www.bobcatos.com
God doesn't have (or need) a Plan B.
More information about the Redhat-install-list
mailing list