BART Output
The following exit values are returned:
- 0
-
Success
- 1
-
Nonfatal error when processing files, such as permission problems
- >1
-
Fatal error, such as an invalid command-line option
The reporting mechanism provides two types of output: verbose and programmatic:
-
Verbose output is the default output and is localized and presented on multiple lines. Verbose output is internationalized and is human-readable. When the
bart compare
command compares two system manifests, a list of file differences is generated.The structure of the output is as follows:
filename attribute control:control-val test:test-val
- filename
-
Name of the file that differs between the control manifest and the test manifest.
- attribute
-
Name of the file attribute that differs between the manifests that are compared. The control-val precedes the test-val. When discrepancies for multiple attributes occur in the same file, each difference is noted on a separate line.
Following is an example of attribute differences for the
/etc/passwd
file. The output indicates that thesize
,mtime
, andcontents
attributes have changed./etc/passwd: size control:74 test:81 mtime control:3c165879 test:3c165979 contents control:daca28ae0de97afd7a6b91fde8d57afa test:84b2b32c4165887355317207b48a6ec7
-
Programmatic output is generated with the
-p
option to thebart compare
command. This output is suitable for programmatic manipulation.The structure of the output is as follows:
filename attribute control-val test-val [attribute control-val test-val]*
For a list of attributes that are supported by the bart
command, see BART Rules File Attributes.
For more information, see the bart
(8) man page.