Media Flow Controller Configuration Tasks : Advanced Configurations : System Logging Options

System Logging Options
The system log (syslog) that records all system activity such as user logins, configuration changes, and system condition changes. It does not record service activity or errors. The Media Flow Controller errorlog records service related errors but is mostly useful for debugging by Juniper Networks Support. Media Flow Controller provides several service-specific logs, detailed in Chapter 5, “Media Flow Controller Fault Management.”
Specify, on a global or local level, what system data is collected when; when log files are deleted, or rotated; where log files are uploaded to; the format for logs; what traps are sent to syslog; and whether or not to accept log messages from remote servers. See logging for CLI details.
About Log Severity Levels and Classes
The logging commands provide pre-defined log severity levels so you can refine what messages are logged, and pre-defined log classes that divide messages up according to their origin. Logging severity-level options are:
emerg—System is unusable (requires immediate action)
alert—System may become unusable (requires immediate action)
crit—Critical conditions (requires immediate action)
err—Error conditions (minor issue; i.e. “disk went bad”)
warning—Warning conditions (functionality OK, but sub-optimal)
notice—Normal but significant conditions (default)
info—Informational messages (administrator actions)
debug—Debug-level messages (all messages)
Logging class options are:
mgmt-core—Management daemon (mgmtd) only
mgmt-back—Other back end components
mgmt-front—Front end components, utilities, and tests
Configuring System Logging
1.
Set the minimum severity of log messages to be saved in log files on local persistent storage (regardless of source), the severity level at which user-executed CLI commands are logged, or disable local logging altogether.
logging local <severity_level>
logging level cli commands <severity_level>
logging local none
2.
Set or remove (with no) a per-class override on the global logging level for logged messages local or to a specified remote syslog server; all classes without an override use the global logging level set with logging local <severity_level> (default is notice). Use the no variant or set none as the severity level to disable logging from that class entirely.
logging local override class <class> priority <severity_level>
logging <IP_address> trap override class <class> priority <severity_level>
3.
Set or remove (with no) a remote syslog server to receive log messages; and a severity level of logged messages sent to all, or a specified, remote syslog server.
logging <IP_address>
logging trap <severity_level>
logging <IP_address> trap <severity_level>
4.
logging trap none
logging <IP_address> trap none
5.
Allow (or disable with no) this system to receive log messages from another host; disabled by default. If enabled, only log messages matching or exceeding the minimum severity specified with logging local <log level> are logged, regardless of what is sent.
logging recieve
6.
Set (or reset default with no) the format in which log messages should be set. The default is standard.
logging format standard
logging format welf
7.
Set (or remove with no) the firewall name that should be associated with each message logged in WELF (Web trends Enhanced Log Format). If no firewall name is set, the hostname is used by default. Note that neither of these commands enables WELF logging if it is not already enabled with logging format welf.
logging format welf fw-name <firewall_name>
8.
Include (or disable with no) an additional field in each log message showing the number of seconds since the Epoch; default is disabled. This is independent of the standard syslog datetime at the beginning of each message in the format "Feb 25 18:00:00". Aside from indicating the year at full precision, its main purpose is to provide subsecond precision. The precision can be controlled with the two digits commands which control the number of digits to the right (fractional) and left (whole) of the decimal point; all = no limit. Please note except for the year, all of these digits are redundant with syslog's own datetime.
logging fields seconds enable
logging fields seconds whole-digits {1 | 6 | all}
logging fields seconds fractional-digits {1 | 2 | 3 | 6}
9.
Configure when log files on local persistent storage should be automatically rotated. Choose one of two mutually exclusive options: rotation based on time, or active log file size. Default is time = daily (once per day at midnight).
logging files rotation criteria frequency {daily | weekly | monthly}
logging files rotation criteria size <log_file_size_threshold>
logging files rotation criteria size-pct <log_file_size_percent_threshold>
10.
Configure how many old log files are kept. When the number of log files exceeds this number (either at rotation time, or when this setting is lowered), the system deletes as many as necessary to bring it down to this number, starting with the oldest.
logging files rotation max-num <maximum_number_of_files_to_keep>
11.
logging files rotation force
12.
logging files delete oldest [<number of files to delete>]
13.
Upload a log file to a remote host. The word current specifies the current log file. To specify an archived log file, give its number instead, as displayed by show log files.
logging files upload {current | <file number>} <URL>
14.
View a local log file. If <file_number> is specified, view an archived log file, where the number is from 1 up to the number of archived log files (10 is the default maximum allowed); the higher the number, the more recent the log file. If [not] matching <regex> is specified, the file is filtered to only include lines either matching, or not matching, the provided regular expression. Note! Enclose all regex entries in single quotes.
show log [files <file_number>] [[not] matching <regex>]
15.
Display the last few lines of the current log file, and then continue to display new lines as they come in, until you press Ctrl+C. If [not] matching <regex> is specified, only log lines matching, or not matching, the provided regular expression are printed. Note! Enclose all regex entries in single quotes.
show log continuous [[not] matching <regex>]
16.
show logging
show log files
Example:
test-vos (config) # logging local notice
test-vos (config) # logging level cli commands notice
test-vos (config) # logging 123.54.10.12
test-vos (config) # logging 123.54.10.12 trap emerg
test-vos (config) # logging local override class mgmt-front priority info
test-vos (config) # logging 123.54.10.12 trap override class mgmt-front priority info
test-vos (config) # logging 123.54.10.12 trap none
test-vos (config) # logging receive
test-vos (config) # logging format standard
test-vos (config) # logging fields seconds enable
test-vos (config) # logging files rotation criteria frequency daily
test-vos (config) # logging files rotation max-num 12
test-vos (config) # logging files rotation force
test-vos (config) # logging files delete oldest 5
test-vos (config) # logging files upload current scp://joe@sv01/home/joe
Password: *******
test-vos (config) #
To make these configurations using the Management Console, go to the System Config tab, Logging page; see System Config > Logging for details.

Report an Error
Media Flow Controller Administrator's Guide and CLI Command Reference
Copyright © 2010 Juniper Networks, Inc.