Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
 

Related Documentation

 

Configuring the Interface Profile

An interface profile specifies the information collected and written to a log file. You can configure a profile to collect error and statistic information for input and output packets on a particular physical or logical interface.

To configure an interface profile, include the interface-profile statement at the [edit accounting-options] hierarchy level:

[edit accounting-options]
interface-profile profile-name {fields {field-name;}file filename;interval minutes;}

By default, the Packet Forwarding Engine (PFE) periodically collects the statistics for all interfaces. To improve the performance, you can optionally disable the periodic refresh by including the periodic-refresh disable statement at the [edit accounting-options] hierarchy level.

Each accounting profile must have a unique profile-name. To apply a profile to a physical or logical interface, include the accounting-profile statement at either the [edit interfaces interface-name] or the [edit interfaces interface-name unit logical-unit-number] hierarchy level. You can also apply an accounting profile at the [edit firewall family family-type filter filter-name] hierarchy level.

To configure an interface profile, perform the tasks described in the following sections:

Configuring Fields

An interface profile must specify what statistics are collected. To configure which statistics should be collected for an interface, include the fields statement at the [edit accounting-options interface-profile profile-name] hierarchy level:

[edit accounting-options interface-profile profile-name]
fields {field-name;}

Configuring the File Information

Each accounting profile logs its statistics to a file in the /var/log directory.

To configure which file to use, include the file statement at the [edit accounting-options interface-profile profile-name] hierarchy level:

[edit accounting-options interface-profile profile-name]file filename;

You must specify a file statement for the interface profile that has already been configured at the [edit accounting-options] hierarchy level.

Configuring the Interval

Each interface with an accounting profile enabled has statistics collected once per interval time specified for the accounting profile. Statistics collection time is scheduled evenly over the configured interval. To configure the interval, include the interval statement at the [edit accounting-options interface-profile profile-name] hierarchy level:

[edit accounting-options interface-profile profile-name]interval minutes;

Note: The minimum interval allowed is 1 minute. Configuring a low interval in an accounting profile for a large number of interfaces might cause serious performance degradation.

The range for the interval statement is 1 through 2880 minutes. The default is 30 minutes.

Example: Configuring the Interface Profile

Configure the interface profile:

[edit]
accounting-options {file if_stats {size 40 files 5;}interface-profile if_profile1 {file if_stats;interval 30;fields {input-bytes;output-bytes;input-packets;output-packets;input-multicast;output-multicast;}}interface-profile if_profile2 {file if_stats;interval 30;fields {input-bytes;output-bytes;input-packets;output-packets;input-multicast;output-multicast;}}interfaces {xe-1/0/0 {accounting-profile if_profile1;unit 0 {accounting-profile if_profile2;...}}}}

The two interface profiles, if-profile1 and if-profile2, write data to the same file, if-stats. The if-stats file might look like the following:

#FILE CREATED 976823478 2000-12-14-19:51:18
#hostname host
#profile-layout if_profile2,epoch-timestamp,interface-name,snmp-index,input-bytes,output-bytes,
input-packets,output-packets,input-multicast,output-multicast
#profile-layout if_profile1,epoch-timestamp,interface-name,snmp-index,input-bytes,output-bytes,
input-packets
if_profile2,976823538,xe-1/0/0.0,8,134696815,3681534,501088,40723,0,0
if_profile1,976823538,xe-1/0/0,7,134696815,3681534,501088
...
#FILE CLOSED 976824378 2000-12-14-20:06:18
 

Related Documentation

 

Published: 2014-12-07

 

Related Documentation

 

Published: 2014-12-07