From b3234491c1bf5e845a16f33f6f2c4dffd2bf6a77 Mon Sep 17 00:00:00 2001 From: William Cohen Date: Mon, 15 Dec 2008 16:14:05 -0500 Subject: Minor editing for example scripts. --- .../en-US/Useful_Scripts-inodewatch.xml | 11 +++++++---- .../en-US/Useful_Scripts-sockettrace.xml | 2 +- .../en-US/Useful_Scripts-traceio2.xml | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) (limited to 'doc/SystemTap_Beginners_Guide/en-US') diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml index 098524ae..47cc4e16 100644 --- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml +++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml @@ -59,7 +59,8 @@ no script in examples need to add references to sources/man pages that explain how "dev_nr = $file->f_dentry->d_inode->i_sb->s_dev" and "($1 << 20 | $2)". - takes the following information about the file as an argument: + takes the following information about the +file as arguments on the command line: script examples file device number (integer format) @@ -81,7 +82,9 @@ no script in examples - The file's device number, in integer format. When this is passed to the script as the first argument, be sure to replace any 0 with a space. + The file's major device number. + + The file's minor device number. The file's inode number. @@ -121,9 +124,9 @@ no script in examples examples of SystemTap scripts -805 is the device number, while 1078319 is the inode number. To start monitoring /etc/crontab, run stap inodewatch.stp 8 5 1078319. +805 is the base-16 (hexadecimal) device number. The lower two digits are the minor device number and the upper digits are the major number. 1078319 is the inode number. To start monitoring /etc/crontab, run stap inodewatch.stp 0x8 0x05 1078319 (The 0x prefixes indicate base-16 values. -The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. vfs_read or vfs_write), the device number (in hex format), and the inode number. contains the output of stap inodewatch.stp 8 5 1078319 (when cat /etc/crontab is executed while the script is running) : +The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. vfs_read or vfs_write), the device number (in hex format), and the inode number. contains the output of stap inodewatch.stp 0x8 0x05 1078319 (when cat /etc/crontab is executed while the script is running) : diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml index 9a9e1c55..6e913b48 100644 --- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml +++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml @@ -51,7 +51,7 @@ socket-trace.stp - + diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml index 4fc7ecc2..7451de98 100644 --- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml +++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml @@ -50,7 +50,7 @@ - traceio2-simple.stp + traceio2.stp -- cgit