The following are examples of using log macros while logged into the primary Screen.
To display the definition of a non-Screen specific macro:
admin% ssadm -r primary edit Initial edit> logmacro print name=mail-only NAME="mail-only" ENABLED VALUE="svc smtp" DESCRIPTION="SMTP mail" ... |
To define a non-Screen specific macro:
admin% ssadm -r primary edit Initial edit> logmacro add name=pkts-only value="loglvl pkt" Description="only network packets" edit> quit |
To define a macro for a specific Screen:
admin% ssadm -r primary edit Initial edit> logmacro add sys=Screenname name=SFO value="port SFO" description="routing SFO" edit> quit |
Although, the output produced by print surrounds the value of each item in double quotes, these are only necessary on input if there are embedded spaces within the values of items. Also, although print outputs all tag names in capital letters (for example, NAME=), these tags are recognized in a case-insensitive manner on input (for example, name=, Name=, NAME= are equivalent.)
You can create expediency log macros on any Screen using logmacro as a subcommand of ssadm (rather than an ssadm edit subcommand). The syntax of the rest of the usage is the same as given above.