Library Table of Contents Index Previous Page (Alt-p) Next Page (Alt-n) Comments

CIFS statistics

Command for displaying CIFS statistics  Top

You use the cifs stat command to display statistics about CIFS operations that take place on your filer. You use the cifs stat display for diagnostic purposes.

Syntax of the cifs stat command  Top

cifs stat [interval] [ -u user ] [ -h host ] [ -v[v] ] 
cifs stat -c
cifs stat -z

Options of the cifs stat command  Top

The following table describes the options of the cifs stat command.

Option

Description

None

If you do not specify any options, the command displays CIFS statistics that have accumulated since the last reboot.

interval

If you specify a time interval, the command displays CIFS statistics continuously. The interval specifies the number of seconds the command waits between updates.

-u user

Displays statistics for one or more user accounts. The reported values are the sum of all clients matching the specified user accounts. To use the -u option, you must have the cifs.per_client_stats.enable option turned on.

-h host

Displays statistics for one or more hosts. The reported values are the sum of all clients matching the specified hosts. To use the -h option, you must have the cifs.per_client_stats.enable option turned on.

-v[v]

If you are using the -u or -h option to display per-client statistics, you might want to use -v to display the number of clients for which statistics are being reported. -vv displays the actual clients as well as the number of clients. To use the -v[v] option, the cifs.per_client_stats.enable option must be turned on.

-c

Displays both blocking and nonblocking CIFS operations. The default is to show only blocking operations. You cannot use this option in conjunction with any of the options for displaying per-client statistics.

-z

Resets the operation counters to zero.

Example of cifs stat output with a specified interval  Top

The following command displays statistics every second:

cifs stat 1

 
    GetAttr   Read   Write   Lock   Open/Cl   Direct   Other
      175     142      54     70      254      643      50
      232      76     123     44      321      154      17
      152     120      34    111       12      435      76

The first line contains the statistics accumulated since the last boot. The following table describes the fields.

Field

Description

GetAttr

Attribute operations

Read

Read data operations

Write

Write data operations

Lock

Lock operations

Open/Cl

Open and close operations

Direct

Directory operations

Other

Other operations, such as deletes and logoffs

Troubleshooting and performance statistics  Top

The following table describes additional cifs stat output fields that are useful for troubleshooting and performance management.

Field

Description

Dup Disconnect

This variable counts the number of times that the Server Message Block (SMB) layer issues a session disconnect. Usually this indicates that the session termination was initiated by the filer.

FidHashAlloc

If a client tries to open more than the threshold number of files, Data ONTAP allocates a new hash table for the new file IDs. This variable counts the number of times this occurs.

FoldAttempts

The number of times Data ONTAP attempts to fold a file with the version in a snapshot. When a file is updated, typically only a subset of the file changes. So, only the changed parts of the file are actually written to disk if folding is enabled.

FoldDuplicates

The number of duplicate folds on the fold queue.

FoldOverflows

The number of times that the fold queue overflowed.

FoldRenameFailures

The number of times that a fold queue entry was unsuccessfully renamed.

FoldRenames

The number of times that an entry on the queue of files waiting for folding was renamed.

FoldWAFLTooBusy

The number of times that WAFL concurrent folds were exceeded.

Mapped Null User

The number of times a "null" or "blank" user was successfully mapped. This mapping is done only for IP addresses specified in the usermap.cfg file.

mBufWait

Each SMB request needs one or more mbufs. If an mbuf is not available, the request is not processed until one becomes available--that is, Data ONTAP waits for an mbuf. This variable counts the number of times Data ONTAP waits for mbufs to become available.

NBT Disconnect

The number of times that the NetBIOS layer issues a session disconnect. Usually, this indicates that the session termination was initiated by the client. NBT Disconnect can also occur when the filer's TCP/IP layer loses the connection to the client due to a networking problem between the filer and the client.

NoSupport

The number of times an unsupported SMB operation is attempted on the filer.

OpLkBkDelayedBreak

When an oplock break is sent too soon after an open request completes, some clients lock up. This variable counts the number of times that Data ONTAP must delay before sending an oplock break. The delay is controlled by the cifs.oplocks.opendelta option.

OpLkBkIgnoredAck

The number of times the filer ignores an oplock break acknowledgment sent from the client. For example, the filer might ignore an acknowledgment that is late.

OpLkBkNoBreakAck

The number of times there was a timeout due to no oplock break acknowledgment being sent by the client to the filer.

OpLkBkNoBreakAck95

The number of oplock break failures to acknowledge caused by Windows 95 clients.

OpLkBkNoBreakAckNT

The number of oplock break failures to acknowledge caused by Windows NT clients.

pBlkWait

A pBlk is the primary control block that holds the context for each SMB request that passes through Data ONTAP. If a pBlk is not available, the request is not processed until one becomes available--that is, Data ONTAP waits for a pBlk. This variable counts the number of times Data ONTAP waits for a pBlk to become available.

PDCupcalls

When a user attempts to map to the filer, Data ONTAP passes all information about the user to a domain controller. This variable counts the number of times Data ONTAP calls into domain controllers for user authentication.

SharingErrorRetries

The number of times an open request that conflicts with another open request is retried before Data ONTAP returns a sharing violation.

Short Msg Prevent

When the TCP stack in Windows NT 4, under high load with many outstanding operations, encounters a client bug that causes the TCP window to become zero and stay at zero, the session is lost. To prevent this situation, the filer implements the Nagle algorithm, which requires only full TCP packets to be transmitted even if it causes delays in transmission. This variable reports the number of CIFS sessions for which the Nagle algorithm has been used.

SMB Disconnect

The number of times the SMB layer issues a session disconnect. Usually, this indicates that the session termination was initiated by the filer.

When to enable per-client statistics  Top

You can enable the filer to collect per-client statistics at any time without restarting CIFS by turning on the cifs.per_client_stats.enable option. This option must be turned on to use the -u and -h options of the cifs stat command and to use the cifs top command. Turning this option on can noticeably affect filer performance. If this option is turned off, any existing per-client statistics are deleted.

Turning on the cifs.per_client_stats.enable option  Top

To turn on the cifs.per_client_stats.enable option, complete the following step.

Step

Action

1

Enter the following command:

options cifs.per_client_stats.enable on

Displaying CIFS client activity  Top

You use the cifs top command to display CIFS client activity, such as which clients are generating large amounts of load. Since this command relies on collected per-client statistics, the cifs.per_client_stats.enable option must be turned on.

The default output is a sorted list of clients, showing the number of I/Os, number and size of read and write requests, the number of "suspicious" events, and the IP address and user account of each client. A single client may have more than one entry if it is multiplexing multiple users on a single connection.

Syntax of the cifs top command  Top

The syntax of the cifs top command is as follows:

cifs top [-s sort] [-n maxclients] [-a avg] [-v]

Options for the cifs top command  Top

The following table describes the options for the cifs top command.

Option

Description

-s sort

Specifies how the client statistics are sorted.

Possible values for sort are the following, which can be abbreviated to their first character:

ops (o)--Sorts by the number of operations per second of any type

reads (r)--Sorts by kilobytes per second of data sent in response to read requests

writes (w)--Sorts by kilobytes per second of data written to the filer

ios (i)--Sorts by the combined total of reads plus writes for each client

suspicious (s)--Sorts by the number of suspicious events sent per second by each client

-n maxclients

Specifies the maximum number of top clients to display. The default is 20.

-a avg

Specifies how the statistics are averaged for display.

Possible values for avg are the following, which can be abbreviated to their first character:

smooth (s)--Uses a smooth average weighted towards recent behavior, but takes into account the client's previous history.

now (n)--Uses a one-second sample, taken immediately.

total (t)--Uses the total count of each statistic divided by the total time since sampling started. If the -v option is also used, the total count is displayed without division by the total sampling time.

-v

Displays detailed statistics.

What suspicious events are  Top

The following events are examples of "suspicious" events:

ACCESS_DENIED returned for FindFirst
ACCESS_DENIED returned for Open/CreateFile
ACCESS_DENIED returned for DeleteFile
SUCCESS returned for DeleteFile
SUCCESS returned for TruncateFile

Example of the cifs top command  Top

The following lines show the output of the cifs top command when you specify -n and -s.

cifs top -n 3 -s w
ops/s
reads
(n, KB/s)
writes
(n, KB/s)
suspect/s
IP
Name
263
29   215
137   627
      0
10.56.10.120
eng\jose
248
27   190
126   619
      1
10.56.10.120
eng\jill
246
26   195
125   616
     19
10.56.12.118
mktg\bob

Library Table of Contents Index Previous Page (Alt-p) Next Page (Alt-n) Comments