Amanda-Users

Re: Why no incrementals in degraded mode?

2006-01-20 09:03:43
Subject: Re: Why no incrementals in degraded mode?
From: Jean-Louis Martineau <martineau AT zmanda DOT com>
To: Josef Wolf <jw AT raven.inka DOT de>
Date: Fri, 20 Jan 2006 08:51:34 -0500
Josef,

What was your version?

If you upgraded from 2.4.4p2 or earlier to a 2.4.5 then could you try the untested attached patch.

As your log show, the start_degraded_mode is done before the schedule is read, it should be done after.

Jean-Louis


Josef Wolf wrote:

Hello!

Since I have re-installed amanda, I get no more incrementals when it runs
into degraded mode.  From the logfiles I can't find any hint why it always
does full-backups.  All DLEs are affected by this problem.  But in the
description below, I list only one DLE.

Index: server-src/driver.c
===================================================================
RCS file: /cvsroot/amanda/amanda/server-src/driver.c,v
retrieving revision 1.58.2.31.2.8.2.20.2.16
diff -u -r1.58.2.31.2.8.2.20.2.16 driver.c
--- server-src/driver.c 20 Sep 2005 21:31:52 -0000      1.58.2.31.2.8.2.20.2.16
+++ server-src/driver.c 20 Jan 2006 13:41:55 -0000
@@ -146,6 +146,7 @@
     amwait_t retstat;
     char *conf_tapetype;
     tapetype_t *tape;
+    int need_degraded;
 
     safe_fd(-1, 0);
 
@@ -326,9 +327,12 @@
 
     if(cmd != TAPER_OK) {
        /* no tape, go into degraded mode: dump to holding disk */
-       start_degraded_mode(&runq);
+       need_degraded=1;
        FD_CLR(taper,&readset);
     }
+    else {
+       need_degraded=0;
+    }
 
     short_dump_state();                                        /* for amstatus 
*/
 
@@ -361,6 +365,7 @@
 
        /* Read the dump schedule */
        read_schedule(&waitq, &runq);
+       if(need_degraded==1) start_degraded_mode(&runq);
     }
 
     /* Start any needed flushes */
<Prev in Thread] Current Thread [Next in Thread>