Blame IbaTools/man/opaxmlgenerate.manPage

Packit 857059
.\" .\" *********************************************************************
Packit 857059
.\" .\" *                                                                   *
Packit 857059
.\" .\" *             Copyright 2015-2019, Intel Corporation                *
Packit 857059
.\" .\" *                                                                   *
Packit 857059
.\" .\" *                       All Rights Reserved.                        *
Packit 857059
.\" .\" *                                                                   *
Packit 857059
.\" .\" *********************************************************************
Packit 857059
Packit 857059
.TH opaxmlgenerate 8 "Intel Corporation" "Copyright(C) 2015\-2019" "IFSFFCLIRG (Man Page)"
Packit 857059
.SH NAME
Packit 857059
opaxmlgenerate
Packit 857059
Packit 857059
Packit 857059
.PP
Packit 857059
Packit 857059
\fB(Linux)\fR
Packit 857059
Takes comma-separated-values (CSV) data as input and generates sequences of XML containing user-specified element names and element values within start and end tag specifications. Use this tool to create an XML representation of fabric data from its CSV form.
Packit 857059
.SH Syntax
Packit 857059
opaxmlgenerate [-v] [-d  \fIdelimiter\fR] [-i  \fInumber\fR] [-g  \fIelement\fR]
Packit 857059
.br
Packit 857059
Packit 857059
[-h  \fIelement\fR] [-e  \fIelement\fR] [-X  \fIinput\(ulfile\fR] [-P  \fIparam\(ulfile\fR]
Packit 857059
.SH Options
Packit 857059
Packit 857059
.TP 10
Packit 857059
--help
Packit 857059
Packit 857059
Produces full help text.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-g/--generate \fIelement\fR
Packit 857059
Packit 857059
Generates value for \fIelement\fR using value in next field from the input file. Can be used multiple times on the command line. Values are assigned to elements in order.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-h/--header \fIelement\fR
Packit 857059
Packit 857059
Name of the XML element that is the enclosing header start tag.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-e/--end \fIelement\fR
Packit 857059
Packit 857059
Name of the XML element that is the enclosing header end tag.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-d/--delimit \fIdelimiter\fR
Packit 857059
Packit 857059
Specifies the delimiter character that separates values in the input file. Default is semicolon.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-i/--indent \fInumber\fR
Packit 857059
Packit 857059
Number of spaces to indent each level of XML output. Default is 0.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-X/--infile \fIinput\(ulfile\fR
Packit 857059
Packit 857059
Generates XML from CSV in input\(ulfile. One record per line with fields in each record separated by the specified delimiter.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-P/--pfile \fIparam\(ulfile\fR
Packit 857059
Packit 857059
Uses input command line options (parameters) from param\(ulfile.
Packit 857059
Packit 857059
.TP 10
Packit 857059
-v/--verbose
Packit 857059
Packit 857059
Produces verbose output. Includes output progress reports during extraction.
Packit 857059
Packit 857059
Packit 857059
.SH Details
Packit 857059
Packit 857059
.PP
Packit 857059
opaxmlgenerate takes the CSV data from an input file. It generates fragments of XML, and in combination with a script, can be used to generate complete XML sequences. opaxmlgenerate does not use nor require a connection to an Intel(R) Omni-Path Fabric.
Packit 857059
.PP
Packit 857059
opaxmlgenerate reads CSV element values and applies element (tag) names to those values. The element names are supplied as command line options to the tool and constitute a template that is applied to the input.
Packit 857059
.PP
Packit 857059
Element names on the command line are of three (3) types, distinguished by their command line option - Generate, Header, and Header\(ulEnd. The Header and Header\(ulEnd types together constitute enclosing element types. Enclosing elements do not contain a value, but serve to separate and organize Generate elements.
Packit 857059
.PP
Packit 857059
Generate elements, along with a value from the CSV input file, cause XML in the form of <element\(ulname> \fIvalue\fR</element\(ulname> to be generated. Generate elements are normally the majority of the XML output since they specify elements containing the input values. Header elements cause an XML header start tag of the form: <element\(ulname> to be generated. Header\(ulEnd elements cause an XML header end tag of the form </element\(ulname> to be generated. Output of enclosing elements is controlled entirely by the placement of those element types on the command line. opaxmlgenerate does
Packit 857059
\fBnot\fR
Packit 857059
check for matching start and end tags or proper nesting of tags.
Packit 857059
.PP
Packit 857059
Options (parameters) to opaxmlgenerate can be specified on the command line, with a parameter file, or both. A parameter file is specified with -P \fIparam\(ulfile\fR. When a parameter file specification is encountered on the command line, option processing on the command line is suspended, the parameter file is read and processed entirely, and then command line processing is resumed. Option syntax within a parameter file is the same as on the command line. Multiple parameter file specifications can be made, on the command line or within other parameter files. At each point that a parameter file is specified, current option processing is suspended while the parameter file is processed, then resumed. Options are processed in the order they are encountered on the command line or in parameter files. A parameter file can be up to 8192 bytes in size and may contain up to 512 parameters.
Packit 857059
Packit 857059
.SH Using opaxmlgenerate to Create Topology Input Files
Packit 857059
Packit 857059
.PP
Packit 857059
opaxmlgenerate can be used to create scripts to translate from user-specific format into the opareport topology\(ulinput file format. opaxmlgenerate itself works against a CSV style file with one line per record. Given such a file it can produce hierarchical XML output of arbitrary complexity and depth.
Packit 857059
.PP
Packit 857059
The typical flow for a script which translates from a user-specific format into opareport topology\(ulinput would be:
Packit 857059
.IP \(bu
Packit 857059
As needed, reorganize the data into link and node data CSV files, in a sequencing similar to that used by opareport topology\(ulinput. One link record per line in one temporary file, one node record per line in another temporary file and one SM per line in a third temporary file.
Packit 857059
.IP \(bu
Packit 857059
The script must directly output the boilerplate for XML version, etc.
Packit 857059
.IP \(bu
Packit 857059
opaxmlgenerate can be used to output the Link section of the topology\(ulinput, using the link record temporary file.
Packit 857059
.IP \(bu
Packit 857059
opaxmlgenerate can be used to output the Node sections of the topology\(ulinput using the node record temporary file. If desired, there could be separate node record temporary files for HFIs and Switches.
Packit 857059
.IP \(bu
Packit 857059
opaxmlgenerate can be used to output the SM section of the topology\(ulinput, if desired.
Packit 857059
.IP \(bu
Packit 857059
The script must directly output the closing XML tags to complete the topology\(ulinput file.