Re: baculabackupreport script error

Chris Wilkinson <[email protected]>
Newsgroups gmane.comp.bacula.user
Message-ID <CAHUKsLJwQxeY_+0OE1t6iCk8f+whZT=C9yDZk1rdnAX3D0u4Lg@mail.gmail.com>
That's perfectly reasonable. I just got confused by the help screen
thinking that since the -C option is in [ ] I took that to mean optional.
Now I know to call with the -C option.

Thanks

On Sat, 19 Oct 2024, 21:53 Bill Arlofski, <[email protected]> wrote:

> On Thursday, October 17th, 2024 at 04:11, Chris Wilkinson <
> [email protected]> wrote:
>
> > I got your Python script working but only if I include the -C
> <baculabackupreport.ini> in the command line. Otherwise it complains that
> email is missing, cannot connect to dB and a few other things. It looks
> like it's not finding the configuration file that I put in my home
> directory. With -C it does find it.
> >
>
> > Is there no default for this parameter?
> >
>
> > -Chris Wilkinson
>
>
> Hello Chris,
>
> Since there are defaults for practically everything (eg: the db name, db
> user, db password, number of hours, days, etc), the only variable required
> which cannot have a default is the email address. This must be set on the
> command line, or as an environment variable, or in a [section] of a config
> file.
>
> Since the config file is not required, there is no default for it, and it
> can be located anywhere you like. I could think of no "correct" location
> for a default config file since there is Bacula Enterprise and several
> different package maintainers for Bacula Community, each choosing different
> places for "bacula stuff" to reside. :)
>
> Also, you will notice that in the example config file, the [DEFAULT]
> section is basically blank - because everything already has some default
> setting. If you have a different name for your Bacula catalog DB, or you
> have set a DB user other than the default 'bacula', or you have set a
> password other than the default "<no password>", then you can set them in
> the environment, on the command line, or in a specified [section] of a
> specified config file.
>
> So, if you specify just the -C /path/to/config/file and -S <name of
> [section] in config file>, everything else can be set/overridden in the
> config file, keeping your cron line nice and short/clean. :)
>
>
> Hope this helps,
> Bill
>
> --
> Bill Arlofski
> [email protected]

-Chris Wilkinson

_______________________________________________
Bacula-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bacula-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.