Discussion:
[Bacula-users] bacula: Keyword Name not permitted in this resource
der_Angler
2010-12-27 20:00:30 UTC
Permalink
Hello,
I've got a serious problem with my bacula configuration. I've changed my bacula configuration and put all the job , clients and so on in extra files. At this point, I've got 6 jobs und with 2 of them i have the problems. But let me explain with an example.

This is the last part of /etc/bacula/bacula-dir

...
...
...
Schedule {
Name = "WindowsWorkstations"
Run = Incremental daily at 20:00
}
# Include below all yours jobs configuration files (remember add '@' at beginning)
@/etc/bacula/conf.d/pc-backup.database.conf
@/etc/bacula/conf.d/pc-backup.full.conf
# @/etc/bacula/conf.d/pc-xxx_full.conf
@/etc/bacula/conf.d/pc-xxx_userdaten.conf
# @/etc/bacula/conf.d/pc-agenda_full.conf
@/etc/bacula/conf.d/pc-agenda_daten.conf
# Include Configs
@/etc/bacula/conf.d/clients.conf
@/etc/bacula/conf.d/filesets.conf


You see, in this example the 2 jobs are comment out. So, let's try to start bacula:

[***@pc-backup ~]# service bacula-dir start
Starting Bacula Director services: [ OK ]


Okay, everything is fine. So we can say the 4 jobs in the config are fine.
Now, I've changed the bacula-dir.conf in that way that one of the "problem"-jobs is on. See:

...
...
...
# Include below all yours jobs configuration files (remember add '@' at beginning)
@/etc/bacula/conf.d/pc-backup.database.conf
@/etc/bacula/conf.d/pc-backup.full.conf
# @/etc/bacula/conf.d/pc-xxx_full.conf
@/etc/bacula/conf.d/pc-xxx_userdaten.conf
@/etc/bacula/conf.d/pc-agenda_full.conf
@/etc/bacula/conf.d/pc-agenda_daten.conf
# Include Configs
@/etc/bacula/conf.d/clients.conf
@/etc/bacula/conf.d/filesets.conf


You can see the changes. Now lets try to start bacula:

[***@pc-backup ~]# service bacula-dir start
Starting Bacula Director services: 27-Dez 03:20 bacula-dir: ERROR TERMINATION at inc_conf.c:410
Config error: Keyword Name not permitted in this resource
: line 2, col 13 of file /etc/bacula/conf.d/pc-agenda_daten.conf
Name = "pc-agenda Daten"

[FEHLGESCHLAGEN]


Bad, don't work anymore. Curiously bacula told me that there is an error in "pc-agenda_daten.conf". BUT, in the example before he worked fine with this file. Why now not?
But perhaps the error is in one of the job files. so, here is the job file itself and the job before this one.
pc-agenda_daten.conf

Job {
Name = "pc-agenda Daten"
Enabled = yes
Client = pc-agenda-fd
FileSet = "pc-agenda Daten"
Schedule = "WindowsWorkstations"
Write Bootstrap = "/var/lib/bacula/%ws.bsr"
Type = Backup
Level = Full
Storage = File
Pool = File
Priority = 11
Messages = Standard
Run After Job = "/usr/local/sbin/bacula2nagios \"%n\" 0 \"%e %l %v\""
Run After Failed Job = "/usr/local/sbin/bacula2nagios \"%n\" 1 \"%e %l %v\""
}
FileSet {
Name = "pc-agenda Daten"
Enable VSS = yes
Include {
Options {
signature = MD5
}
File = "C:\AGENDA"
}
}


pc-agenda_full.conf

Job {
Name = "pc-agenda Full"
Enabled = yes
Client = pc-agenda-fd
FileSet = "pc-agenda Full"
Schedule = "WindowsWorkstations"
Write Bootstrap = "/var/lib/bacula/%ws.bsr"
Type = Backup
Level = Full
Storage = File
Pool = File
Priority = 11
Messages = Standard
Run After Job = "/usr/local/sbin/bacula2nagios \"%n\" 0 \"%e %l %v\""
Run After Failed Job = "/usr/local/sbin/bacula2nagios \"%n\" 1 \"%e %l %v\""
}
FileSet {
Name = "pc-agenda Full"
Enable VSS = yes
Include {
Options {
signature = MD5
}
File = "C:\"
}
}


I'm sarching for hours now ... but i didn't find the error in one of the files. Curiously 30 minutes before, with the proper config, i got another error after starting bacula:

Starting Bacula Director services: 27-Dez 03:12 bacula-dir: ERROR TERMINATION at inc_conf.c:410
Config error: Keyword Name not permitted in this resource
: line 2, col 7 of file /etc/bacula/conf.d/clients.conf
Name = pc-backup-fd

[FEHLGESCHLAGEN]



But my clients.conf is fine, see here:

Client {
Name = pc-backup-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}
Client {
Name = pc-agenda-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}
Client {
Name = pc-xxx-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}



So, is there anybody who could help me please ..... please




PS: Sry for my english, will try my best.

+----------------------------------------------------------------------
|This was sent by ***@linux-media-systems.de via Backup Central.
|Forward SPAM to ***@backupcentral.com.
+----------------------------------------------------------------------
Steve Ellis
2010-12-27 22:12:45 UTC
Permalink
I believe the error is in the file that you had previously commented out
(as I suspect you also believe). Below I've snipped what I think is the
Post by der_Angler
pc-agenda_full.conf
...
Post by der_Angler
FileSet {
Name = "pc-agenda Full"
Enable VSS = yes
Include {
Options {
signature = MD5
}
File = "C:\"
}
}
The problem is that the parser interprets "C:\" as a string consisting
of a 'C', a ':' and a '"'--because you've backslash escaped the quote.
I believe that you will find an easier solution is to use a '/' instead
of a '\', although doubling the '\' character may also work. In other
words try this:
File = "C:/"
instead of:
File = "C:\"

If this doesn't work (and I believe it will, as that is how I have my
windows clients configured), you might also be able to use:
File = "C:\\"
But I haven't tried this.

You may also find that the "Ignore Case = yes" option is useful on
windows--though admittedly it may only come into play if you specify
files or directories to either include or exclude.

Hope this helps,

-se
Robert Garza
2010-12-28 20:16:27 UTC
Permalink
Hello,

Try removing the spaces in between the "Run After Job" and "Run After
Failed Job" directive blocks.

http://bacula.org/5.0.x-manuals/en/main/main/Configuring_Director.html#SECTION001830000000000000000


On Mon, Dec 27, 2010 at 2:00 PM, der_Angler
Post by der_Angler
Hello,
I've got a serious problem with my bacula configuration. I've changed my
bacula configuration and put all the job , clients and so on in extra files.
At this point, I've got 6 jobs und with 2 of them i have the problems. But
let me explain with an example.
This is the last part of /etc/bacula/bacula-dir
...
...
...
Schedule {
Name = "WindowsWorkstations"
Run = Incremental daily at 20:00
}
@/etc/bacula/conf.d/pc-backup.database.conf
@/etc/bacula/conf.d/pc-backup.full.conf
@/etc/bacula/conf.d/pc-xxx_userdaten.conf
@/etc/bacula/conf.d/pc-agenda_daten.conf
# Include Configs
@/etc/bacula/conf.d/clients.conf
@/etc/bacula/conf.d/filesets.conf
Starting Bacula Director services: [ OK ]
Okay, everything is fine. So we can say the 4 jobs in the config are fine.
Now, I've changed the bacula-dir.conf in that way that one of the
...
...
...
@/etc/bacula/conf.d/pc-backup.database.conf
@/etc/bacula/conf.d/pc-backup.full.conf
@/etc/bacula/conf.d/pc-xxx_userdaten.conf
@/etc/bacula/conf.d/pc-agenda_full.conf
@/etc/bacula/conf.d/pc-agenda_daten.conf
# Include Configs
@/etc/bacula/conf.d/clients.conf
@/etc/bacula/conf.d/filesets.conf
Starting Bacula Director services: 27-Dez 03:20 bacula-dir: ERROR
TERMINATION at inc_conf.c:410
Config error: Keyword Name not permitted in this resource
: line 2, col 13 of file /etc/bacula/conf.d/pc-agenda_daten.conf
Name = "pc-agenda Daten"
[FEHLGESCHLAGEN]
Bad, don't work anymore. Curiously bacula told me that there is an error in
"pc-agenda_daten.conf". BUT, in the example before he worked fine with this
file. Why now not?
But perhaps the error is in one of the job files. so, here is the job file
itself and the job before this one.
pc-agenda_daten.conf
Job {
Name = "pc-agenda Daten"
Enabled = yes
Client = pc-agenda-fd
FileSet = "pc-agenda Daten"
Schedule = "WindowsWorkstations"
Write Bootstrap = "/var/lib/bacula/%ws.bsr"
Type = Backup
Level = Full
Storage = File
Pool = File
Priority = 11
Messages = Standard
Run After Job = "/usr/local/sbin/bacula2nagios \"%n\" 0 \"%e %l %v\""
Run After Failed Job = "/usr/local/sbin/bacula2nagios \"%n\" 1 \"%e %l %v\""
}
Should be defined like this:

Job {
Post by der_Angler
Name = "pc-agenda Daten"
Enabled = yes
Client = pc-agenda-fd
FileSet = "pc-agenda Daten"
Schedule = "WindowsWorkstations"
Write Bootstrap = "/var/lib/bacula/%ws.bsr"
Type = Backup
Level = Full
Storage = File
Pool = File
Priority = 11
Messages = Standard
RunAfterJob = "/usr/local/sbin/bacula2nagios \"%n\" 0 \"%e %l %v\""
Post by der_Angler
RunAfterFailedJob = "/usr/local/sbin/bacula2nagios \"%n\" 1 \"%e %l
%v\""
}


You can also try using the RunScript directive block, with the appropriate
directives, if the above does not work.
Post by der_Angler
FileSet {
Name = "pc-agenda Daten"
Enable VSS = yes
Include {
Options {
signature = MD5
}
File = "C:\AGENDA"
}
}
pc-agenda_full.conf
Job {
Name = "pc-agenda Full"
Enabled = yes
Client = pc-agenda-fd
FileSet = "pc-agenda Full"
Schedule = "WindowsWorkstations"
Write Bootstrap = "/var/lib/bacula/%ws.bsr"
Type = Backup
Level = Full
Storage = File
Pool = File
Priority = 11
Messages = Standard
Run After Job = "/usr/local/sbin/bacula2nagios \"%n\" 0 \"%e %l %v\""
Run After Failed Job = "/usr/local/sbin/bacula2nagios \"%n\" 1 \"%e %l %v\""
}
FileSet {
Name = "pc-agenda Full"
Enable VSS = yes
Include {
Options {
signature = MD5
}
File = "C:\"
}
}
I'm sarching for hours now ... but i didn't find the error in one of the
files. Curiously 30 minutes before, with the proper config, i got another
Starting Bacula Director services: 27-Dez 03:12 bacula-dir: ERROR
TERMINATION at inc_conf.c:410
Config error: Keyword Name not permitted in this resource
: line 2, col 7 of file /etc/bacula/conf.d/clients.conf
Name = pc-backup-fd
[FEHLGESCHLAGEN]
Client {
Name = pc-backup-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}
Client {
Name = pc-agenda-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}
Client {
Name = pc-xxx-fd
Address = 192.168.xx.xx
FDPort = 9102
Catalog = MyCatalog
Password = "yx"
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes
}
So, is there anybody who could help me please ..... please
PS: Sry for my english, will try my best.
+----------------------------------------------------------------------
+----------------------------------------------------------------------
------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment,
and,
should the need arise, upgrade to a full multi-node Oracle RAC database
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
Bacula-users mailing list
https://lists.sourceforge.net/lists/listinfo/bacula-users
Roberto Garza
-=-
Jeremy Maes
2010-12-30 08:28:27 UTC
Permalink
Post by der_Angler
Hello,
Try removing the spaces in between the "Run After Job" and "Run
After Failed Job" directive blocks.
http://bacula.org/5.0.x-manuals/en/main/main/Configuring_Director.html#SECTION001830000000000000000
Maybe a bit late (original poster's problem has already been fixed) but
I wanted to reply to this false information (at least for 5.0.x, not
sure about earlier versions).

Quote from the 5.0.3 manual (section 16.2.2: Upper and lower case and
spaces):

/Case (upper/lower) and spaces are totally ignored in the resource
directive keywords (the part before the equal sign).

Within the keyword (i.e. before the equal sign), spaces are not
significant. Thus the keywords: name, Name, and N a m e are all
identical.

Spaces after the equal sign and before the first character of the
value are ignored.

In general, spaces within a value are significant (not ignored), and
if the value is a name, you must enclose the name in double quotes
for the spaces to be accepted. Names may contain up to 127
characters. Currently, a name may contain any ASCII character.
Within a quoted string, any character following a backslash (\) is
taken as itself (handy for inserting backslashes and double quotes (")).

Please note, however, that Bacula resource names as well as certain
other names (e.g. Volume names) must contain only letters (including
ISO accented letters), numbers, and a few special characters (space,
underscore, ...). All other characters and punctuation are invalid./

So it shouldn't matter if there are any spaces in the directive names.
I've verified this in the past as my predecessor used a wide mix of
capitalized/non-capitalized names, names with spaces and without, lines
ended by semicolons and lines without, etc.
Post by der_Angler
On Mon, Dec 27, 2010 at 2:00 PM, der_Angler
Hello,
I've got a serious problem with my bacula configuration. I've
changed my bacula configuration and put all the job , clients and
so on in extra files. At this point, I've got 6 jobs und with 2 of
them i have the problems. But let me explain with an example.
*snip*
Kind regards,
Jeremy

**** DISCLAIMER ****
http://www.schaubroeck.be/maildisclaimer.htm

Michel Meyers
2010-12-29 14:20:09 UTC
Permalink
Post by der_Angler
Hello,
I've got a serious problem with my bacula configuration. I've changed my bacula configuration and put all the job , clients and so on in extra files. At this point, I've got 6 jobs und with 2 of them i have the problems. But let me explain with an example.
This is the last part of /etc/bacula/bacula-dir
PS: Sry for my english, will try my best.
Can you post the entire config file that it is complaining about? (just
remove the passwords)

You may have forgotten to close the section before the Job { section.

- - Michel
der_Angler
2010-12-29 21:18:52 UTC
Permalink
@Steve Ellis

You are my hero :) .... the problem is solved with your tip to change:

File="C:\"

to

File="C:/"

Thank you very much.

+----------------------------------------------------------------------
|This was sent by ***@linux-media-systems.de via Backup Central.
|Forward SPAM to ***@backupcentral.com.
+----------------------------------------------------------------------
Loading...