![]() command line utilitiesThese command line utilities consist of a set of templates that are used with the status service. The commands are defined as an alias.
The templates are stored in /infx/template/infx-cli. You can customize the utility output by modifying these templates.
parametersIn the alias definition, opt=value, defines the valid parameters for each.utility.. When you add parameters to the template, you must also add them to the alias definition.
bob001@bobii:/home/informix>infx alias ...
alias=users cmd=status util=infx-cli-users opt=order class sessid user location waitfor dbname sql
alias=dbspace cmd=status util=infx-cli-dbspaces opt=order class space pg flags alias=chunk cmd=status util=infx-cli-chunks opt=order class chunk del alias=service cmd=status util=infx-cli-services opt=order class service run alias=checkpoint cmd=status util=infx-cli-ckps opt=order class time trigger alias=fs cmd=status util=infx-cli-fs opt=order class name ...orderingPass the column name with the order parameter to change the list output order. The first column header in the table (from the left), that matches the order parameter will be selected to order by. The default order is descending, rows with lower values are last. To reverse this, specify a "-" in front of the column name.
Examples:
bob001@bobii:/home/informix>infx dbspaceclass space pg flags chks size mb free mb used mb used% read mb write mberror root 2k LO DBSCHG 1 100.00 1.20 98.80 98.80% 3.45 6,054.86good dat01 2k OK 1 4,000.00 3,712.96 287.04 7.18% 277.57 1,731.53good idx01 2k OK 1 4,000.00 3,885.27 114.73 2.87% 1,275.25 15,207.77good smartdbs1 2k OK SBSPACE 1 4,000.00 3,709.37 290.63 7.27% 2.54 23.83good smartdbs2 2k OK SBSPACE 1 4,000.00 3,709.27 290.73 7.27% 0.03 23.94bob001@bobii:/home/informix>infx dbspace order=writeclass space pg flags chks size mb free mb used mb used% read mb write mbgood idx01 2k OK 1 4,000.00 3,885.27 114.73 2.87% 1,275.25 15,207.77error root 2k LO DBSCHG 1 100.00 1.20 98.80 98.80% 3.45 6,054.86good dat01 2k OK 1 4,000.00 3,712.96 287.04 7.18% 277.57 1,731.53good smartdbs2 2k OK SBSPACE 1 4,000.00 3,709.27 290.73 7.27% 0.03 23.94good smartdbs1 2k OK SBSPACE 1 4,000.00 3,709.37 290.63 7.27% 2.54 23.83bob001@bobii:/home/informix>infx dbspace order=-freeclass space pg flags chks size mb free mb used mb used% read mb write mberror root 2k LO DBSCHG 1 100.00 1.20 98.80 98.80% 3.45 6,054.86good smartdbs2 2k OK SBSPACE 1 4,000.00 3,709.27 290.73 7.27% 0.03 23.94good smartdbs1 2k OK SBSPACE 1 4,000.00 3,709.37 290.63 7.27% 2.54 23.83good dat01 2k OK 1 4,000.00 3,712.96 287.04 7.18% 277.57 1,731.53good idx01 2k OK 1 4,000.00 3,885.27 114.73 2.87% 1,275.25 15,207.77
filteringThe other parameters for each utility allow you to filter the results. The default alias parameters all filter on alphanumeric columns. Enclose the parameter in qutoes (") if you need to use special characters, such as *. The pattern matching is performed case in-sensitive. Example: bob001@bobii:/home/informix>infx dbspace space=smartclass space pg flags chks size mb free mb used mb used% read mb write mbgood smartdbs1 2k OK SBSPACE 1 4,000.00 3,709.37 290.63 7.27% 2.54 23.83good smartdbs2 2k OK SBSPACE 1 4,000.00 3,709.27 290.73 7.27% 0.03 23.94You can specify multiple patterns to match, separated by a comma. bob001@bobii:/home/informix>infx dbspace space=dat,idxclass space pg flags chks size mb free mb used mb used% read mb write mbgood dat01 2k OK 1 4,000.00 3,712.96 287.04 7.18% 277.57 1,731.53good idx01 2k OK 1 4,000.00 3,885.27 114.73 2.87% 1,275.25 15,207.77The filtering and ordering is performed as a function of the template, see the template reference for more details.
modified outputYou can override the utilities default output by making a local copy of the template, and changing it.
Example:
cp /infx/template/infx-cli/infx-cli-status.htmlt /infx/local/template/cliNow when you execute the status service, it's output will be formatted by the local copy of the template.
You can also create a completely new template of your own and create a new alias for it, see custom utilities. |

