Bacula-users

Re: [Bacula-users] Exchange plugin always truncating logs (when it should not)

2012-05-05 05:00:17
Subject: Re: [Bacula-users] Exchange plugin always truncating logs (when it should not)
From: Guido Falsi <mad AT madpilot DOT net>
To: James Harper <james.harper AT bendigoit.com DOT au>
Date: Sat, 05 May 2012 10:57:36 +0200
On 05/05/12 06:48, James Harper wrote:
>>
>> I've been using bacula to backup an exchange 2003 server for some time with
>> success. You could say I'm an happy user :)
>>
>> Lately I noticed bacula started truncating logs on EVERY backup, also
>> incrementals and differentials, when it should not.
>>
>> I'm not sure when this happened. I'm inclined to thing it started when
>> I upgraded to 5.2.6 But I don't have logs handy till them. I can try to
>> reover them from some backup perhaps.
>>
>> The machine is a Windows 2003 R2 server, 32 bit. I used the installer
>> from the project page on sourceforge to install bacula.
>>
>> If needed I can try installing a previous version on this client and see
>> if this makes the problem disappear. Is such a scenario(older client)
>> supported?
>>
>
> That's really strange. The code to do this is pretty straightforward... at 
> job init it does this:
>
>        switch (context->job_level) {
>        case 'F':
>           if (context->notrunconfull_option) {
>              context->truncate_logs = false;
>           } else {
>              context->truncate_logs = true;
>           }
>           break;
>        case 'D':
>           context->truncate_logs = false;
>           break;
>        case 'I':
>           context->truncate_logs = false;
>           break;
>        default:
>           _DebugMessage(100, "Invalid job level %c\n", context->job_level);
>           return bRC_Error;
>        }
>        break;
>
> Then later it does this:
>
>        if (context->truncate_logs) {
>           _DebugMessage(100, "Calling HrESEBackupTruncateLogs\n");
>           result = HrESEBackupTruncateLogs(hccx);
>           if (result != 0) {
>              _JobMessage(M_FATAL, "HrESEBackupTruncateLogs failed with error 
> 0x%08x - %s\n", result, ESEErrorMessage(result));
>           } else {
>              _JobMessage(M_INFO, "Truncated database logs for Storage Group 
> %s\n", name);
>           }
>        } else {
>           _JobMessage(M_INFO, "Did NOT truncate database logs for Storage 
> Group %s\n", name);
>        }
>
> And nothing else touches truncate_logs in between that I can see.
>
> Could you please try doing:
>
> set debug level=200 trace=1
>
> for your fd, run a backup, and then email me the resulting trace file (in the 
> fd working directory I think). I'm wondering if something has changed and the 
> callback ordering is different or something.
>

Thank you for the fast feedback. I'll try this Monday morning and report 
back.

Thank you again!

-- 
Guido Falsi <mad AT madpilot DOT net>

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

<Prev in Thread] Current Thread [Next in Thread>