Bacula-users

Re: [Bacula-users] Bug or Feature Request - Config token too long?

2009-12-10 14:09:21
Subject: Re: [Bacula-users] Bug or Feature Request - Config token too long?
From: Mingus Dew <shon.stephens AT gmail DOT com>
To: Arno Lehmann <al AT its-lehmann DOT de>
Date: Thu, 10 Dec 2009 14:05:34 -0500
Thank you. Great tip. I won't implement because I'd need to update though. But it did lead me to the right place.

-Shon

On Tue, Nov 24, 2009 at 10:16 AM, Arno Lehmann <al AT its-lehmann DOT de> wrote:
Hi,

24.11.2009 15:47, Mingus Dew wrote:
> All,
>      Running Bacula 3. on Solaris 10 x86. I'm setting up some Copy jobs
> using the Selection Type = SQLQuery. When I try to test the config file
> I get the error:
>
> bacula@backup_svr: bacula-dir -t -c /opt/csw/etc/bacula/bacula-dir.conf
> 24-Nov 01:51 bacula-dir: ERROR TERMINATION at lex.c:270
> Config token too long, file: /opt/csw/etc/bacula/bacula-dir_jobs.conf,
> line 757, begins at line 756

Looks like a config token must not span lines.

> My SQLQuery is actually 2 queries on the same line. It works fine in
> MySQL and I need 2 queries to select jobs from 2 pools in the same Copy
> Job. Here is the SQL statement
>
> select distinct Job.JobId,Job.Name from Job,Pool where Pool.Name =
> 'FS-Incremental_Pool' and Pool.PoolId = Job.PoolId and Job.Type = 'B'
> and Job.JobStatus in ('T','W') and Job.jobBytes > 0 and Job.StartTime >
> date_sub(current_timestamp(),interval 7 day) and Job.StartTime <
> current_timestamp() order by Job.StartTime; select distinct
> Job.JobId,Job.Name from Job,Pool where Pool.Name = 'FS-Full_Pool' and
> Pool.PoolId = Job.PoolId and Job.Type = 'B' and Job.JobStatus in
> ('T','W') and Job.jobBytes > 0 and Job.StartTime >
> date_sub(current_timestamp(),interval 7 day) and Job.StartTime <
> current_timestamp() order by Job.StartTime;
>
> This is the only method I can use as the other methods for selecting Job
> ID's for Copying don't fit my environment. I'd prefer not to split the
> copying of Incrementals and Fulls into different Jobs.

It should be possible to create on query, but I don't know how right
now :-)

I haven't checked the actual length of your queries, but if they
really exceed Baculas built-in limit, you might want a function
defined in the catalog database. Should be possible with PostgreSQL
and MySQL, as far as I know.

Cheers,

Arno

> Thanks,
> Shon
>
>
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
> trial. Simplify your report design, integration and deployment - and focus on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Bacula-users mailing list
> Bacula-users AT lists.sourceforge DOT net
> https://lists.sourceforge.net/lists/listinfo/bacula-users

--
Arno Lehmann
IT-Service Lehmann
Sandstr. 6, 49080 Osnabrück
www.its-lehmann.de

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev
_______________________________________________
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>
  • Re: [Bacula-users] Bug or Feature Request - Config token too long?, Mingus Dew <=