2 .\" Copyright (C) 2001, Sun Microsystems, Inc. All Rights Reserved
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH NCAB2CLF 1 "Sep 28, 2001"
8 ncab2clf \- convert binary log file to Common Log File format
12 \fB/usr/bin/ncab2clf\fR [\fB-Dhv\fR] [\fB-i\fR \fIinput-file\fR] [\fB-o\fR \fIoutput-file\fR]
13 [\fB-b\fR \fIsize\fR] [\fB-n\fR \fInumber\fR] [\fB-s\fR \fIdatetime\fR]
19 The \fBncab2clf\fR command is used to convert the log file generated by the
20 Solaris Network Cache and Accelerator ("\fBNCA\fR") from binary format, to
21 Common Log File ("\fBCLF\fR") format. If no \fIinput-file\fR is specified,
22 \fBncab2clf\fR uses \fBstdin\fR. If no \fIoutput-file\fR is specified, the
23 output goes to \fBstdout\fR.
31 Specifies the binary-log-file blocking in kilobytes; the default is 64 Kbyte.
40 Specifies that direct \fBI/O\fR be disabled.
55 \fB\fB-i\fR \fIinput-file\fR\fR
58 Specifies the input file.
64 \fB\fB-n\fR \fInumber\fR\fR
67 Output \fInumber\fR CLF records.
73 \fB\fB-o\fR \fIoutput-file\fR\fR
76 Specifies the output file.
82 \fB\fB-s\fR \fIdatetime\fR\fR
85 Skip any records before the date and time specified in \fIdatetime\fR. You can
86 specify the date and time in CLF format or in the format specified by the
87 \fBtouch\fR(1) utility. CLF format is the dominant format, so \fBncab2clf\fR
88 first analyzes \fIdatetime\fR assuming CLF.
97 Provides verbose output.
102 \fBExample 1 \fRConverting a Binary File to a Common Log File Format
105 The following example converts the binary file \fB/var/nca/logs/nca.blf\fR to a
106 file \fB/var/nca/logs/nca.clf\fR, which is in Common Log File format.
111 example% \fBncab2clf -D -i /var/nca/logs/nca.blf -o /var/nca/logs/nca.clf\fR
117 \fBExample 2 \fRConverting Multiple Log Files
120 The following script may be used to convert multiple log files. The directory
121 designated by "\fB*\fR" must only contain log files.
129 ncab2clf -D < $filename > $filename.clf
135 \fBExample 3 \fRUsing \fB-s\fR and \fB-n\fR on a Raw Device
138 The following example shows how \fBncab2clf\fR can be used on a raw device. If
139 not using the \fB-n\fR option, the default is to convert all records from the
140 starting location to the end of the file. The date and time specified with
141 \fB-s\fR, below, is in CLF format.
146 example% ncab2clf -s '10/Apr/2001:09:23:13' -n 100 < /dev/dsk/c2t1d0s6
154 The following exit values are returned:
161 The file converted successfully
176 See \fBattributes\fR(5) for descriptions of the following attributes:
184 ATTRIBUTE TYPE ATTRIBUTE VALUE
186 Interface Stability Evolving
192 \fBnca\fR(1), \fBncakmod\fR(1), \fBnca.if\fR(4), \fBncakmod.conf\fR(4),
193 \fBncalogd.conf\fR(4), \fBattributes\fR(5)
196 \fISystem Administration Guide: IP Services\fR
200 The binary log files generated by \fBNCA\fR can become very large. When
201 converting these large binary files, use the \fB-b\fR option to the
202 \fBncab2clf\fR command to help performance.
205 Direct \fBI/O\fR is a benefit to the user if the data being written does not
206 come in as large chunks. However, if the user wishes to convert the log file in
207 large chunks using the \fB-b\fR option, then direct \fBI/O\fR should be
208 disabled by using the \fB-D\fR option.