logIt Log Around The Clock

Working With Templates

tags:

Most template editing is done through Motif-GUI. A “template engineer” privilege capable of doing many things there. However, to run other steps outside his/her privilege, he/she needs to invoke some command line.

Check installed templates and their status (enabled/disabled) in a node:

$ ovpolicy -list -host

Export a template to a flat file

$ opctempl -get

Template types for templ_type can be one of the following:

CONSOLE_TEMPLATE
OPCMSG_TEMPLATE
LOGFILE_TEMPLATE
MONITOR_TEMPLATE
SNMP_TEMPLATE
EC_TEMPLATE
SCHEDULE_TEMPLATE

Then, previous exporting can be done as e.g.

opctempl SOMECOMPANY-BC-VAS-MTR-OS-FS MONITOR_TEMPL some_output_file

How do we get which template type for a template? Visually in Motif-GUI (there is a Type column there) or by listing available templates in management server e.g. (it will appear inside |TYPE| ):

$ opcnode -list_templs | grep VAS
|GRP| VAS
|MON| SOMECOMPANY-BC-VAS-MTR-OS-FS
|MON| SOMECOMPANY-BC-VAS-MTR-APPS-PORT_10001

Assign one of the above templates by e.g.

$ opcnode -assign_templs templ_name="SOMECOMPANY-BC-VAS-MTR-OS-FS" templ_type=MONITOR_TEMPLATE node_name=vasprdpdb3.somecompany.lan net_type=NETWORK_IP

to remove replace with -deassign_templ.
Check assigned templates using

$ opcnode -list_ass_templs node_name=vasprdpdb3.somecompany.lan net_type=NETWORK_IP

One thought on “Working With Templates

  1. Pingback: update bookmark blog 02/05/2015 (a.m.) | Kevin Mullet's Bookmarks

Leave a Reply