archive (All System Log Files)
Syntax
archive <files number> <size size> <start-time time> <transfer-interval interval> <binary-data | no-binary-data> <world-readable | no-world-readable>;
Description
Configure archiving properties for all system log files.
Options
files number
—Maximum number of archived log files to retain. When the Junos
OS logging utility has written a defined maximum amount of data to
a log file logfile, it closes the file, compresses it, and renames it 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 OS 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:
x k
to specify the number of kilobytes,x m
for the number of megabytes, orx g
for the number of gigabytes
Range: 64 KB through 1 GB
Default:
128 KB for EX Series switches
1 MB for M Series, MX Series, and T Series routers, OCX Series, and the QFX3500 switch, and SRX Series Firewalls and vSRX Virtual Firewall.
10 MB for TX Matrix and TX Matrix Plus routers
binary-data | no-binary-data
—Mark
file as containing binary data. This allows proper archiving of binary
files, such as WTMP files (login records for UNIX based systems)..
Default:
no-binary-data
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 OS 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.
Release Information
Statement introduced before Junos OS Release 7.4.