Amanda-Users

Re: Exabyte VXA-2-Packet-Loader: new problem

2005-02-15 14:05:03
Subject: Re: Exabyte VXA-2-Packet-Loader: new problem
From: Eric Siegerman <erics AT telepres DOT com>
To: amanda <amanda-users AT amanda DOT org>
Date: Tue, 15 Feb 2005 13:56:13 -0500
On Tue, Feb 15, 2005 at 01:40:44PM -0500, Jon LaBadie wrote:
> If I issue another command to the drive before it is really
> ready, even an "mt status", I get error messages.  Thus I routinely
> put in delays (sleep's) in scripts that might rewind a tape or change
> a tape to another slot.  As much as 20 or 30 second delays IIRC.

Rather than a hard-coded delay (which is suboptimal if it's too
long and breaks things if it's too short), why not write a little
"mtsync" script that polls the drive for readiness, by doing "mt
status" commands in a loop until one succeeds?

--

|  | /\
|-_|/  >   Eric Siegerman, Toronto, Ont.        erics AT telepres DOT com
|  |  /
The animal that coils in a circle is the serpent; that's why so
many cults and myths of the serpent exist, because it's hard to
represent the return of the sun by the coiling of a hippopotamus.
        - Umberto Eco, "Foucault's Pendulum"