I was able to figure out the query that was getting stuck. It was a simple outer join ======================= SELECT DISTINCT Path.PathId, File.PathId FROM Path LEFT OUTER JOIN FILE ON ( Path.PathId = File.PathId )
======================= I created an index on the File.PathId column and viola, the Orphaned Path query finished within a couple of seconds. Its looking more and more like mysql database might be casuing the problems. I am giong to keep bacula and mysql at the current levels and observe mysql queries the next time bacula director freezes. Will update the list if i find anything useful. Thx for the help Arno. --- Arno Lehmann <[EMAIL PROTECTED]> wrote: > Hello, > > Ali Zaidi wrote: > > > Thx Arno. I am going to upgrade Bacula but i have > > noticed another thing. > > In trying to figure this out, i ran the dbcheck > > utility > > to see if the database was reporting any problems. > > When i tried looking for Orphaned Path entries > using > > the > > dbcheck tool, mysql went bonkers. I thought this > was > > just an expensive query but after running for 1 > hour > > it was not coming back. > > It's a while ago that I used dbcheck, but I usually > started it, left the > console, went drinking coffee or visiting a > customer, and when I was > back it was done :-) > > So, I guess it might take a while to complete... > > > I ran the mysql commands to optimize the various > > tables in the bacula database, but still this > > particular query > > never returns. > > Even after i kill the dbcheck tool, mysql keeps > > chewing up the CPU. > > Well, I couldimagine that MySQL keeps processing the > request and notices > the absence of the client only when it actually goes > to send the results... > > > The only thing that works at that point is > restarting > > mysql. > > The database size is not that big, the backup file > for > > the database is about 134 Mb and the mysql > directory > > for > > the bacula database is about 500 MB. > > I am going to investigate this further and may be > > upgrade mysql aswell. > > However it would be nice to know for debugging > > purposes > > what query is getting executed against the mysql > > database. May i can trace that query and figure > out > > why its getting stuck. > > Try 'mysqladmin processlist' from the console... > > Arno > > > thx for the help > > > > > > --- Arno Lehmann <[EMAIL PROTECTED]> wrote: > > > >>Hi. > >> > >>Ali Zaidi wrote: > >> > >> > >>>I have been using bacula for the past 3 or 4 > >> > >>months > >> > >>>without any problems. > >>>However for the last two Friday nights the bacula > >>>director has been freezing after backing up the > >> > >>first > >> > >>>seven clients. > >>>The system and bacula log files do not report > >>>anything. > >>>When the director freezes, i can no longer get > the > >>>bconsole to connect to the director. > >> > >>I did experience the same, couldn't find any > reason, > >>but after the > >>upgrade to 1.36.2 that didn't happen again. So, I > >>suggest you do an > >>upgrade to that version or the current release > >>version 1.36.3. > >> > >>Upgrading should not be a problem - ./ configure > >>with the same options > >>as before, make, and make make install (or simply > >>copy the binaries). > >> > >> > >>>Another peculiar thing i saw was that the number > >> > >>of > >> > >>>bacula-dir processes on the system increases from > >> > >>4 to > >> > >>>around 21. > >> > >>That's normal - that's all the "worker threads" > for > >>the different jobs > >>and bookkeeping. I don't know how many I had, but > >>when the director > >>crashed I usually had four jobs running and saw > >>about 10-20 jobs / threads. > >> > >> > >>>From the schedule, bacula is doing the exact same > >> > >>kind > >> > >>>of backups monday to saturday. > >>>I am clueless as to where to look and what might > >> > >>be > >> > >>>wrong. Any hints would be appreciated. > >>> > >>>I am on bacula version 1.36.2. > >> > >>Try upgrading - there are no configuration changes > >>or database schema > >>modifications necessary, and I at least never saw > >>such problems again. > >> > >>Arno > >> > >> > >> > >>>thx > >>> > >>> > >>> > >>>__________________________________ > >>>Do you Yahoo!? > >>>Read only the mail you want - Yahoo! Mail > >> > >>SpamGuard. > >> > >>>http://promotions.yahoo.com/new_mail > >>> > >>> > >>> > >> > > > ------------------------------------------------------- > > > >>>This SF.Net email is sponsored by Oracle Space > >> > >>Sweepstakes > >> > >>>Want to be the first software developer in space? > >>>Enter now for the Oracle Space Sweepstakes! > >>> > >> > > > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > > > >>>_______________________________________________ > >>>Bacula-users mailing list > >>>Bacula-users@lists.sourceforge.net > >>> > >> > > > https://lists.sourceforge.net/lists/listinfo/bacula-users > > > >>-- > >>IT-Service Lehmann > >>[EMAIL PROTECTED] > >>Arno Lehmann > >>http://www.its-lehmann.de > >> > > > > > > > > > > > > __________________________________ > > Do you Yahoo!? > > Yahoo! Mail - You care about security. So do we. > > http://promotions.yahoo.com/new_mail > > > > > > > ------------------------------------------------------- > > This SF.Net email is sponsored by Oracle Space > Sweepstakes > > Want to be the first software developer in space? > === message truncated === __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users