From 870681013ad32bbf68a0a74b212990de8bf8ac9c Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Wed, 24 Mar 2021 10:09:23 +0100 Subject: [PATCH] tape: fix catalog restore We need to rewind the tape if fast_catalog_restore() fail ... --- src/api2/tape/drive.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/api2/tape/drive.rs b/src/api2/tape/drive.rs index 358881da..a5dae732 100644 --- a/src/api2/tape/drive.rs +++ b/src/api2/tape/drive.rs @@ -1326,6 +1326,9 @@ pub fn catalog_media( task_log!(worker, "no catalog found - scaning entire media now"); + drive.rewind()?; + drive.read_label()?; // skip over labels - we already read them above + restore_media(&worker, &mut drive, &media_id, None, verbose)?; Ok(())