Bacula-users

Re: [Bacula-users] very slow virtualfull job

2013-04-26 06:06:54
Subject: Re: [Bacula-users] very slow virtualfull job
From: Adrian Reyer <bacula-lists AT lihas DOT de>
To: James Harper <james.harper AT bendigoit.com DOT au>
Date: Fri, 26 Apr 2013 12:03:11 +0200
On Thu, Apr 25, 2013 at 11:41:37PM +0000, James Harper wrote:
> What could have gone wrong with my mysql to make this happen? I've tried 
> rebooting it.

You very likely use MySQL with MyISAM tables. This is a very bad
combination for bacula. It will be better with InnoDB tables and
correctly tuned MySQL for these many inserts. However, postgres can be
tuned the same way and has the additional benefit of being able to use
parts of indices. As every insert has to update the tables and the
indices, you have way less writes with postgres.
I went the way MySQL 4GB MyISAM -> 12GB MYISAM -> 12GB InnoDB ->
Postgres 12GB myself.

> How difficult is it to convert an existing installation over to postgresql? 
> I've been meaning to do this for a while and it may be faster than trying to 
> resolve the issue...

It is not that hard, if I remember right the easiest way is spomething
like that:
1. create a new postgres-bacula-db
2. dump the table contents from mysql
3. modify the dump to suit postgres
4. insert the dump into postgres

2.-4. I did in one line issuing something like
  mysqldump ... | sed ... | psql
The main things to do with 'sed' for me had been to replace the
different 0 timestamps. You get 0000-00-00 00:00:00 with mysql and
postgres expects 1970-01-01 00:00 instead if I remember correctly.
I think I used
http://mtu.net/~jpschewe/blog/2010/06/migrating-bacula-from-mysql-to-postgresql/
back then as a hint, but it needed even further sequences.
http://www.bacula.org/manuals/en/catalog/catalog/Installi_Configur_PostgreS.html
is the base for the above post.

Regards,
        Adrian
-- 
LiHAS - Adrian Reyer - Hessenwiesenstraße 10 - D-70565 Stuttgart
Fon: +49 (7 11) 78 28 50 90 - Fax:  +49 (7 11) 78 28 50 91
Mail: lihas AT lihas DOT de - Web: http://lihas.de
Linux, Netzwerke, Consulting & Support - USt-ID: DE 227 816 626 Stuttgart

------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_apr
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users