[an error occurred while processing this directive][an error occurred while processing this directive]

archive (All System Log Files)

Syntax

archive <files number> <size size <world-readable | no-world-readable>;

Hierarchy Level

[edit system syslog]

Release Information

Statement introduced before JUNOS Release 7.4.

Statement introduced in JUNOS Release 9.0 for EX Series switches.

Description

Configure archiving properties for all system log files.

Options

files number—Maximum number of archived log files to retain. When the JUNOS logging utility has written a defined maximum amount of data to a log file logfile, it closes the file, compresses it, and renames it to logfile.0.gz (the amount of data is determined by the size statement at this hierarchy level). The utility then opens and writes to a new file called logfile. When the new file reaches the maximum size, the logfile.0.gz file is renamed to logfile.1.gz, and the new file is closed, compressed, and renamed logfile.0.gz. By default, the logging facility creates up to ten archive files in this manner. Once the maximum number of archive files exists, each time the active log file reaches the maximum size, the contents of the oldest archive file are lost (overwritten by the next oldest file).

Range: 1 through 1000
Default: 10 files

size size—Maximum amount of data that the JUNOS logging utility writes to a log file logfile before archiving it (closing it, compressing it, and changing its name to logfile.0.gz). The utility then opens and writes to a new file called logfile.

Syntax: xk to specify the number of kilobytes, xm for the number of megabytes, or xg for the number of gigabytes
Range: 64 KB through 1 GB
Default: 128 KB for J Series routers; 1 MB for M Series, MX Series, and T Series routers; 10 MB for TX Matrix and TX Matrix Plus routers

world-readable | no-world-readable—Grant all users permission to read archived log files, or restrict the permission only to the root user and users who have the JUNOS maintenance permission.

Default: no-world-readable

Required Privilege Level

system—To view this statement in the configuration.

system-control—To add this statement to the configuration.


Published: 2010-04-26

[an error occurred while processing this directive]