Grammar files supported by BMC Server Automation
BMC Server Automation supports a variety of grammar files capable of parsing data presented in a prescribed format. After it is parsed, that data can be generated in a format consistent with other information in BMC Server Automation so you can then browse, snapshot, audit, and deploy that information.
Although BMC Server Automation provides many grammar files, the following are the basic types:
- CSV — Parses files consisting of comma-separated entries
- HTTPD — Parses httpd.conf files
- name = value — Parses files with single name/value pairs connected by an equal sign (=)
- name space value — Parses files with name/value pairs connected by white space instead of an equal sign (=)
- XML — Parses XML files using the Xerces DOM parser to generate a DOM tree. Configuration files are then created by traversing the tree. Various schemes are used to generate a unique key for each record.
- Regular — Parses all other configuration files. The following table lists all the grammar files BMC Server Automation supports by default. These grammar files reside in <installDirectory>/scripts. For additional information about how an individual grammar file is used to parse configuration files, refer to information provided in each grammar file. For information about creating custom grammars, see Creating custom grammars.
Grammar Type Name
Associated Grammar File
Description
/etc/auto_* file
auto.gm
Parses files with lines made up of a varying number of tab-delimited entries; the first entry is the unique key.
/etc/group file
group.gm
Parses files with four colon-delimited values in each line; the first value is the unique key.
/etc/inittab file
inittab.gm
Parses files with four colon-delimited values per line; the first value is the unique key.
/etc/pam file
pam.gm
Parses files with lines made up of a varying number of tab-delimited entries; uses the entire line as the unique key.
/etc/passwd file
passwd.gm
Parses files where each line consists of seven colon-delimited fields; the first value is the unique key.
/etc/resolv.conf file
resolv.gm
Parses files with a varying number of space- or tab-delimited entries on each line; the unique key is generated by a combination of all entries.
/etc/shadow file
shadow.gm
Parses files with lines of nine colon-delimited values; the first value is the unique key.
AIX /etc/security/* file
aix_security.gm
Parses all /etc/security files in IBM AIX that have a header on one line followed by name/value pairs connected by an equal sign (=); the first value is the unique key.
audit control file
audit_control.gm
Parses fields separated by colons, using the first field as the key. This grammar is used to parse /etc/security/audit_control files on Oracle Solaris.
audit files
audit.gm
Parses fields separated by colons, using the second field as the key. This grammar is used to parse /etc/security/audit_class and /etc/security/audit_event files on Solaris.
config.xml
config.xml.gm
Parses WebLogic config.xml files.
console_perms
console_perms.gm
Parses /etc/security/console.perms files on Linux.
context.xml
context.xml.gm
Parses Tomcat context.xml files.
crontab file
crontab.gm
Stores five time-based values and one ambiguous command value per line; the command is the unique key.
csv file
csv.gm
Parses files consisting of lines of a varying number of comma-separated entries; uses the entire line as a unique key.
fstab mount file
fstab.gm
Parses files where each line consists of six tab-delimited entries; the first entry is the unique key.
grub.conf
grub.gm
Parses /etc/grub.conf files on Linux.
hosts file
hosts.gm
Parses files with lines consisting of a varying number of space-delimited entries; the first entry is the unique key.
httpd.conf file
httpd.gm
Parses formats similar to a simple XML format.
init.ora file
init.ora.gm
Parses records with a name and one value and treats comments as values.
lilo.conf
lilo.gm
Parses /etc/lilo.conf files on Linux.
Linux /etc/yp.conf file
ypconf.gm
Parses a complex format specific to /etc/yp.conf files on Linux.
Machine Config XML file
machine.config.xml.gm
Parses machine.config XML files used for IIS and .NET applications. This grammar is specifically designed for machine.config XML files that may include multiple nodes with identical names and the same parent node.
name = multi values
nvp.gm
Parses records with a name and multiple values, such as name = value1 value2 value3.
name = value
nsvp.gm
Parses files with single name/value pairs connected by an equal sign (=); uses the name before the equal sign as a unique key.
name space value
nsvp_space.gm
Parses data where the format is "PROPERTY VALUE". The separator is white space instead of an equal sign (=). This grammar is used to parse /etc/login.defs files on Linux and /etc/hosts.deny and /etc/ssh/sshd_config files on Solaris.
NIS /etc/group file
nis-group.gm
Parses files for*/etc/group* and Network Information Server (NIS)/etc/group on UNIX platforms.
nsswitch.conf on UNIX
nsswitch.gm
Parses formats using an initial key followed by a colon with a varying number of space-delimited values after the colon.
Oracle config files
ora.gm
Parses tnsnames.ora and listener.ora files in Oracle.
running-managed-servers.xml
running-managed-servers.xml
Parses Tomcat running-managed-servers.xml files.
single unique value per line
single_val.gm
Parses files where each line contains one value that does not contain a space, equal sign (=), or pound sign (#).
Solaris /etc/system file
system.gm
Uses a complicated grammar to parse Solaris /etc/system files.
Solaris inetd.conf file
inetd.gm
Parses Solaris files with lines consisting of a varying number of tab-delimited entries; all entries make up the unique key.
split line into fields
line.gm
Parses generic records separated by spaces; all fields participate in the key. Used as an alternative to generic.gm, this grammar is used to parse /etc/init.d/netconfig, /etc/security/audit_startup, and /etc/ftpd/ftpaccess files on Solaris.
ssh_config
ssh_config.gm
Parses /etc/ssh/ssh_config files on Linux.
sshd_config
sshd_config.gm
Parses /etc/ssh/sshd_config files on Linux.
tomcat-server.xml
tomcat-server.xml.gm
Parses Tomcat server.xml files.
tomcat-users.xml
tomcat-users.xml.gm
Parses Tomcat users.xml files.
UNIX /etc/syslog.conf file
syslog.gm
Parses /etc/syslog.conf files on UNIX.
users and exports file
users.gm
Parses files using the format of the BMC Server Automation users and exports configuration files. For a discussion of those files, see Setting up configuration files. The first entry is the unique key.
vfstab mount file
vfstab.gm
Parses files where each line consists of seven tab-delimited entries; uses the first entry as the unique key.
web.xml
web.xml.gm
Parses J2EE web.xml files.
Web Config XML file
web.config.xml.gm
Parses web.config XML files used for IIS and .NET applications. This grammar is specifically designed for web.config XML files that may include multiple nodes with identical names and the same parent node.
whole line as record
generic.gm
Parses files by treating a complete line as a single field; uses the entire line as a unique key. This grammar can be used for parameter substitution during Deploy Jobs.
Microsoft Windows INI file
ini.gm
Parses Windows INI formats with a bracket-enclosed header and subsequent name-value pairs; the first entry is the unique key.
xinetd.conf file
xinetd.gm
Parses xinetd.conf files on Linux.
XML file
xml.gm
Uses an XML library to parse XML files.
Comments
Log in or register to comment.