fileops Probes

The fileops provider probes fire on the successful completion of the operation. The probes available in the fileops provider are as follows:

Probe Description

chmod

Fires when the mode of a file is changed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the new file mode.

chown

Fires when the ownership of a file is changed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the user ID of the new owner of the file.

chgrp

Fires when the group ownership of a file is changed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the group ID of the new group owner of the file.chgrp

chgrp

Fires when the group ownership of a file is changed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the group ID of the new group owner of the file.

close

Fires when an open file is closed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation.

create

Fires when a file is created. The fileinfo_t structure corresponding to the new file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the mode of the new file.

link

Fires when a hard link is created to an existing file. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the fileinfo_t corresponding to the new link.

mkdir

Fires when a new directory is created. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the mode of the new directory.

open

Fires when an existing file is opened. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains open(2) flags.

When you call open(2) with theO_CREAT flag and the file does not exist, the fileops:::create probe will fire first on creation of the file.

read

Fires when a read is performed from an open file. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the file offset. args[3] contains the requested number of bytes. args[4] contains the actual number of bytes read.

readdir

Fires when a directory is read. The fileinfo_t structure corresponding to the directory is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the number of bytes read.

rename

Fires when a file is renamed. The fileinfo_t structure corresponding to the original file name is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the fileinfo_t corresponding to the new file name.

rmdir

Fires when a directory is removed. The fileinfo_t structure corresponding to the directory is pointed to by args[0]. args[1] contains the latency of the operation.

symlink

Fires when a symbolic link to a file is created. The fileinfo_t structure corresponding to the source file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the string representing the target of the symbolic link.

unlink

Fires when a link to an existing file is destroyed. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation.

write

Fires when a write is performed to an open file. The fileinfo_t structure corresponding to the file is pointed to by args[0]. args[1] contains the latency of the operation. args[2] contains the file offset. args[3] contains the requested number of bytes. args[4] contains the actual number of bytes actually written.

For more information, see io fileinfo_t Structure structure.