[Contents]
[Prev]
[Next]
[Index]
[Report an Error]
Minimum Configuration for Enabling and Viewing Traceoptions
Output
If no commit script trace options are configured
yet, the simplest way to view the trace output of a commit script
is to configure the output trace flag and issue the show
log cscript.log | last command. To do this, perform the following
steps:
- If you have not done so already, enable
a commit script by including the file statement at the [edit system scripts commit] hierarchy level:
- [edit system scripts commit]
-
file filename;
- Enable trace options by including the traceoptions
flag output statement at the [edit system scripts commit] hierarchy level:
- [edit system scripts commit]
-
traceoptions flag output;
- Issue the commit command:
- [edit]
- user@host# commit
- Display the resulting trace messages recorded in the file /var/log/cscript.log. At the end of the log is the output generated
by the commit script you enabled in Step item. To display the end of the log, issue the show log cscript.log
| last operational mode command:
- [edit]
- user@host# run show log cscript.log | last
Table 14 summarizes useful
filtering commands that display selected portions of the cscript.log file.
Table 14: Commit
Script Tracing Operational Mode Commands
|
Task
|
Command
|
|
Display logging data associated with all script processing.
|
show log cscript.log
|
|
Display script processing for only the most recent commit operation.
|
show log cscript.log | last
|
|
Display processing for script errors.
|
show log cscript.log | match error
|
|
Display script processing for a particular script.
|
show log cscript.log | match script-name
|
[Contents]
[Prev]
[Next]
[Index]
[Report an Error]