Recognized Primitive Data Types
When parsing the resource directives, Bacula classifies the data according to the types listed below. The first time you read this, it may appear a bit overwhelming, but in reality, it is all pretty logical and straightforward.
name A keyword or name consisting of alphanumeric characters, including the hyphen, underscore, and dollar characters. The first character of a name must be a letter. A name has a maximum length currently set to 127 bytes. Typically keywords appear on the left side of an equal (i.e. they are Bacula keywords – i.e. Resource names or directive names). Keywords may not be quoted.
name-string A name-string is similar to a name, except that the name may be quoted and can thus contain additional characters including spaces. Name strings are limited to 127 characters in length. Name strings are typically used on the right side of an equal (i.e. they are values to be associated with a keyword).
string A quoted string containing virtually any character including spaces, or a non-quoted string. A string may be of any length. Strings are typically values that correspond to filenames, directories, or system command names. A backslash () turns the next character into itself, so to include a double quote in a string, you precede the double quote with a backslash. Likewise to include a backslash.
directory A directory is either a quoted or non-quoted string. A directory will be passed to your standard shell for expansion when it is scanned. Thus constructs such as $HOME are interpreted to be their correct values.
password This is a Bacula password and it is stored internally in MD5 hashed format.
integer A 32 bit integer value. It may be positive or negative.
positive integer A 32 bit positive integer value.
long integer A 64 bit integer value. Typically these are values such as bytes that can exceed 4 billion and thus require a 64 bit value.
<yes|no> Either a yes or a no.
size A size specified as bytes. Typically, this is a floating point scientific input format followed by an optional modifier. The floating point input is stored as a 64 bit integer value. If a modifier is present, it must immediately follow the value with no intervening spaces. The following modifiers are permitted:
k 1,024 (kilobytes)
kb 1,000 (kilobytes)
m 1,048,576 (megabytes)
mb 1,000,000 (megabytes)
g 1,073,741,824 (gigabytes)
gb 1,000,000,000 (gigabytes)
time A time or duration specified in seconds. The time is stored internally as a 64 bit integer value, but it is specified in two parts: a number part and a modifier part. The number can be an integer or a floating point number. If it is entered in floating point notation, it will be rounded to the nearest integer. The modifier is mandatory and follows the number part, either with or without intervening spaces. The following modifiers are permitted:
seconds seconds
minutes minutes (60 seconds)
hours hours (3600 seconds)
days days (3600*24 seconds)
weeks weeks (3600*24*7 seconds)
months months (3600*24*30 seconds)
quarters quarters (3600*24*91 seconds)
years years (3600*24*365 seconds)
Any abbreviation of these modifiers is also permitted (i.e. seconds may be specified as sec or s). A specification of m will be taken as months.
The specification of a time may have as many number/modifier parts as you wish. For example:
1 week 2 days 3 hours 10 mins 1 month 2 days 30 sec
are valid date specifications.
speed A speed specified as data transfer rate. Typically, this is a floating point scientific input format followed by an optional modifier. The floating point input is stored as a 64-bit integer value. If a modifier is present, it must immediately follow the value with no intervening spaces. The following modifiers are permitted:
k/s kilobytes per second (1 kilobyte = 1,024 bytes)
kb/s kilobytes per second (1 kilobyte = 1,000 bytes)
kib/s kibibytes per second (1 kibibyte = 1,024 bytes)
m/s megabytes per second (1 megabyte = 1,048,576 bytes)
mb/s megabytes per second (1 megabyte = 1,000,000 bytes)
mib/s mebibytes per second (1 mebibyte = 1,048,576 bytes)
See also
Go back to:
Go to:
Go back to the Customizing the Configuration Files.
Go back to the main Bacula Enterprise Configuration page.