]> sourceware.org Git - systemtap-htdocs.git/commitdiff
Update SystemTap Beginners Guide (both html and pdf versions)
authorwcohen <wcohen>
Wed, 22 Dec 2010 18:46:31 +0000 (18:46 +0000)
committerwcohen <wcohen>
Wed, 22 Dec 2010 18:46:31 +0000 (18:46 +0000)
91 files changed:
SystemTap_Beginners_Guide.pdf
SystemTap_Beginners_Guide/Common_Content/css/common.css
SystemTap_Beginners_Guide/Common_Content/css/lang.css [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/css/overrides.css
SystemTap_Beginners_Guide/Common_Content/css/print.css [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/24.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/24.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/25.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/25.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/26.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/26.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/27.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/27.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/28.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/28.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/29.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/29.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/30.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/30.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/31.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/31.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/32.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/32.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/33.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/33.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/34.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/34.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/35.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/35.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/36.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/36.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/37.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/37.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/38.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/38.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/39.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/39.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/40.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/40.svg [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/green.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/red.png [new file with mode: 0644]
SystemTap_Beginners_Guide/Common_Content/images/yellow.png [new file with mode: 0644]
SystemTap_Beginners_Guide/SystemTap_Beginners_Guide-Preface.html
SystemTap_Beginners_Guide/appe-Publican-Revision_History.html
SystemTap_Beginners_Guide/arrayoperators.html
SystemTap_Beginners_Guide/arrayops-aggregates.html
SystemTap_Beginners_Guide/arrayops-conditionals.html
SystemTap_Beginners_Guide/arrayops-deleting.html
SystemTap_Beginners_Guide/arrayops-foreach.html
SystemTap_Beginners_Guide/arrayops-increment.html
SystemTap_Beginners_Guide/arrayops-readvalues.html
SystemTap_Beginners_Guide/associativearrays.html
SystemTap_Beginners_Guide/commandlineargssect.html
SystemTap_Beginners_Guide/cross-compiling.html
SystemTap_Beginners_Guide/errors.html
SystemTap_Beginners_Guide/futexcontentionsect.html
SystemTap_Beginners_Guide/handlerconditionalstatements.html
SystemTap_Beginners_Guide/index.html
SystemTap_Beginners_Guide/inodewatch2sect.html
SystemTap_Beginners_Guide/inodewatchsect.html
SystemTap_Beginners_Guide/intro-systemtap-vs-others.html
SystemTap_Beginners_Guide/introduction.html
SystemTap_Beginners_Guide/ioblktimesect.html
SystemTap_Beginners_Guide/iotimesect.html
SystemTap_Beginners_Guide/ix01.html
SystemTap_Beginners_Guide/mainsect-disk.html
SystemTap_Beginners_Guide/mainsect-profiling.html
SystemTap_Beginners_Guide/paracallgraph.html
SystemTap_Beginners_Guide/pr01s02.html
SystemTap_Beginners_Guide/references.html
SystemTap_Beginners_Guide/runtimeerror.html
SystemTap_Beginners_Guide/scriptconstructions.html
SystemTap_Beginners_Guide/scripts.html
SystemTap_Beginners_Guide/syscallsbyprocpidsect.html
SystemTap_Beginners_Guide/systemtapscript-handler.html
SystemTap_Beginners_Guide/targetavailable.html [new file with mode: 0644]
SystemTap_Beginners_Guide/targetvariables.html [new file with mode: 0644]
SystemTap_Beginners_Guide/threadtimessect.html
SystemTap_Beginners_Guide/timeoutssect.html
SystemTap_Beginners_Guide/topsyssect.html
SystemTap_Beginners_Guide/traceio2sect.html
SystemTap_Beginners_Guide/traceiosect.html
SystemTap_Beginners_Guide/typecasting.html [new file with mode: 0644]
SystemTap_Beginners_Guide/understanding-how-systemtap-works.html
SystemTap_Beginners_Guide/understanding-tapsets.html
SystemTap_Beginners_Guide/useful-systemtap-scripts.html
SystemTap_Beginners_Guide/userspace-probing.html [new file with mode: 0644]
SystemTap_Beginners_Guide/using-systemtap.html
SystemTap_Beginners_Guide/using-usage.html
SystemTap_Beginners_Guide/ustack.html [new file with mode: 0644]
SystemTap_Beginners_Guide/utargetvariable.html [new file with mode: 0644]

index dfd9e3fd481e14d802f5a7c2e9e1786226b27582..5a34ecf4d6727139aa05c6b75e0fb4af0b0db80c 100644 (file)
Binary files a/SystemTap_Beginners_Guide.pdf and b/SystemTap_Beginners_Guide.pdf differ
index cfb3f3ec3242e56b02e6d916172827a154e01ffd..f9603b70c7ba85f8bb704e9d0490b23e948c6aca 100644 (file)
@@ -16,7 +16,7 @@ body.toc_embeded {
        margin-left: 300px;
 }
 
-object.toc {
+object.toc, iframe.toc {
        /*for web hosting system only*/
        border-style:none;
        position:fixed;
@@ -29,6 +29,27 @@ object.toc {
        border-right:1px solid #999;
 }
 
+/* Hide web menu */
+
+body.notoc {
+       margin-left: 3em;
+}
+
+iframe.notoc {
+       border-style:none;
+       border: none;
+       padding: 0em;
+       position:fixed;
+       width: 21px;
+       height: 29px;
+       top: 0px;
+       left:0;
+       overflow: hidden;
+       margin: 0em;
+       margin-left: -3px;
+}
+/* End hide web menu */
+
 /* desktop styles */
 body.desktop {
        margin-left: 26em;
@@ -50,7 +71,8 @@ body.desktop .book > .toc {
        line-height:1.35em;
 }
 
-.toc .chapter, .toc .appendix, .toc .glossary {
+.toc .glossary,
+.toc .chapter, .toc .appendix {
        margin-top:1em;
 }
 
@@ -59,7 +81,8 @@ body.desktop .book > .toc {
        display:block;
 }
 
-span.appendix, span.glossary {
+span.glossary,
+span.appendix {
        display:block;
        margin-top:0.5em;
 }
@@ -80,6 +103,10 @@ p, div.para, div.formalpara {
 }
 
 /*Links*/
+a {
+       outline: none;
+}
+
 a:link {
        text-decoration:none;
        border-bottom: 1px dotted ;
@@ -219,10 +246,6 @@ hr {
        margin-top: 3em;
 }
 
-sup {
-       color:#999;
-}
-
 /* web site rules */
 ul.languages, .languages li {
        display:inline;
@@ -255,16 +278,6 @@ ul.languages {
 /*supporting stylesheets*/
 
 /*unique to the webpage only*/
-.article ul {
-       padding-left:2em;
-       list-style: disc;
-}
-
-.article li {
-       margin:0em;
-       padding-left:0em;
-}
-
 .books {
        position:relative;
 }
@@ -356,7 +369,6 @@ a.version:focus, a.version:hover {
        clear:both;
 }
 
-
 /*revision history*/
 .revhistory {
        display:block;
@@ -372,32 +384,24 @@ a.version:focus, a.version:hover {
 }
 
 .revhistory td {
-       text-align:right;
+       text-align :left;
        padding:0em;
+       border: none;
        border-top: 1px solid #fff;
+       font-weight: bold;
 }
 
-
-.revhistory tr td:first-child {
-       text-align:left;
+.revhistory .simplelist td {
+       font-weight: normal;
 }
 
-.revhistory tr td p, .revhistory tr td div.para {
-       text-align:left;
-       font-weight:bold;
-       display:block;
-       margin:0em;
-       padding:0em;
-       padding-bottom:0.7em;
-       border-bottom:1px solid #eee;
+.revhistory .simplelist {
+       margin-bottom: 1.5em;
+       margin-left: 1em;
 }
 
 .revhistory table th {
-       background-color:transparent;
-       color:#336699;
-       font-size:2em;
-       padding: 1em 0em;
-       border-bottom:1px solid #eee;
+       display: none;
 }
 
 
@@ -635,7 +639,7 @@ li p, li div.para {
 /*images*/
 img {
        display:block;
-       margin:2em 0;
+       margin: 2em 0;
 }
 
 .inlinemediaobject, .inlinemediaobject img {
@@ -672,27 +676,38 @@ img {
 }
 
 .prompt {
-       background-color:#ede7c8;
        padding:0em .3em;
 }
 
 /*user interface styles*/
 .screen .replaceable {
-       color:#444;
 }
 
 .guibutton, .guilabel {
-       font-family:"liberation mono", "bitstream vera mono", "dejavu mono", monospace;
-       font-weight:bold;
-       white-space:nowrap;
+       font-family: "liberation mono", "bitstream vera mono", "dejavu mono", monospace;
+       font-weight: bold;
+       white-space: nowrap;
 }
 
 .example {
-       background-color:#dc9f2e;
-       padding:5px;
-       margin-bottom:10px;
+       background-color: #ffffff;
+       border-left: 3px solid #aaaaaa;
+       padding-top: 1em;
+       padding-bottom: 0.1em;
 }
 
+.example h6 {
+       padding-left: 10px;
+}
+
+.example-contents {
+       padding-left: 10px;
+       background-color: #ffffff;
+}
+
+.example-contents .para {
+/*      padding: 10px;*/
+}
 
 /*terminal/console text*/
 .computeroutput, 
@@ -711,10 +726,17 @@ img {
        font-weight:bold;
 }
 
+/* no bold in toc */
+.toc * {
+       font-weight: inherit;
+}
+
 pre {
        font-family:"liberation mono", "bitstream vera mono", "dejavu mono", monospace;
        display:block;
-       background-color:#eeeeee;
+       background-color: #f5f5f5;
+       color: #000000;
+       border: 1px solid #aaaaaa;
        margin-bottom: 0.3em;
        padding:.5em 1em;
        white-space: pre-wrap; /* css-3 */
@@ -727,7 +749,6 @@ pre {
 
 pre .replaceable, 
 pre .keycap {
-       color:white;
 }
 
 code {
@@ -736,93 +757,99 @@ code {
        font-weight:bold;
 }
 
-/*Notifications*/
-div.note, div.important, div.warning {
-       padding:1em;
-       padding-bottom:20px;
-       margin-top:.5em;
-       margin-bottom:1.5em;
-       background-repeat:no-repeat;
-       background-position:1em 1em;
-}
-
-div.note pre, div.important pre, div.warning pre {
-       background-color: #333;
-       color: white;
-       margin-left: 4.5em;
-}
-
-
-div.note {
-       background-image:url(../images/note.png);
-       background-color:#8e9f00;
-       color:white;
-}
-
-div.important  {
-       background-color:#d08e13;
-       color:white;
-       background-image:url(../images/important.png);
+.parameter code {
+       display: inline;
+       white-space: pre-wrap; /* css-3 */
+       white-space: -moz-pre-wrap !important; /* Mozilla, since 1999 */
+       white-space: -pre-wrap; /* Opera 4-6 */
+       white-space: -o-pre-wrap; /* Opera 7 */
+       word-wrap: break-word; /* Internet Explorer 5.5+ */
 }
 
-div.warning {
-       background-color:#9e292b;
-       color:white;
-       background-image:url(../images/warning.png);
+/*Notifications*/
+div.warning:before {
+       content:url(../images/warning.png);
+       padding-left: 5px;
 }
 
-
-/* Admonition Headings */
-div.note h2, div.important h2, div.warning h2 {
-       height:32px;
-       font-size:1.3em;
+div.note:before {
+       content:url(../images/note.png);
+       padding-left: 5px;
 }
 
-div.note h2, div.important h2, div.warning h2 {
-       color:white;
+div.important:before {
+       content:url(../images/important.png);
+       padding-left: 5px;
 }
 
-/* Admonition Inlines */
-div.note .replaceable, div.important .replaceable,  div.warning .replaceable {
-       color:#e3dcc0;
+div.warning, div.note, div.important {
+       color: black;
+       margin: 0em;
+       padding: 0em;
+       background: none;
+       background-color: white;
+       margin-bottom: 1em;
+       border-bottom: 1px solid #aaaaaa;
 }
 
-pre .replaceable, tt .replaceable {
-       color:#444;
+div.warning h2, div.note h2,div.important h2 {
+       margin: 0em;
+       padding: 0em;
+       color: #eeeeec;
+       padding-top: 0px;
+       padding-bottom: 0px;
+       height: 1.4em;
+       line-height: 1.4em;
+       font-size: 1.4em;
+       display:inline;
 }
 
-div.note .guilabel, div.important .guilabel, div.warning .guilabel {
-       color:#e3dcc0;
+div.admonition_header {
+       clear: both;
+       margin: 0em;
+       padding: 0em;
+       margin-top: -3.3em;
+       padding-left: 58px;
+       line-height: 1.0em;
+       font-size: 1.0em;
 }
 
-
-/* Admonition Lists ... really? */
-div.note li, div.warning li, div.important li {
-       padding-left:10px;
-       margin:0em;
+div.warning div.admonition_header {
+       background: url(../images/red.png) top left repeat-x;
+       background-color: #590000;
 }
 
-div.note ul, div.warning ul, div.important ul {
-       padding-left:40px;
-       margin:0em;
+div.note div.admonition_header {
+       background: url(../images/green.png) top right repeat-x;
+       background-color: #597800;
 }
 
-/* Admonition links in verbatim ... *really* */
-div.note pre pre a:visited, div.important pre pre a:visited, 
- div.warning pre pre a:visited, div.note pre a:link, div.important pre a:link, div.warning pre a:link {
-       color:#0066cc;
+div.important div.admonition_header {
+       background: url(../images/yellow.png) top right repeat-x;
+       background-color: #a6710f;
 }
 
-/* Admonition links */
-div.note a:visited, div.important a:visited, div.warning a:visited, div.note a:link , div.important a:link , div.warning a:link {
-       color:#f7f2d0;
+div.warning p, div.warning div.para,
+div.note p, div.note div.para,
+div.important p, div.important div.para {
+       padding: 0em;
+       margin: 0em;
 }
 
-/*notification icons*/
-div.note h2, div.note p, div.note div.para, div.warning h2, div.warning p, div.warning div.para, div.important h2, .important p, .important div.para {
+div.admonition {
+       border: none;
+       border-left: 1px solid #aaaaaa;
+       border-right: 1px solid #aaaaaa;
        padding:0em;
        margin:0em;
-       padding-left:56px;
+       padding-top: 1.5em;
+       padding-bottom: 1em;
+       padding-left: 2em;
+       padding-right: 1em;
+       background-color: #eeeeec;
+       -moz-border-radius: 0px;
+       -webkit-border-radius: 0px;
+       border-radius: 0px;
 }
 
 /*Page Title*/
@@ -836,7 +863,6 @@ div.note h2, div.note p, div.note div.para, div.warning h2, div.warning p, div.w
 #title a.left{
        display:inline;
        border:none;
-       padding-left:200px;
 }
 
 #title a.left img{
@@ -854,6 +880,7 @@ div.note h2, div.note p, div.note div.para, div.warning h2, div.warning p, div.w
        border:none;
        float:right;
        margin:0em;
+       margin-top:.7em;
 }
 
 /*Table*/
@@ -892,6 +919,11 @@ table th div.para:first-child, table td div.para:first-child, table  li div.para
 th, td {
        border-style:none;
        vertical-align: top;
+       border: 1px solid #000;
+}
+
+.simplelist th, .simplelist td {
+       border: none;
 }
 
 table table td {
@@ -957,6 +989,10 @@ span.chapter {
        margin-top:0.5em;
 }
 
+table.simplelist td, .calloutlist table td {
+       border-style: none;
+}
+
 /*Breadcrumbs*/
 #breadcrumbs ul li.first:before {
        content:" ";
@@ -1000,7 +1036,8 @@ span.chapter {
        margin-bottom:1em;
 }
 
-.glossary dt, .index dt {
+.glossary dt,
+.index dt {
        color:#444;
        padding-top:.5em;
 }
@@ -1019,20 +1056,20 @@ span.chapter {
 
 /*changes*/
 .footnote {
-       padding:.2em 1em;
-       background-color:#c8c5ac;
        font-size: .7em;
        margin:0em;
-       margin-bottom:.5em;
        color:#222;
 }
 
 table .footnote {
-       margin:1em .5em;
 }
 
 sup {
-       padding:0em .3em;
+       color:#999;
+       margin:0em;
+       padding:0em;
+       line-height: .4em;
+       font-size: 1em;
        padding-left:0em;
 }
 
@@ -1053,12 +1090,11 @@ sup {
 }
 
 .footnote:hover sup a {
-       color:#fff;
        text-decoration:none;
 }
 
 .footnote p,.footnote div.para {
-       padding-left:5em;
+       padding-left:2em;
 }
 
 .footnote a:link, 
@@ -1067,7 +1103,6 @@ sup {
 }
 
 .footnote a:hover {
-       color:white;
 }
 
 /**/
@@ -1086,7 +1121,6 @@ div.note .keycap,
 div.important .keycap, 
 div.warning .keycap
 {
-       color:white;
 }
 
 ul li p:last-child, ul li div.para:last-child {
@@ -1337,7 +1371,7 @@ div.progress span.fuzzy {
        padding-right:.5em;
 }
 
-.results h2, .results h3{
+.results h2, .results h3 {
        display:inline;
        padding-right:.5em;
        font-size:10pt;
@@ -1363,20 +1397,16 @@ pre {
 }
 
 .example {
-       -moz-border-radius:15px;
-       -webkit-border-radius:15px;
-       border-radius: 15px;
-}
-
-.term{
-       color:#336699;
+       -moz-border-radius:0px;
+       -webkit-border-radius:0px;
+       border-radius: 0px;
 }
 
 .package, .citetitle {
        font-style: italic;
 }
 
-.edition {
+.titlepage .edition {
        color: #336699;
        background-color: transparent;
        margin-top: 1em;
@@ -1454,6 +1484,7 @@ div.toc > dl > dt {
        margin: 0em;
        width: 12pt;
        display: inline;
+       vertical-align: middle;
 }
 
 .stepalternatives {
@@ -1461,3 +1492,4 @@ div.toc > dl > dt {
        list-style-type: none;
 }
 
+
diff --git a/SystemTap_Beginners_Guide/Common_Content/css/lang.css b/SystemTap_Beginners_Guide/Common_Content/css/lang.css
new file mode 100644 (file)
index 0000000..81c3115
--- /dev/null
@@ -0,0 +1,2 @@
+/* place holder */
+
index db64f48e839f93dbc59e62a2405acd4ff60d7ddc..895173d5533981d22c23fb32bc08ed779ece32ba 100644 (file)
@@ -41,10 +41,6 @@ table tr.even td {
        background-color:#f5f5f5;
 }
 
-.term{
-       color:#3c6eb4
-}
-
 .revhistory table th {
        color:#3c6eb4;
 }
diff --git a/SystemTap_Beginners_Guide/Common_Content/css/print.css b/SystemTap_Beginners_Guide/Common_Content/css/print.css
new file mode 100644 (file)
index 0000000..773d8ae
--- /dev/null
@@ -0,0 +1,16 @@
+@import url("common.css");
+@import url("overrides.css");
+@import url("lang.css");
+
+#tocframe {
+       display: none;
+}
+
+body.toc_embeded {
+       margin-left: 30px;
+}
+
+.producttitle {
+       color: #336699;
+}
+
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/24.png b/SystemTap_Beginners_Guide/Common_Content/images/24.png
new file mode 100644 (file)
index 0000000..863ce3b
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/24.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/24.svg b/SystemTap_Beginners_Guide/Common_Content/images/24.svg
new file mode 100644 (file)
index 0000000..27e1d39
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.803816,19.493301 -1.460938,0 0,2.515137 -2.498535,0 0,-2.515137 -5.013672,0 0,-1.784668 5.154785,-7.8359371 2.357422,0 0,7.6284181 1.460938,0 0,1.992187 m -3.959473,-1.992187 0,-2.058594 c -5e-6,-0.07193 -5e-6,-0.17431 0,-0.307129 0.0055,-0.138339 0.01106,-0.293287 0.0166,-0.464844 0.0055,-0.171541 0.01106,-0.348625 0.0166,-0.53125 0.01106,-0.182609 0.01936,-0.356925 0.0249,-0.522949 0.01106,-0.166007 0.01936,-0.309887 0.0249,-0.43164 0.01106,-0.12727 0.01936,-0.218579 0.0249,-0.273926 l -0.07471,0 c -0.09961,0.232431 -0.213058,0.478687 -0.340332,0.738769 -0.121749,0.2601 -0.262862,0.520191 -0.42334,0.780274 l -2.02539,3.071289 2.755859,0"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/25.png b/SystemTap_Beginners_Guide/Common_Content/images/25.png
new file mode 100644 (file)
index 0000000..cc23b9b
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/25.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/25.svg b/SystemTap_Beginners_Guide/Common_Content/images/25.svg
new file mode 100644 (file)
index 0000000..114e1a2
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 20.761335,14.255508 c 0.520177,8e-6 1.004389,0.08025 1.452637,0.240723 0.448235,0.160489 0.838372,0.395678 1.17041,0.705566 0.332024,0.309903 0.592114,0.697272 0.780274,1.16211 0.188142,0.459315 0.282218,0.987797 0.282226,1.585449 -8e-6,0.658532 -0.102385,1.250654 -0.307129,1.776367 -0.20476,0.520184 -0.506355,0.962892 -0.904785,1.328125 -0.398444,0.359701 -0.893724,0.636394 -1.48584,0.830078 -0.586594,0.193685 -1.261723,0.290528 -2.02539,0.290528 -0.304366,0 -0.605961,-0.01384 -0.904785,-0.0415 -0.298831,-0.02767 -0.586591,-0.06917 -0.863282,-0.124512 -0.27116,-0.04981 -0.531251,-0.116211 -0.780273,-0.199219 -0.243491,-0.08301 -0.464845,-0.17985 -0.664063,-0.290527 l 0,-2.216309 c 0.193684,0.11068 0.417805,0.215823 0.672364,0.31543 0.254555,0.09408 0.517413,0.177086 0.788574,0.249024 0.27669,0.06641 0.553383,0.121746 0.830078,0.166015 0.276689,0.03874 0.539547,0.05811 0.788574,0.05811 0.741532,2e-6 1.305985,-0.152179 1.69336,-0.456543 0.387364,-0.309893 0.581048,-0.799639 0.581054,-1.469239 -6e-6,-0.597651 -0.190924,-1.051427 -0.572754,-1.361328 -0.376307,-0.315424 -0.960128,-0.473139 -1.751464,-0.473144 -0.143884,5e-6 -0.298832,0.0083 -0.464844,0.0249 -0.160485,0.01661 -0.320967,0.03874 -0.481446,0.06641 -0.15495,0.02768 -0.304364,0.05811 -0.448242,0.09131 -0.143882,0.02767 -0.268394,0.05811 -0.373535,0.09131 l -1.020996,-0.547852 0.456543,-6.1840821 6.408203,0 0,2.1748051 -4.183594,0 -0.199218,2.382324 c 0.177079,-0.03873 0.381832,-0.07747 0.614257,-0.116211 0.237952,-0.03873 0.542314,-0.0581 0.913086,-0.05811"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/26.png b/SystemTap_Beginners_Guide/Common_Content/images/26.png
new file mode 100644 (file)
index 0000000..583fe34
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/26.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/26.svg b/SystemTap_Beginners_Guide/Common_Content/images/26.svg
new file mode 100644 (file)
index 0000000..e9b5d23
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 16.428328,16.853653 c -1e-6,-0.581049 0.03044,-1.159336 0.09131,-1.734863 0.06641,-0.575514 0.17985,-1.126132 0.340332,-1.651856 0.166015,-0.531241 0.387369,-1.023753 0.664063,-1.477539 0.282224,-0.453765 0.636391,-0.846669 1.0625,-1.178711 0.431637,-0.337553 0.946285,-0.600411 1.543945,-0.788574 0.603185,-0.1936727 1.305984,-0.2905151 2.108398,-0.2905274 0.116205,1.23e-5 0.243483,0.00278 0.381836,0.0083 0.13834,0.00555 0.276686,0.013847 0.415039,0.024902 0.143873,0.00555 0.282219,0.016614 0.415039,0.033203 0.132805,0.016614 0.251783,0.035982 0.356934,0.058105 l 0,2.0502924 c -0.210294,-0.04979 -0.434415,-0.08853 -0.672363,-0.116211 -0.232429,-0.03319 -0.467618,-0.04979 -0.705567,-0.0498 -0.747076,1e-5 -1.361333,0.09408 -1.842773,0.282226 -0.48145,0.182627 -0.863285,0.439951 -1.145508,0.771973 -0.28223,0.33204 -0.484215,0.730477 -0.605957,1.195312 -0.116214,0.464852 -0.188154,0.9795 -0.21582,1.543946 l 0.09961,0 c 0.110674,-0.199212 0.243487,-0.384596 0.398438,-0.556153 0.160478,-0.177076 0.345862,-0.32649 0.556152,-0.448242 0.210282,-0.127271 0.445471,-0.22688 0.705566,-0.298828 0.265621,-0.07193 0.561681,-0.107902 0.888184,-0.10791 0.52571,8e-6 0.998854,0.08578 1.419434,0.257324 0.420565,0.171557 0.774732,0.42058 1.0625,0.74707 0.293286,0.326504 0.517407,0.727708 0.672363,1.203614 0.154939,0.475916 0.232413,1.021 0.232422,1.635254 -9e-6,0.658532 -0.09408,1.247887 -0.282227,1.768066 -0.182625,0.520184 -0.445483,0.962892 -0.788574,1.328125 -0.343106,0.359701 -0.758145,0.636394 -1.245117,0.830078 -0.486985,0.188151 -1.034836,0.282227 -1.643555,0.282227 -0.59766,0 -1.156579,-0.105144 -1.676758,-0.31543 -0.520185,-0.21582 -0.97396,-0.542317 -1.361328,-0.979492 -0.381837,-0.437173 -0.683432,-0.987791 -0.904785,-1.651856 -0.215821,-0.669593 -0.323731,-1.460933 -0.32373,-2.374023 m 4.216796,3.270508 c 0.226883,2e-6 0.431636,-0.0415 0.614258,-0.124512 0.188146,-0.08854 0.348627,-0.218585 0.481446,-0.390137 0.13834,-0.17708 0.243483,-0.398434 0.315429,-0.664062 0.07747,-0.265622 0.116205,-0.581051 0.116211,-0.946289 -6e-6,-0.592118 -0.124518,-1.056961 -0.373535,-1.394531 -0.243495,-0.343094 -0.61703,-0.514643 -1.120605,-0.514649 -0.254562,6e-6 -0.486984,0.04981 -0.697266,0.149414 -0.21029,0.09962 -0.390141,0.229661 -0.539551,0.390137 -0.149417,0.160487 -0.265628,0.340337 -0.348633,0.539551 -0.07748,0.199223 -0.116214,0.401209 -0.116211,0.605957 -3e-6,0.28223 0.0332,0.564456 0.09961,0.846679 0.07194,0.276696 0.17708,0.528486 0.315429,0.755371 0.143877,0.221357 0.318193,0.401207 0.52295,0.539551 0.210282,0.138349 0.453771,0.207522 0.730468,0.20752"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/27.png b/SystemTap_Beginners_Guide/Common_Content/images/27.png
new file mode 100644 (file)
index 0000000..d1c3dfa
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/27.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/27.svg b/SystemTap_Beginners_Guide/Common_Content/images/27.svg
new file mode 100644 (file)
index 0000000..4a80177
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 17.51573,22.008438 4.316406,-9.960937 -5.578125,0 0,-2.1582035 8.367188,0 0,1.6103515 -4.424317,10.508789 -2.681152,0"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/28.png b/SystemTap_Beginners_Guide/Common_Content/images/28.png
new file mode 100644 (file)
index 0000000..f5db747
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/28.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/28.svg b/SystemTap_Beginners_Guide/Common_Content/images/28.svg
new file mode 100644 (file)
index 0000000..d453f29
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 20.48741,9.7149811 c 0.503575,1.23e-5 0.979486,0.060885 1.427734,0.1826172 0.448236,0.1217567 0.841139,0.3043737 1.178711,0.5478517 0.337557,0.243501 0.605949,0.547862 0.805176,0.913086 0.19921,0.365244 0.298819,0.794118 0.298828,1.286621 -9e-6,0.365243 -0.05535,0.697274 -0.166016,0.996094 -0.110685,0.293302 -0.262866,0.561694 -0.456543,0.805175 -0.193692,0.237963 -0.423347,0.451017 -0.688965,0.639161 -0.265631,0.188157 -0.553392,0.359707 -0.863281,0.514648 0.320957,0.171556 0.63362,0.362473 0.937988,0.572754 0.309889,0.210292 0.583814,0.448247 0.821778,0.713867 0.237947,0.260096 0.428865,0.55339 0.572754,0.879883 0.143871,0.326501 0.215811,0.691735 0.21582,1.095703 -9e-6,0.503583 -0.09962,0.960126 -0.298828,1.369629 -0.199227,0.409506 -0.478687,0.758139 -0.838379,1.045898 -0.359708,0.287761 -0.791348,0.509115 -1.294922,0.664063 -0.498053,0.154948 -1.048671,0.232422 -1.651855,0.232422 -0.652999,0 -1.234053,-0.07471 -1.743164,-0.224121 -0.509117,-0.149414 -0.937991,-0.362467 -1.286622,-0.639161 -0.348634,-0.276691 -0.614258,-0.617023 -0.796875,-1.020996 -0.177084,-0.403969 -0.265625,-0.857744 -0.265625,-1.361328 0,-0.415035 0.06087,-0.78857 0.182618,-1.120605 0.121744,-0.332027 0.287759,-0.630855 0.498046,-0.896485 0.210285,-0.265619 0.456542,-0.500808 0.73877,-0.705566 0.282224,-0.204747 0.583819,-0.384597 0.904785,-0.539551 -0.271161,-0.171543 -0.525718,-0.356927 -0.763672,-0.556152 -0.237957,-0.204746 -0.445477,-0.428866 -0.622558,-0.672363 -0.171551,-0.249016 -0.309897,-0.522942 -0.415039,-0.821778 -0.09961,-0.298819 -0.149415,-0.628083 -0.149414,-0.987793 -1e-6,-0.481435 0.09961,-0.902008 0.298828,-1.261718 0.204751,-0.365224 0.478676,-0.669585 0.821777,-0.913086 0.343097,-0.249012 0.738767,-0.434396 1.187012,-0.5561527 0.448238,-0.1217326 0.918615,-0.1826049 1.411133,-0.1826172 m -1.718262,9.0644529 c -3e-6,0.221357 0.03597,0.42611 0.10791,0.614258 0.07194,0.18262 0.17708,0.340334 0.31543,0.473145 0.143876,0.132814 0.32096,0.237957 0.53125,0.315429 0.210282,0.07194 0.453771,0.107912 0.730468,0.10791 0.58105,2e-6 1.015457,-0.135577 1.303223,-0.406738 0.287754,-0.27669 0.431634,-0.639157 0.431641,-1.087402 -7e-6,-0.232419 -0.04981,-0.439938 -0.149414,-0.622559 -0.09408,-0.188147 -0.218594,-0.359696 -0.373535,-0.514648 -0.14942,-0.160478 -0.32097,-0.307125 -0.514649,-0.439942 -0.19369,-0.132807 -0.387375,-0.260086 -0.581055,-0.381836 L 20.3878,16.72084 c -0.243494,0.12175 -0.464848,0.254563 -0.664062,0.398438 -0.199223,0.138351 -0.370772,0.293299 -0.514649,0.464844 -0.138349,0.16602 -0.246259,0.348637 -0.32373,0.547851 -0.07748,0.199223 -0.116214,0.415043 -0.116211,0.647461 m 1.70166,-7.188476 c -0.182622,10e-6 -0.354171,0.02768 -0.514648,0.08301 -0.154952,0.05535 -0.290532,0.13559 -0.406739,0.240723 -0.11068,0.105153 -0.199222,0.235199 -0.265625,0.390137 -0.06641,0.154957 -0.09961,0.329274 -0.09961,0.522949 -3e-6,0.232431 0.0332,0.434416 0.09961,0.605957 0.07194,0.166024 0.166012,0.315438 0.282227,0.448242 0.121741,0.127287 0.260087,0.243498 0.415039,0.348633 0.160477,0.09962 0.32926,0.199226 0.506348,0.298828 0.171544,-0.08853 0.334793,-0.185376 0.489746,-0.290527 0.154942,-0.105135 0.290522,-0.224113 0.406738,-0.356934 0.121739,-0.138338 0.218581,-0.293286 0.290527,-0.464843 0.07193,-0.171541 0.107904,-0.367993 0.10791,-0.589356 -6e-6,-0.193675 -0.03321,-0.367992 -0.09961,-0.522949 -0.06641,-0.154938 -0.15772,-0.284984 -0.273926,-0.390137 -0.116216,-0.105133 -0.254562,-0.185374 -0.415039,-0.240723 -0.160487,-0.05533 -0.334803,-0.083 -0.522949,-0.08301"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/29.png b/SystemTap_Beginners_Guide/Common_Content/images/29.png
new file mode 100644 (file)
index 0000000..9a3141e
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/29.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/29.svg b/SystemTap_Beginners_Guide/Common_Content/images/29.svg
new file mode 100644 (file)
index 0000000..04b5c50
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.257917,22.008438 -8.143066,0 0,-1.784668 2.8554687,-3.07959 c 0.3596963,-0.387364 0.6861933,-0.744297 0.9794923,-1.0708 0.293289,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373536,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437178,10e-6 -0.857751,0.10792 -1.2617183,0.323731 C 9.3422244,12.379541 8.918885,12.68667 8.4761791,13.085098 L 7.0816479,11.433243 C 7.3306704,11.206366 7.5907613,10.990545 7.8619213,10.785782 8.1330785,10.575507 8.4319063,10.390123 8.7584057,10.22963 9.0849004,10.06916 9.4446006,9.9418812 9.8375072,9.8477936 10.230407,9.7481965 10.670348,9.6983918 11.157331,9.6983795 c 0.58105,1.23e-5 1.101232,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860508,0.3901488 1.187012,0.6889648 0.32649,0.293305 0.575513,0.650239 0.74707,1.070801 0.177075,0.420583 0.265617,0.893727 0.265625,1.419433 -8e-6,0.47592 -0.08302,0.932463 -0.249023,1.369629 -0.166024,0.431648 -0.392912,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622566,0.830083 -1.004395,1.245117 -0.376308,0.40951 -0.780279,0.827315 -1.211914,1.253418 l -1.460937,1.469238 0,0.116211 4.947265,0 0,2.158203"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.554792,15.052383 c -8e-6,0.581061 -0.03321,1.162116 -0.09961,1.743164 -0.06088,0.575526 -0.174325,1.126144 -0.340332,1.651856 -0.16049,0.525719 -0.381844,1.018232 -0.664063,1.477539 -0.2767,0.453778 -0.630866,0.846681 -1.0625,1.178711 -0.426112,0.332032 -0.94076,0.59489 -1.543945,0.788574 -0.597661,0.188151 -1.300459,0.282227 -2.108398,0.282227 -0.116214,0 -0.243493,-0.0028 -0.381836,-0.0083 -0.138349,-0.0055 -0.279462,-0.01384 -0.42334,-0.0249 -0.138348,-0.0055 -0.273928,-0.0166 -0.406738,-0.0332 -0.132814,-0.01107 -0.249025,-0.02767 -0.348633,-0.0498 l 0,-2.058594 c 0.204751,0.05534 0.423338,0.09961 0.655762,0.132813 0.237953,0.02767 0.478675,0.04151 0.722168,0.0415 0.747066,2e-6 1.361324,-0.09131 1.842773,-0.273925 0.48144,-0.188149 0.863276,-0.44824 1.145508,-0.780274 0.28222,-0.337562 0.481439,-0.738766 0.597656,-1.203613 0.121738,-0.464839 0.196445,-0.97672 0.224121,-1.535645 l -0.10791,0 c -0.110683,0.199225 -0.243496,0.384609 -0.398438,0.556153 -0.154953,0.171554 -0.33757,0.320968 -0.547851,0.448242 -0.210292,0.127283 -0.448247,0.226892 -0.713867,0.298828 -0.26563,0.07194 -0.561691,0.107914 -0.888184,0.10791 -0.525719,4e-6 -0.998863,-0.08577 -1.419433,-0.257324 -0.420575,-0.171545 -0.777509,-0.420568 -1.070801,-0.74707 -0.287762,-0.326492 -0.509116,-0.727696 -0.664063,-1.203614 -0.154948,-0.475904 -0.232422,-1.020988 -0.232422,-1.635253 0,-0.65852 0.09131,-1.247875 0.273926,-1.768067 0.18815,-0.520172 0.453775,-0.960113 0.796875,-1.319824 0.343097,-0.365223 0.758136,-0.644682 1.245117,-0.838379 0.49251,-0.1936727 1.043128,-0.2905151 1.651856,-0.2905274 0.597651,1.23e-5 1.15657,0.1079224 1.676758,0.3237304 0.520175,0.210298 0.971184,0.534028 1.353027,0.971192 0.381828,0.437185 0.683423,0.990569 0.904785,1.660156 0.221346,0.669605 0.332023,1.458178 0.332031,2.365722 m -4.216796,-3.262207 c -0.226893,1.1e-5 -0.434412,0.04151 -0.622559,0.124512 -0.188155,0.08302 -0.351403,0.213063 -0.489746,0.390137 -0.132816,0.171559 -0.237959,0.392913 -0.31543,0.664062 -0.07194,0.265634 -0.107913,0.581063 -0.10791,0.946289 -3e-6,0.586596 0.124509,1.05144 0.373535,1.394532 0.24902,0.343105 0.625322,0.514654 1.128906,0.514648 0.254553,6e-6 0.486975,-0.0498 0.697266,-0.149414 0.210281,-0.0996 0.390131,-0.229648 0.539551,-0.390137 0.149408,-0.160475 0.262852,-0.340325 0.340332,-0.53955 0.083,-0.199212 0.124505,-0.401197 0.124512,-0.605958 -7e-6,-0.282218 -0.03598,-0.561677 -0.107911,-0.838378 -0.06641,-0.282218 -0.171555,-0.534008 -0.315429,-0.755372 -0.138352,-0.226878 -0.312669,-0.409495 -0.52295,-0.547851 -0.204757,-0.138336 -0.44548,-0.207509 -0.722167,-0.20752"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/30.png b/SystemTap_Beginners_Guide/Common_Content/images/30.png
new file mode 100644 (file)
index 0000000..9d3db24
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/30.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/30.svg b/SystemTap_Beginners_Guide/Common_Content/images/30.svg
new file mode 100644 (file)
index 0000000..5cdcf65
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.6378,15.940567 c -9e-6,0.979497 -0.07748,1.853845 -0.232422,2.623047 -0.149422,0.769208 -0.392912,1.422202 -0.730468,1.958984 -0.332039,0.536785 -0.763679,0.94629 -1.294922,1.228516 -0.525722,0.282226 -1.162115,0.42334 -1.90918,0.42334 -0.702803,0 -1.314294,-0.141114 -1.834473,-0.42334 -0.520184,-0.282226 -0.951824,-0.691731 -1.294922,-1.228516 -0.3431,-0.536782 -0.600424,-1.189776 -0.771972,-1.958984 -0.166016,-0.769202 -0.249024,-1.64355 -0.249024,-2.623047 0,-0.979485 0.07471,-1.8566 0.224121,-2.631348 0.154948,-0.77473 0.398437,-1.430491 0.730469,-1.967285 0.33203,-0.536772 0.760903,-0.946277 1.286621,-1.228515 0.525713,-0.2877487 1.162106,-0.4316287 1.90918,-0.431641 0.69726,1.23e-5 1.305984,0.1411254 1.826172,0.42334 0.520175,0.282238 0.954582,0.691743 1.303223,1.228515 0.348624,0.536794 0.608715,1.192555 0.780273,1.967286 0.171541,0.774747 0.257315,1.654629 0.257324,2.639648 m -5.760742,0 c -3e-6,1.383468 0.118975,2.423832 0.356934,3.121094 0.237952,0.697268 0.650223,1.0459 1.236816,1.045898 0.575516,2e-6 0.987787,-0.345863 1.236816,-1.037597 0.254552,-0.691729 0.38183,-1.734859 0.381836,-3.129395 -6e-6,-1.38899 -0.127284,-2.43212 -0.381836,-3.129395 -0.249029,-0.702789 -0.6613,-1.054188 -1.236816,-1.054199 -0.293299,1.1e-5 -0.542322,0.08855 -0.74707,0.265625 -0.199223,0.177093 -0.362471,0.439951 -0.489746,0.788574 -0.127282,0.348642 -0.218591,0.785816 -0.273926,1.311524 -0.05534,0.52019 -0.08301,1.126146 -0.08301,1.817871"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/31.png b/SystemTap_Beginners_Guide/Common_Content/images/31.png
new file mode 100644 (file)
index 0000000..9e2675d
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/31.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/31.svg b/SystemTap_Beginners_Guide/Common_Content/images/31.svg
new file mode 100644 (file)
index 0000000..f0fdb29
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 22.579206,22.008438 -2.564941,0 0,-7.022461 c -4e-6,-0.143873 -4e-6,-0.315422 0,-0.514648 0.0055,-0.204745 0.01106,-0.415031 0.0166,-0.63086 0.01106,-0.221345 0.01936,-0.442699 0.0249,-0.664062 0.01106,-0.221345 0.01936,-0.423331 0.0249,-0.605957 -0.02767,0.03321 -0.07471,0.08302 -0.141113,0.149414 -0.06641,0.06642 -0.141117,0.141122 -0.224121,0.224121 -0.08301,0.07748 -0.168786,0.157724 -0.257324,0.240723 -0.08855,0.08302 -0.17432,0.157723 -0.257325,0.224121 l -1.394531,1.120605 -1.245117,-1.543945 3.909668,-3.1127931 2.108398,0 0,12.1357421"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/32.png b/SystemTap_Beginners_Guide/Common_Content/images/32.png
new file mode 100644 (file)
index 0000000..20f1bb2
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/32.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/32.svg b/SystemTap_Beginners_Guide/Common_Content/images/32.svg
new file mode 100644 (file)
index 0000000..9382928
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.621199,22.008438 -8.143067,0 0,-1.784668 2.855469,-3.07959 c 0.359697,-0.387364 0.686194,-0.744297 0.979492,-1.0708 0.29329,-0.326492 0.54508,-0.644688 0.755371,-0.95459 0.210281,-0.309889 0.37353,-0.625318 0.489746,-0.946289 0.116205,-0.320956 0.174311,-0.666821 0.174317,-1.037598 -6e-6,-0.409496 -0.124518,-0.727692 -0.373535,-0.95459 -0.243495,-0.226878 -0.572759,-0.340322 -0.987793,-0.340332 -0.437179,10e-6 -0.857751,0.10792 -1.261719,0.323731 -0.403974,0.215829 -0.827314,0.522958 -1.27002,0.921386 l -1.394531,-1.651855 c 0.249023,-0.226877 0.509114,-0.442698 0.780274,-0.647461 0.271157,-0.210275 0.569985,-0.395659 0.896484,-0.556152 0.326495,-0.16047 0.686195,-0.2877488 1.079101,-0.3818364 0.3929,-0.099597 0.832841,-0.1494018 1.319825,-0.1494141 0.581049,1.23e-5 1.101231,0.080253 1.560547,0.2407227 0.464837,0.1604938 0.860507,0.3901488 1.187011,0.6889648 0.32649,0.293305 0.575513,0.650239 0.747071,1.070801 0.177075,0.420583 0.265616,0.893727 0.265625,1.419433 -9e-6,0.47592 -0.08302,0.932463 -0.249024,1.369629 -0.166024,0.431648 -0.392911,0.857754 -0.680664,1.278321 -0.287768,0.415044 -0.622565,0.830083 -1.004394,1.245117 -0.376309,0.40951 -0.78028,0.827315 -1.211914,1.253418 l -1.460938,1.469238 0,0.116211 4.947266,0 0,2.158203"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/33.png b/SystemTap_Beginners_Guide/Common_Content/images/33.png
new file mode 100644 (file)
index 0000000..01407e6
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/33.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/33.svg b/SystemTap_Beginners_Guide/Common_Content/images/33.svg
new file mode 100644 (file)
index 0000000..f46815f
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.148054,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.207519,1.137207 -0.132821,0.33204 -0.318205,0.625334 -0.556153,0.879883 -0.232429,0.249031 -0.509121,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979486,0.121751 1.721021,0.420579 2.22461,0.896485 0.503572,0.470382 0.755362,1.106775 0.755371,1.909179 -9e-6,0.531253 -0.09685,1.023766 -0.290528,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879882,1.170411 -0.392911,0.332031 -0.890958,0.592122 -1.494141,0.780273 -0.597662,0.182617 -1.303227,0.273926 -2.116699,0.273926 -0.652998,0 -1.267256,-0.05534 -1.842774,-0.166016 -0.575522,-0.105143 -1.112305,-0.268392 -1.610351,-0.489746 l 0,-2.183105 c 0.249022,0.132815 0.51188,0.249025 0.788574,0.348632 0.276691,0.09961 0.553384,0.185387 0.830078,0.257325 0.27669,0.06641 0.547849,0.116212 0.813477,0.149414 0.271155,0.0332 0.525712,0.04981 0.763671,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315425,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188146,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124512,-0.73877 -7e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.20474 -0.265631,-0.376289 -0.498047,-0.51464 -0.226893,-0.143876 -0.525721,-0.254553 -0.896485,-0.332032 -0.370772,-0.07747 -0.827315,-0.116205 -1.369628,-0.116211 l -0.863282,0 0,-1.801269 0.84668,0 c 0.509111,7e-6 0.93245,-0.04426 1.270019,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124512,-0.672363 -6e-6,-0.431632 -0.135585,-0.769197 -0.406739,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,1e-5 -0.514652,0.02768 -0.747071,0.08301 -0.226891,0.04981 -0.439944,0.116221 -0.63916,0.199218 -0.193687,0.07748 -0.373537,0.166026 -0.53955,0.265625 -0.160484,0.09409 -0.307131,0.188161 -0.439942,0.282227 l -1.294922,-1.709961 c 0.232421,-0.171538 0.484212,-0.329253 0.755371,-0.473145 0.276692,-0.143868 0.575519,-0.26838 0.896485,-0.373535 0.320961,-0.1106647 0.666826,-0.1964393 1.037597,-0.2573239 0.370765,-0.06086 0.766435,-0.091296 1.187012,-0.091309 0.597651,1.23e-5 1.139969,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/34.png b/SystemTap_Beginners_Guide/Common_Content/images/34.png
new file mode 100644 (file)
index 0000000..ba44352
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/34.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/34.svg b/SystemTap_Beginners_Guide/Common_Content/images/34.svg
new file mode 100644 (file)
index 0000000..7bbdf5b
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.803816,19.493301 -1.460938,0 0,2.515137 -2.498535,0 0,-2.515137 -5.013672,0 0,-1.784668 5.154785,-7.8359371 2.357422,0 0,7.6284181 1.460938,0 0,1.992187 m -3.959473,-1.992187 0,-2.058594 c -5e-6,-0.07193 -5e-6,-0.17431 0,-0.307129 0.0055,-0.138339 0.01106,-0.293287 0.0166,-0.464844 0.0055,-0.171541 0.01106,-0.348625 0.0166,-0.53125 0.01106,-0.182609 0.01936,-0.356925 0.0249,-0.522949 0.01106,-0.166007 0.01936,-0.309887 0.0249,-0.43164 0.01106,-0.12727 0.01936,-0.218579 0.0249,-0.273926 l -0.07471,0 c -0.09961,0.232431 -0.213058,0.478687 -0.340332,0.738769 -0.121749,0.2601 -0.262862,0.520191 -0.42334,0.780274 l -2.02539,3.071289 2.755859,0"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/35.png b/SystemTap_Beginners_Guide/Common_Content/images/35.png
new file mode 100644 (file)
index 0000000..21d4575
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/35.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/35.svg b/SystemTap_Beginners_Guide/Common_Content/images/35.svg
new file mode 100644 (file)
index 0000000..8e19553
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 20.761335,14.255508 c 0.520177,8e-6 1.004389,0.08025 1.452637,0.240723 0.448235,0.160489 0.838372,0.395678 1.17041,0.705566 0.332024,0.309903 0.592114,0.697272 0.780274,1.16211 0.188142,0.459315 0.282218,0.987797 0.282226,1.585449 -8e-6,0.658532 -0.102385,1.250654 -0.307129,1.776367 -0.20476,0.520184 -0.506355,0.962892 -0.904785,1.328125 -0.398444,0.359701 -0.893724,0.636394 -1.48584,0.830078 -0.586594,0.193685 -1.261723,0.290528 -2.02539,0.290528 -0.304366,0 -0.605961,-0.01384 -0.904785,-0.0415 -0.298831,-0.02767 -0.586591,-0.06917 -0.863282,-0.124512 -0.27116,-0.04981 -0.531251,-0.116211 -0.780273,-0.199219 -0.243491,-0.08301 -0.464845,-0.17985 -0.664063,-0.290527 l 0,-2.216309 c 0.193684,0.11068 0.417805,0.215823 0.672364,0.31543 0.254555,0.09408 0.517413,0.177086 0.788574,0.249024 0.27669,0.06641 0.553383,0.121746 0.830078,0.166015 0.276689,0.03874 0.539547,0.05811 0.788574,0.05811 0.741532,2e-6 1.305985,-0.152179 1.69336,-0.456543 0.387364,-0.309893 0.581048,-0.799639 0.581054,-1.469239 -6e-6,-0.597651 -0.190924,-1.051427 -0.572754,-1.361328 -0.376307,-0.315424 -0.960128,-0.473139 -1.751464,-0.473144 -0.143884,5e-6 -0.298832,0.0083 -0.464844,0.0249 -0.160485,0.01661 -0.320967,0.03874 -0.481446,0.06641 -0.15495,0.02768 -0.304364,0.05811 -0.448242,0.09131 -0.143882,0.02767 -0.268394,0.05811 -0.373535,0.09131 l -1.020996,-0.547852 0.456543,-6.1840821 6.408203,0 0,2.1748051 -4.183594,0 -0.199218,2.382324 c 0.177079,-0.03873 0.381832,-0.07747 0.614257,-0.116211 0.237952,-0.03873 0.542314,-0.0581 0.913086,-0.05811"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/36.png b/SystemTap_Beginners_Guide/Common_Content/images/36.png
new file mode 100644 (file)
index 0000000..b5402b5
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/36.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/36.svg b/SystemTap_Beginners_Guide/Common_Content/images/36.svg
new file mode 100644 (file)
index 0000000..d364dbf
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 16.428328,16.853653 c -1e-6,-0.581049 0.03044,-1.159336 0.09131,-1.734863 0.06641,-0.575514 0.17985,-1.126132 0.340332,-1.651856 0.166015,-0.531241 0.387369,-1.023753 0.664063,-1.477539 0.282224,-0.453765 0.636391,-0.846669 1.0625,-1.178711 0.431637,-0.337553 0.946285,-0.600411 1.543945,-0.788574 0.603185,-0.1936727 1.305984,-0.2905151 2.108398,-0.2905274 0.116205,1.23e-5 0.243483,0.00278 0.381836,0.0083 0.13834,0.00555 0.276686,0.013847 0.415039,0.024902 0.143873,0.00555 0.282219,0.016614 0.415039,0.033203 0.132805,0.016614 0.251783,0.035982 0.356934,0.058105 l 0,2.0502924 c -0.210294,-0.04979 -0.434415,-0.08853 -0.672363,-0.116211 -0.232429,-0.03319 -0.467618,-0.04979 -0.705567,-0.0498 -0.747076,1e-5 -1.361333,0.09408 -1.842773,0.282226 -0.48145,0.182627 -0.863285,0.439951 -1.145508,0.771973 -0.28223,0.33204 -0.484215,0.730477 -0.605957,1.195312 -0.116214,0.464852 -0.188154,0.9795 -0.21582,1.543946 l 0.09961,0 c 0.110674,-0.199212 0.243487,-0.384596 0.398438,-0.556153 0.160478,-0.177076 0.345862,-0.32649 0.556152,-0.448242 0.210282,-0.127271 0.445471,-0.22688 0.705566,-0.298828 0.265621,-0.07193 0.561681,-0.107902 0.888184,-0.10791 0.52571,8e-6 0.998854,0.08578 1.419434,0.257324 0.420565,0.171557 0.774732,0.42058 1.0625,0.74707 0.293286,0.326504 0.517407,0.727708 0.672363,1.203614 0.154939,0.475916 0.232413,1.021 0.232422,1.635254 -9e-6,0.658532 -0.09408,1.247887 -0.282227,1.768066 -0.182625,0.520184 -0.445483,0.962892 -0.788574,1.328125 -0.343106,0.359701 -0.758145,0.636394 -1.245117,0.830078 -0.486985,0.188151 -1.034836,0.282227 -1.643555,0.282227 -0.59766,0 -1.156579,-0.105144 -1.676758,-0.31543 -0.520185,-0.21582 -0.97396,-0.542317 -1.361328,-0.979492 -0.381837,-0.437173 -0.683432,-0.987791 -0.904785,-1.651856 -0.215821,-0.669593 -0.323731,-1.460933 -0.32373,-2.374023 m 4.216796,3.270508 c 0.226883,2e-6 0.431636,-0.0415 0.614258,-0.124512 0.188146,-0.08854 0.348627,-0.218585 0.481446,-0.390137 0.13834,-0.17708 0.243483,-0.398434 0.315429,-0.664062 0.07747,-0.265622 0.116205,-0.581051 0.116211,-0.946289 -6e-6,-0.592118 -0.124518,-1.056961 -0.373535,-1.394531 -0.243495,-0.343094 -0.61703,-0.514643 -1.120605,-0.514649 -0.254562,6e-6 -0.486984,0.04981 -0.697266,0.149414 -0.21029,0.09962 -0.390141,0.229661 -0.539551,0.390137 -0.149417,0.160487 -0.265628,0.340337 -0.348633,0.539551 -0.07748,0.199223 -0.116214,0.401209 -0.116211,0.605957 -3e-6,0.28223 0.0332,0.564456 0.09961,0.846679 0.07194,0.276696 0.17708,0.528486 0.315429,0.755371 0.143877,0.221357 0.318193,0.401207 0.52295,0.539551 0.210282,0.138349 0.453771,0.207522 0.730468,0.20752"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/37.png b/SystemTap_Beginners_Guide/Common_Content/images/37.png
new file mode 100644 (file)
index 0000000..9fd99d2
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/37.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/37.svg b/SystemTap_Beginners_Guide/Common_Content/images/37.svg
new file mode 100644 (file)
index 0000000..771fa4d
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 17.51573,22.008438 4.316406,-9.960937 -5.578125,0 0,-2.1582035 8.367188,0 0,1.6103515 -4.424317,10.508789 -2.681152,0"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/38.png b/SystemTap_Beginners_Guide/Common_Content/images/38.png
new file mode 100644 (file)
index 0000000..3ce6027
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/38.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/38.svg b/SystemTap_Beginners_Guide/Common_Content/images/38.svg
new file mode 100644 (file)
index 0000000..487e0ef
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 20.48741,9.7149811 c 0.503575,1.23e-5 0.979486,0.060885 1.427734,0.1826172 0.448236,0.1217567 0.841139,0.3043737 1.178711,0.5478517 0.337557,0.243501 0.605949,0.547862 0.805176,0.913086 0.19921,0.365244 0.298819,0.794118 0.298828,1.286621 -9e-6,0.365243 -0.05535,0.697274 -0.166016,0.996094 -0.110685,0.293302 -0.262866,0.561694 -0.456543,0.805175 -0.193692,0.237963 -0.423347,0.451017 -0.688965,0.639161 -0.265631,0.188157 -0.553392,0.359707 -0.863281,0.514648 0.320957,0.171556 0.63362,0.362473 0.937988,0.572754 0.309889,0.210292 0.583814,0.448247 0.821778,0.713867 0.237947,0.260096 0.428865,0.55339 0.572754,0.879883 0.143871,0.326501 0.215811,0.691735 0.21582,1.095703 -9e-6,0.503583 -0.09962,0.960126 -0.298828,1.369629 -0.199227,0.409506 -0.478687,0.758139 -0.838379,1.045898 -0.359708,0.287761 -0.791348,0.509115 -1.294922,0.664063 -0.498053,0.154948 -1.048671,0.232422 -1.651855,0.232422 -0.652999,0 -1.234053,-0.07471 -1.743164,-0.224121 -0.509117,-0.149414 -0.937991,-0.362467 -1.286622,-0.639161 -0.348634,-0.276691 -0.614258,-0.617023 -0.796875,-1.020996 -0.177084,-0.403969 -0.265625,-0.857744 -0.265625,-1.361328 0,-0.415035 0.06087,-0.78857 0.182618,-1.120605 0.121744,-0.332027 0.287759,-0.630855 0.498046,-0.896485 0.210285,-0.265619 0.456542,-0.500808 0.73877,-0.705566 0.282224,-0.204747 0.583819,-0.384597 0.904785,-0.539551 -0.271161,-0.171543 -0.525718,-0.356927 -0.763672,-0.556152 -0.237957,-0.204746 -0.445477,-0.428866 -0.622558,-0.672363 -0.171551,-0.249016 -0.309897,-0.522942 -0.415039,-0.821778 -0.09961,-0.298819 -0.149415,-0.628083 -0.149414,-0.987793 -1e-6,-0.481435 0.09961,-0.902008 0.298828,-1.261718 0.204751,-0.365224 0.478676,-0.669585 0.821777,-0.913086 0.343097,-0.249012 0.738767,-0.434396 1.187012,-0.5561527 0.448238,-0.1217326 0.918615,-0.1826049 1.411133,-0.1826172 m -1.718262,9.0644529 c -3e-6,0.221357 0.03597,0.42611 0.10791,0.614258 0.07194,0.18262 0.17708,0.340334 0.31543,0.473145 0.143876,0.132814 0.32096,0.237957 0.53125,0.315429 0.210282,0.07194 0.453771,0.107912 0.730468,0.10791 0.58105,2e-6 1.015457,-0.135577 1.303223,-0.406738 0.287754,-0.27669 0.431634,-0.639157 0.431641,-1.087402 -7e-6,-0.232419 -0.04981,-0.439938 -0.149414,-0.622559 -0.09408,-0.188147 -0.218594,-0.359696 -0.373535,-0.514648 -0.14942,-0.160478 -0.32097,-0.307125 -0.514649,-0.439942 -0.19369,-0.132807 -0.387375,-0.260086 -0.581055,-0.381836 L 20.3878,16.72084 c -0.243494,0.12175 -0.464848,0.254563 -0.664062,0.398438 -0.199223,0.138351 -0.370772,0.293299 -0.514649,0.464844 -0.138349,0.16602 -0.246259,0.348637 -0.32373,0.547851 -0.07748,0.199223 -0.116214,0.415043 -0.116211,0.647461 m 1.70166,-7.188476 c -0.182622,10e-6 -0.354171,0.02768 -0.514648,0.08301 -0.154952,0.05535 -0.290532,0.13559 -0.406739,0.240723 -0.11068,0.105153 -0.199222,0.235199 -0.265625,0.390137 -0.06641,0.154957 -0.09961,0.329274 -0.09961,0.522949 -3e-6,0.232431 0.0332,0.434416 0.09961,0.605957 0.07194,0.166024 0.166012,0.315438 0.282227,0.448242 0.121741,0.127287 0.260087,0.243498 0.415039,0.348633 0.160477,0.09962 0.32926,0.199226 0.506348,0.298828 0.171544,-0.08853 0.334793,-0.185376 0.489746,-0.290527 0.154942,-0.105135 0.290522,-0.224113 0.406738,-0.356934 0.121739,-0.138338 0.218581,-0.293286 0.290527,-0.464843 0.07193,-0.171541 0.107904,-0.367993 0.10791,-0.589356 -6e-6,-0.193675 -0.03321,-0.367992 -0.09961,-0.522949 -0.06641,-0.154938 -0.15772,-0.284984 -0.273926,-0.390137 -0.116216,-0.105133 -0.254562,-0.185374 -0.415039,-0.240723 -0.160487,-0.05533 -0.334803,-0.083 -0.522949,-0.08301"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/39.png b/SystemTap_Beginners_Guide/Common_Content/images/39.png
new file mode 100644 (file)
index 0000000..d689450
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/39.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/39.svg b/SystemTap_Beginners_Guide/Common_Content/images/39.svg
new file mode 100644 (file)
index 0000000..cea69f7
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 14.784773,12.587051 c -8e-6,0.420582 -0.06918,0.799651 -0.20752,1.137207 -0.13282,0.33204 -0.318204,0.625334 -0.556152,0.879883 -0.232429,0.249031 -0.509122,0.459317 -0.830078,0.63086 -0.315436,0.166022 -0.658535,0.2933 -1.029297,0.381836 l 0,0.0498 c 0.979485,0.121751 1.721021,0.420579 2.224609,0.896485 0.503573,0.470382 0.755363,1.106775 0.755371,1.909179 -8e-6,0.531253 -0.09685,1.023766 -0.290527,1.477539 -0.188159,0.448244 -0.481453,0.83838 -0.879883,1.170411 -0.39291,0.332031 -0.890957,0.592122 -1.49414,0.780273 -0.597662,0.182617 -1.303228,0.273926 -2.1167,0.273926 -0.6529976,0 -1.2672548,-0.05534 -1.842773,-0.166016 C 7.9421607,21.903295 7.4053774,21.740046 6.9073315,21.518692 l 0,-2.183105 c 0.2490227,0.132815 0.5118805,0.249025 0.7885742,0.348632 0.2766912,0.09961 0.5533836,0.185387 0.8300781,0.257325 0.2766904,0.06641 0.5478489,0.116212 0.8134766,0.149414 0.2711557,0.0332 0.5257127,0.04981 0.7636716,0.0498 0.475908,2e-6 0.871578,-0.04427 1.187012,-0.132812 0.315424,-0.08854 0.567215,-0.213051 0.755371,-0.373535 0.188145,-0.16048 0.320958,-0.351397 0.398438,-0.572754 0.083,-0.226885 0.124505,-0.473141 0.124511,-0.73877 -6e-6,-0.249019 -0.05258,-0.47314 -0.157715,-0.672363 -0.09962,-0.204748 -0.26563,-0.376297 -0.498046,-0.514648 C 11.685809,16.992 11.386981,16.881323 11.016218,16.803844 10.645446,16.726374 10.188903,16.687639 9.6465893,16.687633 l -0.8632813,0 0,-1.801269 0.8466797,0 c 0.5091113,7e-6 0.9324503,-0.04426 1.2700193,-0.132813 0.337561,-0.09407 0.605952,-0.218579 0.805176,-0.373535 0.204747,-0.160474 0.348627,-0.345858 0.431641,-0.556152 0.083,-0.210278 0.124506,-0.434399 0.124511,-0.672363 -5e-6,-0.431632 -0.135585,-0.769197 -0.406738,-1.012696 -0.26563,-0.243479 -0.688969,-0.365224 -1.270019,-0.365234 -0.265629,10e-6 -0.514653,0.02768 -0.7470708,0.08301 -0.2268911,0.04981 -0.4399443,0.116221 -0.6391601,0.199218 -0.1936875,0.07748 -0.3735376,0.166026 -0.5395508,0.265625 -0.1604838,0.09409 -0.3071308,0.188161 -0.4399414,0.282227 L 6.923933,10.893692 c 0.2324212,-0.171538 0.4842113,-0.329253 0.7553711,-0.473145 0.2766912,-0.143868 0.575519,-0.26838 0.8964844,-0.373535 0.3209611,-0.1106647 0.6668266,-0.1964393 1.0375977,-0.2573239 0.3707646,-0.06086 0.7664348,-0.091296 1.1870118,-0.091309 0.597651,1.23e-5 1.139968,0.066419 1.626953,0.1992188 0.492507,0.1272911 0.913079,0.3154421 1.261719,0.5644531 0.348625,0.243501 0.617017,0.545096 0.805176,0.904786 0.193676,0.354177 0.290519,0.760914 0.290527,1.220214"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.554792,15.052383 c -8e-6,0.581061 -0.03321,1.162116 -0.09961,1.743164 -0.06088,0.575526 -0.174325,1.126144 -0.340332,1.651856 -0.16049,0.525719 -0.381844,1.018232 -0.664063,1.477539 -0.2767,0.453778 -0.630866,0.846681 -1.0625,1.178711 -0.426112,0.332032 -0.94076,0.59489 -1.543945,0.788574 -0.597661,0.188151 -1.300459,0.282227 -2.108398,0.282227 -0.116214,0 -0.243493,-0.0028 -0.381836,-0.0083 -0.138349,-0.0055 -0.279462,-0.01384 -0.42334,-0.0249 -0.138348,-0.0055 -0.273928,-0.0166 -0.406738,-0.0332 -0.132814,-0.01107 -0.249025,-0.02767 -0.348633,-0.0498 l 0,-2.058594 c 0.204751,0.05534 0.423338,0.09961 0.655762,0.132813 0.237953,0.02767 0.478675,0.04151 0.722168,0.0415 0.747066,2e-6 1.361324,-0.09131 1.842773,-0.273925 0.48144,-0.188149 0.863276,-0.44824 1.145508,-0.780274 0.28222,-0.337562 0.481439,-0.738766 0.597656,-1.203613 0.121738,-0.464839 0.196445,-0.97672 0.224121,-1.535645 l -0.10791,0 c -0.110683,0.199225 -0.243496,0.384609 -0.398438,0.556153 -0.154953,0.171554 -0.33757,0.320968 -0.547851,0.448242 -0.210292,0.127283 -0.448247,0.226892 -0.713867,0.298828 -0.26563,0.07194 -0.561691,0.107914 -0.888184,0.10791 -0.525719,4e-6 -0.998863,-0.08577 -1.419433,-0.257324 -0.420575,-0.171545 -0.777509,-0.420568 -1.070801,-0.74707 -0.287762,-0.326492 -0.509116,-0.727696 -0.664063,-1.203614 -0.154948,-0.475904 -0.232422,-1.020988 -0.232422,-1.635253 0,-0.65852 0.09131,-1.247875 0.273926,-1.768067 0.18815,-0.520172 0.453775,-0.960113 0.796875,-1.319824 0.343097,-0.365223 0.758136,-0.644682 1.245117,-0.838379 0.49251,-0.1936727 1.043128,-0.2905151 1.651856,-0.2905274 0.597651,1.23e-5 1.15657,0.1079224 1.676758,0.3237304 0.520175,0.210298 0.971184,0.534028 1.353027,0.971192 0.381828,0.437185 0.683423,0.990569 0.904785,1.660156 0.221346,0.669605 0.332023,1.458178 0.332031,2.365722 m -4.216796,-3.262207 c -0.226893,1.1e-5 -0.434412,0.04151 -0.622559,0.124512 -0.188155,0.08302 -0.351403,0.213063 -0.489746,0.390137 -0.132816,0.171559 -0.237959,0.392913 -0.31543,0.664062 -0.07194,0.265634 -0.107913,0.581063 -0.10791,0.946289 -3e-6,0.586596 0.124509,1.05144 0.373535,1.394532 0.24902,0.343105 0.625322,0.514654 1.128906,0.514648 0.254553,6e-6 0.486975,-0.0498 0.697266,-0.149414 0.210281,-0.0996 0.390131,-0.229648 0.539551,-0.390137 0.149408,-0.160475 0.262852,-0.340325 0.340332,-0.53955 0.083,-0.199212 0.124505,-0.401197 0.124512,-0.605958 -7e-6,-0.282218 -0.03598,-0.561677 -0.107911,-0.838378 -0.06641,-0.282218 -0.171555,-0.534008 -0.315429,-0.755372 -0.138352,-0.226878 -0.312669,-0.409495 -0.52295,-0.547851 -0.204757,-0.138336 -0.44548,-0.207509 -0.722167,-0.20752"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/40.png b/SystemTap_Beginners_Guide/Common_Content/images/40.png
new file mode 100644 (file)
index 0000000..0d3532e
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/40.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/40.svg b/SystemTap_Beginners_Guide/Common_Content/images/40.svg
new file mode 100644 (file)
index 0000000..bb4e1d7
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   version="1.0"
+   width="32"
+   height="32"
+   id="svg2">
+  <defs
+     id="defs15" />
+  <circle
+     cx="16"
+     cy="16"
+     r="14"
+     id="circle"
+     style="fill:#336699" />
+  <g
+     id="text2820"
+     style="font-size:10px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;text-anchor:middle;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans">
+    <path
+       d="m 15.440535,19.493301 -1.460938,0 0,2.515137 -2.498535,0 0,-2.515137 -5.0136719,0 0,-1.784668 5.1547849,-7.8359371 2.357422,0 0,7.6284181 1.460938,0 0,1.992187 m -3.959473,-1.992187 0,-2.058594 c -5e-6,-0.07193 -5e-6,-0.17431 0,-0.307129 0.0055,-0.138339 0.01106,-0.293287 0.0166,-0.464844 0.0055,-0.171541 0.01106,-0.348625 0.0166,-0.53125 0.01106,-0.182609 0.01936,-0.356925 0.0249,-0.522949 0.01106,-0.166007 0.01936,-0.309887 0.0249,-0.43164 0.01106,-0.12727 0.01936,-0.218579 0.0249,-0.273926 l -0.07471,0 c -0.09961,0.232431 -0.213058,0.478687 -0.340332,0.738769 -0.121749,0.2601 -0.262863,0.520191 -0.42334,0.780274 l -2.0253904,3.071289 2.7558594,0"
+       id="path2818"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+    <path
+       d="m 24.6378,15.940567 c -9e-6,0.979497 -0.07748,1.853845 -0.232422,2.623047 -0.149422,0.769208 -0.392912,1.422202 -0.730468,1.958984 -0.332039,0.536785 -0.763679,0.94629 -1.294922,1.228516 -0.525722,0.282226 -1.162115,0.42334 -1.90918,0.42334 -0.702803,0 -1.314294,-0.141114 -1.834473,-0.42334 -0.520184,-0.282226 -0.951824,-0.691731 -1.294922,-1.228516 -0.3431,-0.536782 -0.600424,-1.189776 -0.771972,-1.958984 -0.166016,-0.769202 -0.249024,-1.64355 -0.249024,-2.623047 0,-0.979485 0.07471,-1.8566 0.224121,-2.631348 0.154948,-0.77473 0.398437,-1.430491 0.730469,-1.967285 0.33203,-0.536772 0.760903,-0.946277 1.286621,-1.228515 0.525713,-0.2877487 1.162106,-0.4316287 1.90918,-0.431641 0.69726,1.23e-5 1.305984,0.1411254 1.826172,0.42334 0.520175,0.282238 0.954582,0.691743 1.303223,1.228515 0.348624,0.536794 0.608715,1.192555 0.780273,1.967286 0.171541,0.774747 0.257315,1.654629 0.257324,2.639648 m -5.760742,0 c -3e-6,1.383468 0.118975,2.423832 0.356934,3.121094 0.237952,0.697268 0.650223,1.0459 1.236816,1.045898 0.575516,2e-6 0.987787,-0.345863 1.236816,-1.037597 0.254552,-0.691729 0.38183,-1.734859 0.381836,-3.129395 -6e-6,-1.38899 -0.127284,-2.43212 -0.381836,-3.129395 -0.249029,-0.702789 -0.6613,-1.054188 -1.236816,-1.054199 -0.293299,1.1e-5 -0.542322,0.08855 -0.74707,0.265625 -0.199223,0.177093 -0.362471,0.439951 -0.489746,0.788574 -0.127282,0.348642 -0.218591,0.785816 -0.273926,1.311524 -0.05534,0.52019 -0.08301,1.126146 -0.08301,1.817871"
+       id="path2820"
+       style="font-size:17px;font-weight:bold;fill:#ffffff;-inkscape-font-specification:Bitstream Vera Sans Bold" />
+  </g>
+</svg>
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/green.png b/SystemTap_Beginners_Guide/Common_Content/images/green.png
new file mode 100644 (file)
index 0000000..ebb3c24
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/green.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/red.png b/SystemTap_Beginners_Guide/Common_Content/images/red.png
new file mode 100644 (file)
index 0000000..d32d5e2
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/red.png differ
diff --git a/SystemTap_Beginners_Guide/Common_Content/images/yellow.png b/SystemTap_Beginners_Guide/Common_Content/images/yellow.png
new file mode 100644 (file)
index 0000000..223865d
Binary files /dev/null and b/SystemTap_Beginners_Guide/Common_Content/images/yellow.png differ
index 19fa13e7f4067fdff38d86b956d25a6120f8eafa..ae0b0e13400ee11dc7c7fbf1909e9fdbe70b5233 100644 (file)
@@ -1,11 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Preface</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="index.html" title="SystemTap Beginners Guide" /><link rel="next" href="pr01s02.html" title="2. We Need Feedback!" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="index.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="pr01s02.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="preface" title="Preface" lang="en-US"><div class="titlepage"><div><div><h1 id="SystemTap_Beginners_Guide-Preface" class="title">Preface</h1></div></div></div><div class="para">
-       </div><div xml:lang="en-US" class="section" title="1. Document Conventions" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="id586261">1. Document Conventions</h2></div></div></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Preface</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="index.html" title="SystemTap Beginners Guide" /><link rel="next" href="pr01s02.html" title="2. We Need Feedback!" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="index.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="pr01s02.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="preface" id="SystemTap_Beginners_Guide-Preface" lang="en-US"><div class="titlepage"><div><div><h1 class="title">Preface</h1></div></div></div><div class="para">
+
+       </div><div xml:lang="en-US" class="section" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="id573981">1. Document Conventions</h2></div></div></div><div class="para">
                This manual uses several conventions to highlight certain words and phrases and draw attention to specific pieces of information.
        </div><div class="para">
                In PDF and paper editions, this manual uses typefaces drawn from the <a href="https://fedorahosted.org/liberation-fonts/">Liberation Fonts</a> set. The Liberation Fonts set is also used in HTML editions if the set is installed on your system. If not, alternative but equivalent typefaces are displayed. Note: Red Hat Enterprise Linux 5 and later includes the Liberation Fonts set by default.
-       </div><div class="section" title="1.1. Typographic Conventions"><div class="titlepage"><div><div><h3 class="title" id="id628309">1.1. Typographic Conventions</h3></div></div></div><div class="para">
+       </div><div class="section"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="id573950">1.1. Typographic Conventions</h3></div></div></div><div class="para">
                        Four typographic conventions are used to call attention to specific words and phrases. These conventions, and the circumstances they apply to, are as follows.
                </div><div class="para">
                        <code class="literal">Mono-spaced Bold</code>
@@ -20,7 +21,7 @@
                </div><div class="blockquote"><blockquote class="blockquote"><div class="para">
                                Press <span class="keycap"><strong>Enter</strong></span> to execute the command.
                        </div><div class="para">
-                               Press <span class="keycap"><strong>Ctrl</strong></span>+<span class="keycap"><strong>Alt</strong></span>+<span class="keycap"><strong>F1</strong></span> to switch to the first virtual terminal. Press <span class="keycap"><strong>Ctrl</strong></span>+<span class="keycap"><strong>Alt</strong></span>+<span class="keycap"><strong>F7</strong></span> to return to your X-Windows session.
+                               Press <span class="keycap"><strong>Ctrl</strong></span>+<span class="keycap"><strong>Alt</strong></span>+<span class="keycap"><strong>F2</strong></span> to switch to the first virtual terminal. Press <span class="keycap"><strong>Ctrl</strong></span>+<span class="keycap"><strong>Alt</strong></span>+<span class="keycap"><strong>F1</strong></span> to return to your X-Windows session.
                        </div></blockquote></div><div class="para">
                        The first paragraph highlights the particular keycap to press. The second highlights two key combinations (each a set of three keycaps with each set pressed simultaneously).
                </div><div class="para">
                        Aside from standard usage for presenting the title of a work, italics denotes the first use of a new and important term. For example:
                </div><div class="blockquote"><blockquote class="blockquote"><div class="para">
                                Publican is a <em class="firstterm">DocBook</em> publishing system.
-                       </div></blockquote></div></div><div class="section" title="1.2. Pull-quote Conventions"><div class="titlepage"><div><div><h3 class="title" id="id537954">1.2. Pull-quote Conventions</h3></div></div></div><div class="para">
+                       </div></blockquote></div></div><div class="section"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="id656642">1.2. Pull-quote Conventions</h3></div></div></div><div class="para">
                        Terminal output and source code listings are set off visually from the surrounding text.
                </div><div class="para">
                        Output sent to a terminal is set in <code class="computeroutput">mono-spaced roman</code> and presented thus:
                </div><pre class="screen">books        Desktop   documentation  drafts  mss    photos   stuff  svn
-books_tests  Desktop1  downloads      images  notes  scripts  svgs
-</pre><div class="para">
+books_tests  Desktop1  downloads      images  notes  scripts  svgs</pre><div class="para">
                        Source-code listings are also set in <code class="computeroutput">mono-spaced roman</code> but add syntax highlighting as follows:
                </div><pre class="programlisting">package org.<span class="perl_Function">jboss</span>.<span class="perl_Function">book</span>.<span class="perl_Function">jca</span>.<span class="perl_Function">ex1</span>;
 
@@ -79,13 +79,12 @@ books_tests  Desktop1  downloads      images  notes  scripts  svgs
 
       System.<span class="perl_Function">out</span>.<span class="perl_Function">println</span>(<span class="perl_String">"Echo.echo('Hello') = "</span> + echo.<span class="perl_Function">echo</span>(<span class="perl_String">"Hello"</span>));
    }
-}
-</pre></div><div class="section" title="1.3. Notes and Warnings"><div class="titlepage"><div><div><h3 class="title" id="id472332">1.3. Notes and Warnings</h3></div></div></div><div class="para">
+}</pre></div><div class="section"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="id511567">1.3. Notes and Warnings</h3></div></div></div><div class="para">
                        Finally, we use three visual styles to draw attention to information that might otherwise be overlooked.
-               </div><div class="note"><h2>Note</h2><div class="para">
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
                                Notes are tips, shortcuts or alternative approaches to the task at hand. Ignoring a note should have no negative consequences, but you might miss out on a trick that makes your life easier.
-                       </div></div><div class="important"><h2>Important</h2><div class="para">
-                               Important boxes detail things that are easily missed: configuration changes that only apply to the current session, or services that need restarting before an update will apply. Ignoring a box labeled 'Important' won't cause data loss but may cause irritation and frustration.
-                       </div></div><div class="warning"><h2>Warning</h2><div class="para">
+                       </div></div></div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
+                               Important boxes detail things that are easily missed: configuration changes that only apply to the current session, or services that need restarting before an update will apply. Ignoring a box labeled 'Important' will not cause data loss but may cause irritation and frustration.
+                       </div></div></div><div class="warning"><div class="admonition_header"><h2>Warning</h2></div><div class="admonition"><div class="para">
                                Warnings should not be ignored. Ignoring warnings will most likely cause data loss.
-                       </div></div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="index.html"><strong>Prev</strong>SystemTap Beginners Guide</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="pr01s02.html"><strong>Next</strong>2. We Need Feedback!</a></li></ul></body></html>
+                       </div></div></div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="index.html"><strong>Prev</strong>SystemTap Beginners Guide</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="pr01s02.html"><strong>Next</strong>2. We Need Feedback!</a></li></ul></body></html>
index 13f810965c537a16b311a87d8858decbc9051bcf..d7a0093d26b57a71b1e154ace9b36aa9f9a08d49 100644 (file)
@@ -1,9 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Appendix A. Revision History</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="references.html" title="Chapter 6. References" /><link rel="next" href="ix01.html" title="Index" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="references.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="ix01.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="appendix" title="Appendix A. Revision History" lang="en-US"><div class="titlepage"><div><div><h1 id="appe-Publican-Revision_History" class="title">Revision History</h1></div></div></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Appendix A. Revision History</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="references.html" title="Chapter 7. References" /><link rel="next" href="ix01.html" title="Index" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="references.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="ix01.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="appendix" id="appe-Publican-Revision_History" lang="en-US"><div class="titlepage"><div><div><h1 class="title">Revision History</h1></div></div></div><div class="para">
                <div class="revhistory"><table border="0" width="100%" summary="Revision history"><tr><th align="left" valign="top" colspan="3"><b>Revision History</b></th></tr><tr><td align="left">Revision 2.0</td><td align="left">Mon Jul 20 2009</td><td align="left"><span class="author"><span class="firstname">Don</span> <span class="surname">Domingo</span></span></td></tr><tr><td align="left" colspan="3">
                                        <table border="0" summary="Simple list" class="simplelist"><tr><td>includes 5.4 minor updates and additional script "dropwatch.stp"</td></tr></table>
+
                                </td></tr><tr><td align="left">Revision 1.0</td><td align="left">Wed Jun 17 2009</td><td align="left"><span class="author"><span class="firstname">Don</span> <span class="surname">Domingo</span></span></td></tr><tr><td align="left" colspan="3">
                                        <table border="0" summary="Simple list" class="simplelist"><tr><td>Building+pushing to RHEL</td></tr></table>
+
                                </td></tr></table></div>
-       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="references.html"><strong>Prev</strong>Chapter 6. References</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="ix01.html"><strong>Next</strong>Index</a></li></ul></body></html>
+
+       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="references.html"><strong>Prev</strong>Chapter 7. References</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="ix01.html"><strong>Next</strong>Index</a></li></ul></body></html>
index cab522341d38e436a82396ec40cc99a0ce0aa497..fbed3044decc5532c3dd74155219ba25239d904b 100644 (file)
@@ -1,17 +1,13 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5. Array Operations in SystemTap</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="associativearrays.html" title="3.4. Associative Arrays" /><link rel="next" href="arrayops-readvalues.html" title="3.5.2. Reading Values From Arrays" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="associativearrays.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-readvalues.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="3.5. Array Operations in SystemTap" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="arrayoperators">3.5. Array Operations in SystemTap</h2></div></div></div><a id="id647746" class="indexterm"></a><a id="id501080" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5. Array Operations in SystemTap</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="associativearrays.html" title="3.4. Associative Arrays" /><link rel="next" href="arrayops-readvalues.html" title="3.5.2. Reading Values From Arrays" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="associativearrays.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-readvalues.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="arrayoperators" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="arrayoperators">3.5. Array Operations in SystemTap</h2></div></div></div><a id="id1976071" class="indexterm"></a><a id="id559010" class="indexterm"></a><div class="para">
                This section enumerates some of the most commonly used array operations in SystemTap.
-       </div><div class="section" title="3.5.1. Assigning an Associated Value"><div class="titlepage"><div><div><h3 class="title" id="arrayops-assignvalue">3.5.1. Assigning an Associated Value</h3></div></div></div><a id="id581889" class="indexterm"></a><a id="id499066" class="indexterm"></a><a id="id493477" class="indexterm"></a><div class="para">
+       </div><div class="section" id="arrayops-assignvalue"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-assignvalue">3.5.1. Assigning an Associated Value</h3></div></div></div><a id="id426012" class="indexterm"></a><a id="id737672" class="indexterm"></a><a id="id620697" class="indexterm"></a><div class="para">
                        Use <code class="command">=</code> to set an associated value to indexed unique pairs, as in:
-               </div><pre class="screen">
-<em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>] = <em class="replaceable"><code>value</code></em>
-</pre><div class="para">
-                       <a class="xref" href="associativearrays.html#arraysimplestexample" title="Example 3.11. Basic Array Statements">Example 3.11, “Basic Array Statements”</a> shows a very basic example of how to set an explicit associated value to a unique key. You can also use a handler function as both your <code class="command"><em class="replaceable"><code>index_expression</code></em></code> and <code class="command"><em class="replaceable"><code>value</code></em></code>. For example, you can use arrays to set a timestamp as the associated value to a process name (which you wish to use as your unique key), as in:
-               </div><a id="id494115" class="indexterm"></a><a id="id506377" class="indexterm"></a><a id="id611817" class="indexterm"></a><a id="id597615" class="indexterm"></a><a id="id540524" class="indexterm"></a><a id="id641215" class="indexterm"></a><div class="example" id="arrays-timestampprocessname"><div class="example-contents"><pre class="programlisting">
-foo[tid()] = gettimeofday_s()
-</pre></div><h6>Example 3.12. Associating Timestamps to Process Names</h6></div><br class="example-break" /><div class="para">
-                       Whenever an event invokes the statement in <a class="xref" href="arrayoperators.html#arrays-timestampprocessname" title="Example 3.12. Associating Timestamps to Process Names">Example 3.12, “Associating Timestamps to Process Names”</a>, SystemTap returns the appropriate <code class="command">tid()</code> value (i.e. the ID of a thread, which is then used as the unique key). At the same time, SystemTap also uses the function <code class="command">gettimeofday_s()</code> to set the corresponding timestamp as the associated value to the unique key defined by the function <code class="command">tid()</code>. This creates an array composed of key pairs containing thread IDs and timestamps.
+               </div><pre class="screen"><em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>] = <em class="replaceable"><code>value</code></em></pre><div class="para">
+                       <a class="xref" href="associativearrays.html#arraysimplestexample">Example 3.13, “Basic Array Statements”</a> shows a very basic example of how to set an explicit associated value to a unique key. You can also use a handler function as both your <code class="command"><em class="replaceable"><code>index_expression</code></em></code> and <code class="command"><em class="replaceable"><code>value</code></em></code>. For example, you can use arrays to set a timestamp as the associated value to a process name (which you wish to use as your unique key), as in:
+               </div><a id="id734339" class="indexterm"></a><a id="id761102" class="indexterm"></a><a id="id518688" class="indexterm"></a><a id="id414217" class="indexterm"></a><a id="id422798" class="indexterm"></a><a id="id612348" class="indexterm"></a><div class="example" id="arrays-timestampprocessname"><h6>Example 3.14. Associating Timestamps to Process Names</h6><div class="example-contents"><pre class="programlisting">foo[tid()] = gettimeofday_s()</pre></div></div><br class="example-break" /><div class="para">
+                       Whenever an event invokes the statement in <a class="xref" href="arrayoperators.html#arrays-timestampprocessname">Example 3.14, “Associating Timestamps to Process Names”</a>, SystemTap returns the appropriate <code class="command">tid()</code> value (i.e. the ID of a thread, which is then used as the unique key). At the same time, SystemTap also uses the function <code class="command">gettimeofday_s()</code> to set the corresponding timestamp as the associated value to the unique key defined by the function <code class="command">tid()</code>. This creates an array composed of key pairs containing thread IDs and timestamps.
                </div><div class="para">
                        In this same example, if <code class="command">tid()</code> returns a value that is already defined in the array <code class="command">foo</code>, the operator will discard the original associated value to it, and replace it with the current timestamp from <code class="command">gettimeofday_s()</code>.
                </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="associativearrays.html"><strong>Prev</strong>3.4. Associative Arrays</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-readvalues.html"><strong>Next</strong>3.5.2. Reading Values From Arrays</a></li></ul></body></html>
index 7aa867b345c8a0cc41246608be002f999a087c27..b7430d1d2b50b769b274a5f8d332c0bc5401f104 100644 (file)
@@ -1,35 +1,32 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.7. Computing for Statistical Aggregates</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-conditionals.html" title="3.5.6. Using Arrays in Conditional Statements" /><link rel="next" href="understanding-tapsets.html" title="3.6. Tapsets" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-conditionals.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="understanding-tapsets.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.7. Computing for Statistical Aggregates"><div class="titlepage"><div><div><h3 class="title" id="arrayops-aggregates">3.5.7. Computing for Statistical Aggregates</h3></div></div></div><a id="id647576" class="indexterm"></a><a id="id647588" class="indexterm"></a><a id="id545810" class="indexterm"></a><a id="id545822" class="indexterm"></a><a id="id500121" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.7. Computing for Statistical Aggregates</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-conditionals.html" title="3.5.6. Using Arrays in Conditional Statements" /><link rel="next" href="understanding-tapsets.html" title="3.6. Tapsets" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-conditionals.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="understanding-tapsets.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-aggregates"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-aggregates">3.5.7. Computing for Statistical Aggregates</h3></div></div></div><a id="id655846" class="indexterm"></a><a id="id491025" class="indexterm"></a><a id="id491037" class="indexterm"></a><a id="id527662" class="indexterm"></a><a id="id1963432" class="indexterm"></a><div class="para">
                        Statistical aggregates are used to collect statistics on numerical values where it is important to accumulate new data quickly and in large volume (i.e. storing only aggregated stream statistics). Statistical aggregates can be used in global variables or as elements in an array.
-               </div><a id="id500143" class="indexterm"></a><a id="id546810" class="indexterm"></a><a id="id502196" class="indexterm"></a><a id="id502212" class="indexterm"></a><div class="para">
+               </div><a id="id1946559" class="indexterm"></a><a id="id525447" class="indexterm"></a><a id="id525462" class="indexterm"></a><a id="id487192" class="indexterm"></a><div class="para">
                        To add value to a statistical aggregate, use the operator <code class="command">&lt;&lt;&lt; <em class="replaceable"><code>value</code></em></code>.
-               </div><div class="example" id="simpleaggregates"><div class="example-contents"><pre class="programlisting">
-global reads   
+               </div><div class="example" id="simpleaggregates"><h6>Example 3.21. stat-aggregates.stp</h6><div class="example-contents"><pre class="programlisting">global reads
 probe vfs.read
 {
   reads[execname()] &lt;&lt;&lt; count
-}
-</pre></div><h6>Example 3.19. stat-aggregates.stp</h6></div><br class="example-break" /><a id="id498629" class="indexterm"></a><a id="id500312" class="indexterm"></a><a id="id500328" class="indexterm"></a><a id="id492122" class="indexterm"></a><div class="para">
-                       In <a class="xref" href="arrayops-aggregates.html#simpleaggregates" title="Example 3.19. stat-aggregates.stp">Example 3.19, “stat-aggregates.stp”</a>, the operator <code class="command">&lt;&lt;&lt; count</code> <span class="emphasis"><em>stores</em></span> the amount returned by <code class="literal">count</code> to to the associated value of the corresponding <code class="command">execname()</code> in the <code class="literal">reads</code> array. Remember, these values are <span class="emphasis"><em>stored</em></span>; they are not added to the associated values of each unique key, nor are they used to replace the current associated values. In a manner of speaking, think of it as having each unique key (<code class="command">execname()</code>) having multiple associated values, accumulating with each probe handler run.
-               </div><div class="note"><h2>Note</h2><div class="para">
-                               In the context of <a class="xref" href="arrayops-aggregates.html#simpleaggregates" title="Example 3.19. stat-aggregates.stp">Example 3.19, “stat-aggregates.stp”</a>, <code class="literal">count</code> returns the amount of data written by the returned <code class="command">execname()</code> to the virtual file system.
-                       </div></div><a id="id596786" class="indexterm"></a><a id="id596802" class="indexterm"></a><a id="id501042" class="indexterm"></a><a id="id501058" class="indexterm"></a><a id="id500918" class="indexterm"></a><div class="para">
+}</pre></div></div><br class="example-break" /><a id="id536579" class="indexterm"></a><a id="id440597" class="indexterm"></a><a id="id612925" class="indexterm"></a><a id="id612940" class="indexterm"></a><div class="para">
+                       In <a class="xref" href="arrayops-aggregates.html#simpleaggregates">Example 3.21, “stat-aggregates.stp”</a>, the operator <code class="command">&lt;&lt;&lt; count</code> <span class="emphasis"><em>stores</em></span> the amount returned by <code class="literal">count</code> to to the associated value of the corresponding <code class="command">execname()</code> in the <code class="literal">reads</code> array. Remember, these values are <span class="emphasis"><em>stored</em></span>; they are not added to the associated values of each unique key, nor are they used to replace the current associated values. In a manner of speaking, think of it as having each unique key (<code class="command">execname()</code>) having multiple associated values, accumulating with each probe handler run.
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
+                               In the context of <a class="xref" href="arrayops-aggregates.html#simpleaggregates">Example 3.21, “stat-aggregates.stp”</a>, <code class="literal">count</code> returns the amount of data written by the returned <code class="command">execname()</code> to the virtual file system.
+                       </div></div></div><a id="id562260" class="indexterm"></a><a id="id562276" class="indexterm"></a><a id="id497520" class="indexterm"></a><a id="id444420" class="indexterm"></a><a id="id597210" class="indexterm"></a><div class="para">
                        To extract data collected by statistical aggregates, use the syntax format <code class="command">@<em class="replaceable"><code>extractor</code></em>(<em class="replaceable"><code>variable/array index expression</code></em>)</code>. <code class="command"><em class="replaceable"><code>extractor</code></em></code> can be any of the following integer extractors:
-               </div><div class="variablelist"><dl><dt><span class="term">count</span></dt><dd><a id="id538674" class="indexterm"></a><a id="id538690" class="indexterm"></a><a id="id650194" class="indexterm"></a><a id="id650210" class="indexterm"></a><div class="para">
-                                               Returns the number of all values stored into the variable/array index expression. Given the sample probe in <a class="xref" href="arrayops-aggregates.html#simpleaggregates" title="Example 3.19. stat-aggregates.stp">Example 3.19, “stat-aggregates.stp”</a>, the expression <code class="command">@count(writes[execname()])</code> will return <span class="emphasis"><em>how many values are stored</em></span> in each unique key in array <code class="literal">writes</code>.
-                                       </div></dd><dt><span class="term">sum</span></dt><dd><a id="id587644" class="indexterm"></a><a id="id537808" class="indexterm"></a><a id="id537824" class="indexterm"></a><a id="id643765" class="indexterm"></a><div class="para">
-                                               Returns the sum of all values stored into the variable/array index expression. Again, given sample probe in <a class="xref" href="arrayops-aggregates.html#simpleaggregates" title="Example 3.19. stat-aggregates.stp">Example 3.19, “stat-aggregates.stp”</a>, the expression <code class="command">@sum(writes[execname()])</code> will return <span class="emphasis"><em>the total of all values stored</em></span> in each unique key in array <code class="literal">writes</code>.
-                                       </div></dd><dt><span class="term">min</span></dt><dd><a id="id640716" class="indexterm"></a><a id="id640733" class="indexterm"></a><a id="id610342" class="indexterm"></a><a id="id610359" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">count</span></dt><dd><a id="id524367" class="indexterm"></a><a id="id620137" class="indexterm"></a><a id="id995424" class="indexterm"></a><a id="id638782" class="indexterm"></a><div class="para">
+                                               Returns the number of all values stored into the variable/array index expression. Given the sample probe in <a class="xref" href="arrayops-aggregates.html#simpleaggregates">Example 3.21, “stat-aggregates.stp”</a>, the expression <code class="command">@count(writes[execname()])</code> will return <span class="emphasis"><em>how many values are stored</em></span> in each unique key in array <code class="literal">writes</code>.
+                                       </div></dd><dt class="varlistentry"><span class="term">sum</span></dt><dd><a id="id440632" class="indexterm"></a><a id="id1942795" class="indexterm"></a><a id="id694025" class="indexterm"></a><a id="id692699" class="indexterm"></a><div class="para">
+                                               Returns the sum of all values stored into the variable/array index expression. Again, given sample probe in <a class="xref" href="arrayops-aggregates.html#simpleaggregates">Example 3.21, “stat-aggregates.stp”</a>, the expression <code class="command">@sum(writes[execname()])</code> will return <span class="emphasis"><em>the total of all values stored</em></span> in each unique key in array <code class="literal">writes</code>.
+                                       </div></dd><dt class="varlistentry"><span class="term">min</span></dt><dd><a id="id612418" class="indexterm"></a><a id="id601237" class="indexterm"></a><a id="id1942424" class="indexterm"></a><a id="id1966476" class="indexterm"></a><div class="para">
                                                Returns the smallest among all the values stored in the variable/array index expression.
-                                       </div></dd><dt><span class="term">max</span></dt><dd><a id="id490326" class="indexterm"></a><a id="id638831" class="indexterm"></a><a id="id638847" class="indexterm"></a><a id="id595220" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">max</span></dt><dd><a id="id586445" class="indexterm"></a><a id="id586460" class="indexterm"></a><a id="id467793" class="indexterm"></a><a id="id699002" class="indexterm"></a><div class="para">
                                                Returns the largest among all the values stored in the variable/array index expression.
-                                       </div></dd><dt><span class="term">avg</span></dt><dd><a id="id611457" class="indexterm"></a><a id="id645207" class="indexterm"></a><a id="id645224" class="indexterm"></a><a id="id646110" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">avg</span></dt><dd><a id="id1966358" class="indexterm"></a><a id="id686130" class="indexterm"></a><a id="id686145" class="indexterm"></a><a id="id454543" class="indexterm"></a><div class="para">
                                                Returns the average of all values stored in the variable/array index expression.
                                        </div></dd></dl></div><div class="para">
                        When using statistical aggregates, you can also build array constructs that use multiple index expressions (to a maximum of 5). This is helpful in capturing additional contextual information during a probe. For example:
-               </div><div class="example" id="multiplearrayindices"><div class="example-contents"><pre class="programlisting">
-global reads
+               </div><div class="example" id="multiplearrayindices"><h6>Example 3.22. Multiple Array Indexes</h6><div class="example-contents"><pre class="programlisting">global reads
 probe vfs.read
 {
   reads[execname(),pid()] &lt;&lt;&lt; 1
@@ -38,9 +35,8 @@ probe timer.s(3)
 {
   foreach([var1,var2] in reads)
     printf("%s (%d) : %d \n", var1, var2, @count(reads[var1,var2]))
-}
-</pre></div><h6>Example 3.20. Multiple Array Indexes</h6></div><br class="example-break" /><div class="para">
-                       In <a class="xref" href="arrayops-aggregates.html#multiplearrayindices" title="Example 3.20. Multiple Array Indexes">Example 3.20, “Multiple Array Indexes”</a>, the first probe tracks how many times each process performs a VFS read. What makes this different from earlier examples is that this array associates a performed read to both a process name <span class="emphasis"><em>and</em></span> its corresponding process ID.
+}</pre></div></div><br class="example-break" /><div class="para">
+                       In <a class="xref" href="arrayops-aggregates.html#multiplearrayindices">Example 3.22, “Multiple Array Indexes”</a>, the first probe tracks how many times each process performs a VFS read. What makes this different from earlier examples is that this array associates a performed read to both a process name <span class="emphasis"><em>and</em></span> its corresponding process ID.
                </div><div class="para">
-                       The second probe in <a class="xref" href="arrayops-aggregates.html#multiplearrayindices" title="Example 3.20. Multiple Array Indexes">Example 3.20, “Multiple Array Indexes”</a> demonstrates how to process and print the information collected by the array <code class="literal">reads</code>. Note how the <code class="command">foreach</code> statement uses the same number of variables (i.e. <code class="literal">var1</code> and <code class="literal">var2</code>) contained in the first instance of the array <code class="literal">reads</code> from the first probe.
+                       The second probe in <a class="xref" href="arrayops-aggregates.html#multiplearrayindices">Example 3.22, “Multiple Array Indexes”</a> demonstrates how to process and print the information collected by the array <code class="literal">reads</code>. Note how the <code class="command">foreach</code> statement uses the same number of variables (i.e. <code class="literal">var1</code> and <code class="literal">var2</code>) contained in the first instance of the array <code class="literal">reads</code> from the first probe.
                </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-conditionals.html"><strong>Prev</strong>3.5.6. Using Arrays in Conditional Statements</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="understanding-tapsets.html"><strong>Next</strong>3.6. Tapsets</a></li></ul></body></html>
index 0ddf98ef522b40100d6e2b90db19ea4af6cff5a4..cb7be2bdb245933c538b95b433f967bf13dc669c 100644 (file)
@@ -1,9 +1,8 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.6. Using Arrays in Conditional Statements</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-deleting.html" title="3.5.5. Clearing/Deleting Arrays and Array Elements" /><link rel="next" href="arrayops-aggregates.html" title="3.5.7. Computing for Statistical Aggregates" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-deleting.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-aggregates.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.6. Using Arrays in Conditional Statements"><div class="titlepage"><div><div><h3 class="title" id="arrayops-conditionals">3.5.6. Using Arrays in Conditional Statements</h3></div></div></div><a id="id539184" class="indexterm"></a><a id="id539196" class="indexterm"></a><a id="id495432" class="indexterm"></a><a id="id495444" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.6. Using Arrays in Conditional Statements</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-deleting.html" title="3.5.5. Clearing/Deleting Arrays and Array Elements" /><link rel="next" href="arrayops-aggregates.html" title="3.5.7. Computing for Statistical Aggregates" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-deleting.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-aggregates.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-conditionals"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-conditionals">3.5.6. Using Arrays in Conditional Statements</h3></div></div></div><a id="id409720" class="indexterm"></a><a id="id737688" class="indexterm"></a><a id="id693247" class="indexterm"></a><a id="id693258" class="indexterm"></a><div class="para">
                        You can also use associative arrays in <code class="command">if</code> statements. This is useful if you want to execute a subroutine once a value in the array matches a certain condition. Consider the following example:
-               </div><div class="example" id="simplevfsreadprintif"><div class="example-contents"><pre class="programlisting">
-global reads
+               </div><div class="example" id="simplevfsreadprintif"><h6>Example 3.19. vfsreads-print-if-1kb.stp</h6><div class="example-contents"><pre class="programlisting">global reads
 probe vfs.read
 {
   reads[execname()] ++
@@ -17,17 +16,13 @@ probe timer.s(3)
       printf("%s : %dkB \n", count, reads[count]/1024)
     else
       printf("%s : %dB \n", count, reads[count])
-}
-</pre></div><h6>Example 3.17. vfsreads-print-if-1kb.stp</h6></div><br class="example-break" /><div class="para">
-                       Every three seconds, <a class="xref" href="arrayops-conditionals.html#simplevfsreadprintif" title="Example 3.17. vfsreads-print-if-1kb.stp">Example 3.17, “vfsreads-print-if-1kb.stp”</a> prints out a list of all processes, along with how many times each process performed a VFS read. If the associated value of a process name is equal or greater than 1024, the <code class="command">if</code> statement in the script converts and prints it out in <code class="command">kB</code>.
-               </div><div class="formalpara"><h5 class="formalpara" id="id639144">Testing for Membership</h5><a id="id629014" class="indexterm"></a><a id="id629030" class="indexterm"></a><a id="id601544" class="indexterm"></a><a id="id608871" class="indexterm"></a><a id="id608888" class="indexterm"></a>
+}</pre></div></div><br class="example-break" /><div class="para">
+                       Every three seconds, <a class="xref" href="arrayops-conditionals.html#simplevfsreadprintif">Example 3.19, “vfsreads-print-if-1kb.stp”</a> prints out a list of all processes, along with how many times each process performed a VFS read. If the associated value of a process name is equal or greater than 1024, the <code class="command">if</code> statement in the script converts and prints it out in <code class="command">kB</code>.
+               </div><div class="formalpara"><h5 class="formalpara" id="id1920016">Testing for Membership</h5><a id="id1920025" class="indexterm"></a><a id="id727542" class="indexterm"></a><a id="id688306" class="indexterm"></a><a id="id451025" class="indexterm"></a><a id="id541405" class="indexterm"></a>
                                You can also test whether a specific unique key is a member of an array. Further, membership in an array can be used in <code class="command">if</code> statements, as in:
-                       </div><pre class="screen">
-if([<em class="replaceable"><code>index_expression</code></em>] in <em class="replaceable"><code>array_name</code></em>) <em class="replaceable"><code>statement</code></em>
-</pre><div class="para">
+                       </div><pre class="screen">if([<em class="replaceable"><code>index_expression</code></em>] in <em class="replaceable"><code>array_name</code></em>) <em class="replaceable"><code>statement</code></em></pre><div class="para">
                        To illustrate this, consider the following example:
-               </div><div class="example" id="simplesimplevfsreadprintifmember"><div class="example-contents"><pre class="programlisting">
-global reads
+               </div><div class="example" id="simplesimplevfsreadprintifmember"><h6>Example 3.20. vfsreads-stop-on-stapio2.stp</h6><div class="example-contents"><pre class="programlisting">global reads
 
 probe vfs.read
 {
@@ -37,13 +32,12 @@ probe vfs.read
 probe timer.s(3)
 {
   printf("=======\n")
-  foreach (count in reads+) 
+  foreach (count in reads+)
     printf("%s : %d \n", count, reads[count])
   if(["stapio"] in reads) {
     printf("stapio read detected, exiting\n")
     exit()
   }
-}
-</pre></div><h6>Example 3.18. vfsreads-stop-on-stapio2.stp</h6></div><br class="example-break" /><div class="para">
+}</pre></div></div><br class="example-break" /><div class="para">
                        The <code class="command">if(["stapio"] in reads)</code> statement instructs the script to print <code class="computeroutput">stapio read detected, exiting</code> once the unique key <code class="command">stapio</code> is added to the array <code class="command">reads</code>.
                </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-deleting.html"><strong>Prev</strong>3.5.5. Clearing/Deleting Arrays and Array Elements</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-aggregates.html"><strong>Next</strong>3.5.7. Computing for Statistical Aggregates</a></li></ul></body></html>
index 5b51002989afd5cb377b69632521be7ccbaef20b..1c8db5efa7522e0f62719ef40744e1e72e037910 100644 (file)
@@ -1,27 +1,24 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.5. Clearing/Deleting Arrays and Array Elements</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array" /><link rel="next" href="arrayops-conditionals.html" title="3.5.6. Using Arrays in Conditional Statements" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-foreach.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-conditionals.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.5. Clearing/Deleting Arrays and Array Elements"><div class="titlepage"><div><div><h3 class="title" id="arrayops-deleting">3.5.5. Clearing/Deleting Arrays and Array Elements</h3></div></div></div><a id="id499459" class="indexterm"></a><a id="id499470" class="indexterm"></a><a id="id611515" class="indexterm"></a><a id="id611527" class="indexterm"></a><a id="id601311" class="indexterm"></a><div class="para">
-                       Sometimes, you may need to clear the associated values in array elements, or reset an entire array for re-use in another probe. <a class="xref" href="arrayops-foreach.html#simplevfsreadprint" title="Example 3.15. cumulative-vfsreads.stp">Example 3.15, “cumulative-vfsreads.stp”</a> in <a class="xref" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array">Section 3.5.4, “Processing Multiple Elements in an Array”</a> allows you to track how the number of VFS reads per process grows over time, but it does not show you the number of VFS reads each process makes per 3-second period.
-               </div><a id="id508980" class="indexterm"></a><a id="id495118" class="indexterm"></a><a id="id495134" class="indexterm"></a><a id="id507527" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.5. Clearing/Deleting Arrays and Array Elements</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array" /><link rel="next" href="arrayops-conditionals.html" title="3.5.6. Using Arrays in Conditional Statements" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-foreach.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-conditionals.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-deleting"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-deleting">3.5.5. Clearing/Deleting Arrays and Array Elements</h3></div></div></div><a id="id745386" class="indexterm"></a><a id="id745398" class="indexterm"></a><a id="id1963458" class="indexterm"></a><a id="id527678" class="indexterm"></a><a id="id417010" class="indexterm"></a><div class="para">
+                       Sometimes, you may need to clear the associated values in array elements, or reset an entire array for re-use in another probe. <a class="xref" href="arrayops-foreach.html#simplevfsreadprint">Example 3.17, “cumulative-vfsreads.stp”</a> in <a class="xref" href="arrayops-foreach.html">Section 3.5.4, “Processing Multiple Elements in an Array”</a> allows you to track how the number of VFS reads per process grows over time, but it does not show you the number of VFS reads each process makes per 3-second period.
+               </div><a id="id591671" class="indexterm"></a><a id="id682623" class="indexterm"></a><a id="id522227" class="indexterm"></a><a id="id578116" class="indexterm"></a><div class="para">
                        To do that, you will need to clear the values accumulated by the array. You can accomplish this using the <code class="command">delete</code> operator to delete elements in an array, or an entire array. Consider the following example:
-               </div><a id="id540365" class="indexterm"></a><a id="id587604" class="indexterm"></a><a id="id587620" class="indexterm"></a><a id="id530560" class="indexterm"></a><div class="example" id="simplevfsreadprintnotcumulative"><div class="example-contents"><pre class="programlisting">
-global reads
+               </div><a id="id618177" class="indexterm"></a><a id="id582548" class="indexterm"></a><a id="id411787" class="indexterm"></a><a id="id536996" class="indexterm"></a><div class="example" id="simplevfsreadprintnotcumulative"><h6>Example 3.18. noncumulative-vfsreads.stp</h6><div class="example-contents"><pre class="programlisting">global reads
 probe vfs.read
-{ 
+{
   reads[execname()] ++
 }
 probe timer.s(3)
 {
   foreach (count in reads)
     printf("%s : %d \n", count, reads[count])
-  delete reads 
-}
-</pre></div><h6>Example 3.16. noncumulative-vfsreads.stp</h6></div><br class="example-break" /><div class="para">
-                       In <a class="xref" href="arrayops-deleting.html#simplevfsreadprintnotcumulative" title="Example 3.16. noncumulative-vfsreads.stp">Example 3.16, “noncumulative-vfsreads.stp”</a>, the second probe prints the number of VFS reads each process made <span class="emphasis"><em>within the probed 3-second period only</em></span>. The <code class="command">delete reads</code> statement clears the <code class="command">reads</code> array within the probe.
-               </div><div class="note"><h2>Note</h2><a id="id646585" class="indexterm"></a><a id="id646600" class="indexterm"></a><a id="id495405" class="indexterm"></a><a id="id506233" class="indexterm"></a><div class="para">
-                               You can have multiple array operations within the same probe. Using the examples from <a class="xref" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array">Section 3.5.4, “Processing Multiple Elements in an Array”</a> and <a class="xref" href="arrayops-deleting.html" title="3.5.5. Clearing/Deleting Arrays and Array Elements">Section 3.5.5, “Clearing/Deleting Arrays and Array Elements”</a> , you can track the number of VFS reads each process makes per 3-second period <span class="emphasis"><em>and</em></span> tally the cumulative VFS reads of those same processes. Consider the following example:
-                       </div><pre class="screen">
-global reads, totalreads
+  delete reads
+}</pre></div></div><br class="example-break" /><div class="para">
+                       In <a class="xref" href="arrayops-deleting.html#simplevfsreadprintnotcumulative">Example 3.18, “noncumulative-vfsreads.stp”</a>, the second probe prints the number of VFS reads each process made <span class="emphasis"><em>within the probed 3-second period only</em></span>. The <code class="command">delete reads</code> statement clears the <code class="command">reads</code> array within the probe.
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><a id="id563235" class="indexterm"></a><a id="id578032" class="indexterm"></a><a id="id1970828" class="indexterm"></a><a id="id503800" class="indexterm"></a><div class="para">
+                               You can have multiple array operations within the same probe. Using the examples from <a class="xref" href="arrayops-foreach.html">Section 3.5.4, “Processing Multiple Elements in an Array”</a> and <a class="xref" href="arrayops-deleting.html">Section 3.5.5, “Clearing/Deleting Arrays and Array Elements”</a> , you can track the number of VFS reads each process makes per 3-second period <span class="emphasis"><em>and</em></span> tally the cumulative VFS reads of those same processes. Consider the following example:
+                       </div><pre class="screen">global reads, totalreads
 
 probe vfs.read
 {
@@ -32,7 +29,7 @@ probe vfs.read
 probe timer.s(3)
 {
   printf("=======\n")
-  foreach (count in reads-) 
+  foreach (count in reads-)
     printf("%s : %d \n", count, reads[count])
   delete reads
 }
@@ -42,7 +39,6 @@ probe end
   printf("TOTALS\n")
   foreach (total in totalreads-)
     printf("%s : %d \n", total, totalreads[total])
-}
-</pre><div class="para">
+}</pre><div class="para">
                                In this example, the arrays <code class="command">reads</code> and <code class="command">totalreads</code> track the same information, and are printed out in a similar fashion. The only difference here is that <code class="command">reads</code> is cleared every 3-second period, whereas <code class="command">totalreads</code> keeps growing.
-                       </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-foreach.html"><strong>Prev</strong>3.5.4. Processing Multiple Elements in an Array</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-conditionals.html"><strong>Next</strong>3.5.6. Using Arrays in Conditional Statements</a></li></ul></body></html>
+                       </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-foreach.html"><strong>Prev</strong>3.5.4. Processing Multiple Elements in an Array</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-conditionals.html"><strong>Next</strong>3.5.6. Using Arrays in Conditional Statements</a></li></ul></body></html>
index cc37dd95d35e5473c3f99acee22b36891d2b8c13..5df5240b55f1d9e2458ef091229f20f6cdaa645d 100644 (file)
@@ -1,34 +1,30 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.4. Processing Multiple Elements in an Array</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-increment.html" title="3.5.3. Incrementing Associated Values" /><link rel="next" href="arrayops-deleting.html" title="3.5.5. Clearing/Deleting Arrays and Array Elements" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-increment.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-deleting.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.4. Processing Multiple Elements in an Array"><div class="titlepage"><div><div><h3 class="title" id="arrayops-foreach">3.5.4. Processing Multiple Elements in an Array</h3></div></div></div><a id="id508640" class="indexterm"></a><a id="id495726" class="indexterm"></a><a id="id643508" class="indexterm"></a><a id="id643520" class="indexterm"></a><a id="id506964" class="indexterm"></a><a id="id506976" class="indexterm"></a><div class="para">
-                       Once you've collected enough information in an array, you will need to retrieve and process all elements in that array to make it useful. Consider <a class="xref" href="arrayops-increment.html#simplesimplevfsread" title="Example 3.14. vfsreads.stp">Example 3.14, “vfsreads.stp”</a>: the script collects information about how many VFS reads each process performs, but does not specify what to do with it. The obvious means for making <a class="xref" href="arrayops-increment.html#simplesimplevfsread" title="Example 3.14. vfsreads.stp">Example 3.14, “vfsreads.stp”</a> useful is to print the key pairs in the array <code class="command">reads</code>, but how?
-               </div><a id="id502431" class="indexterm"></a><a id="id596065" class="indexterm"></a><a id="id612206" class="indexterm"></a><a id="id612222" class="indexterm"></a><a id="id500107" class="indexterm"></a><a id="id600644" class="indexterm"></a><a id="id636256" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.4. Processing Multiple Elements in an Array</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-increment.html" title="3.5.3. Incrementing Associated Values" /><link rel="next" href="arrayops-deleting.html" title="3.5.5. Clearing/Deleting Arrays and Array Elements" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-increment.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-deleting.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-foreach"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-foreach">3.5.4. Processing Multiple Elements in an Array</h3></div></div></div><a id="id525283" class="indexterm"></a><a id="id586748" class="indexterm"></a><a id="id532627" class="indexterm"></a><a id="id685374" class="indexterm"></a><a id="id685386" class="indexterm"></a><a id="id511733" class="indexterm"></a><div class="para">
+                       Once you've collected enough information in an array, you will need to retrieve and process all elements in that array to make it useful. Consider <a class="xref" href="arrayops-increment.html#simplesimplevfsread">Example 3.16, “vfsreads.stp”</a>: the script collects information about how many VFS reads each process performs, but does not specify what to do with it. The obvious means for making <a class="xref" href="arrayops-increment.html#simplesimplevfsread">Example 3.16, “vfsreads.stp”</a> useful is to print the key pairs in the array <code class="command">reads</code>, but how?
+               </div><a id="id684805" class="indexterm"></a><a id="id712270" class="indexterm"></a><a id="id512039" class="indexterm"></a><a id="id497567" class="indexterm"></a><a id="id456060" class="indexterm"></a><a id="id409096" class="indexterm"></a><a id="id550752" class="indexterm"></a><div class="para">
                        The best way to process all key pairs in an array (as an iteration) is to use the <code class="command">foreach</code> statement. Consider the following example:
-               </div><a id="id535759" class="indexterm"></a><a id="id643931" class="indexterm"></a><a id="id643947" class="indexterm"></a><a id="id609219" class="indexterm"></a><a id="id508600" class="indexterm"></a><div class="example" id="simplevfsreadprint"><div class="example-contents"><pre class="programlisting">
-global reads
+               </div><a id="id702455" class="indexterm"></a><a id="id1974673" class="indexterm"></a><a id="id589787" class="indexterm"></a><a id="id734883" class="indexterm"></a><a id="id1017023" class="indexterm"></a><div class="example" id="simplevfsreadprint"><h6>Example 3.17. cumulative-vfsreads.stp</h6><div class="example-contents"><pre class="programlisting">global reads
 probe vfs.read
-{ 
+{
   reads[execname()] ++
 }
 probe timer.s(3)
 {
   foreach (count in reads)
     printf("%s : %d \n", count, reads[count])
-}
-</pre></div><h6>Example 3.15. cumulative-vfsreads.stp</h6></div><br class="example-break" /><div class="para">
-                       In the second probe of <a class="xref" href="arrayops-foreach.html#simplevfsreadprint" title="Example 3.15. cumulative-vfsreads.stp">Example 3.15, “cumulative-vfsreads.stp”</a>, the <code class="command">foreach</code> statement uses the variable <code class="command">count</code> to reference each iteration of a unique key in the array <code class="command">reads</code>. The <code class="command">reads[count]</code> array statement in the same probe retrieves the associated value of each unique key.
+}</pre></div></div><br class="example-break" /><div class="para">
+                       In the second probe of <a class="xref" href="arrayops-foreach.html#simplevfsreadprint">Example 3.17, “cumulative-vfsreads.stp”</a>, the <code class="command">foreach</code> statement uses the variable <code class="command">count</code> to reference each iteration of a unique key in the array <code class="command">reads</code>. The <code class="command">reads[count]</code> array statement in the same probe retrieves the associated value of each unique key.
                </div><div class="para">
-                       Given what we know about the first probe in <a class="xref" href="arrayops-foreach.html#simplevfsreadprint" title="Example 3.15. cumulative-vfsreads.stp">Example 3.15, “cumulative-vfsreads.stp”</a>, the script prints VFS-read statistics every 3 seconds, displaying names of processes that performed a VFS-read along with a corresponding VFS-read count.
-               </div><a id="id506672" class="indexterm"></a><a id="id506688" class="indexterm"></a><a id="id646449" class="indexterm"></a><a id="id511939" class="indexterm"></a><a id="id647749" class="indexterm"></a><a id="id647765" class="indexterm"></a><a id="id500707" class="indexterm"></a><a id="id596084" class="indexterm"></a><div class="para">
-                       Now, remember that the <code class="command">foreach</code> statement in <a class="xref" href="arrayops-foreach.html#simplevfsreadprint" title="Example 3.15. cumulative-vfsreads.stp">Example 3.15, “cumulative-vfsreads.stp”</a> prints <span class="emphasis"><em>all</em></span> iterations of process names in the array, and in no particular order. You can instruct the script to process the iterations in a particular order by using <code class="command">+</code> (ascending) or <code class="command">-</code> (descending). In addition, you can also limit the number of iterations the script needs to process with the <code class="command">limit <em class="replaceable"><code>value</code></em></code> option.
+                       Given what we know about the first probe in <a class="xref" href="arrayops-foreach.html#simplevfsreadprint">Example 3.17, “cumulative-vfsreads.stp”</a>, the script prints VFS-read statistics every 3 seconds, displaying names of processes that performed a VFS-read along with a corresponding VFS-read count.
+               </div><a id="id497174" class="indexterm"></a><a id="id1969397" class="indexterm"></a><a id="id1963392" class="indexterm"></a><a id="id777443" class="indexterm"></a><a id="id751430" class="indexterm"></a><a id="id546383" class="indexterm"></a><a id="id1969382" class="indexterm"></a><a id="id586436" class="indexterm"></a><div class="para">
+                       Now, remember that the <code class="command">foreach</code> statement in <a class="xref" href="arrayops-foreach.html#simplevfsreadprint">Example 3.17, “cumulative-vfsreads.stp”</a> prints <span class="emphasis"><em>all</em></span> iterations of process names in the array, and in no particular order. You can instruct the script to process the iterations in a particular order by using <code class="command">+</code> (ascending) or <code class="command">-</code> (descending). In addition, you can also limit the number of iterations the script needs to process with the <code class="command">limit <em class="replaceable"><code>value</code></em></code> option.
                </div><div class="para">
                        For example, consider the following replacement probe:
-               </div><pre class="screen">
-probe timer.s(3)
+               </div><pre class="screen">probe timer.s(3)
 {
   foreach (count in reads- limit 10)
     printf("%s : %d \n", count, reads[count])
-}
-</pre><div class="para">
+}</pre><div class="para">
                        This <code class="command">foreach</code> statement instructs the script to process the elements in the array <code class="command">reads</code> in descending order (of associated value). The <code class="command">limit 10</code> option instructs the <code class="command">foreach</code> to only process the first ten iterations (i.e. print the first 10, starting with the highest value).
                </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-increment.html"><strong>Prev</strong>3.5.3. Incrementing Associated Values</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-deleting.html"><strong>Next</strong>3.5.5. Clearing/Deleting Arrays and Array Elements</a></li></ul></body></html>
index 902cf1c00e0248a89135306be0dc07a03cffdc16..02b0b052d404986240d6b0312e22930b002169f9 100644 (file)
@@ -1,16 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.3. Incrementing Associated Values</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-readvalues.html" title="3.5.2. Reading Values From Arrays" /><link rel="next" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-readvalues.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-foreach.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.3. Incrementing Associated Values"><div class="titlepage"><div><div><h3 class="title" id="arrayops-increment">3.5.3. Incrementing Associated Values</h3></div></div></div><a id="id510177" class="indexterm"></a><a id="id537242" class="indexterm"></a><a id="id537254" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.3. Incrementing Associated Values</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayops-readvalues.html" title="3.5.2. Reading Values From Arrays" /><link rel="next" href="arrayops-foreach.html" title="3.5.4. Processing Multiple Elements in an Array" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-readvalues.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-foreach.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-increment"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-increment">3.5.3. Incrementing Associated Values</h3></div></div></div><a id="id1919042" class="indexterm"></a><a id="id639384" class="indexterm"></a><a id="id620717" class="indexterm"></a><div class="para">
                        Use <code class="command">++</code> to increment the associated value of a unique key in an array, as in:
-               </div><pre class="screen">
-<em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>] ++
-</pre><div class="para">
+               </div><pre class="screen"><em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>] ++</pre><div class="para">
                        Again, you can also use a handler function for your <code class="command"><em class="replaceable"><code>index_expression</code></em></code>. For example, if you wanted to tally how many times a specific process performed a read to the virtual file system (using the event <code class="command">vfs.read</code>), you can use the following probe:
-               </div><a id="id511918" class="indexterm"></a><a id="id605796" class="indexterm"></a><a id="id605812" class="indexterm"></a><a id="id498223" class="indexterm"></a><a id="id596634" class="indexterm"></a><div class="example" id="simplesimplevfsread"><div class="example-contents"><pre class="programlisting">
-probe vfs.read
+               </div><a id="id454418" class="indexterm"></a><a id="id524339" class="indexterm"></a><a id="id573391" class="indexterm"></a><a id="id620709" class="indexterm"></a><a id="id606708" class="indexterm"></a><div class="example" id="simplesimplevfsread"><h6>Example 3.16. vfsreads.stp</h6><div class="example-contents"><pre class="programlisting">probe vfs.read
 {
   reads[execname()] ++
-}
-</pre></div><h6>Example 3.14. vfsreads.stp</h6></div><br class="example-break" /><div class="para">
-                       In <a class="xref" href="arrayops-increment.html#simplesimplevfsread" title="Example 3.14. vfsreads.stp">Example 3.14, “vfsreads.stp”</a>, the first time that the probe returns the process name <code class="command">gnome-terminal</code> (i.e. the first time <code class="command">gnome-terminal</code> performs a VFS read), that process name is set as the unique key <code class="literal">gnome-terminal</code> with an associated value of 1. The next time that the probe returns the process name <code class="command">gnome-terminal</code>, SystemTap increments the associated value of <code class="literal">gnome-terminal</code> by 1. SystemTap performs this operation for <span class="emphasis"><em>all</em></span> process names as the probe returns them.
+}</pre></div></div><br class="example-break" /><div class="para">
+                       In <a class="xref" href="arrayops-increment.html#simplesimplevfsread">Example 3.16, “vfsreads.stp”</a>, the first time that the probe returns the process name <code class="command">gnome-terminal</code> (i.e. the first time <code class="command">gnome-terminal</code> performs a VFS read), that process name is set as the unique key <code class="literal">gnome-terminal</code> with an associated value of 1. The next time that the probe returns the process name <code class="command">gnome-terminal</code>, SystemTap increments the associated value of <code class="literal">gnome-terminal</code> by 1. SystemTap performs this operation for <span class="emphasis"><em>all</em></span> process names as the probe returns them.
                </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-readvalues.html"><strong>Prev</strong>3.5.2. Reading Values From Arrays</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-foreach.html"><strong>Next</strong>3.5.4. Processing Multiple Elements in an Array</a></li></ul></body></html>
index 7732581f596d3301c4315266a208dceb53b38b7a..1e1d6c10c1fc5c102fc1677d3b5b51c06c45cf41 100644 (file)
@@ -1,13 +1,11 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.2. Reading Values From Arrays</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="next" href="arrayops-increment.html" title="3.5.3. Incrementing Associated Values" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayoperators.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-increment.html"><strong>Next</strong></a></li></ul><div class="section" title="3.5.2. Reading Values From Arrays"><div class="titlepage"><div><div><h3 class="title" id="arrayops-readvalues">3.5.2. Reading Values From Arrays</h3></div></div></div><a id="id641392" class="indexterm"></a><a id="id644305" class="indexterm"></a><a id="id644317" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.5.2. Reading Values From Arrays</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="prev" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /><link rel="next" href="arrayops-increment.html" title="3.5.3. Incrementing Associated Values" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayoperators.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayops-increment.html"><strong>Next</strong></a></li></ul><div class="section" id="arrayops-readvalues"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="arrayops-readvalues">3.5.2. Reading Values From Arrays</h3></div></div></div><a id="id664233" class="indexterm"></a><a id="id467776" class="indexterm"></a><a id="id602931" class="indexterm"></a><div class="para">
                        You can also read values from an array the same way you would read the value of a variable. To do so, include the <code class="command"><em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>]</code> statement as an element in a mathematical expression. For example:
-               </div><a id="id491834" class="indexterm"></a><a id="id498600" class="indexterm"></a><a id="id491267" class="indexterm"></a><a id="id491960" class="indexterm"></a><a id="id609862" class="indexterm"></a><a id="id500268" class="indexterm"></a><a id="id635933" class="indexterm"></a><a id="id613502" class="indexterm"></a><a id="id650004" class="indexterm"></a><a id="id650020" class="indexterm"></a><div class="example" id="arrayreadingvaluesfrom"><div class="example-contents"><pre class="screen">
-delta = gettimeofday_s() - foo[tid()]
-</pre></div><h6>Example 3.13. Using Array Values in Simple Computations</h6></div><br class="example-break" /><div class="para">
-                       This example assumes that the array <code class="command">foo</code> was built using the construct in <a class="xref" href="arrayoperators.html#arrays-timestampprocessname" title="Example 3.12. Associating Timestamps to Process Names">Example 3.12, “Associating Timestamps to Process Names”</a> (from <a class="xref" href="arrayoperators.html#arrayops-assignvalue" title="3.5.1. Assigning an Associated Value">Section 3.5.1, “Assigning an Associated Value”</a>). This sets a timestamp that will serve as a <span class="emphasis"><em>reference point</em></span>, to be used in computing for <code class="literal">delta</code>.
+               </div><a id="id450320" class="indexterm"></a><a id="id754783" class="indexterm"></a><a id="id535096" class="indexterm"></a><a id="id606827" class="indexterm"></a><a id="id624652" class="indexterm"></a><a id="id1970357" class="indexterm"></a><a id="id743174" class="indexterm"></a><a id="id501922" class="indexterm"></a><a id="id637494" class="indexterm"></a><a id="id1950916" class="indexterm"></a><div class="example" id="arrayreadingvaluesfrom"><h6>Example 3.15. Using Array Values in Simple Computations</h6><div class="example-contents"><pre class="screen">delta = gettimeofday_s() - foo[tid()]</pre></div></div><br class="example-break" /><div class="para">
+                       This example assumes that the array <code class="command">foo</code> was built using the construct in <a class="xref" href="arrayoperators.html#arrays-timestampprocessname">Example 3.14, “Associating Timestamps to Process Names”</a> (from <a class="xref" href="arrayoperators.html#arrayops-assignvalue">Section 3.5.1, “Assigning an Associated Value”</a>). This sets a timestamp that will serve as a <span class="emphasis"><em>reference point</em></span>, to be used in computing for <code class="literal">delta</code>.
                </div><div class="para">
-                       The construct in <a class="xref" href="arrayops-readvalues.html#arrayreadingvaluesfrom" title="Example 3.13. Using Array Values in Simple Computations">Example 3.13, “Using Array Values in Simple Computations”</a> computes a value for the variable <code class="literal">delta</code> by subtracting the associated value of the key <code class="literal">tid()</code> from the current <code class="command">gettimeofday_s()</code>. The construct does this by <span class="emphasis"><em>reading</em></span> the value of <code class="literal">tid()</code> from the array. This particular construct is useful for determining the time between two events, such as the start and completion of a read operation.
-               </div><a id="id492483" class="indexterm"></a><a id="id545910" class="indexterm"></a><a id="id596468" class="indexterm"></a><a id="id644145" class="indexterm"></a><div class="note"><h2>Note</h2><div class="para">
-                               If the <code class="command"><em class="replaceable"><code>index_expression</code></em></code> cannot find the unique key, it returns a value of 0 (for numerical operations, such as <a class="xref" href="arrayops-readvalues.html#arrayreadingvaluesfrom" title="Example 3.13. Using Array Values in Simple Computations">Example 3.13, “Using Array Values in Simple Computations”</a>) or a null/empty string value (for string operations) by default.
-                       </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayoperators.html"><strong>Prev</strong>3.5. Array Operations in SystemTap</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-increment.html"><strong>Next</strong>3.5.3. Incrementing Associated Values</a></li></ul></body></html>
+                       The construct in <a class="xref" href="arrayops-readvalues.html#arrayreadingvaluesfrom">Example 3.15, “Using Array Values in Simple Computations”</a> computes a value for the variable <code class="literal">delta</code> by subtracting the associated value of the key <code class="literal">tid()</code> from the current <code class="command">gettimeofday_s()</code>. The construct does this by <span class="emphasis"><em>reading</em></span> the value of <code class="literal">tid()</code> from the array. This particular construct is useful for determining the time between two events, such as the start and completion of a read operation.
+               </div><a id="id552794" class="indexterm"></a><a id="id727556" class="indexterm"></a><a id="id1920305" class="indexterm"></a><a id="id639507" class="indexterm"></a><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
+                               If the <code class="command"><em class="replaceable"><code>index_expression</code></em></code> cannot find the unique key, it returns a value of 0 (for numerical operations, such as <a class="xref" href="arrayops-readvalues.html#arrayreadingvaluesfrom">Example 3.15, “Using Array Values in Simple Computations”</a>) or a null/empty string value (for string operations) by default.
+                       </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayoperators.html"><strong>Prev</strong>3.5. Array Operations in SystemTap</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayops-increment.html"><strong>Next</strong>3.5.3. Incrementing Associated Values</a></li></ul></body></html>
index 47ed86e33db995b04f0554db1207ac24bf58e44f..940925a200d7ea8603095d2d9077cea699bc449e 100644 (file)
@@ -1,21 +1,15 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.4. Associative Arrays</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="commandlineargssect.html" title="3.3.3. Command-Line Arguments" /><link rel="next" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="commandlineargssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayoperators.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="3.4. Associative Arrays" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="associativearrays">3.4. Associative Arrays</h2></div></div></div><a id="id605788" class="indexterm"></a><a id="id637410" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.4. Associative Arrays</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="commandlineargssect.html" title="3.3.4. Command-Line Arguments" /><link rel="next" href="arrayoperators.html" title="3.5. Array Operations in SystemTap" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="commandlineargssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="arrayoperators.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="associativearrays" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="associativearrays">3.4. Associative Arrays</h2></div></div></div><a id="id553959" class="indexterm"></a><a id="id707893" class="indexterm"></a><div class="para">
                SystemTap also supports the use of associative arrays. While an ordinary variable represents a single value, associative arrays can represent a collection of values. Simply put, an associative array is a collection of unique keys; each key in the array has a value associated with it.
-       </div><a id="id539784" class="indexterm"></a><a id="id543875" class="indexterm"></a><a id="id495236" class="indexterm"></a><a id="id495875" class="indexterm"></a><a id="id608857" class="indexterm"></a><a id="id605521" class="indexterm"></a><a id="id506320" class="indexterm"></a><a id="id644129" class="indexterm"></a><div class="para">
-               Since associative arrays are normally processed in multiple probes (as we will demonstrate later), they are declared as <code class="command">global</code> variables in the SystemTap script. The syntax for accessing an element in an associative array is similar to that of <code class="command">awk</code>, and is as follows:
-       </div><a id="id537365" class="indexterm"></a><a id="id501021" class="indexterm"></a><a id="id587660" class="indexterm"></a><pre class="screen">
-<em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>]
-</pre><div class="para">
+       </div><a id="id589327" class="indexterm"></a><a id="id1953382" class="indexterm"></a><a id="id552807" class="indexterm"></a><a id="id573399" class="indexterm"></a><a id="id578015" class="indexterm"></a><a id="id495192" class="indexterm"></a><a id="id443389" class="indexterm"></a><a id="id624641" class="indexterm"></a><div class="para">
+               Since associative arrays are normally processed in multiple probes (as we will demonstrate later), they should be declared as <code class="command">global</code> variables in the SystemTap script. The syntax for accessing an element in an associative array is similar to that of <code class="command">awk</code>, and is as follows:
+       </div><a id="id534065" class="indexterm"></a><a id="id528102" class="indexterm"></a><a id="id612825" class="indexterm"></a><pre class="screen"><em class="replaceable"><code>array_name</code></em>[<em class="replaceable"><code>index_expression</code></em>]</pre><div class="para">
                Here, the <code class="command"><em class="replaceable"><code>array_name</code></em></code> is any arbitrary name the array uses. The <code class="command"><em class="replaceable"><code>index_expression</code></em></code> is used to refer to a specific unique key in the array. To illustrate, let us try to build an array named <code class="command">foo</code> that specifies the ages of three people (i.e. the unique keys): <code class="command">tom</code>, <code class="command">dick</code>, and <code class="command">harry</code>. To assign them the ages (i.e. associated values) of 23, 24, and 25 respectively, we'd use the following array statements:
-       </div><a id="id507561" class="indexterm"></a><a id="id650429" class="indexterm"></a><div class="example" id="arraysimplestexample"><div class="example-contents"><pre class="screen">
-foo["tom"] = 23
+       </div><a id="id522062" class="indexterm"></a><a id="id454408" class="indexterm"></a><div class="example" id="arraysimplestexample"><h6>Example 3.13. Basic Array Statements</h6><div class="example-contents"><pre class="screen">foo["tom"] = 23
 foo["dick"] = 24
-foo["harry"] = 25
-</pre></div><h6>Example 3.11. Basic Array Statements</h6></div><br class="example-break" /><div class="para">
-               You can specify up to 5 index expressons in an array statement, each one delimited by a comma (<code class="command">,</code>). This is useful if you wish to have a key that contains multiple pieces of information. The following line from <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> uses 5 elements for the key: process ID, executable name, user ID, parent process ID, and string "W". It associates the value of <code class="command">devname</code> with that key.
-       </div><pre class="screen">
-device[pid(),execname(),uid(),ppid(),"W"] = devname
-</pre><div class="important"><h2>Important</h2><div class="para">
+foo["harry"] = 25</pre></div></div><br class="example-break" /><div class="para">
+               You can specify up to nine index expressons in an array statement, each one delimited by a comma (<code class="command">,</code>). This is useful if you wish to have a key that contains multiple pieces of information. The following line from <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> uses 5 elements for the key: process ID, executable name, user ID, parent process ID, and string "W". It associates the value of <code class="command">devname</code> with that key.
+       </div><pre class="screen">device[pid(),execname(),uid(),ppid(),"W"] = devname</pre><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
                        All associate arrays must be declared as <code class="command">global</code>, regardless of whether the associate array is used in one or multiple probes.
-               </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="commandlineargssect.html"><strong>Prev</strong>3.3.3. Command-Line Arguments</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayoperators.html"><strong>Next</strong>3.5. Array Operations in SystemTap</a></li></ul></body></html>
+               </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="commandlineargssect.html"><strong>Prev</strong>3.3.4. Command-Line Arguments</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="arrayoperators.html"><strong>Next</strong>3.5. Array Operations in SystemTap</a></li></ul></body></html>
index 0516f85edf24a94a598bdd9cafeddd23030af780..1d0e7ca3bd5efc449f82507de1ebd8d9e029555a 100644 (file)
@@ -1,10 +1,8 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.3. Command-Line Arguments</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="prev" href="handlerconditionalstatements.html" title="3.3.2. Conditional Statements" /><link rel="next" href="associativearrays.html" title="3.4. Associative Arrays" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="handlerconditionalstatements.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="associativearrays.html"><strong>Next</strong></a></li></ul><div class="section" title="3.3.3. Command-Line Arguments"><div class="titlepage"><div><div><h3 class="title" id="commandlineargssect">3.3.3. Command-Line Arguments</h3></div></div></div><a id="id636336" class="indexterm"></a><a id="id644780" class="indexterm"></a><a id="id509743" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.4. Command-Line Arguments</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="prev" href="handlerconditionalstatements.html" title="3.3.3. Conditional Statements" /><link rel="next" href="associativearrays.html" title="3.4. Associative Arrays" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="handlerconditionalstatements.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="associativearrays.html"><strong>Next</strong></a></li></ul><div class="section" id="commandlineargssect"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="commandlineargssect">3.3.4. Command-Line Arguments</h3></div></div></div><a id="id733592" class="indexterm"></a><a id="id414146" class="indexterm"></a><a id="id517014" class="indexterm"></a><div class="para">
                        You can also allow a SystemTap script to accept simple command-line arguments using a <code class="command">$</code> or <code class="command">@</code> immediately followed by the number of the argument on the command line. Use <code class="command">$</code> if you are expecting the user to enter an integer as a command-line argument, and <code class="command">@</code> if you are expecting a string.
-               </div><div class="example" id="commandlineargs"><div class="example-contents"><pre class="programlisting">
-probe kernel.function(@1) { }
-probe kernel.function(@1).return { }
-</pre></div><h6>Example 3.10. commandlineargs.stp</h6></div><br class="example-break" /><div class="para">
-                       <a class="xref" href="commandlineargssect.html#commandlineargs" title="Example 3.10. commandlineargs.stp">Example 3.10, “commandlineargs.stp”</a> is similar to <a class="xref" href="scripts.html#wildcards" title="Example 3.1. wildcards.stp">Example 3.1, “wildcards.stp”</a>, except that it allows you to pass the kernel function to be probed as a command-line argument (as in <code class="command">stap commandlineargs.stp <em class="replaceable"><code>kernel function</code></em></code>). You can also specify the script to accept multiple command-line arguments, noting them as <code class="command">@1</code>, <code class="command">@2</code>, and so on, in the order they are entered by the user.
-               </div><a id="id613634" class="indexterm"></a><a id="id642891" class="indexterm"></a><a id="id650889" class="indexterm"></a></div><ul class="docnav"><li class="previous"><a accesskey="p" href="handlerconditionalstatements.html"><strong>Prev</strong>3.3.2. Conditional Statements</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="associativearrays.html"><strong>Next</strong>3.4. Associative Arrays</a></li></ul></body></html>
+               </div><div class="example" id="commandlineargs"><h6>Example 3.12. commandlineargs.stp</h6><div class="example-contents"><pre class="programlisting">probe kernel.function(@1) { }
+probe kernel.function(@1).return { }</pre></div></div><br class="example-break" /><div class="para">
+                       <a class="xref" href="commandlineargssect.html#commandlineargs">Example 3.12, “commandlineargs.stp”</a> is similar to <a class="xref" href="scripts.html#wildcards">Example 3.1, “wildcards.stp”</a>, except that it allows you to pass the kernel function to be probed as a command-line argument (as in <code class="command">stap commandlineargs.stp <em class="replaceable"><code>kernel function</code></em></code>). You can also specify the script to accept multiple command-line arguments, noting them as <code class="command">@1</code>, <code class="command">@2</code>, and so on, in the order they are entered by the user.
+               </div><a id="id526309" class="indexterm"></a><a id="id604192" class="indexterm"></a><a id="id1967945" class="indexterm"></a></div><ul class="docnav"><li class="previous"><a accesskey="p" href="handlerconditionalstatements.html"><strong>Prev</strong>3.3.3. Conditional Statements</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="associativearrays.html"><strong>Next</strong>3.4. Associative Arrays</a></li></ul></body></html>
index f172ea364e4d86765d988c142336ffa81953812e..60294bf4ba0caeee7de042e233efdaa45727ae59 100644 (file)
@@ -1,56 +1,52 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2.2. Generating Instrumentation for Other Computers</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="prev" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="next" href="using-usage.html" title="2.3. Running SystemTap Scripts" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="using-systemtap.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="using-usage.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="2.2. Generating Instrumentation for Other Computers" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="cross-compiling">2.2. Generating Instrumentation for Other Computers</h2></div></div></div><a id="id616206" class="indexterm"></a><a id="id505560" class="indexterm"></a><a id="id533644" class="indexterm"></a><a id="id533557" class="indexterm"></a><a id="id544523" class="indexterm"></a><a id="id497983" class="indexterm"></a><a id="id592488" class="indexterm"></a><a id="id524377" class="indexterm"></a><div class="para">
-               When users run a SystemTap script, SystemTap builds a kernel module out of that script. SystemTap then loads the module into the kernel, allowing it to extract the specified data directly from the kernel (refer to <a class="xref" href="understanding-how-systemtap-works.html#systemtapsession" title="Procedure 3.1. SystemTap Session">Procedure 3.1, “SystemTap Session”</a> in <a class="xref" href="understanding-how-systemtap-works.html#understanding-architecture-tools" title="3.1. Architecture">Section 3.1, “Architecture”</a> for more information).
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2.2. Generating Instrumentation for Other Computers</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="prev" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="next" href="using-usage.html" title="2.3. Running SystemTap Scripts" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="using-systemtap.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="using-usage.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="cross-compiling" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="cross-compiling">2.2. Generating Instrumentation for Other Computers</h2></div></div></div><a id="id456443" class="indexterm"></a><a id="id606681" class="indexterm"></a><a id="id636225" class="indexterm"></a><a id="id696166" class="indexterm"></a><a id="id558750" class="indexterm"></a><a id="id437434" class="indexterm"></a><a id="id722920" class="indexterm"></a><a id="id753056" class="indexterm"></a><div class="para">
+               When users run a SystemTap script, SystemTap builds a kernel module out of that script. SystemTap then loads the module into the kernel, allowing it to extract the specified data directly from the kernel (refer to <a class="xref" href="understanding-how-systemtap-works.html#systemtapsession">Procedure 3.1, “SystemTap Session”</a> in <a class="xref" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Section 3.1, “Architecture”</a> for more information).
        </div><div class="para">
-               Normally, however, SystemTap scripts can only be run on systems where SystemTap is deployed (as in <a class="xref" href="using-systemtap.html#using-setup" title="2.1. Installation and Setup">Section 2.1, “Installation and Setup”</a>). This could mean that if you want to run SystemTap on ten systems, you would need to deploy SystemTap on <span class="emphasis"><em>all</em></span> those systems. In some cases, this may be neither feasible nor desired. For instance, corporate policy may prohibit an administrator from installing RPMs that provide compilers or debug information on specific machines, which will prevent the deployment of SystemTap.
+               Normally, however, SystemTap scripts can only be run on systems where SystemTap is deployed (as in <a class="xref" href="using-systemtap.html#using-setup">Section 2.1, “Installation and Setup”</a>). This could mean that if you want to run SystemTap on ten systems, you would need to deploy SystemTap on <span class="emphasis"><em>all</em></span> those systems. In some cases, this may be neither feasible nor desired. For instance, corporate policy may prohibit an administrator from installing RPMs that provide compilers or debug information on specific machines, which will prevent the deployment of SystemTap.
        </div><div class="para">
                To work around this, you can resort to <em class="firstterm">cross-instrumentation</em>. Cross-instrumentation is the process of generating SystemTap instrumentation module from a SystemTap script on one computer to be used on another computer. This process offers the following benefits:
-       </div><a id="id595927" class="indexterm"></a><a id="id495114" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
+       </div><a id="id1030898" class="indexterm"></a><a id="id1950703" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                The kernel information packages for various machines can be installed on a single <span class="emphasis"><em>host machine</em></span>.
                        </div></li><li class="listitem"><div class="para">
-                               Each <span class="emphasis"><em>target machine</em></span> only needs one RPM to installed to use the generated SystemTap instrumentation module: <code class="filename">systemtap-runtime</code>.
-                       </div></li></ul></div><div class="note"><h2>Note</h2><div class="para">
+                               Each <span class="emphasis"><em>target machine</em></span> only needs one RPM to be installed to use the generated SystemTap instrumentation module: <code class="filename">systemtap-runtime</code>.
+                       </div></li></ul></div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
                        For the sake of simplicity, we will be using the following terms throughout this section:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                                       <a id="id641078" class="indexterm"></a>
-                                       <a id="id644392" class="indexterm"></a>
-                                       <span class="emphasis"><em>instrumentation module</em></span> — the kernel module built from a SystemTap script; i.e. the <span class="emphasis"><em>SystemTap module</em></span> is built on the <span class="emphasis"><em>host system</em></span>, and will be loaded on the <span class="emphasis"><em>target kernel</em></span> of <span class="emphasis"><em>target system</em></span>.
+                                       <a id="id570786" class="indexterm"></a>
+                                        <a id="id1922841" class="indexterm"></a>
+                                        <span class="emphasis"><em>instrumentation module</em></span> — the kernel module built from a SystemTap script; i.e. the <span class="emphasis"><em>SystemTap module</em></span> is built on the <span class="emphasis"><em>host system</em></span>, and will be loaded on the <span class="emphasis"><em>target kernel</em></span> of <span class="emphasis"><em>target system</em></span>.
                                </div></li><li class="listitem"><div class="para">
-                                       <a id="id536558" class="indexterm"></a>
-                                       <a id="id608655" class="indexterm"></a>
-                                       <span class="emphasis"><em>host system</em></span> — the system on which you compile the instrumentation modules (from SystemTap scripts), to be loaded on <span class="emphasis"><em>target systems</em></span>.
+                                       <a id="id719576" class="indexterm"></a>
+                                        <a id="id496068" class="indexterm"></a>
+                                        <span class="emphasis"><em>host system</em></span> — the system on which you compile the instrumentation modules (from SystemTap scripts), to be loaded on <span class="emphasis"><em>target systems</em></span>.
                                </div></li><li class="listitem"><div class="para">
-                                       <a id="id536267" class="indexterm"></a>
-                                       <a id="id611915" class="indexterm"></a>
-                                       <span class="emphasis"><em>target system</em></span> — the system for which you are building the <span class="emphasis"><em>instrumentation module</em></span> (from SystemTap scripts).
+                                       <a id="id515470" class="indexterm"></a>
+                                        <a id="id673171" class="indexterm"></a>
+                                        <span class="emphasis"><em>target system</em></span> — the system for which you are building the <span class="emphasis"><em>instrumentation module</em></span> (from SystemTap scripts).
                                </div></li><li class="listitem"><div class="para">
-                                       <a id="id493141" class="indexterm"></a>
-                                       <a id="id641195" class="indexterm"></a>
-                                       <span class="emphasis"><em>target kernel</em></span> — the kernel of the <span class="emphasis"><em>target system</em></span>. This is the kernel on which you wish to load/run the <span class="emphasis"><em>instrumentation module</em></span>.
-                               </div></li></ul></div></div><div class="procedure" id="preppingxcompile"><h6>Procedure 2.1. Configuring a Host System and Target Systems</h6><a id="id502144" class="indexterm"></a><a id="id612710" class="indexterm"></a><a id="id508863" class="indexterm"></a><ol class="1"><li class="step" title="Step 1"><div class="para">
+                                       <a id="id494934" class="indexterm"></a>
+                                        <a id="id467759" class="indexterm"></a>
+                                        <span class="emphasis"><em>target kernel</em></span> — the kernel of the <span class="emphasis"><em>target system</em></span>. This is the kernel on which you wish to load/run the <span class="emphasis"><em>instrumentation module</em></span>.
+                               </div></li></ul></div></div></div><div class="procedure" id="preppingxcompile"><h6>Procedure 2.1. Configuring a Host System and Target Systems</h6><a id="id686944" class="indexterm"></a><a id="id1949545" class="indexterm"></a><a id="id729843" class="indexterm"></a><ol class="1"><li class="step"><div class="para">
                                Install the <code class="filename">systemtap-runtime</code> RPM on each <span class="emphasis"><em>target system</em></span>.
-                       </div></li><li class="step" title="Step 2"><div class="para">
+                       </div></li><li class="step"><div class="para">
                                Determine the kernel running on each <span class="emphasis"><em>target system</em></span> by running <code class="command">uname -r</code> on each <span class="emphasis"><em>target system</em></span>.
-                       </div></li><li class="step" title="Step 3"><div class="para">
-                               Install SystemTap on the <span class="emphasis"><em>host system</em></span>. You will be building the <span class="emphasis"><em>instrumentation module</em></span> for the <span class="emphasis"><em>target systems</em></span> on the <span class="emphasis"><em>host system</em></span>. For instructions on how to install SystemTap, refer to <a class="xref" href="using-systemtap.html#installproper" title="2.1.1. Installing SystemTap">Section 2.1.1, “Installing SystemTap”</a>.
-                       </div></li><li class="step" title="Step 4"><div class="para">
-                               Using the <span class="emphasis"><em>target kernel</em></span> version determined earlier, install the <span class="emphasis"><em>target kernel</em></span> and related RPMs on the <span class="emphasis"><em>host system</em></span> by the method described in <a class="xref" href="using-systemtap.html#install-kinfo" title="2.1.2. Installing Required Kernel Information RPMs">Section 2.1.2, “Installing Required Kernel Information RPMs”</a>. If multiple <span class="emphasis"><em>target systems</em></span> use different <span class="emphasis"><em>target kernels</em></span>, you will need to repeat this step for each different kernel used on the <span class="emphasis"><em>target systems</em></span>.
+                       </div></li><li class="step"><div class="para">
+                               Install SystemTap on the <span class="emphasis"><em>host system</em></span>. You will be building the <span class="emphasis"><em>instrumentation module</em></span> for the <span class="emphasis"><em>target systems</em></span> on the <span class="emphasis"><em>host system</em></span>. For instructions on how to install SystemTap, refer to <a class="xref" href="using-systemtap.html#installproper">Section 2.1.1, “Installing SystemTap”</a>.
+                       </div></li><li class="step"><div class="para">
+                               Using the <span class="emphasis"><em>target kernel</em></span> version determined earlier, install the <span class="emphasis"><em>target kernel</em></span> and related RPMs on the <span class="emphasis"><em>host system</em></span> by the method described in <a class="xref" href="using-systemtap.html#install-kinfo">Section 2.1.2, “Installing Required Kernel Information RPMs”</a>. If multiple <span class="emphasis"><em>target systems</em></span> use different <span class="emphasis"><em>target kernels</em></span>, you will need to repeat this step for each different kernel used on the <span class="emphasis"><em>target systems</em></span>.
                        </div></li></ol></div><div class="para">
-               After performing <a class="xref" href="cross-compiling.html#preppingxcompile" title="Procedure 2.1. Configuring a Host System and Target Systems">Procedure 2.1, “Configuring a Host System and Target Systems”</a>, you can now build the <span class="emphasis"><em>instrumentation module</em></span> (for any <span class="emphasis"><em>target system</em></span>) on the <span class="emphasis"><em>host system</em></span>.
+               After performing <a class="xref" href="cross-compiling.html#preppingxcompile">Procedure 2.1, “Configuring a Host System and Target Systems”</a>, you can now build the <span class="emphasis"><em>instrumentation module</em></span> (for any <span class="emphasis"><em>target system</em></span>) on the <span class="emphasis"><em>host system</em></span>.
        </div><div class="para">
                To build the <span class="emphasis"><em>instrumentation module</em></span>, run the following command on the <span class="emphasis"><em>host system</em></span> (be sure to specify the appropriate values):
-       </div><pre class="screen">
-stap -r <em class="replaceable"><code>kernel_version</code></em> <em class="replaceable"><code>script</code></em> -m <em class="replaceable"><code>module_name</code></em>
-</pre><div class="para">
+       </div><pre class="screen">stap -r <em class="replaceable"><code>kernel_version</code></em> <em class="replaceable"><code>script</code></em> -m <em class="replaceable"><code>module_name</code></em></pre><div class="para">
                Here, <code class="command"><em class="replaceable"><code>kernel_version</code></em></code> refers to the version of the <span class="emphasis"><em>target kernel</em></span> (the output of <code class="command">uname -r</code> on the target machine), <code class="command"><em class="replaceable"><code>script</code></em></code> refers to the script to be converted into an <span class="emphasis"><em>instrumentation module</em></span>, and <code class="command"><em class="replaceable"><code>module_name</code></em></code> is the desired name of the <span class="emphasis"><em>instrumentation module</em></span>.
-       </div><div class="note"><h2>Note</h2><a id="id538715" class="indexterm"></a><a id="id640382" class="indexterm"></a><a id="id640390" class="indexterm"></a><div class="para">
+       </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><a id="id520342" class="indexterm"></a><a id="id520350" class="indexterm"></a><a id="id692139" class="indexterm"></a><div class="para">
                        To determine the architecture notation of a running kernel, run <code class="command">uname -m</code>.
-               </div></div><div class="para">
+               </div></div></div><div class="para">
                Once the the <span class="emphasis"><em>instrumentation module</em></span> is compiled, copy it to the <span class="emphasis"><em>target system</em></span> and then load it using:
-       </div><pre class="screen">
-staprun <em class="replaceable"><code>module_name</code></em>.ko
-</pre><div class="para">
+       </div><pre class="screen">staprun <em class="replaceable"><code>module_name</code></em>.ko</pre><div class="para">
                For example, to create the <span class="emphasis"><em>instrumentation module</em></span> <code class="filename">simple.ko</code> from a SystemTap script named <code class="filename">simple.stp</code> for the <span class="emphasis"><em>target kernel</em></span> 2.6.18-92.1.10.el5 (on x86_64 architecture), use the following command:
        </div><div class="para">
                <code class="command">stap -r 2.6.18-92.1.10.el5 -e 'probe vfs.read {exit()}' -m simple</code>
@@ -58,6 +54,6 @@ staprun <em class="replaceable"><code>module_name</code></em>.ko
                This will create a module named <code class="filename">simple.ko</code>. To use the <span class="emphasis"><em>instrumentation module</em></span> <code class="filename">simple.ko</code>, copy it to the <span class="emphasis"><em>target system</em></span> and run the following command (on the <span class="emphasis"><em>target system</em></span>):
        </div><div class="para">
                <code class="command">staprun simple.ko</code>
-       </div><div class="important"><h2>Important</h2><div class="para">
+       </div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
                        The <span class="emphasis"><em>host system</em></span> must be the same architecture and running the same distribution of Linux as the <span class="emphasis"><em>target system</em></span> in order for the built <span class="emphasis"><em>instrumentation module</em></span> to work.
-               </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="using-systemtap.html"><strong>Prev</strong>Chapter 2. Using SystemTap</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="using-usage.html"><strong>Next</strong>2.3. Running SystemTap Scripts</a></li></ul></body></html>
+               </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="using-systemtap.html"><strong>Prev</strong>Chapter 2. Using SystemTap</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="using-usage.html"><strong>Next</strong>2.3. Running SystemTap Scripts</a></li></ul></body></html>
index 70bbd0d430d7169e1cec28f57cc04ff16872032c..5d4ba8fde31c6f86af57c449850a708a97fd3486 100644 (file)
@@ -1,64 +1,56 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 5. Understanding SystemTap Errors</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="futexcontentionsect.html" title="4.4. Identifying Contended User-Space Locks" /><link rel="next" href="runtimeerror.html" title="5.2. Run Time Errors and Warnings" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="futexcontentionsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="runtimeerror.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 5. Understanding SystemTap Errors" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="errors">Chapter 5. Understanding SystemTap Errors</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="errors.html#parsetype">5.1. Parse and Semantic Errors</a></span></dt><dt><span class="section"><a href="runtimeerror.html">5.2. Run Time Errors and Warnings</a></span></dt></dl></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 6. Understanding SystemTap Errors</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="futexcontentionsect.html" title="5.4. Identifying Contended User-Space Locks" /><link rel="next" href="runtimeerror.html" title="6.2. Run Time Errors and Warnings" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="futexcontentionsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="runtimeerror.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="errors" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 6. Understanding SystemTap Errors</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="errors.html#parsetype">6.1. Parse and Semantic Errors</a></span></dt><dt><span class="section"><a href="runtimeerror.html">6.2. Run Time Errors and Warnings</a></span></dt></dl></div><div class="para">
                This chapter explains the most common errors you may encounter while using SystemTap.
-       </div><div class="section" title="5.1. Parse and Semantic Errors"><div class="titlepage"><div><div><h2 class="title" id="parsetype">5.1. Parse and Semantic Errors</h2></div></div></div><a id="id583108" class="indexterm"></a><a id="id646610" class="indexterm"></a><a id="id640444" class="indexterm"></a><div class="para">
+       </div><div class="section" id="parsetype"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="parsetype">6.1. Parse and Semantic Errors</h2></div></div></div><a id="id539185" class="indexterm"></a><a id="id548523" class="indexterm"></a><a id="id713364" class="indexterm"></a><div class="para">
                        These types of errors occur while SystemTap attempts to parse and translate the script into C, prior to being converted into a kernel module. For example type errors result from operations that assign invalid values to variables or arrays.
-               </div><div class="formalpara"><h5 class="formalpara" id="id581293">parse error: expected <em class="replaceable"><code>foo</code></em>, saw <em class="replaceable"><code>bar</code></em></h5><a id="id591540" class="indexterm"></a><a id="id584670" class="indexterm"></a><a id="id506296" class="indexterm"></a><a id="id533906" class="indexterm"></a><a id="id592699" class="indexterm"></a><a id="id491505" class="indexterm"></a><a id="id491521" class="indexterm"></a><a id="id491537" class="indexterm"></a><a id="id617329" class="indexterm"></a>
+               </div><div class="formalpara"><h5 class="formalpara" id="id414344">parse error: expected <em class="replaceable"><code>foo</code></em>, saw <em class="replaceable"><code>bar</code></em></h5><a id="id561677" class="indexterm"></a><a id="id679590" class="indexterm"></a><a id="id585800" class="indexterm"></a><a id="id683394" class="indexterm"></a><a id="id514474" class="indexterm"></a><a id="id504820" class="indexterm"></a><a id="id504835" class="indexterm"></a><a id="id425663" class="indexterm"></a><a id="id425681" class="indexterm"></a>
                                The script contains a grammatical/typographical error. SystemTap detected type of construct that is incorrect, given the context of the probe.
                        </div><div class="para">
                        The following invalid SystemTap script is missing its probe handlers:
                </div><div class="para">
                        
-<pre class="programlisting">
-probe vfs.read
+<pre class="programlisting">probe vfs.read
 probe vfs.write
-
 </pre>
                </div><div class="para">
                        It results in the following error message showing that the parser was expecting something other than the <code class="command">probe</code> keyword in column 1 of line 2:
                </div><div class="para">
                        
-<pre class="programlisting">
-parse error: expected one of '. , ( ? ! { = +='
+<pre class="programlisting">parse error: expected one of '. , ( ? ! { = +='
        saw: keyword at perror.stp:2:1
-1 parse error(s).
-</pre>
-               </div><div class="formalpara"><h5 class="formalpara" id="id499011">parse error: embedded code in unprivileged script</h5><a id="id499020" class="indexterm"></a><a id="id499036" class="indexterm"></a><a id="id603014" class="indexterm"></a><a id="id603030" class="indexterm"></a><a id="id603046" class="indexterm"></a><a id="id610922" class="indexterm"></a>
-                               The script contains unsafe embedded C code (blocks of code surrounded by <code class="command">%{</code> <code class="command">%}</code>. SystemTap allows you to embed C code in a script, which is useful if there are no tapsets to suit your purposes. However, embedded C constructs are not be safe; as such, SystemTap warns you with this error if such constructs appear in the script.
-                       </div><a id="id610956" class="indexterm"></a><a id="id597001" class="indexterm"></a><a id="id597017" class="indexterm"></a><a id="id597034" class="indexterm"></a><div class="para">
+1 parse error(s).</pre>
+               </div><div class="formalpara"><h5 class="formalpara" id="id449933">parse error: embedded code in unprivileged script</h5><a id="id547884" class="indexterm"></a><a id="id547899" class="indexterm"></a><a id="id547915" class="indexterm"></a><a id="id539042" class="indexterm"></a><a id="id539057" class="indexterm"></a><a id="id539073" class="indexterm"></a>
+                               The script contains unsafe embedded C code (blocks of code surrounded by <code class="command">%{</code> <code class="command">%}</code>. SystemTap allows you to embed C code in a script, which is useful if there are no tapsets to suit your purposes. However, embedded C constructs are not safe; as such, SystemTap warns you with this error if such constructs appear in the script.
+                       </div><a id="id603184" class="indexterm"></a><a id="id603199" class="indexterm"></a><a id="id522258" class="indexterm"></a><a id="id522274" class="indexterm"></a><div class="para">
                        If you are sure of the safety of any similar constructs in the script <span class="emphasis"><em>and</em></span> are member of <code class="command">stapdev</code> group (or have root privileges), run the script in "guru" mode by using the option <code class="command">-g</code> (i.e. <code class="command">stap -g <em class="replaceable"><code>script</code></em></code>).
-               </div><div class="formalpara"><h5 class="formalpara" id="id529414">semantic error: type mismatch for identifier '<em class="replaceable"><code>foo</code></em>' ... string vs. long</h5><a id="id529427" class="indexterm"></a><a id="id529443" class="indexterm"></a><a id="id536027" class="indexterm"></a><a id="id536044" class="indexterm"></a><a id="id536060" class="indexterm"></a>
-                               The function <code class="command"><em class="replaceable"><code>foo</code></em></code> in the script used the wrong type (i.e. <code class="command">%s</code> or <code class="command">%d</code>). This error will present itself in <a class="xref" href="errors.html#errorvariable" title="Example 5.1. error-variable.stp">Example 5.1, “error-variable.stp”</a>, because the function <code class="command">execname()</code> returns a string the format specifier should be a <code class="command">%s</code>, not <code class="command">%d</code>.
-                       </div><div class="example" id="errorvariable"><div class="example-contents"><pre class="programlisting">
-probe syscall.open
+               </div><div class="formalpara"><h5 class="formalpara" id="id484992">semantic error: type mismatch for identifier '<em class="replaceable"><code>foo</code></em>' ... string vs. long</h5><a id="id485005" class="indexterm"></a><a id="id485020" class="indexterm"></a><a id="id703588" class="indexterm"></a><a id="id703604" class="indexterm"></a><a id="id703619" class="indexterm"></a>
+                               The function <code class="command"><em class="replaceable"><code>foo</code></em></code> in the script used the wrong type (i.e. <code class="command">%s</code> or <code class="command">%d</code>). This error will present itself in <a class="xref" href="errors.html#errorvariable">Example 6.1, “error-variable.stp”</a>, because the function <code class="command">execname()</code> returns a string the format specifier should be a <code class="command">%s</code>, not <code class="command">%d</code>.
+                       </div><div class="example" id="errorvariable"><h6>Example 6.1. error-variable.stp</h6><div class="example-contents"><pre class="programlisting">probe syscall.open
 {
   printf ("%d(%d) open\n", execname(), pid())
-}
-</pre></div><h6>Example 5.1. error-variable.stp</h6></div><br class="example-break" /><div class="formalpara"><h5 class="formalpara" id="id639642">semantic error: unresolved type for identifier '<em class="replaceable"><code>foo</code></em>'</h5><a id="id639654" class="indexterm"></a><a id="id639670" class="indexterm"></a><a id="id639687" class="indexterm"></a><a id="id607675" class="indexterm"></a>
+}</pre></div></div><br class="example-break" /><div class="formalpara"><h5 class="formalpara" id="id546464">semantic error: unresolved type for identifier '<em class="replaceable"><code>foo</code></em>'</h5><a id="id546477" class="indexterm"></a><a id="id546493" class="indexterm"></a><a id="id711141" class="indexterm"></a><a id="id711156" class="indexterm"></a>
                                The identifier (e.g. a variable) was used, but no type (integer or string) could be determined. This occurs, for instance, if you use a variable in a <code class="command">printf</code> statement while the script never assigns a value to the variable.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id607701">semantic error: Expecting symbol or array index expression</h5><a id="id607710" class="indexterm"></a><a id="id594026" class="indexterm"></a><a id="id594042" class="indexterm"></a><a id="id594058" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id439634">semantic error: Expecting symbol or array index expression</h5><a id="id439642" class="indexterm"></a><a id="id439658" class="indexterm"></a><a id="id1922577" class="indexterm"></a><a id="id1922592" class="indexterm"></a>
                                SystemTap could not assign a value to a variable or to a location in an array. The destination for the assignment is not a valid destination. The following example code would generate this error:
                        </div><div class="para">
                        
-<pre class="programlisting">
-probe begin { printf("x") = 1 }
-
+<pre class="programlisting">probe begin { printf("x") = 1 }
 </pre>
-               </div><div class="formalpara"><h5 class="formalpara" id="id537642">while searching for arity <em class="replaceable"><code>N</code></em> function, semantic error: unresolved function call</h5><a id="id537655" class="indexterm"></a><a id="id588047" class="indexterm"></a><a id="id588063" class="indexterm"></a><a id="id588080" class="indexterm"></a><a id="id588096" class="indexterm"></a>
+               </div><div class="formalpara"><h5 class="formalpara" id="id729129">while searching for arity <em class="replaceable"><code>N</code></em> function, semantic error: unresolved function call</h5><a id="id729142" class="indexterm"></a><a id="id729157" class="indexterm"></a><a id="id539648" class="indexterm"></a><a id="id539664" class="indexterm"></a><a id="id539679" class="indexterm"></a>
                                A function call or array index expression in the script used an invalid number of arguments/parameters. In SystemTap <em class="firstterm">arity</em> can either refer to the number of indices for an array, or the number of parameters to a function.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id602196">semantic error: array locals not supported, missing global declaration?</h5><a id="id602204" class="indexterm"></a><a id="id602221" class="indexterm"></a><a id="id639575" class="indexterm"></a><a id="id639591" class="indexterm"></a><a id="id639607" class="indexterm"></a>
-                               The script used an array operation without declaring the array as a global variable (global variables can be declared after their use in Systemtap scripts). Similar messages appear if an array is used, but with inconsistent arities.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id501204">semantic error: variable ’<em class="replaceable"><code>foo</code></em>’ modified during ’foreach’ iteration</h5><a id="id501217" class="indexterm"></a><a id="id501233" class="indexterm"></a><a id="id535160" class="indexterm"></a><a id="id535176" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id683602">semantic error: array locals not supported, missing global declaration?</h5><a id="id683611" class="indexterm"></a><a id="id683626" class="indexterm"></a><a id="id496121" class="indexterm"></a><a id="id496137" class="indexterm"></a><a id="id496153" class="indexterm"></a>
+                               The script used an array operation without declaring the array as a global variable (global variables can be declared after their use in SystemTap scripts). Similar messages appear if an array is used, but with inconsistent arities.
+                       </div><div class="formalpara"><h5 class="formalpara" id="id400543">semantic error: variable ’<em class="replaceable"><code>foo</code></em>’ modified during ’foreach’ iteration</h5><a id="id400555" class="indexterm"></a><a id="id400571" class="indexterm"></a><a id="id490957" class="indexterm"></a><a id="id490972" class="indexterm"></a>
                                The array <code class="literal">foo</code> is being modifed (being assigned to or deleted from) within an active <code class="command">foreach</code> loop. This error also displays if an operation within the script performs a function call within the <code class="command">foreach</code> loop.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id535209">semantic error: probe point mismatch at position <em class="replaceable"><code>N</code></em>, while resolving probe point <em class="replaceable"><code>foo</code></em></h5><a id="id609021" class="indexterm"></a><a id="id609037" class="indexterm"></a><a id="id609053" class="indexterm"></a><a id="id650229" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id486416">semantic error: probe point mismatch at position <em class="replaceable"><code>N</code></em>, while resolving probe point <em class="replaceable"><code>foo</code></em></h5><a id="id486431" class="indexterm"></a><a id="id486447" class="indexterm"></a><a id="id750148" class="indexterm"></a><a id="id750163" class="indexterm"></a>
                                SystemTap did not understand what the event or SystemTap function <code class="computeroutput"><em class="replaceable"><code>foo</code></em></code> refers to. This usually means that SystemTap could not find a match for <code class="computeroutput"><em class="replaceable"><code>foo</code></em></code> in the tapset library. The <em class="replaceable"><code>N</code></em> refers to the line and column of the error.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id650270">semantic error: no match for probe point, while resolving probe point <em class="replaceable"><code>foo</code></em></h5><a id="id639362" class="indexterm"></a><a id="id639378" class="indexterm"></a><a id="id639394" class="indexterm"></a><a id="id544823" class="indexterm"></a><a id="id544839" class="indexterm"></a>
-                               The events / handler function <code class="computeroutput"><em class="replaceable"><code>foo</code></em></code> could not be resolved altogether, for a variety of reasons. This error occurs when the script contains the event <code class="command">kernel.function("<em class="replaceable"><code>blah</code></em>")</code>, and <code class="command"><em class="replaceable"><code>blah</code></em></code> does not exist. In some cases, the error could also mean the script contains an invalid kernel file name or source line number.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id637513">semantic error: unresolved target-symbol expression</h5><a id="id637522" class="indexterm"></a><a id="id637538" class="indexterm"></a><a id="id637554" class="indexterm"></a><a id="id647396" class="indexterm"></a><a id="id647412" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id615496">semantic error: no match for probe point, while resolving probe point <em class="replaceable"><code>foo</code></em></h5><a id="id615508" class="indexterm"></a><a id="id615524" class="indexterm"></a><a id="id491629" class="indexterm"></a><a id="id491644" class="indexterm"></a><a id="id491660" class="indexterm"></a>
+                               The events/handler function <code class="computeroutput"><em class="replaceable"><code>foo</code></em></code> could not be resolved altogether, for a variety of reasons. This error occurs when the script contains the event <code class="command">kernel.function("<em class="replaceable"><code>blah</code></em>")</code>, and <code class="command"><em class="replaceable"><code>blah</code></em></code> does not exist. In some cases, the error could also mean the script contains an invalid kernel file name or source line number.
+                       </div><div class="formalpara"><h5 class="formalpara" id="id552848">semantic error: unresolved target-symbol expression</h5><a id="id552858" class="indexterm"></a><a id="id550549" class="indexterm"></a><a id="id550565" class="indexterm"></a><a id="id550581" class="indexterm"></a><a id="id406859" class="indexterm"></a>
                                A handler in the script references a target variable, but the value of the variable could not be resolved. This error could also mean that a handler is referencing a target variable that is not valid in the context when it was referenced. This may be a result of compiler optimization of the generated code.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id647437">semantic error: libdwfl failure </h5><a id="id626917" class="indexterm"></a><a id="id626933" class="indexterm"></a><a id="id626949" class="indexterm"></a><a id="id626965" class="indexterm"></a>
-                               There was a problem processing the debugging information. In most cases, this error results from the installation of a <code class="filename">kernel-debuginfo</code> RPM whose version does not match the probed kernel exactly. The installed <code class="filename">kernel-debuginfo</code> RPM itself may have some consistency / correctness problems.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id585619">semantic error: cannot find <em class="replaceable"><code>foo</code></em> debuginfo</h5>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id406882">semantic error: libdwfl failure </h5><a id="id406891" class="indexterm"></a><a id="id503820" class="indexterm"></a><a id="id503836" class="indexterm"></a><a id="id503851" class="indexterm"></a>
+                               There was a problem processing the debugging information. In most cases, this error results from the installation of a <code class="filename">kernel-debuginfo</code> RPM whose version does not match the probed kernel exactly. The installed <code class="filename">kernel-debuginfo</code> RPM itself may have some consistency/correctness problems.
+                       </div><div class="formalpara"><h5 class="formalpara" id="id546905">semantic error: cannot find <em class="replaceable"><code>foo</code></em> debuginfo</h5>
                                SystemTap could not find a suitable <code class="filename">kernel-debuginfo</code> at all.
-                       </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="futexcontentionsect.html"><strong>Prev</strong>4.4. Identifying Contended User-Space Locks</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="runtimeerror.html"><strong>Next</strong>5.2. Run Time Errors and Warnings</a></li></ul></body></html>
+                       </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="futexcontentionsect.html"><strong>Prev</strong>5.4. Identifying Contended User-Space Locks</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="runtimeerror.html"><strong>Next</strong>6.2. Run Time Errors and Warnings</a></li></ul></body></html>
index 97f45e65ec6b83dbf56b90645120dc84e658f3ed..8f47a57c6c53a9d23973eedd73971a13bc4086b6 100644 (file)
@@ -1,43 +1,28 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.4. Identifying Contended User-Space Locks</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts" /><link rel="prev" href="syscallsbyprocpidsect.html" title="4.3.6. Tracking System Call Volume Per Process" /><link rel="next" href="errors.html" title="Chapter 5. Understanding SystemTap Errors" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="syscallsbyprocpidsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="errors.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.4. Identifying Contended User-Space Locks" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="futexcontentionsect">4.4. Identifying Contended User-Space Locks</h2></div></div></div><a id="id490386" class="indexterm"></a><a id="id510052" class="indexterm"></a><a id="id495556" class="indexterm"></a><a id="id537750" class="indexterm"></a><div class="para">
-               This section describes how to identify contended user-space locks throughout the system within a specific time period. The ability to identify contended user-space locks can help you investigate hangs that you suspect may be caused by <code class="command">futex</code> contentions.
-       </div><a id="id543179" class="indexterm"></a><a id="id543516" class="indexterm"></a><a id="id539629" class="indexterm"></a><a id="id502684" class="indexterm"></a><a id="id643273" class="indexterm"></a><div class="para">
-               Simply put, a <code class="command">futex</code> contention occurs when multiple processes are trying to access the same region of memory. In some cases, this can result in a deadlock between the processes in contention, thereby appearing as an application hang.
-       </div><a id="id638117" class="indexterm"></a><a id="id501405" class="indexterm"></a><a id="id499547" class="indexterm"></a><div class="para">
-               To do this, <a class="xref" href="futexcontentionsect.html#futexcontention" title="futexes.stp">futexes.stp</a> probes the <code class="command">futex</code> system call.
-       </div><div class="formalpara"><h5 class="formalpara" id="futexcontention">futexes.stp</h5>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.4. Identifying Contended User-Space Locks</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 5. Useful SystemTap Scripts" /><link rel="prev" href="syscallsbyprocpidsect.html" title="5.3.6. Tracking System Call Volume Per Process" /><link rel="next" href="errors.html" title="Chapter 6. Understanding SystemTap Errors" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="syscallsbyprocpidsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="errors.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="futexcontentionsect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="futexcontentionsect">5.4. Identifying Contended User-Space Locks</h2></div></div></div><a id="id604270" class="indexterm"></a><a id="id411830" class="indexterm"></a><a id="id616477" class="indexterm"></a><a id="id1922568" class="indexterm"></a><div class="para">
+               This section describes how to identify contended user-space locks throughout the system within a specific time period. The ability to identify contended user-space locks can help you investigate poor program performance that you suspect may be caused by <code class="command">futex</code> contentions.
+       </div><a id="id536481" class="indexterm"></a><a id="id727018" class="indexterm"></a><a id="id438657" class="indexterm"></a><a id="id589172" class="indexterm"></a><a id="id535047" class="indexterm"></a><div class="para">
+               Simply put, <code class="command">futex</code> contention occurs when multiple processes are trying to access the same lock variable at the same time. This can result in a poor performance because the lock serializes execution; one process obtains the lock while the other processes must wait for the lock variable to become available again.
+       </div><a id="id602618" class="indexterm"></a><a id="id422824" class="indexterm"></a><a id="id541675" class="indexterm"></a><div class="para">
+               The <a class="xref" href="futexcontentionsect.html#futexcontention">futexes.stp</a> script probes the <code class="command">futex</code> system call to show lock contention.
+       </div><div class="formalpara" id="futexcontention"><h5 class="formalpara">futexes.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 # This script tries to identify contended user-space locks by hooking
 # into the futex system call.
 
-global thread_thislock # short
-global thread_blocktime # 
 global FUTEX_WAIT = 0 /*, FUTEX_WAKE = 1 */
 
 global lock_waits # long-lived stats on (tid,lock) blockage elapsed time
 global process_names # long-lived pid-to-execname mapping
 
-probe syscall.futex {  
-  if (op != FUTEX_WAIT) next # don't care about WAKE event originator
-  t = tid ()
-  process_names[pid()] = execname()
-  thread_thislock[t] = $uaddr
-  thread_blocktime[t] = gettimeofday_us()
-}
-
 probe syscall.futex.return {  
-  t = tid()
-  ts = thread_blocktime[t]
-  if (ts) {
-    elapsed = gettimeofday_us() - ts
-    lock_waits[pid(), thread_thislock[t]] &lt;&lt;&lt; elapsed
-    delete thread_blocktime[t]
-    delete thread_thislock[t]
-  }
+  if ($op != FUTEX_WAIT) next # don't care about WAKE event originator
+  process_names[pid()] = execname()
+  elapsed = gettimeofday_us() - @entry(gettimeofday_us())
+  lock_waits[pid(), $uaddr] &lt;&lt;&lt; elapsed
 }
 
 probe end {
@@ -46,25 +31,22 @@ probe end {
             process_names[pid], pid, lock, @count(lock_waits[pid,lock]),
             @avg(lock_waits[pid,lock]))
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="futexcontentionsect.html#futexcontention" title="futexes.stp">futexes.stp</a> needs to be manually stopped; upon exit, it prints the following information:
+               <a class="xref" href="futexcontentionsect.html#futexcontention">futexes.stp</a> needs to be manually stopped; upon exit, it prints the following information:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                Name and ID of the process responsible for a contention
                        </div></li><li class="listitem"><div class="para">
-                               The region of memory it contested
+                               The location of the contested lock variable
                        </div></li><li class="listitem"><div class="para">
-                               How many times the region of memory was contended
+                               How many times the lock variable was contended
                        </div></li><li class="listitem"><div class="para">
                                Average time of contention throughout the probe
                        </div></li></ul></div><div class="para">
-               <a class="xref" href="futexcontentionsect.html#futexcontentionoutput" title="Example 4.19. futexes.stp Sample Output">Example 4.19, “futexes.stp Sample Output”</a> contains an excerpt from the output of <a class="xref" href="futexcontentionsect.html#futexcontention" title="futexes.stp">futexes.stp</a> upon exiting the script (after approximately 20 seconds).
-       </div><div class="example" id="futexcontentionoutput"><div class="example-contents"><pre class="screen">
-[...]  
+               <a class="xref" href="futexcontentionsect.html#futexcontentionoutput">Example 5.19, “futexes.stp Sample Output”</a> contains an excerpt from the output of <a class="xref" href="futexcontentionsect.html#futexcontention">futexes.stp</a> upon exiting the script (after approximately 20 seconds).
+       </div><div class="example" id="futexcontentionoutput"><h6>Example 5.19. <a class="xref" href="futexcontentionsect.html#futexcontention">futexes.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 automount[2825] lock 0x00bc7784 contended 18 times, 999931 avg us
 synergyc[3686] lock 0x0861e96c contended 192 times, 101991 avg us
 synergyc[3758] lock 0x08d98744 contended 192 times, 101990 avg us
 synergyc[3938] lock 0x0982a8b4 contended 192 times, 101997 avg us
-[...]
-</pre></div><h6>Example 4.19. <a class="xref" href="futexcontentionsect.html#futexcontention" title="futexes.stp">futexes.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="syscallsbyprocpidsect.html"><strong>Prev</strong>4.3.6. Tracking System Call Volume Per Process</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="errors.html"><strong>Next</strong>Chapter 5. Understanding SystemTap Errors</a></li></ul></body></html>
+[...]</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="syscallsbyprocpidsect.html"><strong>Prev</strong>5.3.6. Tracking System Call Volume Per Process</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="errors.html"><strong>Next</strong>Chapter 6. Understanding SystemTap Errors</a></li></ul></body></html>
index 5e8bd0f1b0904f6ea17a303afea23e1bf13063c2..4b33e175a51bfd9e430b319433cf659ea6c14898 100644 (file)
@@ -1,59 +1,49 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.2. Conditional Statements</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="prev" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="next" href="commandlineargssect.html" title="3.3.3. Command-Line Arguments" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="scriptconstructions.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="commandlineargssect.html"><strong>Next</strong></a></li></ul><div class="section" title="3.3.2. Conditional Statements"><div class="titlepage"><div><div><h3 class="title" id="handlerconditionalstatements">3.3.2. Conditional Statements</h3></div></div></div><a id="id610472" class="indexterm"></a><a id="id511723" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.3. Conditional Statements</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="prev" href="targetavailable.html" title="3.3.2.3. Checking Target Variable Availablility" /><link rel="next" href="commandlineargssect.html" title="3.3.4. Command-Line Arguments" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="targetavailable.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="commandlineargssect.html"><strong>Next</strong></a></li></ul><div class="section" id="handlerconditionalstatements"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="handlerconditionalstatements">3.3.3. Conditional Statements</h3></div></div></div><a id="id661964" class="indexterm"></a><a id="id746076" class="indexterm"></a><div class="para">
                        In some cases, the output of a SystemTap script may be too big. To address this, you need to further refine the script's logic in order to delimit the output into something more relevant or useful to your probe.
                </div><div class="para">
                        You can do this by using <span class="emphasis"><em>conditionals</em></span> in handlers. SystemTap accepts the following types of conditional statements:
-               </div><div class="variablelist"><dl><dt><span class="term">If/Else Statements</span></dt><dd><a id="id491251" class="indexterm"></a><a id="id491345" class="indexterm"></a><a id="id536643" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">If/Else Statements</span></dt><dd><a id="id638895" class="indexterm"></a><a id="id664195" class="indexterm"></a><a id="id538672" class="indexterm"></a><div class="para">
                                                Format:
-                                       </div><pre class="programlisting">
-if (<em class="replaceable"><code>condition</code></em>)
+                                       </div><pre class="programlisting">if (<em class="replaceable"><code>condition</code></em>)
   <em class="replaceable"><code>statement1</code></em>
 else
-  <em class="replaceable"><code>statement2</code></em>
-</pre><div class="para">
-                                               The <code class="command"><em class="replaceable"><code>statement1</code></em></code> is executed if the <code class="command"><em class="replaceable"><code>condition</code></em></code> expression is non-zero. The <code class="command"><em class="replaceable"><code>statement2</code></em></code> is executed if the <code class="command"><em class="replaceable"><code>condition</code></em></code> expression is zero. The <code class="command">else</code> clause (<code class="command">else</code> <em class="replaceable"><code>statement2</code></em>)is optional. Both <code class="command"><em class="replaceable"><code>statement1</code></em></code> and <code class="command"><em class="replaceable"><code>statement2</code></em></code> can be statement blocks.
-                                       </div><div class="example" id="simpleifelseexample"><div class="example-contents"><pre class="programlisting">
-global countread, countnonread
+  <em class="replaceable"><code>statement2</code></em></pre><div class="para">
+                                               The <code class="command"><em class="replaceable"><code>statement1</code></em></code> is executed if the <code class="command"><em class="replaceable"><code>condition</code></em></code> expression is non-zero. The <code class="command"><em class="replaceable"><code>statement2</code></em></code> is executed if the <code class="command"><em class="replaceable"><code>condition</code></em></code> expression is zero. The <code class="command">else</code> clause (<code class="command">else</code> <em class="replaceable"><code>statement2</code></em>) is optional. Both <code class="command"><em class="replaceable"><code>statement1</code></em></code> and <code class="command"><em class="replaceable"><code>statement2</code></em></code> can be statement blocks.
+                                       </div><div class="example" id="simpleifelseexample"><h6>Example 3.11. ifelse.stp</h6><div class="example-contents"><pre class="programlisting">global countread, countnonread
 probe kernel.function("vfs_read"),kernel.function("vfs_write")
 {
-  if (probefunc()=="vfs_read") 
-    countread ++ 
-  else 
+  if (probefunc()=="vfs_read")
+    countread ++
+  else
     countnonread ++
 }
 probe timer.s(5) { exit() }
-probe end 
+probe end
 {
   printf("VFS reads total %d\n VFS writes total %d\n", countread, countnonread)
-}
-</pre></div><h6>Example 3.9. ifelse.stp</h6></div><br class="example-break" /><div class="para">
-                                               <a class="xref" href="handlerconditionalstatements.html#simpleifelseexample" title="Example 3.9. ifelse.stp">Example 3.9, “ifelse.stp”</a> is a script that counts how many virtual file system reads (<code class="command">vfs_read</code>) and writes (<code class="command">vfs_write</code>) the system performs within a 5-second span. When run, the script increments the value of the variable <code class="command">countread</code> by 1 if the name of the function it probed matches <code class="command">vfs_read</code> (as noted by the condition <code class="command">if (probefunc()=="vfs_read")</code>); otherwise, it increments <code class="command">countnonread</code> (<code class="command">else {countnonread ++}</code>).
-                                       </div></dd><dt><span class="term">While Loops</span></dt><dd><a id="id497063" class="indexterm"></a><a id="id597219" class="indexterm"></a><a id="id506952" class="indexterm"></a><div class="para">
+}</pre></div></div><br class="example-break" /><div class="para">
+                                               <a class="xref" href="handlerconditionalstatements.html#simpleifelseexample">Example 3.11, “ifelse.stp”</a> is a script that counts how many virtual file system reads (<code class="command">vfs_read</code>) and writes (<code class="command">vfs_write</code>) the system performs within a 5-second span. When run, the script increments the value of the variable <code class="command">countread</code> by 1 if the name of the function it probed matches <code class="command">vfs_read</code> (as noted by the condition <code class="command">if (probefunc()=="vfs_read")</code>); otherwise, it increments <code class="command">countnonread</code> (<code class="command">else {countnonread ++}</code>).
+                                       </div></dd><dt class="varlistentry"><span class="term">While Loops</span></dt><dd><a id="id736644" class="indexterm"></a><a id="id1966495" class="indexterm"></a><a id="id454304" class="indexterm"></a><div class="para">
                                                Format:
-                                       </div><pre class="programlisting">
-while (<em class="replaceable"><code>condition</code></em>)
-  <em class="replaceable"><code>statement</code></em>
-</pre><div class="para">
+                                       </div><pre class="programlisting">while (<em class="replaceable"><code>condition</code></em>)
+  <em class="replaceable"><code>statement</code></em></pre><div class="para">
                                                So long as <code class="command"><em class="replaceable"><code>condition</code></em></code> is non-zero the block of statements in <code class="command"><em class="replaceable"><code>statement</code></em></code> are executed. The <code class="command"><em class="replaceable"><code>statement</code></em></code> is often a statement block and it must change a value so <code class="command"><em class="replaceable"><code>condition</code></em></code> will eventually be zero.
-                                       </div></dd><dt><span class="term">For Loops</span></dt><dd><a id="id503294" class="indexterm"></a><a id="id504649" class="indexterm"></a><a id="id492357" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">For Loops</span></dt><dd><a id="id684725" class="indexterm"></a><a id="id515229" class="indexterm"></a><a id="id512566" class="indexterm"></a><div class="para">
                                                Format:
-                                       </div><pre class="programlisting">
-for (<em class="replaceable"><code>initialization</code></em>; <em class="replaceable"><code>conditional</code></em>; <em class="replaceable"><code>increment</code></em>) <em class="replaceable"><code>statement</code></em>
-</pre><div class="para">
+                                       </div><pre class="programlisting">for (<em class="replaceable"><code>initialization</code></em>; <em class="replaceable"><code>conditional</code></em>; <em class="replaceable"><code>increment</code></em>) <em class="replaceable"><code>statement</code></em></pre><div class="para">
                                                The <code class="command">for</code> loop is simply shorthand for a while loop. The following is the equivalent <code class="command">while</code> loop:
-                                       </div><pre class="programlisting">
-<em class="replaceable"><code>initialization</code></em>
+                                       </div><pre class="programlisting"><em class="replaceable"><code>initialization</code></em>
 while (<em class="replaceable"><code>conditional</code></em>) {
    <em class="replaceable"><code>statement</code></em>
    <em class="replaceable"><code>increment</code></em>
-}
-</pre></dd></dl></div><div class="formalpara"><h5 class="formalpara" id="id637256">Conditional Operators</h5><a id="id608708" class="indexterm"></a><a id="id537350" class="indexterm"></a><a id="id639111" class="indexterm"></a>
+}</pre></dd></dl></div><div class="formalpara"><h5 class="formalpara" id="id443606">Conditional Operators</h5><a id="id601433" class="indexterm"></a><a id="id491045" class="indexterm"></a><a id="id720268" class="indexterm"></a>
                                Aside from <code class="command">==</code> ("is equal to"), you can also use the following operators in your conditional statements:
-                       </div><div class="variablelist"><dl><dt><span class="term">&gt;=</span></dt><dd><div class="para">
+                       </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">&gt;=</span></dt><dd><div class="para">
                                                Greater than or equal to
-                                       </div></dd><dt><span class="term">&lt;=</span></dt><dd><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">&lt;=</span></dt><dd><div class="para">
                                                Less than or equal to
-                                       </div></dd><dt><span class="term">!=</span></dt><dd><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">!=</span></dt><dd><div class="para">
                                                Is not equal to
-                                       </div></dd></dl></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="scriptconstructions.html"><strong>Prev</strong>3.3. Basic SystemTap Handler Constructs</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="commandlineargssect.html"><strong>Next</strong>3.3.3. Command-Line Arguments</a></li></ul></body></html>
+                                       </div></dd></dl></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="targetavailable.html"><strong>Prev</strong>3.3.2.3. Checking Target Variable Availablility</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="commandlineargssect.html"><strong>Next</strong>3.3.4. Command-Line Arguments</a></li></ul></body></html>
index 11225b447e64ce569e0fda7e1a2463219c706fbb..16c808a460526fa90e893e18589eda694c924102 100644 (file)
@@ -1,10 +1,11 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>SystemTap Beginners Guide</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><meta name="description" content="This guide provides basic instructions on how to use SystemTap to monitor different subsystems of Fedora 10 in finer detail. The SystemTap Beginners Guideis recommended for users who have taken RHCTor have a similar level of expertise in Fedora 10." /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="next" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"></li><li class="next"><a accesskey="n" href="SystemTap_Beginners_Guide-Preface.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="book" title="SystemTap Beginners Guide" lang="en-US"><div class="titlepage"><div><div class="producttitle"><span class="productname">Systemtap</span> <span class="productnumber">1.0</span></div><div><h1 id="id471501" class="title">SystemTap Beginners Guide</h1></div><div><h2 class="subtitle">Introduction to SystemTap (for Fedora 10)</h2></div><p class="edition">Edition 2.0</p><div><h3 class="corpauthor">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>SystemTap Beginners Guide</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><meta name="description" content="This guide provides basic instructions on how to use SystemTap to monitor different subsystems of Fedora in finer detail. The SystemTap Beginners Guide is recommended for users who have taken RHCT or have a similar level of expertise in Fedora." /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="next" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"></li><li class="next"><a accesskey="n" href="SystemTap_Beginners_Guide-Preface.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="book" id="id449837" lang="en-US"><div class="titlepage"><div><div class="producttitle" font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><span class="productname">Systemtap</span> <span class="productnumber">1.4</span></div><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><h1 id="id449837" class="title">SystemTap Beginners Guide</h1></div><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><h2 class="subtitle">Introduction to SystemTap (for Fedora)</h2></div><p class="edition">Edition 2.0</p><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><h3 class="corpauthor">
                <span class="inlinemediaobject"><object data="Common_Content/images/title_logo.svg" type="image/svg+xml"> Logo</object></span>
-       </h3></div><div><div xml:lang="en-US" class="authorgroup" lang="en-US"><h3 class="corpauthor">
+
+       </h3></div><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><div xml:lang="en-US" class="authorgroup" lang="en-US"><h3 class="corpauthor">
                Red Hat, Inc.
-       </h3><div class="author"><h3 class="author"><span class="firstname">Don</span> <span class="surname">Domingo </span></h3><div class="affiliation"><span class="orgname">Engineering Services and Operations</span> <span class="orgdiv">Content Services</span></div><code class="email"><a class="email" href="mailto:ddomingo@redhat.com">ddomingo@redhat.com</a></code></div><div class="author"><h3 class="author"><span class="firstname">William</span> <span class="surname">Cohen</span></h3><div class="affiliation"><span class="orgname">Engineering Services and Operations</span> <span class="orgdiv">Performance Tools</span></div><code class="email"><a class="email" href="mailto:wcohen@redhat.com">wcohen@redhat.com</a></code></div></div></div><div><p class="copyright">Copyright © 2009 Red Hat, Inc</p></div><hr /><div><div id="id616673" class="legalnotice"><h1 class="legalnotice">Legal Notice</h1><div class="para">
+       </h3><div class="author"><h3 class="author"><span class="firstname">Don</span> <span class="surname">Domingo </span></h3><div class="affiliation"><span class="orgname">Engineering Services and Operations</span> <span class="orgdiv">Content Services</span></div><code class="email"><a class="email" href="mailto:ddomingo@redhat.com">ddomingo@redhat.com</a></code></div><div class="author"><h3 class="author"><span class="firstname">William</span> <span class="surname">Cohen</span></h3><div class="affiliation"><span class="orgname">Engineering Services and Operations</span> <span class="orgdiv">Performance Tools</span></div><code class="email"><a class="email" href="mailto:wcohen@redhat.com">wcohen@redhat.com</a></code></div></div></div><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><p class="copyright">Copyright © 2010 Red Hat, Inc</p></div><hr /><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><div id="id613996" class="legalnotice"><h1 class="legalnotice">Legal Notice</h1><div class="para">
                This documentation is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.
        </div><div class="para">
                This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
@@ -12,7 +13,6 @@
                You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
        </div><div class="para">
                For more details see the file COPYING in the source distribution of Linux.
-       </div></div></div><div><div class="abstract" title="Abstract"><h6>Abstract</h6><div class="para">
-This guide provides basic instructions on how to use SystemTap to
-monitor different subsystems of Fedora 10 in finer detail. The <em class="citetitle">SystemTap Beginners Guide</em>is recommended for users who have taken <a href="https://www.redhat.com/courses/rh133_red_hat_linux_system_administration_and_rhct_exam/">RHCT</a>or have a similar level of expertise in Fedora 10.
-</div></div></div></div><hr /></div><div class="toc"><dl><dt><span class="preface"><a href="SystemTap_Beginners_Guide-Preface.html">Preface</a></span></dt><dd><dl><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id586261">1. Document Conventions</a></span></dt><dd><dl><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id628309">1.1. Typographic Conventions</a></span></dt><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id537954">1.2. Pull-quote Conventions</a></span></dt><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id472332">1.3. Notes and Warnings</a></span></dt></dl></dd><dt><span class="section"><a href="pr01s02.html">2. We Need Feedback!</a></span></dt></dl></dd><dt><span class="chapter"><a href="introduction.html">1. Introduction</a></span></dt><dd><dl><dt><span class="section"><a href="introduction.html#goals">1.1. Documentation Goals</a></span></dt><dt><span class="section"><a href="intro-systemtap-vs-others.html">1.2. SystemTap Capabilities</a></span></dt></dl></dd><dt><span class="chapter"><a href="using-systemtap.html">2. Using SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#using-setup">2.1. Installation and Setup</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#installproper">2.1.1. Installing SystemTap</a></span></dt><dt><span class="section"><a href="using-systemtap.html#install-kinfo">2.1.2. Installing Required Kernel Information RPMs</a></span></dt><dt><span class="section"><a href="using-systemtap.html#testing">2.1.3. Initial Testing</a></span></dt></dl></dd><dt><span class="section"><a href="cross-compiling.html">2.2. Generating Instrumentation for Other Computers</a></span></dt><dt><span class="section"><a href="using-usage.html">2.3. Running SystemTap Scripts</a></span></dt></dl></dd><dt><span class="chapter"><a href="understanding-how-systemtap-works.html">3. Understanding How SystemTap Works</a></span></dt><dd><dl><dt><span class="section"><a href="understanding-how-systemtap-works.html#understanding-architecture-tools">3.1. Architecture</a></span></dt><dt><span class="section"><a href="scripts.html">3.2. SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="scripts.html#systemtapscript-events">3.2.1. Event</a></span></dt><dt><span class="section"><a href="systemtapscript-handler.html">3.2.2. Systemtap Handler/Body</a></span></dt></dl></dd><dt><span class="section"><a href="scriptconstructions.html">3.3. Basic SystemTap Handler Constructs</a></span></dt><dd><dl><dt><span class="section"><a href="scriptconstructions.html#variablesconstructs">3.3.1. Variables</a></span></dt><dt><span class="section"><a href="handlerconditionalstatements.html">3.3.2. Conditional Statements</a></span></dt><dt><span class="section"><a href="commandlineargssect.html">3.3.3. Command-Line Arguments</a></span></dt></dl></dd><dt><span class="section"><a href="associativearrays.html">3.4. Associative Arrays</a></span></dt><dt><span class="section"><a href="arrayoperators.html">3.5. Array Operations in SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="arrayoperators.html#arrayops-assignvalue">3.5.1. Assigning an Associated Value</a></span></dt><dt><span class="section"><a href="arrayops-readvalues.html">3.5.2. Reading Values From Arrays</a></span></dt><dt><span class="section"><a href="arrayops-increment.html">3.5.3. Incrementing Associated Values</a></span></dt><dt><span class="section"><a href="arrayops-foreach.html">3.5.4. Processing Multiple Elements in an Array</a></span></dt><dt><span class="section"><a href="arrayops-deleting.html">3.5.5. Clearing/Deleting Arrays and Array Elements</a></span></dt><dt><span class="section"><a href="arrayops-conditionals.html">3.5.6. Using Arrays in Conditional Statements</a></span></dt><dt><span class="section"><a href="arrayops-aggregates.html">3.5.7. Computing for Statistical Aggregates</a></span></dt></dl></dd><dt><span class="section"><a href="understanding-tapsets.html">3.6. Tapsets</a></span></dt></dl></dd><dt><span class="chapter"><a href="useful-systemtap-scripts.html">4. Useful SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#mainsect-network">4.1. Network</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#nettopsect">4.1.1. Network Profiling</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#sockettracesect">4.1.2. Tracing Functions Called in Network Socket Code</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpconnectionssect">4.1.3. Monitoring Incoming TCP Connections</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpdumplikesect">4.1.4. Monitoring TCP Packets</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#dropwatchsect">4.1.5. Monitoring Network Packets Drops in Kernel</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-disk.html">4.2. Disk</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-disk.html#disktop">4.2.1. Summarizing Disk Read/Write Traffic</a></span></dt><dt><span class="section"><a href="iotimesect.html">4.2.2. Tracking I/O Time For Each File Read or Write</a></span></dt><dt><span class="section"><a href="traceiosect.html">4.2.3. Track Cumulative IO</a></span></dt><dt><span class="section"><a href="traceio2sect.html">4.2.4. I/O Monitoring (By Device)</a></span></dt><dt><span class="section"><a href="inodewatchsect.html">4.2.5. Monitoring Reads and Writes to a File</a></span></dt><dt><span class="section"><a href="inodewatch2sect.html">4.2.6. Monitoring Changes to File Attributes</a></span></dt><dt><span class="section"><a href="ioblktimesect.html">4.2.7. Periodically Print I/O Block Time</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-profiling.html">4.3. Profiling</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-profiling.html#countcallssect">4.3.1. Counting Function Calls Made</a></span></dt><dt><span class="section"><a href="paracallgraph.html">4.3.2. Call Graph Tracing</a></span></dt><dt><span class="section"><a href="threadtimessect.html">4.3.3. Determining Time Spent in Kernel and User Space</a></span></dt><dt><span class="section"><a href="timeoutssect.html">4.3.4. Monitoring Polling Applications</a></span></dt><dt><span class="section"><a href="topsyssect.html">4.3.5. Tracking Most Frequently Used System Calls</a></span></dt><dt><span class="section"><a href="syscallsbyprocpidsect.html">4.3.6. Tracking System Call Volume Per Process</a></span></dt></dl></dd><dt><span class="section"><a href="futexcontentionsect.html">4.4. Identifying Contended User-Space Locks</a></span></dt></dl></dd><dt><span class="chapter"><a href="errors.html">5. Understanding SystemTap Errors</a></span></dt><dd><dl><dt><span class="section"><a href="errors.html#parsetype">5.1. Parse and Semantic Errors</a></span></dt><dt><span class="section"><a href="runtimeerror.html">5.2. Run Time Errors and Warnings</a></span></dt></dl></dd><dt><span class="chapter"><a href="references.html">6. References</a></span></dt><dt><span class="appendix"><a href="appe-Publican-Revision_History.html">A. Revision History</a></span></dt><dt><span class="index"><a href="ix01.html">Index</a></span></dt></dl></div></div><ul class="docnav"><li class="previous"></li><li class="next"><a accesskey="n" href="SystemTap_Beginners_Guide-Preface.html"><strong>Next</strong>Preface</a></li></ul></body></html>
+       </div></div></div><div font-family="sans-serif,Symbol,ZapfDingbats" font-weight="bold" font-size="12pt" text-align="center"><div class="abstract"><h6>Abstract</h6><div class="para">
+                       This guide provides basic instructions on how to use SystemTap to monitor different subsystems of Fedora in finer detail. The <em class="citetitle">SystemTap Beginners Guide</em> is recommended for users who have taken <a href="https://www.redhat.com/courses/rh133_red_hat_linux_system_administration_and_rhct_exam/">RHCT</a> or have a similar level of expertise in Fedora.
+               </div></div></div></div><hr /></div><div class="toc"><dl><dt><span class="preface"><a href="SystemTap_Beginners_Guide-Preface.html">Preface</a></span></dt><dd><dl><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id573981">1. Document Conventions</a></span></dt><dd><dl><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id573950">1.1. Typographic Conventions</a></span></dt><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id656642">1.2. Pull-quote Conventions</a></span></dt><dt><span class="section"><a href="SystemTap_Beginners_Guide-Preface.html#id511567">1.3. Notes and Warnings</a></span></dt></dl></dd><dt><span class="section"><a href="pr01s02.html">2. We Need Feedback!</a></span></dt></dl></dd><dt><span class="chapter"><a href="introduction.html">1. Introduction</a></span></dt><dd><dl><dt><span class="section"><a href="introduction.html#goals">1.1. Documentation Goals</a></span></dt><dt><span class="section"><a href="intro-systemtap-vs-others.html">1.2. SystemTap Capabilities</a></span></dt></dl></dd><dt><span class="chapter"><a href="using-systemtap.html">2. Using SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#using-setup">2.1. Installation and Setup</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#installproper">2.1.1. Installing SystemTap</a></span></dt><dt><span class="section"><a href="using-systemtap.html#install-kinfo">2.1.2. Installing Required Kernel Information RPMs</a></span></dt><dt><span class="section"><a href="using-systemtap.html#testing">2.1.3. Initial Testing</a></span></dt></dl></dd><dt><span class="section"><a href="cross-compiling.html">2.2. Generating Instrumentation for Other Computers</a></span></dt><dt><span class="section"><a href="using-usage.html">2.3. Running SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="using-usage.html#flight-recorder">2.3.1. SystemTap Flight Recorder Mode</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="understanding-how-systemtap-works.html">3. Understanding How SystemTap Works</a></span></dt><dd><dl><dt><span class="section"><a href="understanding-how-systemtap-works.html#understanding-architecture-tools">3.1. Architecture</a></span></dt><dt><span class="section"><a href="scripts.html">3.2. SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="scripts.html#systemtapscript-events">3.2.1. Event</a></span></dt><dt><span class="section"><a href="systemtapscript-handler.html">3.2.2. Systemtap Handler/Body</a></span></dt></dl></dd><dt><span class="section"><a href="scriptconstructions.html">3.3. Basic SystemTap Handler Constructs</a></span></dt><dd><dl><dt><span class="section"><a href="scriptconstructions.html#variablesconstructs">3.3.1. Variables</a></span></dt><dt><span class="section"><a href="targetvariables.html">3.3.2. Target Variables</a></span></dt><dt><span class="section"><a href="handlerconditionalstatements.html">3.3.3. Conditional Statements</a></span></dt><dt><span class="section"><a href="commandlineargssect.html">3.3.4. Command-Line Arguments</a></span></dt></dl></dd><dt><span class="section"><a href="associativearrays.html">3.4. Associative Arrays</a></span></dt><dt><span class="section"><a href="arrayoperators.html">3.5. Array Operations in SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="arrayoperators.html#arrayops-assignvalue">3.5.1. Assigning an Associated Value</a></span></dt><dt><span class="section"><a href="arrayops-readvalues.html">3.5.2. Reading Values From Arrays</a></span></dt><dt><span class="section"><a href="arrayops-increment.html">3.5.3. Incrementing Associated Values</a></span></dt><dt><span class="section"><a href="arrayops-foreach.html">3.5.4. Processing Multiple Elements in an Array</a></span></dt><dt><span class="section"><a href="arrayops-deleting.html">3.5.5. Clearing/Deleting Arrays and Array Elements</a></span></dt><dt><span class="section"><a href="arrayops-conditionals.html">3.5.6. Using Arrays in Conditional Statements</a></span></dt><dt><span class="section"><a href="arrayops-aggregates.html">3.5.7. Computing for Statistical Aggregates</a></span></dt></dl></dd><dt><span class="section"><a href="understanding-tapsets.html">3.6. Tapsets</a></span></dt></dl></dd><dt><span class="chapter"><a href="userspace-probing.html">4. User-Space Probing</a></span></dt><dd><dl><dt><span class="section"><a href="userspace-probing.html#uevents">4.1. User-Space Events</a></span></dt><dt><span class="section"><a href="utargetvariable.html">4.2. Accessing User-Space Target Variables</a></span></dt><dt><span class="section"><a href="ustack.html">4.3. User-Space Stack Backtraces</a></span></dt></dl></dd><dt><span class="chapter"><a href="useful-systemtap-scripts.html">5. Useful SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#mainsect-network">5.1. Network</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#nettopsect">5.1.1. Network Profiling</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#sockettracesect">5.1.2. Tracing Functions Called in Network Socket Code</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpconnectionssect">5.1.3. Monitoring Incoming TCP Connections</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpdumplikesect">5.1.4. Monitoring TCP Packets</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#dropwatchsect">5.1.5. Monitoring Network Packets Drops in Kernel</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-disk.html">5.2. Disk</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-disk.html#disktop">5.2.1. Summarizing Disk Read/Write Traffic</a></span></dt><dt><span class="section"><a href="iotimesect.html">5.2.2. Tracking I/O Time For Each File Read or Write</a></span></dt><dt><span class="section"><a href="traceiosect.html">5.2.3. Track Cumulative IO</a></span></dt><dt><span class="section"><a href="traceio2sect.html">5.2.4. I/O Monitoring (By Device)</a></span></dt><dt><span class="section"><a href="inodewatchsect.html">5.2.5. Monitoring Reads and Writes to a File</a></span></dt><dt><span class="section"><a href="inodewatch2sect.html">5.2.6. Monitoring Changes to File Attributes</a></span></dt><dt><span class="section"><a href="ioblktimesect.html">5.2.7. Periodically Print I/O Block Time</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-profiling.html">5.3. Profiling</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-profiling.html#countcallssect">5.3.1. Counting Function Calls Made</a></span></dt><dt><span class="section"><a href="paracallgraph.html">5.3.2. Call Graph Tracing</a></span></dt><dt><span class="section"><a href="threadtimessect.html">5.3.3. Determining Time Spent in Kernel and User Space</a></span></dt><dt><span class="section"><a href="timeoutssect.html">5.3.4. Monitoring Polling Applications</a></span></dt><dt><span class="section"><a href="topsyssect.html">5.3.5. Tracking Most Frequently Used System Calls</a></span></dt><dt><span class="section"><a href="syscallsbyprocpidsect.html">5.3.6. Tracking System Call Volume Per Process</a></span></dt></dl></dd><dt><span class="section"><a href="futexcontentionsect.html">5.4. Identifying Contended User-Space Locks</a></span></dt></dl></dd><dt><span class="chapter"><a href="errors.html">6. Understanding SystemTap Errors</a></span></dt><dd><dl><dt><span class="section"><a href="errors.html#parsetype">6.1. Parse and Semantic Errors</a></span></dt><dt><span class="section"><a href="runtimeerror.html">6.2. Run Time Errors and Warnings</a></span></dt></dl></dd><dt><span class="chapter"><a href="references.html">7. References</a></span></dt><dt><span class="appendix"><a href="appe-Publican-Revision_History.html">A. Revision History</a></span></dt><dt><span class="index"><a href="ix01.html">Index</a></span></dt></dl></div></div><ul class="docnav"><li class="previous"></li><li class="next"><a accesskey="n" href="SystemTap_Beginners_Guide-Preface.html"><strong>Next</strong>Preface</a></li></ul></body></html>
index 828ded17354f896f5fd6ff96ff75142360927e4b..ef655f9a8f8524d2aa18f3d314ec6e74697266d5 100644 (file)
@@ -1,29 +1,29 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.6. Monitoring Changes to File Attributes</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="inodewatchsect.html" title="4.2.5. Monitoring Reads and Writes to a File" /><link rel="next" href="ioblktimesect.html" title="4.2.7. Periodically Print I/O Block Time" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatchsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="ioblktimesect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.6. Monitoring Changes to File Attributes" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="inodewatch2sect">4.2.6. Monitoring Changes to File Attributes</h3></div></div></div><a id="id506541" class="indexterm"></a><a id="id495965" class="indexterm"></a><a id="id493065" class="indexterm"></a><a id="id507486" class="indexterm"></a><a id="id584911" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.6. Monitoring Changes to File Attributes</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="inodewatchsect.html" title="5.2.5. Monitoring Reads and Writes to a File" /><link rel="next" href="ioblktimesect.html" title="5.2.7. Periodically Print I/O Block Time" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatchsect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="ioblktimesect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="inodewatch2sect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="inodewatch2sect">5.2.6. Monitoring Changes to File Attributes</h3></div></div></div><a id="id494518" class="indexterm"></a><a id="id601348" class="indexterm"></a><a id="id440345" class="indexterm"></a><a id="id623517" class="indexterm"></a><a id="id431042" class="indexterm"></a><div class="para">
                This section describes how to monitor if any processes are changing the attributes of a targeted file, in real time.
-       </div><div class="formalpara"><h5 class="formalpara" id="inodewatch2">inodewatch2-simple.stp</h5>
+       </div><div class="formalpara" id="inodewatch2"><h5 class="formalpara">inodewatch2.stp</h5>
                        
-<pre class="programlisting">
-global ATTR_MODE = 1&#13;
-&#13;
-probe kernel.function("inode_setattr") {&#13;
-  dev_nr = $inode-&gt;i_sb-&gt;s_dev&#13;
-  inode_nr = $inode-&gt;i_ino&#13;
-&#13;
-  if (dev_nr == ($1 &lt;&lt; 20 | $2) # major/minor device&#13;
-      &amp;&amp; inode_nr == $3&#13;
-      &amp;&amp; $attr-&gt;ia_valid &amp; ATTR_MODE)&#13;
-    printf ("%s(%d) %s 0x%x/%u %o %d\n",&#13;
-      execname(), pid(), probefunc(), dev_nr, inode_nr, $attr-&gt;ia_mode, uid())&#13;
-}&#13;
+<pre class="programlisting">#! /usr/bin/env stap
 
+global ATTR_MODE = 1
+
+probe kernel.function("setattr_copy")!,
+      kernel.function("generic_setattr")!,
+      kernel.function("inode_setattr") {
+  dev_nr = $inode-&gt;i_sb-&gt;s_dev
+  inode_nr = $inode-&gt;i_ino
+
+  if (dev_nr == MKDEV($1,$2) # major/minor device
+      &amp;&amp; inode_nr == $3
+      &amp;&amp; $attr-&gt;ia_valid &amp; ATTR_MODE)
+    printf ("%s(%d) %s 0x%x/%u %o %d\n",
+      execname(), pid(), probefunc(), dev_nr, inode_nr, $attr-&gt;ia_mode, uid())
+}
 </pre>
                </div><div class="para">
-               Like <a class="xref" href="inodewatchsect.html#inodewatch" title="inodewatch-simple.stp">inodewatch-simple.stp</a> from <a class="xref" href="inodewatchsect.html" title="4.2.5. Monitoring Reads and Writes to a File">Section 4.2.5, “Monitoring Reads and Writes to a File”</a>, <a class="xref" href="inodewatch2sect.html#inodewatch2" title="inodewatch2-simple.stp">inodewatch2-simple.stp</a> takes the targeted file's device number (in integer format) and <code class="command">inode</code> number as arguments. For more information on how to retrieve this information, refer to <a class="xref" href="inodewatchsect.html" title="4.2.5. Monitoring Reads and Writes to a File">Section 4.2.5, “Monitoring Reads and Writes to a File”</a>.
+               Like <a class="xref" href="inodewatchsect.html#inodewatch">inodewatch.stp</a> from <a class="xref" href="inodewatchsect.html">Section 5.2.5, “Monitoring Reads and Writes to a File”</a>, <a class="xref" href="inodewatch2sect.html#inodewatch2">inodewatch2.stp</a> takes the targeted file's device number (in integer format) and <code class="command">inode</code> number as arguments. For more information on how to retrieve this information, refer to <a class="xref" href="inodewatchsect.html">Section 5.2.5, “Monitoring Reads and Writes to a File”</a>.
        </div><div class="para">
-               The output for <a class="xref" href="inodewatch2sect.html#inodewatch2" title="inodewatch2-simple.stp">inodewatch2-simple.stp</a> is similar to that of <a class="xref" href="inodewatchsect.html#inodewatch" title="inodewatch-simple.stp">inodewatch-simple.stp</a>, except that <a class="xref" href="inodewatch2sect.html#inodewatch2" title="inodewatch2-simple.stp">inodewatch2-simple.stp</a> also contains the attribute changes to the monitored file, as well as the ID of the user responsible (<code class="command">uid()</code>). <a class="xref" href="inodewatch2sect.html#inodewatch2output" title="Example 4.11. inodewatch2-simple.stp Sample Output">Example 4.11, “inodewatch2-simple.stp Sample Output”</a> contains shows the output of <a class="xref" href="inodewatch2sect.html#inodewatch2" title="inodewatch2-simple.stp">inodewatch2-simple.stp</a> while monitoring <code class="filename">/home/joe/bigfile</code> when user <code class="computeroutput">joe</code> executes <code class="command">chmod 777 /home/joe/bigfile</code> and <code class="command">chmod 666 /home/joe/bigfile</code>.
-       </div><div class="example" id="inodewatch2output"><div class="example-contents"><pre class="screen">
-chmod(17448) inode_setattr 0x800005/6011835 100777 500
-chmod(17449) inode_setattr 0x800005/6011835 100666 500
-</pre></div><h6>Example 4.11. <a class="xref" href="inodewatch2sect.html#inodewatch2" title="inodewatch2-simple.stp">inodewatch2-simple.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatchsect.html"><strong>Prev</strong>4.2.5. Monitoring Reads and Writes to a File</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="ioblktimesect.html"><strong>Next</strong>4.2.7. Periodically Print I/O Block Time</a></li></ul></body></html>
+               The output for <a class="xref" href="inodewatch2sect.html#inodewatch2">inodewatch2.stp</a> is similar to that of <a class="xref" href="inodewatchsect.html#inodewatch">inodewatch.stp</a>, except that <a class="xref" href="inodewatch2sect.html#inodewatch2">inodewatch2.stp</a> also contains the attribute changes to the monitored file, as well as the ID of the user responsible (<code class="command">uid()</code>). <a class="xref" href="inodewatch2sect.html#inodewatch2output">Example 5.11, “inodewatch2.stp Sample Output”</a> shows the output of <a class="xref" href="inodewatch2sect.html#inodewatch2">inodewatch2.stp</a> while monitoring <code class="filename">/home/joe/bigfile</code> when user <code class="computeroutput">joe</code> executes <code class="command">chmod 777 /home/joe/bigfile</code> and <code class="command">chmod 666 /home/joe/bigfile</code>.
+       </div><div class="example" id="inodewatch2output"><h6>Example 5.11. <a class="xref" href="inodewatch2sect.html#inodewatch2">inodewatch2.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">chmod(17448) inode_setattr 0x800005/6011835 100777 500
+chmod(17449) inode_setattr 0x800005/6011835 100666 500</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatchsect.html"><strong>Prev</strong>5.2.5. Monitoring Reads and Writes to a File</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="ioblktimesect.html"><strong>Next</strong>5.2.7. Periodically Print I/O Block Time</a></li></ul></body></html>
index a218f79bd0a2cbfff9315fe84f69c637b9cd036e..7974672444003c57bbab02b8a659aedc2d117220 100644 (file)
@@ -1,40 +1,35 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.5. Monitoring Reads and Writes to a File</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="traceio2sect.html" title="4.2.4. I/O Monitoring (By Device)" /><link rel="next" href="inodewatch2sect.html" title="4.2.6. Monitoring Changes to File Attributes" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="traceio2sect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="inodewatch2sect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.5. Monitoring Reads and Writes to a File" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="inodewatchsect">4.2.5. Monitoring Reads and Writes to a File</h3></div></div></div><a id="id501349" class="indexterm"></a><a id="id490942" class="indexterm"></a><a id="id627531" class="indexterm"></a><a id="id591293" class="indexterm"></a><a id="id642378" class="indexterm"></a><a id="id641908" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.5. Monitoring Reads and Writes to a File</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="traceio2sect.html" title="5.2.4. I/O Monitoring (By Device)" /><link rel="next" href="inodewatch2sect.html" title="5.2.6. Monitoring Changes to File Attributes" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="traceio2sect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="inodewatch2sect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="inodewatchsect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="inodewatchsect">5.2.5. Monitoring Reads and Writes to a File</h3></div></div></div><a id="id434374" class="indexterm"></a><a id="id649421" class="indexterm"></a><a id="id684521" class="indexterm"></a><a id="id729885" class="indexterm"></a><a id="id580044" class="indexterm"></a><a id="id451586" class="indexterm"></a><div class="para">
                This section describes how to monitor reads from and writes to a file in real time.
-       </div><div class="formalpara"><h5 class="formalpara" id="inodewatch">inodewatch-simple.stp</h5>
+       </div><div class="formalpara" id="inodewatch"><h5 class="formalpara">inodewatch.stp</h5>
                        
-<pre class="programlisting">
-probe vfs.write, vfs.read&#13;
-{&#13;
-  dev_nr = $file-&gt;f_dentry-&gt;d_inode-&gt;i_sb-&gt;s_dev&#13;
-  inode_nr = $file-&gt;f_dentry-&gt;d_inode-&gt;i_ino&#13;
-  if (dev_nr == ($1 &lt;&lt; 20 | $2) # major/minor device&#13;
-      &amp;&amp; inode_nr == $3)&#13;
-    printf ("%s(%d) %s 0x%x/%u\n",&#13;
-      execname(), pid(), probefunc(), dev_nr, inode_nr)&#13;
-}&#13;
+<pre class="programlisting">#! /usr/bin/env stap
 
+probe vfs.write, vfs.read
+{
+  # dev and ino are defined by vfs.write and vfs.read
+  if (dev == MKDEV($1,$2) # major/minor device
+      &amp;&amp; ino == $3)
+    printf ("%s(%d) %s 0x%x/%u\n",
+      execname(), pid(), probefunc(), dev, ino)
+}
 </pre>
                </div><div class="para">
-               <a class="xref" href="inodewatchsect.html#inodewatch" title="inodewatch-simple.stp">inodewatch-simple.stp</a> takes the following information about the file as arguments on the command line:
-       </div><a id="id546120" class="indexterm"></a><a id="id605244" class="indexterm"></a><a id="id614044" class="indexterm"></a><a id="id493575" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
+               <a class="xref" href="inodewatchsect.html#inodewatch">inodewatch.stp</a> takes the following information about the file as arguments on the command line:
+       </div><a id="id568235" class="indexterm"></a><a id="id623873" class="indexterm"></a><a id="id1949723" class="indexterm"></a><a id="id567805" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                The file's major device number.
                        </div></li><li class="listitem"><div class="para">
                                The file's minor device number.
                        </div></li><li class="listitem"><div class="para">
                                The file's <code class="command">inode</code> number.
-                       </div></li></ul></div><a id="id507743" class="indexterm"></a><a id="id637086" class="indexterm"></a><a id="id650356" class="indexterm"></a><div class="para">
+                       </div></li></ul></div><a id="id644329" class="indexterm"></a><a id="id571575" class="indexterm"></a><a id="id520724" class="indexterm"></a><div class="para">
                To get this information, use <code class="command">stat -c '%D %i' <em class="replaceable"><code>filename</code></em></code>, where <code class="command"><em class="replaceable"><code>filename</code></em></code> is an absolute path.
        </div><div class="para">
                For instance: if you wish to monitor <code class="filename">/etc/crontab</code>, run <code class="command">stat -c '%D %i' /etc/crontab</code> first. This gives the following output:
-       </div><pre class="screen">
-805 1078319
-</pre><a id="id494034" class="indexterm"></a><a id="id510815" class="indexterm"></a><a id="id612105" class="indexterm"></a><div class="para">
+       </div><pre class="screen">805 1078319</pre><a id="id436346" class="indexterm"></a><a id="id671755" class="indexterm"></a><a id="id1939129" class="indexterm"></a><div class="para">
                <code class="computeroutput">805</code> is the base-16 (hexadecimal) device number. The lower two digits are the minor device number and the upper digits are the major number. <code class="computeroutput">1078319</code> is the <code class="command">inode</code> number. To start monitoring <code class="filename">/etc/crontab</code>, run <code class="command">stap inodewatch.stp 0x8 0x05 1078319</code> (The <code class="command">0x</code> prefixes indicate base-16 values.
        </div><div class="para">
-               The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. <code class="command">vfs_read</code> or <code class="command">vfs_write</code>), the device number (in hex format), and the <code class="command">inode</code> number. <a class="xref" href="inodewatchsect.html#inodewatchoutput" title="Example 4.10. inodewatch-simple.stp Sample Output">Example 4.10, “inodewatch-simple.stp Sample Output”</a> contains the output of <code class="command">stap inodewatch.stp 0x8 0x05 1078319</code> (when <code class="command">cat /etc/crontab</code> is executed while the script is running) :
-       </div><div class="example" id="inodewatchoutput"><div class="example-contents"><pre class="screen">
-cat(16437) vfs_read 0x800005/1078319
-cat(16437) vfs_read 0x800005/1078319
-</pre></div><h6>Example 4.10. <a class="xref" href="inodewatchsect.html#inodewatch" title="inodewatch-simple.stp">inodewatch-simple.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="traceio2sect.html"><strong>Prev</strong>4.2.4. I/O Monitoring (By Device)</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="inodewatch2sect.html"><strong>Next</strong>4.2.6. Monitoring Changes to File Attributes</a></li></ul></body></html>
+               The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. <code class="command">vfs_read</code> or <code class="command">vfs_write</code>), the device number (in hex format), and the <code class="command">inode</code> number. <a class="xref" href="inodewatchsect.html#inodewatchoutput">Example 5.10, “inodewatch.stp Sample Output”</a> contains the output of <code class="command">stap inodewatch.stp 0x8 0x05 1078319</code> (when <code class="command">cat /etc/crontab</code> is executed while the script is running) :
+       </div><div class="example" id="inodewatchoutput"><h6>Example 5.10. <a class="xref" href="inodewatchsect.html#inodewatch">inodewatch.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">cat(16437) vfs_read 0x800005/1078319
+cat(16437) vfs_read 0x800005/1078319</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="traceio2sect.html"><strong>Prev</strong>5.2.4. I/O Monitoring (By Device)</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="inodewatch2sect.html"><strong>Next</strong>5.2.6. Monitoring Changes to File Attributes</a></li></ul></body></html>
index 273e4a130320e94803bede919ef9a09d25bfe978..22b0475a22d41485488b38ef91762103705b8663 100644 (file)
@@ -1,13 +1,13 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>1.2. SystemTap Capabilities</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="introduction.html" title="Chapter 1. Introduction" /><link rel="prev" href="introduction.html" title="Chapter 1. Introduction" /><link rel="next" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="introduction.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="using-systemtap.html"><strong>Next</strong></a></li></ul><div class="section" title="1.2. SystemTap Capabilities"><div class="titlepage"><div><div><h2 class="title" id="intro-systemtap-vs-others">1.2. SystemTap Capabilities</h2></div></div></div><a id="id471417" class="indexterm"></a><a id="id471429" class="indexterm"></a><div class="para">
-                       SystemTap was originally developed to provide functionality for Fedora 10 similar to previous Linux probing tools such as <span class="application"><strong>dprobes</strong></span> and the Linux Trace Toolkit. SystemTap aims to supplement the existing suite of Linux monitoring tools by providing users with the infrastructure to track kernel activity. In addition, SystemTap combines this capability with two things:
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>1.2. SystemTap Capabilities</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="introduction.html" title="Chapter 1. Introduction" /><link rel="prev" href="introduction.html" title="Chapter 1. Introduction" /><link rel="next" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="introduction.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="using-systemtap.html"><strong>Next</strong></a></li></ul><div class="section" id="intro-systemtap-vs-others"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="intro-systemtap-vs-others">1.2. SystemTap Capabilities</h2></div></div></div><a id="id426851" class="indexterm"></a><a id="id426862" class="indexterm"></a><div class="para">
+                       SystemTap was originally developed to provide functionality for Fedora similar to previous Linux probing tools such as <span class="application"><strong>dprobes</strong></span> and the Linux Trace Toolkit. SystemTap aims to supplement the existing suite of Linux monitoring tools by providing users with the infrastructure to track kernel activity. In addition, SystemTap combines this capability with two things:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                        Flexibility: SystemTap's framework allows users to develop simple scripts for investigating and monitoring a wide variety of kernel functions, system calls, and other events that occur in kernel-space. With this, SystemTap is not so much a <span class="emphasis"><em>tool</em></span> as it is a system that allows you to develop your own kernel-specific forensic and monitoring tools.
                                </div></li><li class="listitem"><div class="para">
                                        Ease-Of-Use: as mentioned earlier, SystemTap allows users to probe kernel-space events without having to resort to instrument, recompile, install, and reboot the kernel.
                                </div></li></ul></div><div class="para">
-                       Most of the SystemTap scripts enumerated in <a class="xref" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts">Chapter 4, <i>Useful SystemTap Scripts</i></a> demonstrate system forensics and monitoring capabilities not natively available with other similar tools (such as <code class="command">top</code>, <code class="command">oprofile</code>, or <code class="command">ps</code>). These scripts are provided to give readers extensive examples of the application of SystemTap, which in turn will educate them further on the capabilities they can employ when writing their own SystemTap scripts.
-               </div><a id="id463264" class="indexterm"></a><a id="id463277" class="indexterm"></a><div class="formalpara"><h5 class="formalpara" id="id463289">Limitations</h5>
-                               The current iteration of SystemTap allows for a multitude of options when probing kernel-space events. However, SystemTap's ability to probe user-space events is quite limited. At present, the developmental efforts of the SystemTap community are geared towards improving SystemTap's user-space probing capabilities.
+                       Most of the SystemTap scripts enumerated in <a class="xref" href="useful-systemtap-scripts.html">Chapter 5, <i>Useful SystemTap Scripts</i></a> demonstrate system forensics and monitoring capabilities not natively available with other similar tools (such as <code class="command">top</code>, <code class="command">oprofile</code>, or <code class="command">ps</code>). These scripts are provided to give readers extensive examples of the application of SystemTap, which in turn will educate them further on the capabilities they can employ when writing their own SystemTap scripts.
+               </div><a id="id1947095" class="indexterm"></a><a id="id1947106" class="indexterm"></a><div class="formalpara"><h5 class="formalpara" id="id1947118">Limitations</h5>
+                               The current iteration of SystemTap allows for a multitude of options when probing kernel-space events for a wide range of kernels. However, SystemTap's ability to probe user-space events is dependent on kernel support (the Utrace mechanism) that is unavailable in many kernels. Thus, only some kernel versions support user-space probing. At present, the developmental efforts of the SystemTap community are geared towards improving SystemTap's user-space probing capabilities.
                        </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="introduction.html"><strong>Prev</strong>Chapter 1. Introduction</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="using-systemtap.html"><strong>Next</strong>Chapter 2. Using SystemTap</a></li></ul></body></html>
index 876742e4181e99f810275e08e8f92f00e0d3ab7e..156da7a84add080f2f75fc90ed576b9adad964c1 100644 (file)
@@ -1,10 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 1. Introduction</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="pr01s02.html" title="2. We Need Feedback!" /><link rel="next" href="intro-systemtap-vs-others.html" title="1.2. SystemTap Capabilities" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="pr01s02.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="intro-systemtap-vs-others.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 1. Introduction" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="introduction">Chapter 1. Introduction</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="introduction.html#goals">1.1. Documentation Goals</a></span></dt><dt><span class="section"><a href="intro-systemtap-vs-others.html">1.2. SystemTap Capabilities</a></span></dt></dl></div><a id="id541982" class="indexterm"></a><a id="id541089" class="indexterm"></a><div class="para">
-               SystemTap is a tracing and probing tool that allows users to study and monitor the activities of the operating system (particularly, the kernel) in fine detail. It provides information similar to the output of tools like <code class="command">netstat</code>, <code class="command">ps</code>, <code class="command">top</code>, and <code class="command">iostat</code>; however, SystemTap is designed to provide more filtering and analysis options for collected information.
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 1. Introduction</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="pr01s02.html" title="2. We Need Feedback!" /><link rel="next" href="intro-systemtap-vs-others.html" title="1.2. SystemTap Capabilities" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="pr01s02.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="intro-systemtap-vs-others.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="introduction" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 1. Introduction</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="introduction.html#goals">1.1. Documentation Goals</a></span></dt><dt><span class="section"><a href="intro-systemtap-vs-others.html">1.2. SystemTap Capabilities</a></span></dt></dl></div><a id="id622285" class="indexterm"></a><a id="id590701" class="indexterm"></a><div class="para">
+               SystemTap is a tracing and probing tool that allows users to study and monitor the activities of the computer system (particularly, the kernel) in fine detail. It provides information similar to the output of tools like <code class="command">netstat</code>, <code class="command">ps</code>, <code class="command">top</code>, and <code class="command">iostat</code>; however, SystemTap is designed to provide more filtering and analysis options for collected information.
        </div><div class="para">
-               For system administrators, SystemTap can be used as a performance monitoring tool for Fedora 10. It is most useful when other similar tools cannot precisely pinpoint a bottleneck in the system, requiring a deep analysis of kernel activity. In the same manner, application developers can also use SystemTap to monitor, in finer detail, how their application behaves within the Linux system.
-       </div><div class="section" title="1.1. Documentation Goals"><div class="titlepage"><div><div><h2 class="title" id="goals">1.1. Documentation Goals</h2></div></div></div><a id="id504564" class="indexterm"></a><a id="id590101" class="indexterm"></a><a id="id535082" class="indexterm"></a><a id="id615400" class="indexterm"></a><div class="para">
+               For system administrators, SystemTap can be used as a performance monitoring tool for Fedora. It is most useful when other similar tools cannot precisely pinpoint a bottleneck in the system, requiring a deep analysis of kernel activity. In the same manner, application developers can also use SystemTap to monitor, in finer detail, how their application behaves within the Linux system.
+       </div><div class="section" id="goals"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="goals">1.1. Documentation Goals</h2></div></div></div><a id="id1933977" class="indexterm"></a><a id="id572957" class="indexterm"></a><a id="id657099" class="indexterm"></a><a id="id426534" class="indexterm"></a><div class="para">
                        SystemTap provides the infrastructure to monitor the running Linux kernel for detailed analysis. This can assist administrators and developers in identifying the underlying cause of a bug or performance problem.
                </div><div class="para">
                        Without SystemTap, monitoring the activity of a running kernel would require a tedious instrument, recompile, install, and reboot sequence. SystemTap is designed to eliminate this, allowing users to gather the same information by simply running user-written SystemTap scripts.
@@ -13,7 +13,7 @@
                </div><div class="para">
                        To lower these barriers the SystemTap Beginners Guide was written with the following goals:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                                       To introduce users to SystemTap, familiarize them with its architecture, and provide setup instructions for all kernel types.
+                                       To introduce users to SystemTap, familiarize them with its architecture, and provide setup instructions.
                                </div></li><li class="listitem"><div class="para">
                                        To provide pre-written SystemTap scripts for monitoring detailed activity in different components of the system, along with instructions on how to run them and analyze their output.
                                </div></li></ul></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="pr01s02.html"><strong>Prev</strong>2. We Need Feedback!</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="intro-systemtap-vs-others.html"><strong>Next</strong>1.2. SystemTap Capabilities</a></li></ul></body></html>
index b4025c7f0b6276fceb79084a4305667f4077fe98..764fc51fa1b63354fa76e7b9098ffcb14aa6a1b7 100644 (file)
@@ -1,11 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.7. Periodically Print I/O Block Time</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="inodewatch2sect.html" title="4.2.6. Monitoring Changes to File Attributes" /><link rel="next" href="mainsect-profiling.html" title="4.3. Profiling" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatch2sect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="mainsect-profiling.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.7. Periodically Print I/O Block Time" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="ioblktimesect">4.2.7. Periodically Print I/O Block Time</h3></div></div></div><a id="id510358" class="indexterm"></a><a id="id492408" class="indexterm"></a><a id="id600990" class="indexterm"></a><a id="id612113" class="indexterm"></a><a id="id592893" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.7. Periodically Print I/O Block Time</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="inodewatch2sect.html" title="5.2.6. Monitoring Changes to File Attributes" /><link rel="next" href="mainsect-profiling.html" title="5.3. Profiling" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatch2sect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="mainsect-profiling.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="ioblktimesect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="ioblktimesect">5.2.7. Periodically Print I/O Block Time</h3></div></div></div><a id="id1966374" class="indexterm"></a><a id="id712736" class="indexterm"></a><a id="id436499" class="indexterm"></a><a id="id739877" class="indexterm"></a><a id="id523271" class="indexterm"></a><div class="para">
                This section describes how to track the amount of time each block I/O requests spends waiting for completion. This is useful in determining whether there are too many outstanding block I/O operations at any given time.
-       </div><div class="formalpara"><h5 class="formalpara" id="ioblktime">ioblktime.stp</h5>
+       </div><div class="formalpara" id="ioblktime"><h5 class="formalpara">ioblktime.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 global req_time, etimes
 
@@ -34,18 +33,15 @@ probe timer.s(10), end {
   }
   delete etimes
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="ioblktimesect.html#ioblktime" title="ioblktime.stp">ioblktime.stp</a> computes the average waiting time for block I/O per device, and prints a list every 10 seconds. As always, you can revise this refresh rate by editing the specified value in <code class="command">probe timer.s(10), end {</code>.
+               <a class="xref" href="ioblktimesect.html#ioblktime">ioblktime.stp</a> computes the average waiting time for block I/O per device, and prints a list every 10 seconds. As always, you can revise this refresh rate by editing the specified value in <code class="command">probe timer.s(10), end {</code>.
        </div><div class="para">
                In some cases, there can be too many outstanding block I/O operations, at which point the script can exceed the default number of <code class="command">MAXMAPENTRIES</code>. <code class="command">MAXMAPENTRIES</code> is the maximum number of rows in an array if the array size is not specified explicitly when declared. If the script exceeds the default <code class="command">MAXMAPENTRIES</code> value of 2048, run the script again with the <code class="command">stap</code> option <code class="command">-DMAXMAPENTRIES=10000</code>.
-       </div><div class="example" id="ioblktimeoutput"><div class="example-contents"><pre class="screen">
-    device  rw total (us)      count   avg (us)
+       </div><div class="example" id="ioblktimeoutput"><h6>Example 5.12. <a class="xref" href="ioblktimesect.html#ioblktime">ioblktime.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">    device  rw total (us)      count   avg (us)
        sda   W       9659          6       1609
       dm-0   W      20278          6       3379
       dm-0   R      20524          5       4104
-       sda   R      19277          5       3855
-</pre></div><h6>Example 4.12. <a class="xref" href="ioblktimesect.html#ioblktime" title="ioblktime.stp">ioblktime.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
-               <a class="xref" href="ioblktimesect.html#ioblktimeoutput" title="Example 4.12. ioblktime.stp Sample Output">Example 4.12, “ioblktime.stp Sample Output”</a> displays the device name, operations performed (<code class="command">rw</code>), total wait time of all operations (<code class="command">total(us)</code>), number of operations (<code class="command">count</code>), and average wait time for all those operations (<code class="command">avg (us)</code>). The times tallied by the script are in microseconds.
-       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatch2sect.html"><strong>Prev</strong>4.2.6. Monitoring Changes to File Attributes</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="mainsect-profiling.html"><strong>Next</strong>4.3. Profiling</a></li></ul></body></html>
+       sda   R      19277          5       3855</pre></div></div><br class="example-break" /><div class="para">
+               <a class="xref" href="ioblktimesect.html#ioblktimeoutput">Example 5.12, “ioblktime.stp Sample Output”</a> displays the device name, operations performed (<code class="command">rw</code>), total wait time of all operations (<code class="command">total(us)</code>), number of operations (<code class="command">count</code>), and average wait time for all those operations (<code class="command">avg (us)</code>). The times tallied by the script are in microseconds.
+       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="inodewatch2sect.html"><strong>Prev</strong>5.2.6. Monitoring Changes to File Attributes</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="mainsect-profiling.html"><strong>Next</strong>5.3. Profiling</a></li></ul></body></html>
index a6b6cedacb6b87bc8291cdc79865ae4832294d69..6bb1ec0ed86738700065698379aeb37423e95eea 100644 (file)
@@ -1,81 +1,85 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.2. Tracking I/O Time For Each File Read or Write</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="mainsect-disk.html" title="4.2. Disk" /><link rel="next" href="traceiosect.html" title="4.2.3. Track Cumulative IO" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-disk.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="traceiosect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.2. Tracking I/O Time For Each File Read or Write" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="iotimesect">4.2.2. Tracking I/O Time For Each File Read or Write</h3></div></div></div><a id="id646579" class="indexterm"></a><a id="id501190" class="indexterm"></a><a id="id491612" class="indexterm"></a><a id="id645326" class="indexterm"></a><a id="id597746" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.2. Tracking I/O Time For Each File Read or Write</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="mainsect-disk.html" title="5.2. Disk" /><link rel="next" href="traceiosect.html" title="5.2.3. Track Cumulative IO" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-disk.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="traceiosect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="iotimesect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="iotimesect">5.2.2. Tracking I/O Time For Each File Read or Write</h3></div></div></div><a id="id1953406" class="indexterm"></a><a id="id564885" class="indexterm"></a><a id="id451120" class="indexterm"></a><a id="id439723" class="indexterm"></a><a id="id565865" class="indexterm"></a><div class="para">
                This section describes how to monitor the amount of time it takes for each process to read from or write to any file. This is useful if you wish to determine what files are slow to load on a given system.
-       </div><div class="formalpara"><h5 class="formalpara" id="iotime">iotime.stp</h5>
+       </div><div class="formalpara" id="iotime"><h5 class="formalpara">iotime.stp</h5>
                        
-<pre class="programlisting">
+<pre class="programlisting">#! /usr/bin/env stap
+
+/*
+ * Copyright (C) 2006-2007 Red Hat Inc.
+ * 
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU General Public License v.2.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ *
+ * Print out the amount of time spent in the read and write systemcall
+ * when each file opened by the process is closed. Note that the systemtap 
+ * script needs to be running before the open operations occur for
+ * the script to record data.
+ *
+ * This script could be used to to find out which files are slow to load
+ * on a machine. e.g.
+ *
+ * stap iotime.stp -c 'firefox'
+ *
+ * Output format is:
+ * timestamp pid (executabable) info_type path ...
+ *
+ * 200283135 2573 (cupsd) access /etc/printcap read: 0 write: 7063
+ * 200283143 2573 (cupsd) iotime /etc/printcap time: 69
+ *
+ */
+
 global start
-global entry_io
-global fd_io
 global time_io
 
-function timestamp:long() {
-  return gettimeofday_us() - start
-}
-
-function proc:string() {
-  return sprintf("%d (%s)", pid(), execname())
-}
+function timestamp:long() { return gettimeofday_us() - start }
 
-probe begin {
- start = gettimeofday_us()
-}
+function proc:string() { return sprintf("%d (%s)", pid(), execname()) }
 
-global filenames
-global filehandles
-global fileread
-global filewrite
+probe begin { start = gettimeofday_us() }
 
-probe syscall.open {
-  filenames[pid()] = user_string($filename)
-} 
+global filehandles, fileread, filewrite
 
 probe syscall.open.return {
+  filename = user_string($filename)
   if ($return != -1) {
-    filehandles[pid(), $return] = filenames[pid()]
-    fileread[pid(), $return] = 0
-    filewrite[pid(), $return] = 0
+    filehandles[pid(), $return] = filename
   } else {
-    printf("%d %s access %s fail\n", timestamp(), proc(), filenames[pid()])
+    printf("%d %s access %s fail\n", timestamp(), proc(), filename)
   }
-  delete filenames[pid()]
-}
-
-probe syscall.read {
-  if ($count &gt; 0) {
-    fileread[pid(), $fd] += $count
-  }
-  t = gettimeofday_us(); p = pid()
-  entry_io[p] = t
-  fd_io[p] = $fd
 }
 
 probe syscall.read.return {
-  t = gettimeofday_us(); p = pid()
-  fd = fd_io[p]
-  time_io[p,fd] &lt;&lt;&lt; t - entry_io[p]
-}
-
-probe syscall.write {
-  if ($count &gt; 0) {
-    filewrite[pid(), $fd] += $count
-  }
-  t = gettimeofday_us(); p = pid()
-  entry_io[p] = t
-  fd_io[p] = $fd
+  p = pid()
+  fd = $fd
+  bytes = $return
+  time = gettimeofday_us() - @entry(gettimeofday_us())
+  if (bytes &gt; 0)
+    fileread[p, fd] += bytes
+  time_io[p, fd] &lt;&lt;&lt; time
 }
 
 probe syscall.write.return {
-  t = gettimeofday_us(); p = pid()
-  fd = fd_io[p]
-  time_io[p,fd] &lt;&lt;&lt; t - entry_io[p]
+  p = pid()
+  fd = $fd
+  bytes = $return
+  time = gettimeofday_us() - @entry(gettimeofday_us())
+  if (bytes &gt; 0)
+    filewrite[p, fd] += bytes
+  time_io[p, fd] &lt;&lt;&lt; time
 }
 
 probe syscall.close {
-  if (filehandles[pid(), $fd] != "") {
-    printf("%d %s access %s read: %d write: %d\n",  timestamp(), proc(),
-           filehandles[pid(), $fd], fileread[pid(), $fd], filewrite[pid(), $fd])
+  if ([pid(), $fd] in filehandles) {
+    printf("%d %s access %s read: %d write: %d\n",
+           timestamp(), proc(), filehandles[pid(), $fd],
+           fileread[pid(), $fd], filewrite[pid(), $fd])
     if (@count(time_io[pid(), $fd]))
       printf("%d %s iotime %s time: %d\n",  timestamp(), proc(),
              filehandles[pid(), $fd], @sum(time_io[pid(), $fd]))
@@ -83,18 +87,14 @@ probe syscall.close {
   delete fileread[pid(), $fd]
   delete filewrite[pid(), $fd]
   delete filehandles[pid(), $fd]
-  delete fd_io[pid()]
-  delete entry_io[pid()]
   delete time_io[pid(),$fd]
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="iotimesect.html#iotime" title="iotime.stp">iotime.stp</a> tracks each time a system call opens, closes, reads from, and writes to a file. For each file any system call accesses, <a class="xref" href="iotimesect.html#iotime" title="iotime.stp">iotime.stp</a> counts the number of microseconds it takes for any reads or writes to finish and tracks the amount of data (in bytes) read from or written to the file.
-       </div><a id="id640470" class="indexterm"></a><a id="id619999" class="indexterm"></a><a id="id502563" class="indexterm"></a><div class="para">
-               <a class="xref" href="iotimesect.html#iotime" title="iotime.stp">iotime.stp</a> also uses the local variable <code class="command">$count</code> to track the amount of data (in bytes) that any system call <span class="emphasis"><em>attempts</em></span> to read or write. Note that <code class="command">$return</code> (as used in <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> from <a class="xref" href="mainsect-disk.html#disktop" title="4.2.1. Summarizing Disk Read/Write Traffic">Section 4.2.1, “Summarizing Disk Read/Write Traffic”</a>) stores the <span class="emphasis"><em>actual</em></span> amount of data read/written. <code class="command">$count</code> can only be used on probes that track data reads or writes (e.g. <code class="command">syscall.read</code> and <code class="command">syscall.write</code>).
-       </div><div class="example" id="iotimeoutput"><div class="example-contents"><pre class="screen">
-[...]
+               <a class="xref" href="iotimesect.html#iotime">iotime.stp</a> tracks each time a system call opens, closes, reads from, and writes to a file. For each file any system call accesses, <a class="xref" href="iotimesect.html#iotime">iotime.stp</a> counts the number of microseconds it takes for any reads or writes to finish and tracks the amount of data (in bytes) read from or written to the file.
+       </div><a id="id441413" class="indexterm"></a><a id="id1953738" class="indexterm"></a><a id="id531562" class="indexterm"></a><div class="para">
+               <a class="xref" href="iotimesect.html#iotime">iotime.stp</a> also uses the local variable <code class="command">$count</code> to track the amount of data (in bytes) that any system call <span class="emphasis"><em>attempts</em></span> to read or write. Note that <code class="command">$return</code> (as used in <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> from <a class="xref" href="mainsect-disk.html#disktop">Section 5.2.1, “Summarizing Disk Read/Write Traffic”</a>) stores the <span class="emphasis"><em>actual</em></span> amount of data read/written. <code class="command">$count</code> can only be used on probes that track data reads or writes (e.g. <code class="command">syscall.read</code> and <code class="command">syscall.write</code>).
+       </div><div class="example" id="iotimeoutput"><h6>Example 5.7. <a class="xref" href="iotimesect.html#iotime">iotime.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 825946 3364 (NetworkManager) access /sys/class/net/eth0/carrier read: 8190 write: 0
 825955 3364 (NetworkManager) iotime /sys/class/net/eth0/carrier time: 9
 [...]
@@ -103,19 +103,18 @@ probe syscall.close {
 [...]
 3973737 2886 (sendmail) access /proc/loadavg read: 4096 write: 0
 3973744 2886 (sendmail) iotime /proc/loadavg time: 11
-[...]
-</pre></div><h6>Example 4.7. <a class="xref" href="iotimesect.html#iotime" title="iotime.stp">iotime.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
-               <a class="xref" href="iotimesect.html#iotimeoutput" title="Example 4.7. iotime.stp Sample Output">Example 4.7, “iotime.stp Sample Output”</a> prints out the following data:
+[...]</pre></div></div><br class="example-break" /><div class="para">
+               <a class="xref" href="iotimesect.html#iotimeoutput">Example 5.7, “iotime.stp Sample Output”</a> prints out the following data:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                               A timestamp, in microseconds
+                               A timestamp, in microseconds.
                        </div></li><li class="listitem"><div class="para">
-                               Process ID and process name
+                               Process ID and process name.
                        </div></li><li class="listitem"><div class="para">
-                               An <code class="computeroutput">access</code> or <code class="computeroutput">iotime</code> flag
+                               An <code class="computeroutput">access</code> or <code class="computeroutput">iotime</code> flag.
                        </div></li><li class="listitem"><div class="para">
-                               The file accessed
+                               The file accessed.
                        </div></li></ul></div><div class="para">
-               If a process was able to read or write any data, a pair of <code class="computeroutput">access</code> and <code class="computeroutput">iotime</code> lines should appear together. The <code class="computeroutput">access</code> line's timestamp refer to the time that a given process started accessing a file; at the end of the line, it will show the amount of data read/written (in bytes). The <code class="computeroutput">iotime</code> line will show the amount of time (in microseconds) that the process took in order to perform the read or write.
+               If a process was able to read or write any data, a pair of <code class="computeroutput">access</code> and <code class="computeroutput">iotime</code> lines should appear together. The <code class="computeroutput">access</code> line's timestamp refers to the time that a given process started accessing a file; at the end of the line, it will show the amount of data read/written (in bytes). The <code class="computeroutput">iotime</code> line will show the amount of time (in microseconds) that the process took in order to perform the read or write.
        </div><div class="para">
                If an <code class="computeroutput">access</code> line is not followed by an <code class="computeroutput">iotime</code> line, it simply means that the process did not read or write any data.
-       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-disk.html"><strong>Prev</strong>4.2. Disk</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="traceiosect.html"><strong>Next</strong>4.2.3. Track Cumulative IO</a></li></ul></body></html>
+       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-disk.html"><strong>Prev</strong>5.2. Disk</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="traceiosect.html"><strong>Next</strong>5.2.3. Track Cumulative IO</a></li></ul></body></html>
index bed3e782a5e1972589f0a7146a3746da6865c712..59511a4827efd80a425175d16d87a3c5d7c9adc2 100644 (file)
@@ -1,3 +1,3 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Index</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="appe-Publican-Revision_History.html" title="Appendix A. Revision History" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="appe-Publican-Revision_History.html"><strong>Prev</strong></a></li><li class="next"></li></ul><div class="index" title="Index"><div class="titlepage"><div><div><h2 class="title" id="id475588">Index</h2></div></div></div><div class="index"><div class="indexdiv"><h3>Symbols</h3><dl><dt>$count</dt><dd><dl><dt>sample usage</dt><dd><dl><dt>local variables, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd></dl></dd><dt>$return</dt><dd><dl><dt>sample usage</dt><dd><dl><dt>local variables, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd><dt>@avg (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@count (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@max (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@min (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@sum (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>A</h3><dl><dt>adding values to statistical aggregates</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>advantages of cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>aggregate element not found</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>aggregates (statistical)</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>aggregation overflow</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>algebraic formulas using arrays</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>architecture notation, determining, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>architecture of SystemTap, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>array locals not supported</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>array operations</dt><dd><dl><dt>assigning associated values, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associative arrays, <a class="indexterm" href="arrayoperators.html">Array Operations in SystemTap</a></dt><dt>clearing arrays/array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd><dt>computing for statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>conditional statements, using arrays in, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>deleting arrays and array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>incrementing associated values, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd><dt>multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>processing multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dd><dl><dt>cumulative virtual file system reads, tallying, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>iterations, processing elements in an array as, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>limiting the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>ordering the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>reading values from arrays, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>computing for timestamp deltas, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dd><dl><dt>(see also associative arrays)</dt></dl></dd><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associating timestamps to process names</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>associated values</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>associating timestamps to process names</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>associative arrays</dt><dd><dl><dt>introduction, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dd><dl><dt>associated values, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>example, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>index expression, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>key pairs, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>syntax, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>unique keys, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>asynchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>B</h3><dl><dt>begin</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>building instrumentation modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>building kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></div><div class="indexdiv"><h3>C</h3><dl><dt>call graph tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>capabilities of SystemTap</dt><dd><dl><dt>Introduction, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt></dl></dd><dt>changes to file attributes, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>command-line arguments</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt></dl></dd></dl></dd><dt>compiling instrumentation/kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>components</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>computing for timestamp deltas</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>conditional operators</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>CONFIG_HZ, computing for, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>contended user-space locks (futex contentions), identifying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>copy fault</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>count operator</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>counting function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>CPU ticks</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>cpu()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>cross-compiling, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>cross-instrumentation</dt><dd><dl><dt>advantages of, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>building kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>configuration</dt><dd><dl><dt>host system and target system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>generating instrumentation from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>host system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>instrumentation module, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>target kernel, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>target system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>ctime()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>ctime(), example of usage</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>cumulative I/O, tracking</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>cumulative virtual file system reads, tallying</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>D</h3><dl><dt>delete operator</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>determining architecture notation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>determining the kernel version, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>determining time spent in kernel and user space</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>device I/O, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>device number of a file (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>disk I/O traffic, summarizing</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>division by 0</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>documentation goals</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>E</h3><dl><dt>embedded code in unprivileged script</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>empty unique keys</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>end</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>errors</dt><dd><dl><dt>parse/semantics error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd><dt>runtime errors/warnings, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>event types</dt><dd><dl><dt>Understanding How SystemTap Works, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt></dl></dd><dt>Events</dt><dd><dl><dt>asynchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>begin, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>end, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>examples of synchronous and asynchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>introduction, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>kernel.function("function"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>kernel.trace("tracepoint"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>module("module"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>synchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>syscall.system_call, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>timer events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>vfs.file_operation, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>wildcards, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>events and handlers, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>events wildcards, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>example</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>example of multiple command-line arguments</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>examples of synchronous and asynchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt><dd><dl><dt>call graph tracing, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>CPU ticks, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>ctime(), example of usage, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>determining time spent in kernel and user space, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>futex system call, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>identifying contended user-space locks (i.e. futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>if/else conditionals, alternative syntax, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt><dt>inode number, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring changes to file attributes, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt><dt>monitoring device I/O, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>monitoring I/O block time, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt><dt>monitoring I/O time, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>monitoring incoming TCP connections, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt><dt>monitoring polling applications, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt><dt>monitoring reads and writes to a file, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring system calls, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>monitoring system calls (volume per process), <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt><dt>monitoring TCP packets, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt><dt>multiple command-line arguments, example of, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>net/socket.c, tracing functions from, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>network profiling, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>process deadlocks (arising from futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>stat -c, determining file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>stat -c, determining whole device number, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>summarizing disk I/O traffic, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>tallying function calls, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>thread_indent(), sample usage, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>timer.ms(), sample usage, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>timer.s(), sample usage, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>tracing functions called in network socket code, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>tracking cumulative I/O, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt><dt>trigger function, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>usrdev2kerndev(), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>whole device number (usage as a command-line argument), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>exceeded MAXACTION</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>exceeded MAXNESTING</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>exit()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>expected symbol/array index expression</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>extracting data collected by statistical aggregates</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>F</h3><dl><dt>fedoradebugurl.sh, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>feedback</dt><dd><dl><dt>contact information for this manual, <a class="indexterm" href="pr01s02.html">We Need Feedback!</a></dt></dl></dd><dt>file attributes, monitoring changes to</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>file device number (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>file reads/writes, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>for loops</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>format</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>format and syntax</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>format specifiers</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>format strings</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>function call (unresolved)</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>function calls (incoming/outgoing), tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>function calls, tallying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dd><dl><dt>cpu(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>ctime(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>gettimeofday_s(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>pp(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd><dt>target(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>thread_indent(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>tid(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>uid(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>functions (used in handlers)</dt><dd><dl><dt>exit(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>functions called in network socket code, tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>futex contention, definition</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>futex contentions, identifying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>futex system call</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>G</h3><dl><dt>gettimeofday_s()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>global</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>goals, documentation</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt></dl></dd><dt>grammatical/typographical script error</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>guru mode</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>H</h3><dl><dt>handler functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>handlers</dt><dd><dl><dt>conditional statements, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dd><dl><dt>conditional operators, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>for loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>if/else, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>while loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd><dt>introduction, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dd><dl><dt>command-line arguments, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>global, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>syntax and format, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dt>variable notations, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>variables, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>handlers and events, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>heaviest disk reads/writes, identifying</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>host system</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>host system and target system</dt><dd><dl><dt>cross-instrumentation</dt><dd><dl><dt>configuration, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>I</h3><dl><dt>I/O block time, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>I/O monitoring (by device)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>I/O time, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>I/O traffic, summarizing</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>identifier type mismatch</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>identifying contended user-space locks (i.e. futex contentions)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>identifying heaviest disk reads/writes</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>if/else</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>if/else conditionals, alternative syntax</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt></dl></dd><dt>if/else statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>incoming TCP connections, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>incoming/outgoing function calls, tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>index expression</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>initial testing, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>inode number</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>Installation</dt><dd><dl><dt>fedoradebugurl.sh, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>initial testing, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>kernel information packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel version, determining the, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>required packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>Setup and Installation, <a class="indexterm" href="using-systemtap.html#using-setup">Installation and Setup</a></dt><dt>systemtap package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>systemtap-runtime package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt></dl></dd><dt>instrumentation module</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>instrumentation modules from SystemTap scripts, building, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>integer extractors</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>Introduction</dt><dd><dl><dt>capabilities of SystemTap, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt><dt>documentation goals, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt><dt>goals, documentation, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt><dt>limitations of SystemTap, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt><dt>performance monitoring, <a class="indexterm" href="introduction.html">Introduction</a></dt></dl></dd><dt>invalid division</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>invalid values to variables/arrays</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>iterations, processing elements in an array as</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>K</h3><dl><dt>kernel and user space, determining time spent in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>kernel information packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel modules from SystemTap scripts, building, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>kernel version, determining the, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel.function("function")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>kernel.trace("tracepoint")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>key pairs</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>L</h3><dl><dt>libdwfl failure</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>limitations of SystemTap</dt><dd><dl><dt>Introduction, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt></dl></dd><dt>limiting the output of foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>local variables</dt><dd><dl><dt>name, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>sample usage</dt><dd><dl><dt>$count, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>$return, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>M</h3><dl><dt>MAXACTION exceeded</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>MAXNESTING exceeded</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>membership (in array), testing for</dt><dd><dl><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>module("module")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>monitoring changes to file attributes</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>monitoring cumulative I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>monitoring device I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>monitoring I/O block time</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>monitoring I/O time</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>monitoring incoming TCP connections</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>monitoring polling applications</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt></dl></dd><dt>monitoring reads and writes to a file</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>monitoring system calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>monitoring system calls (volume per process)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt></dl></dd><dt>monitoring TCP packets</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt></dl></dd><dt>multiple array operations within the same probe</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>multiple command-line arguments, example of</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>N</h3><dl><dt>name</dt><dd><dl><dt>local variables, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>net/socket.c, tracing functions from</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>network profiling</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd><dt>network socket code, tracing functions called in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>network traffic, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd><dt>no match for probe point</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>non-global arrays</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>number of errors: N, skipped probes: M</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>O</h3><dl><dt>operations</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associative arrays, <a class="indexterm" href="arrayoperators.html">Array Operations in SystemTap</a></dt><dt>clearing arrays/array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd><dt>computing for statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>conditional statements, using arrays in, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>deleting arrays and array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>incrementing associated values, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd><dt>multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>processing multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dd><dl><dt>cumulative virtual file system reads, tallying, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>iterations, processing elements in an array as, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>limiting the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>ordering the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>reading values from arrays, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>computing for timestamp deltas, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>options, stap</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>ordering the output of foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>overflow of aggregation</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>P</h3><dl><dt>packages required to run SystemTap, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>performance monitoring</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html">Introduction</a></dt></dl></dd><dt>pointer dereference fault</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>polling applications, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt></dl></dd><dt>pp()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>printf()</dt><dd><dl><dt>format specifiers, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>format strings, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>syntax and format, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>printing I/O activity (cumulative)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>printing I/O block time (periodically)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>probe mismatch</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>probe point (no match for)</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>probes</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>process deadlocks (arising from futex contentions)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>cumulative virtual file system reads, tallying</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>limiting the output of foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>ordering the output of foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>profiling the network</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>R</h3><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd><dt>computing for timestamp deltas</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>reads/writes to a file, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>required packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>RPMs required to run SystemTap, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>running scripts from standard input, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>running SystemTap scripts</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>S</h3><dl><dt>script examples</dt><dd><dl><dt>call graph tracing, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>CPU ticks, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>ctime(), example of usage, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>determining time spent in kernel and user space, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>futex system call, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>identifying contended user-space locks (i.e. futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>if/else conditionals, alternative syntax, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt><dt>inode number, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring changes to file attributes, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt><dt>monitoring device I/O, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>monitoring I/O block time, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt><dt>monitoring I/O time, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>monitoring incoming TCP connections, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt><dt>monitoring polling applications, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt><dt>monitoring reads and writes to a file, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring system calls, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>monitoring system calls (volume per process), <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt><dt>monitoring TCP packets, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt><dt>multiple command-line arguments, example of, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>net/socket.c, tracing functions from, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>network profiling, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>process deadlocks (arising from futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>stat -c, determining file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>stat -c, determining whole device number, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>summarizing disk I/O traffic, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>tallying function calls, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>thread_indent(), sample usage, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>timer.ms(), sample usage, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>timer.s(), sample usage, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>tracing functions called in network socket code, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>tracking cumulative I/O, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt><dt>trigger function, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>usrdev2kerndev(), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>whole device number (usage as a command-line argument), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dd><dl><dt>components, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>events and handlers, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>format and syntax, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>functions, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>probes, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>statement blocks, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>sessions, SystemTap, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>Setup and Installation, <a class="indexterm" href="using-systemtap.html#using-setup">Installation and Setup</a></dt><dt>standard input, running scripts from</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stap</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stap options, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapdev</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>staprun</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stapusr</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stat -c, determining file device number (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>stat -c, determining whole device number</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>statement blocks</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>summarizing disk I/O traffic</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>synchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>syntax</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>syntax and format</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt></dl></dd><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>syscall.system_call</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>system calls volume (per process), monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt></dl></dd><dt>system calls, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>SystemTap architecture, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>SystemTap handlers</dt><dd><dl><dt>SystemTap handler constructs, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dd><dl><dt>syntax and format, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt></dl></dd></dl></dd><dt>systemtap package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>SystemTap script functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dd><dl><dt>components, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>events and handlers, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>format and syntax, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>functions, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>probes, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>statement blocks, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd><dt>useful examples, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt></dl></dd><dt>SystemTap scripts, how to run, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>SystemTap sessions, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>SystemTap statements</dt><dd><dl><dt>conditional statements, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dd><dl><dt>conditional operators, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>for loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>if/else, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>while loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd><dt>SystemTap handler constructs</dt><dd><dl><dt>command-line arguments, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>global, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>variable notations, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>variables, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>systemtap-runtime package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>systemtap-testsuite package</dt><dd><dl><dt>sample scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>T</h3><dl><dt>tallying function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>tallying virtual file system reads (VFS reads)</dt><dd><dl><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>Tapsets</dt><dd><dl><dt>definition of, <a class="indexterm" href="understanding-tapsets.html">Tapsets</a></dt></dl></dd><dt>target kernel</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target system</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target system and host system</dt><dd><dl><dt>configuration, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>target-symbol expression, unresolved</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>TCP connections (incoming), monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>TCP packets, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt></dl></dd><dt>testing for array membership</dt><dd><dl><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>testing, initial, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>thread_indent()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>thread_indent(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tid()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>time of I/O </dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>time spent in kernel/user space, determining</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>timer events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>timer.ms(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>timer.s(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>timestamp deltas, computing for</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>timestamps, association thereof to process names</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>tracepoint, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>tracing call graph</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tracing functions called in network socket code</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>tracing incoming/outgoing function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tracking cumulative I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>trigger function</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>type mismatch for identifier</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>typographical script error</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>U</h3><dl><dt>uid()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>uname -m, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>uname -r, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>understainding SystemTap errors</dt><dd><dl><dt>runtime errors/warnings, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>Understanding How SystemTap Works, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dd><dl><dt>architecture, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>event types, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>events and handlers, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>SystemTap sessions, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt></dl></dd><dt>understanding SystemTap errors</dt><dd><dl><dt>parse/semantics error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unique keys</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>unprivileged script, embedded code in</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved function call</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved target-symbol expression</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved type for identifier</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unsafe embedded code in unprivileged script</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>Usage</dt><dd><dl><dt>options, stap, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>running SystemTap scripts, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>standard input, running scripts from, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stap, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapdev, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>staprun, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapusr, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>useful examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt><dt>user and kernel space, determining time spent in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>using arrays in simple computations</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>Using SystemTap, <a class="indexterm" href="using-systemtap.html">Using SystemTap</a></dt><dt>usrdev2kerndev()</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>V</h3><dl><dt>values, assignment of</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>variable modified during 'foreach'</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>variable notations</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt></dl></dd></dl></dd><dt>variables</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>variables (local)</dt><dd><dl><dt>name, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>sample usage</dt><dd><dl><dt>$count, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>$return, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd><dt>VFS reads, tallying of</dt><dd><dl><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>vfs.file_operation</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>virtual file system reads (cumulative), tallying</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>virtual file system reads (non-cumulative), tallying</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>W</h3><dl><dt>while loops</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>whole device number (usage as a command-line argument)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>wildcards in events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>writes/reads to a file, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd></dl></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="appe-Publican-Revision_History.html"><strong>Prev</strong>Appendix A. Revision History</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li></ul></body></html>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Index</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="appe-Publican-Revision_History.html" title="Appendix A. Revision History" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="appe-Publican-Revision_History.html"><strong>Prev</strong></a></li><li class="next"></li></ul><div class="index" id="id515552"><div class="titlepage"><div><div><h2 class="title">Index</h2></div></div></div><div class="index"><div class="indexdiv"><h3>Symbols</h3><dl><dt>$count</dt><dd><dl><dt>sample usage</dt><dd><dl><dt>local variables, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd></dl></dd><dt>$return</dt><dd><dl><dt>sample usage</dt><dd><dl><dt>local variables, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd><dt>@avg (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@count (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@max (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@min (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>@sum (integer extractor)</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>A</h3><dl><dt>adding values to statistical aggregates</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>advantages of cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>aggregate element not found</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>aggregates (statistical)</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>aggregation overflow</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>algebraic formulas using arrays</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>architecture notation, determining, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>architecture of SystemTap, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>array locals not supported</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>array operations</dt><dd><dl><dt>assigning associated values, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associative arrays, <a class="indexterm" href="arrayoperators.html">Array Operations in SystemTap</a></dt><dt>clearing arrays/array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd><dt>computing for statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>conditional statements, using arrays in, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>deleting arrays and array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>incrementing associated values, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd><dt>multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>processing multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dd><dl><dt>cumulative virtual file system reads, tallying, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>iterations, processing elements in an array as, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>limiting the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>ordering the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>reading values from arrays, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>computing for timestamp deltas, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dd><dl><dt>(see also associative arrays)</dt></dl></dd><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associating timestamps to process names</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>associated values</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>associating timestamps to process names</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>associative arrays</dt><dd><dl><dt>introduction, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dd><dl><dt>associated values, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>example, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>index expression, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>key pairs, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>syntax, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt><dt>unique keys, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>asynchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>B</h3><dl><dt>begin</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>building instrumentation modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>building kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></div><div class="indexdiv"><h3>C</h3><dl><dt>call graph tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>capabilities of SystemTap</dt><dd><dl><dt>Introduction, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt></dl></dd><dt>changes to file attributes, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>command-line arguments</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt></dl></dd></dl></dd><dt>compiling instrumentation/kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>components</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>computing for timestamp deltas</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>conditional operators</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>CONFIG_HZ, computing for, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>contended user-space locks (futex contentions), identifying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>copy fault</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>count operator</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>counting function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>CPU ticks</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>cpu()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>cross-compiling, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>cross-instrumentation</dt><dd><dl><dt>advantages of, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>building kernel modules from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>configuration</dt><dd><dl><dt>host system and target system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>generating instrumentation from SystemTap scripts, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>host system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>instrumentation module, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>target kernel, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>target system, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>ctime()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>ctime(), example of usage</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>cumulative I/O, tracking</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>cumulative virtual file system reads, tallying</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>D</h3><dl><dt>delete operator</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>determining architecture notation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>determining the kernel version, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>determining time spent in kernel and user space</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>device I/O, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>device number of a file (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>disk I/O traffic, summarizing</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>division by 0</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>documentation goals</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>E</h3><dl><dt>embedded code in unprivileged script</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>empty unique keys</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>end</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>errors</dt><dd><dl><dt>parse/semantics error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd><dt>runtime errors/warnings, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>event types</dt><dd><dl><dt>Understanding How SystemTap Works, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt></dl></dd><dt>Events</dt><dd><dl><dt>asynchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>begin, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>end, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>examples of synchronous and asynchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>introduction, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>kernel.function("function"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>kernel.trace("tracepoint"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>module("module"), <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>synchronous events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>syscall.system_call, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>timer events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>user-space, <a class="indexterm" href="userspace-probing.html#uevents">User-Space Events</a></dt><dt>vfs.file_operation, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>wildcards, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>events and handlers, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>events wildcards, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>example</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>example of multiple command-line arguments</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>examples of synchronous and asynchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt><dd><dl><dt>call graph tracing, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>CPU ticks, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>ctime(), example of usage, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>determining time spent in kernel and user space, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>futex (lock) contentions, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>futex system call, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>identifying contended user-space locks (i.e. futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>if/else conditionals, alternative syntax, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt><dt>inode number, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring changes to file attributes, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt><dt>monitoring device I/O, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>monitoring I/O block time, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt><dt>monitoring I/O time, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>monitoring incoming TCP connections, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt><dt>monitoring polling applications, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt><dt>monitoring reads and writes to a file, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring system calls, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>monitoring system calls (volume per process), <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt><dt>monitoring TCP packets, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt><dt>multiple command-line arguments, example of, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>net/socket.c, tracing functions from, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>network profiling, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>stat -c, determining file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>stat -c, determining whole device number, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>summarizing disk I/O traffic, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>tallying function calls, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>thread_indent(), sample usage, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>timer.ms(), sample usage, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>timer.s(), sample usage, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>tracing functions called in network socket code, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>tracking cumulative I/O, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt><dt>trigger function, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>usrdev2kerndev(), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>whole device number (usage as a command-line argument), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>exceeded MAXACTION</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>exceeded MAXNESTING</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>exit()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>expected symbol/array index expression</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>extracting data collected by statistical aggregates</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>F</h3><dl><dt>fedoradebugurl.sh, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>feedback</dt><dd><dl><dt>contact information for this manual, <a class="indexterm" href="pr01s02.html">We Need Feedback!</a></dt></dl></dd><dt>file attributes, monitoring changes to</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>file device number (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>file reads/writes, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>flight recorder mode, <a class="indexterm" href="using-usage.html#flight-recorder">SystemTap Flight Recorder Mode</a></dt><dd><dl><dt>file mode, <a class="indexterm" href="using-usage.html#file-flight-recorder">File Flight Recorder</a></dt><dt>in-memory mode, <a class="indexterm" href="using-usage.html#memory-flight-recorder">In-memory Flight Recorder</a></dt></dl></dd><dt>for loops</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>format</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>format and syntax</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>format specifiers</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>format strings</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>function call (unresolved)</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>function calls (incoming/outgoing), tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>function calls, tallying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dd><dl><dt>cpu(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>ctime(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>gettimeofday_s(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>pp(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd><dt>target(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>thread_indent(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>tid(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>uid(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>functions (used in handlers)</dt><dd><dl><dt>exit(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>functions called in network socket code, tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>futex (lock) contentions</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>futex contention, definition</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>futex contentions, identifying</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>futex system call</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>G</h3><dl><dt>gettimeofday_s()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>global</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>goals, documentation</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt></dl></dd><dt>grammatical/typographical script error</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>guru mode</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>H</h3><dl><dt>handler functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>handlers</dt><dd><dl><dt>conditional statements, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dd><dl><dt>conditional operators, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>for loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>if/else, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>while loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd><dt>introduction, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dd><dl><dt>command-line arguments, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>global, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>syntax and format, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dt>variable notations, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>variables, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd><dt>target variables, <a class="indexterm" href="targetvariables.html">Target Variables</a></dt></dl></dd><dt>handlers and events, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>heaviest disk reads/writes, identifying</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>host system</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>host system and target system</dt><dd><dl><dt>cross-instrumentation</dt><dd><dl><dt>configuration, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>I</h3><dl><dt>I/O block time, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>I/O monitoring (by device)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>I/O time, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>I/O traffic, summarizing</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>identifier type mismatch</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>identifying contended user-space locks (i.e. futex contentions)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt></dl></dd><dt>identifying heaviest disk reads/writes</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>if/else</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>if/else conditionals, alternative syntax</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt></dl></dd><dt>if/else statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>incoming TCP connections, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>incoming/outgoing function calls, tracing</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>index expression</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>initial testing, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>inode number</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>Installation</dt><dd><dl><dt>fedoradebugurl.sh, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>initial testing, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>kernel information packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel version, determining the, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>required packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>Setup and Installation, <a class="indexterm" href="using-systemtap.html#using-setup">Installation and Setup</a></dt><dt>systemtap package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>systemtap-runtime package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt></dl></dd><dt>instrumentation module</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>instrumentation modules from SystemTap scripts, building, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>integer extractors</dt><dd><dl><dt>computing for statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd></dl></dd><dt>Introduction</dt><dd><dl><dt>capabilities of SystemTap, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt><dt>documentation goals, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt><dt>goals, documentation, <a class="indexterm" href="introduction.html#goals">Documentation Goals</a></dt><dt>limitations of SystemTap, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt><dt>performance monitoring, <a class="indexterm" href="introduction.html">Introduction</a></dt></dl></dd><dt>invalid division</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>invalid values to variables/arrays</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>iterations, processing elements in an array as</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>K</h3><dl><dt>kernel and user space, determining time spent in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>kernel information packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel modules from SystemTap scripts, building, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>kernel version, determining the, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>kernel.function("function")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>kernel.trace("tracepoint")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>key pairs</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>L</h3><dl><dt>libdwfl failure</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>limitations of SystemTap</dt><dd><dl><dt>Introduction, <a class="indexterm" href="intro-systemtap-vs-others.html">SystemTap Capabilities</a></dt></dl></dd><dt>limiting the output of foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>local variables</dt><dd><dl><dt>name, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>sample usage</dt><dd><dl><dt>$count, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>$return, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>M</h3><dl><dt>MAXACTION exceeded</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>MAXNESTING exceeded</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>membership (in array), testing for</dt><dd><dl><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>module("module")</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>monitoring changes to file attributes</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt></dl></dd><dt>monitoring cumulative I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>monitoring device I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>monitoring I/O block time</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>monitoring I/O time</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>monitoring incoming TCP connections</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>monitoring polling applications</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt></dl></dd><dt>monitoring reads and writes to a file</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>monitoring system calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>monitoring system calls (volume per process)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt></dl></dd><dt>monitoring TCP packets</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt></dl></dd><dt>multiple array operations within the same probe</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd><dt>multiple command-line arguments, example of</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>N</h3><dl><dt>name</dt><dd><dl><dt>local variables, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>net/socket.c, tracing functions from</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>network profiling</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd><dt>network socket code, tracing functions called in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>network traffic, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd><dt>no match for probe point</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>non-global arrays</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>number of errors: N, skipped probes: M</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>O</h3><dl><dt>operations</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>associating timestamps to process names, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>associative arrays, <a class="indexterm" href="arrayoperators.html">Array Operations in SystemTap</a></dt><dt>clearing arrays/array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dd><dl><dt>delete operator, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>multiple array operations within the same probe, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>virtual file system reads (non-cumulative), tallying, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd><dt>computing for statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dd><dl><dt>@avg (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@count (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@max (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@min (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>@sum (integer extractor), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>adding values to statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>count (operator), <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt><dt>extracting data collected by statistical aggregates, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>conditional statements, using arrays in, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt><dd><dl><dt>testing for array membership, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd><dt>deleting arrays and array elements, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt><dt>incrementing associated values, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt><dd><dl><dt>tallying virtual file system reads (VFS reads), <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd><dt>multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>processing multiple elements in an array, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dd><dl><dt>cumulative virtual file system reads, tallying, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>iterations, processing elements in an array as, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>limiting the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>ordering the output of foreach, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>reading values from arrays, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>computing for timestamp deltas, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>options, stap</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>ordering the output of foreach</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>overflow of aggregation</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>P</h3><dl><dt>packages required to run SystemTap, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>performance monitoring</dt><dd><dl><dt>Introduction, <a class="indexterm" href="introduction.html">Introduction</a></dt></dl></dd><dt>pointer dereference fault</dt><dd><dl><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>polling applications, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt></dl></dd><dt>pp()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>printf()</dt><dd><dl><dt>format specifiers, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>format strings, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>syntax and format, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>printing I/O activity (cumulative)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>printing I/O block time (periodically)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt></dl></dd><dt>probe mismatch</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>probe point (no match for)</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>probes</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt><dt>cumulative virtual file system reads, tallying</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>limiting the output of foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd><dt>ordering the output of foreach</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>profiling the network</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>R</h3><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dd><dl><dt>empty unique keys, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt><dt>using arrays in simple computations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd><dt>computing for timestamp deltas</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>reads/writes to a file, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>required packages, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>RPMs required to run SystemTap, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>running scripts from standard input, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>running SystemTap scripts</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>runtime errors/warnings</dt><dd><dl><dt>understainding SystemTap errors, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>S</h3><dl><dt>script examples</dt><dd><dl><dt>call graph tracing, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>CPU ticks, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>ctime(), example of usage, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>determining time spent in kernel and user space, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt><dt>file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>futex (lock) contentions, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>futex system call, <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>identifying contended user-space locks (i.e. futex contentions), <a class="indexterm" href="futexcontentionsect.html">Identifying Contended User-Space Locks</a></dt><dt>if/else conditionals, alternative syntax, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a></dt><dt>inode number, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring changes to file attributes, <a class="indexterm" href="inodewatch2sect.html">Monitoring Changes to File Attributes</a></dt><dt>monitoring device I/O, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>monitoring I/O block time, <a class="indexterm" href="ioblktimesect.html">Periodically Print I/O Block Time</a></dt><dt>monitoring I/O time, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>monitoring incoming TCP connections, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt><dt>monitoring polling applications, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a></dt><dt>monitoring reads and writes to a file, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>monitoring system calls, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>monitoring system calls (volume per process), <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt><dt>monitoring TCP packets, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt><dt>multiple command-line arguments, example of, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>net/socket.c, tracing functions from, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>network profiling, <a class="indexterm" href="useful-systemtap-scripts.html#nettopsect">Network Profiling</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>stat -c, determining file device number (integer format), <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt><dt>stat -c, determining whole device number, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>summarizing disk I/O traffic, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt><dt>tallying function calls, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>thread_indent(), sample usage, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>timer.ms(), sample usage, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt><dt>timer.s(), sample usage, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt><dt>tracing functions called in network socket code, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt><dt>tracking cumulative I/O, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt><dt>trigger function, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt><dt>usrdev2kerndev(), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt><dt>whole device number (usage as a command-line argument), <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dd><dl><dt>components, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>events and handlers, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>format and syntax, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>functions, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>probes, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>statement blocks, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>sessions, SystemTap, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>Setup and Installation, <a class="indexterm" href="using-systemtap.html#using-setup">Installation and Setup</a></dt><dt>Stack backtrace</dt><dd><dl><dt>user-space, <a class="indexterm" href="ustack.html">User-Space Stack Backtraces</a></dt></dl></dd><dt>standard input, running scripts from</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stap</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stap options, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapdev</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>staprun</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stapusr</dt><dd><dl><dt>Usage, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>stat -c, determining file device number (integer format)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd><dt>stat -c, determining whole device number</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>statement blocks</dt><dd><dl><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>statistical aggregates</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-aggregates.html">Computing for Statistical Aggregates</a></dt></dl></dd><dt>summarizing disk I/O traffic</dt><dd><dl><dt>script examples, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a></dt></dl></dd><dt>synchronous events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>syntax</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>syntax and format</dt><dd><dl><dt>printf(), <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt></dl></dd><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd></dl></dd><dt>syscall.system_call</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>system calls volume (per process), monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="syscallsbyprocpidsect.html">Tracking System Call Volume Per Process</a></dt></dl></dd><dt>system calls, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>SystemTap architecture, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>SystemTap handlers</dt><dd><dl><dt>SystemTap handler constructs, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt><dd><dl><dt>syntax and format, <a class="indexterm" href="scriptconstructions.html">Basic SystemTap Handler Constructs</a></dt></dl></dd></dl></dd><dt>systemtap package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>SystemTap script functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>SystemTap scripts</dt><dd><dl><dt>introduction, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dd><dl><dt>components, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>events and handlers, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>format and syntax, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>functions, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>probes, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt><dt>statement blocks, <a class="indexterm" href="scripts.html">SystemTap Scripts</a></dt></dl></dd><dt>useful examples, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt></dl></dd><dt>SystemTap scripts, how to run, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>SystemTap sessions, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>SystemTap statements</dt><dd><dl><dt>conditional statements, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dd><dl><dt>conditional operators, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>for loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>if/else, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt><dt>while loops, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd><dt>SystemTap handler constructs</dt><dd><dl><dt>command-line arguments, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>global, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt><dt>variable notations, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt><dt>variables, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>systemtap-runtime package, <a class="indexterm" href="using-systemtap.html#installproper">Installing SystemTap</a></dt><dt>systemtap-testsuite package</dt><dd><dl><dt>sample scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>T</h3><dl><dt>tallying function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>tallying virtual file system reads (VFS reads)</dt><dd><dl><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>Tapsets</dt><dd><dl><dt>definition of, <a class="indexterm" href="understanding-tapsets.html">Tapsets</a></dt></dl></dd><dt>target kernel</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target system</dt><dd><dl><dt>cross-instrumentation, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target system and host system</dt><dd><dl><dt>configuration, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt></dl></dd><dt>target variables, <a class="indexterm" href="targetvariables.html">Target Variables</a></dt><dd><dl><dt>pretty printing, <a class="indexterm" href="targetvariables.html#targetprettyprinting">Pretty Printing Target Variables</a></dt><dt>typecasting, <a class="indexterm" href="typecasting.html">Typecasting</a></dt><dt>user-space, <a class="indexterm" href="utargetvariable.html">Accessing User-Space Target Variables</a></dt><dt>variable availability, <a class="indexterm" href="targetavailable.html">Checking Target Variable Availablility</a></dt></dl></dd><dt>target()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>target-symbol expression, unresolved</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>TCP connections (incoming), monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpconnectionssect">Monitoring Incoming TCP Connections</a></dt></dl></dd><dt>TCP packets, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#tcpdumplikesect">Monitoring TCP Packets</a></dt></dl></dd><dt>testing for array membership</dt><dd><dl><dt>conditional statements, using arrays in</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-conditionals.html">Using Arrays in Conditional Statements</a></dt></dl></dd></dl></dd><dt>testing, initial, <a class="indexterm" href="using-systemtap.html#testing">Initial Testing</a></dt><dt>thread_indent()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>thread_indent(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tid()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>time of I/O </dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt></dl></dd><dt>time spent in kernel/user space, determining</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>timer events</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>timer.ms(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="mainsect-profiling.html#countcallssect">Counting Function Calls Made</a></dt></dl></dd><dt>timer.s(), sample usage</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="timeoutssect.html">Monitoring Polling Applications</a>, <a class="indexterm" href="topsyssect.html">Tracking Most Frequently Used System Calls</a></dt></dl></dd><dt>timestamp deltas, computing for</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>timestamps, association thereof to process names</dt><dd><dl><dt>assigning associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd></dl></dd><dt>tracepoint, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a>, <a class="indexterm" href="useful-systemtap-scripts.html#dropwatchsect">Monitoring Network Packets Drops in Kernel</a></dt><dt>tracing call graph</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tracing functions called in network socket code</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html#sockettracesect">Tracing Functions Called in Network Socket Code</a></dt></dl></dd><dt>tracing incoming/outgoing function calls</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>tracking cumulative I/O</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd><dt>trigger function</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="paracallgraph.html">Call Graph Tracing</a></dt></dl></dd><dt>type mismatch for identifier</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>typographical script error</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>U</h3><dl><dt>uid()</dt><dd><dl><dt>functions, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt></dl></dd><dt>uname -m, <a class="indexterm" href="cross-compiling.html">Generating Instrumentation for Other Computers</a></dt><dt>uname -r, <a class="indexterm" href="using-systemtap.html#install-kinfo">Installing Required Kernel Information RPMs</a></dt><dt>understainding SystemTap errors</dt><dd><dl><dt>runtime errors/warnings, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dd><dl><dt>aggregate element not found, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>aggregation overflow, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>copy fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>division by 0, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXACTION exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>MAXNESTING exceeded, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>number of errors: N, skipped probes: M, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt><dt>pointer dereference fault, <a class="indexterm" href="runtimeerror.html">Run Time Errors and Warnings</a></dt></dl></dd></dl></dd><dt>Understanding How SystemTap Works, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dd><dl><dt>architecture, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt><dt>event types, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>events and handlers, <a class="indexterm" href="understanding-how-systemtap-works.html">Understanding How SystemTap Works</a></dt><dt>SystemTap sessions, <a class="indexterm" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Architecture</a></dt></dl></dd><dt>understanding SystemTap errors</dt><dd><dl><dt>parse/semantics error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dd><dl><dt>embedded code in unprivileged script, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>expected symbol/array index expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>grammatical/typographical script error, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>guru mode, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>invalid values to variables/arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>libdwfl failure, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>no match for probe point, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>non-global arrays, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>probe mismatch, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>type mismatch for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved function call, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved target-symbol expression, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>unresolved type for identifier, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt><dt>variable modified during 'foreach', <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unique keys</dt><dd><dl><dt>introduction</dt><dd><dl><dt>arrays, <a class="indexterm" href="associativearrays.html">Associative Arrays</a></dt></dl></dd></dl></dd><dt>unprivileged script, embedded code in</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved function call</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved target-symbol expression</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unresolved type for identifier</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>unsafe embedded code in unprivileged script</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>Usage</dt><dd><dl><dt>options, stap, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>running SystemTap scripts, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>standard input, running scripts from, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stap, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapdev, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>staprun, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt><dt>stapusr, <a class="indexterm" href="using-usage.html">Running SystemTap Scripts</a></dt></dl></dd><dt>useful examples of SystemTap scripts, <a class="indexterm" href="useful-systemtap-scripts.html">Useful SystemTap Scripts</a></dt><dt>user and kernel space, determining time spent in</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="threadtimessect.html">Determining Time Spent in Kernel and User Space</a></dt></dl></dd><dt>using arrays in simple computations</dt><dd><dl><dt>reading values from arrays</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-readvalues.html">Reading Values From Arrays</a></dt></dl></dd></dl></dd><dt>Using SystemTap, <a class="indexterm" href="using-systemtap.html">Using SystemTap</a></dt><dt>usrdev2kerndev()</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd></dl></div><div class="indexdiv"><h3>V</h3><dl><dt>values, assignment of</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayoperators.html#arrayops-assignvalue">Assigning an Associated Value</a></dt></dl></dd><dt>variable modified during 'foreach'</dt><dd><dl><dt>parse/semantics error</dt><dd><dl><dt>understanding SystemTap errors, <a class="indexterm" href="errors.html#parsetype">Parse and Semantic Errors</a></dt></dl></dd></dl></dd><dt>variable notations</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="commandlineargssect.html">Command-Line Arguments</a></dt></dl></dd></dl></dd><dt>variables</dt><dd><dl><dt>SystemTap handler constructs</dt><dd><dl><dt>handlers, <a class="indexterm" href="scriptconstructions.html#variablesconstructs">Variables</a></dt></dl></dd></dl></dd><dt>variables (local)</dt><dd><dl><dt>name, <a class="indexterm" href="systemtapscript-handler.html">Systemtap Handler/Body</a></dt><dt>sample usage</dt><dd><dl><dt>$count, <a class="indexterm" href="iotimesect.html">Tracking I/O Time For Each File Read or Write</a></dt><dt>$return, <a class="indexterm" href="mainsect-disk.html#disktop">Summarizing Disk Read/Write Traffic</a>, <a class="indexterm" href="traceiosect.html">Track Cumulative IO</a></dt></dl></dd></dl></dd><dt>VFS reads, tallying of</dt><dd><dl><dt>incrementing associated values</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-increment.html">Incrementing Associated Values</a></dt></dl></dd></dl></dd><dt>vfs.file_operation</dt><dd><dl><dt>Events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt></dl></dd><dt>virtual file system reads (cumulative), tallying</dt><dd><dl><dt>processing multiple elements in an array</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-foreach.html">Processing Multiple Elements in an Array</a></dt></dl></dd></dl></dd><dt>virtual file system reads (non-cumulative), tallying</dt><dd><dl><dt>clearing arrays/array elements</dt><dd><dl><dt>array operations, <a class="indexterm" href="arrayops-deleting.html">Clearing/Deleting Arrays and Array Elements</a></dt></dl></dd></dl></dd></dl></div><div class="indexdiv"><h3>W</h3><dl><dt>while loops</dt><dd><dl><dt>conditional statements</dt><dd><dl><dt>handlers, <a class="indexterm" href="handlerconditionalstatements.html">Conditional Statements</a></dt></dl></dd></dl></dd><dt>whole device number (usage as a command-line argument)</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="traceio2sect.html">I/O Monitoring (By Device)</a></dt></dl></dd><dt>wildcards in events, <a class="indexterm" href="scripts.html#systemtapscript-events">Event</a></dt><dt>writes/reads to a file, monitoring</dt><dd><dl><dt>examples of SystemTap scripts, <a class="indexterm" href="inodewatchsect.html">Monitoring Reads and Writes to a File</a></dt></dl></dd></dl></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="appe-Publican-Revision_History.html"><strong>Prev</strong>Appendix A. Revision History</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li></ul></body></html>
index ce20f1a5996d2588e044b31f99840d6fb50bc637..a243168d5b7123a94a63226f3e813e58acf78968 100644 (file)
@@ -1,13 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2. Disk</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts" /><link rel="prev" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts" /><link rel="next" href="iotimesect.html" title="4.2.2. Tracking I/O Time For Each File Read or Write" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="useful-systemtap-scripts.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="iotimesect.html"><strong>Next</strong></a></li></ul><div class="section" title="4.2. Disk"><div class="titlepage"><div><div><h2 class="title" id="mainsect-disk">4.2. Disk</h2></div></div></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2. Disk</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 5. Useful SystemTap Scripts" /><link rel="prev" href="useful-systemtap-scripts.html" title="Chapter 5. Useful SystemTap Scripts" /><link rel="next" href="iotimesect.html" title="5.2.2. Tracking I/O Time For Each File Read or Write" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="useful-systemtap-scripts.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="iotimesect.html"><strong>Next</strong></a></li></ul><div class="section" id="mainsect-disk"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="mainsect-disk">5.2. Disk</h2></div></div></div><div class="para">
                        The following sections showcase scripts that monitor disk and I/O activity.
-               </div><div xml:lang="en-US" class="section" title="4.2.1. Summarizing Disk Read/Write Traffic" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="disktop">4.2.1. Summarizing Disk Read/Write Traffic</h3></div></div></div><a id="id646551" class="indexterm"></a><a id="id657861" class="indexterm"></a><a id="id587977" class="indexterm"></a><a id="id538513" class="indexterm"></a><a id="id597722" class="indexterm"></a><a id="id645573" class="indexterm"></a><a id="id597862" class="indexterm"></a><a id="id499358" class="indexterm"></a><div class="para">
+               </div><div xml:lang="en-US" class="section" id="disktop" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="disktop">5.2.1. Summarizing Disk Read/Write Traffic</h3></div></div></div><a id="id1972611" class="indexterm"></a><a id="id440426" class="indexterm"></a><a id="id746816" class="indexterm"></a><a id="id602566" class="indexterm"></a><a id="id512779" class="indexterm"></a><a id="id651145" class="indexterm"></a><a id="id608396" class="indexterm"></a><a id="id529206" class="indexterm"></a><div class="para">
                This section describes how to identify which processes are performing the heaviest disk reads/writes to the system.
-       </div><div class="formalpara"><h5 class="formalpara" id="scriptdisktop">disktop.stp</h5>
+       </div><div class="formalpara" id="scriptdisktop"><h5 class="formalpara">disktop.stp</h5>
                        
-<pre class="programlisting">
-#!/usr/bin/env stap 
+<pre class="programlisting">#!/usr/bin/env stap 
 #
 # Copyright (C) 2007 Oracle Corp.
 #
@@ -78,10 +77,9 @@ probe end{
   delete read_bytes
   delete write_bytes
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> outputs the top ten processes responsible for the heaviest reads/writes to disk. <a class="xref" href="mainsect-disk.html#disktopoutput" title="Example 4.6. disktop.stp Sample Output">Example 4.6, “disktop.stp Sample Output”</a> displays a sample output for this script, and includes the following data per listed process:
+               <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> outputs the top ten processes responsible for the heaviest reads/writes to disk. <a class="xref" href="mainsect-disk.html#disktopoutput">Example 5.6, “disktop.stp Sample Output”</a> displays a sample output for this script, and includes the following data per listed process:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                <code class="computeroutput">UID</code> — user ID. A user ID of <code class="computeroutput">0</code> refers to the root user.
                        </div></li><li class="listitem"><div class="para">
@@ -96,12 +94,11 @@ probe end{
                                <code class="computeroutput">T</code> — the type of action performed by the listed process; <code class="computeroutput">W</code> refers to write, while <code class="computeroutput">R</code> refers to read.
                        </div></li><li class="listitem"><div class="para">
                                <code class="computeroutput">BYTES</code> — the amount of data read to or written from disk.
-                       </div></li></ul></div><a id="id596357" class="indexterm"></a><a id="id637322" class="indexterm"></a><a id="id510790" class="indexterm"></a><div class="para">
-               The time and date in the output of <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> is returned by the functions <code class="command">ctime()</code> and <code class="command">gettimeofday_s()</code>. <code class="command">ctime()</code> derives calendar time in terms of seconds passed since the Unix epoch (January 1, 1970). <code class="command">gettimeofday_s()</code> counts the <span class="emphasis"><em>actual</em></span> number of seconds since Unix epoch, which gives a fairly accurate human-readable timestamp for the output.
-       </div><a id="id615916" class="indexterm"></a><a id="id601744" class="indexterm"></a><a id="id645655" class="indexterm"></a><div class="para">
+                       </div></li></ul></div><a id="id517010" class="indexterm"></a><a id="id560437" class="indexterm"></a><a id="id495310" class="indexterm"></a><div class="para">
+               The time and date in the output of <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> is returned by the functions <code class="command">ctime()</code> and <code class="command">gettimeofday_s()</code>. <code class="command">ctime()</code> derives calendar time in terms of seconds passed since the Unix epoch (January 1, 1970). <code class="command">gettimeofday_s()</code> counts the <span class="emphasis"><em>actual</em></span> number of seconds since Unix epoch, which gives a fairly accurate human-readable timestamp for the output.
+       </div><a id="id532504" class="indexterm"></a><a id="id679665" class="indexterm"></a><a id="id713434" class="indexterm"></a><div class="para">
                In this script, the <code class="command">$return</code> is a local variable that stores the actual number of bytes each process reads or writes from the virtual file system. <code class="command">$return</code> can only be used in return probes (e.g. <code class="command">vfs.read.return</code> and <code class="command">vfs.read.return</code>).
-       </div><div class="example" id="disktopoutput"><div class="example-contents"><pre class="screen">
-[...]
+       </div><div class="example" id="disktopoutput"><h6>Example 5.6. <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 Mon Sep 29 03:38:28 2008 , Average:  19Kb/sec, Read: 7Kb, Write: 89Kb
 
 UID      PID     PPID                       CMD   DEVICE    T    BYTES
@@ -113,5 +110,4 @@ Mon Sep 29 03:38:38 2008 , Average:   1Kb/sec, Read: 7Kb, Write: 1Kb
 
 UID      PID     PPID                       CMD   DEVICE    T    BYTES
 0     2758     2757           pam_timestamp_c     sda5    R         8064
-0     2885        1                     cupsd     sda5    W         1678
-</pre></div><h6>Example 4.6. <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> Sample Output</h6></div><br class="example-break" /></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="useful-systemtap-scripts.html"><strong>Prev</strong>Chapter 4. Useful SystemTap Scripts</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="iotimesect.html"><strong>Next</strong>4.2.2. Tracking I/O Time For Each File Read or Wr...</a></li></ul></body></html>
+0     2885        1                     cupsd     sda5    W         1678</pre></div></div><br class="example-break" /></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="useful-systemtap-scripts.html"><strong>Prev</strong>Chapter 5. Useful SystemTap Scripts</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="iotimesect.html"><strong>Next</strong>5.2.2. Tracking I/O Time For Each File Read or Wr...</a></li></ul></body></html>
index b1dce9fb837794b3891cd3504a76e1a0242a0456..34017c68f55afd814b76f115a352245eb3d4444a 100644 (file)
@@ -1,13 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3. Profiling</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts" /><link rel="prev" href="ioblktimesect.html" title="4.2.7. Periodically Print I/O Block Time" /><link rel="next" href="paracallgraph.html" title="4.3.2. Call Graph Tracing" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="ioblktimesect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="paracallgraph.html"><strong>Next</strong></a></li></ul><div class="section" title="4.3. Profiling"><div class="titlepage"><div><div><h2 class="title" id="mainsect-profiling">4.3. Profiling</h2></div></div></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3. Profiling</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="useful-systemtap-scripts.html" title="Chapter 5. Useful SystemTap Scripts" /><link rel="prev" href="ioblktimesect.html" title="5.2.7. Periodically Print I/O Block Time" /><link rel="next" href="paracallgraph.html" title="5.3.2. Call Graph Tracing" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="ioblktimesect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="paracallgraph.html"><strong>Next</strong></a></li></ul><div class="section" id="mainsect-profiling"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="mainsect-profiling">5.3. Profiling</h2></div></div></div><div class="para">
                        The following sections showcase scripts that profile kernel activity by monitoring function calls.
-               </div><div xml:lang="en-US" class="section" title="4.3.1. Counting Function Calls Made" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="countcallssect">4.3.1. Counting Function Calls Made</h3></div></div></div><a id="id499160" class="indexterm"></a><a id="id641696" class="indexterm"></a><a id="id648027" class="indexterm"></a><a id="id491552" class="indexterm"></a><a id="id498562" class="indexterm"></a><div class="para">
+               </div><div xml:lang="en-US" class="section" id="countcallssect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="countcallssect">5.3.1. Counting Function Calls Made</h3></div></div></div><a id="id685366" class="indexterm"></a><a id="id407636" class="indexterm"></a><a id="id457502" class="indexterm"></a><a id="id1923226" class="indexterm"></a><a id="id713884" class="indexterm"></a><div class="para">
                This section describes how to identify how many times the system called a specific kernel function in a 30-second sample. Depending on your use of wildcards, you can also use this script to target multiple kernel functions.
-       </div><div class="formalpara"><h5 class="formalpara" id="countcalls">functioncallcount.stp</h5>
+       </div><div class="formalpara" id="countcalls"><h5 class="formalpara">functioncallcount.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 # The following line command will probe all the functions
 # in kernel's memory management code:
 #
@@ -25,14 +24,12 @@ probe end {
     printf("%s %d\n", fn, @count(called[fn]))
   exit()
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="mainsect-profiling.html#countcalls" title="functioncallcount.stp">functioncallcount.stp</a> takes the targeted kernel function as an argument. The argument supports wildcards, which enables you to target multiple kernel functions up to a certain extent.
-       </div><a id="id588354" class="indexterm"></a><a id="id612011" class="indexterm"></a><a id="id497300" class="indexterm"></a><div class="para">
-               You can increase the sample time by editing the timer in the second probe (<code class="command">timer.ms()</code>). The output of <a class="xref" href="mainsect-profiling.html#countcalls" title="functioncallcount.stp">functioncallcount.stp</a> contains the name of the function called and how many times it was called during the sample time (in alphabetical order). <a class="xref" href="mainsect-profiling.html#countcallsoutput" title="Example 4.13. functioncallcount.stp Sample Output">Example 4.13, “functioncallcount.stp Sample Output”</a> contains an excerpt from the output of <code class="command">stap countcalls.stp "*@mm/*.c"</code>:
-       </div><div class="example" id="countcallsoutput"><div class="example-contents"><pre class="screen">
-[...]
+               <a class="xref" href="mainsect-profiling.html#countcalls">functioncallcount.stp</a> takes the targeted kernel function as an argument. The argument supports wildcards, which enables you to target multiple kernel functions up to a certain extent.
+       </div><a id="id554268" class="indexterm"></a><a id="id466540" class="indexterm"></a><a id="id721265" class="indexterm"></a><div class="para">
+               The output of <a class="xref" href="mainsect-profiling.html#countcalls">functioncallcount.stp</a> contains the name of the function called and how many times it was called during the sample time (in alphabetical order). <a class="xref" href="mainsect-profiling.html#countcallsoutput">Example 5.13, “functioncallcount.stp Sample Output”</a> contains an excerpt from the output of <code class="command">stap functioncallcount.stp "*@mm/*.c"</code>:
+       </div><div class="example" id="countcallsoutput"><h6>Example 5.13. <a class="xref" href="mainsect-profiling.html#countcalls">functioncallcount.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 __vma_link 97
 __vma_link_file 66
 __vma_link_list 97
@@ -59,5 +56,4 @@ atomic_add_negative 97
 atomic_dec_and_test 5153
 atomic_inc 470
 atomic_inc_and_test 1
-[...]
-</pre></div><h6>Example 4.13. <a class="xref" href="mainsect-profiling.html#countcalls" title="functioncallcount.stp">functioncallcount.stp</a> Sample Output</h6></div><br class="example-break" /></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="ioblktimesect.html"><strong>Prev</strong>4.2.7. Periodically Print I/O Block Time</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="paracallgraph.html"><strong>Next</strong>4.3.2. Call Graph Tracing</a></li></ul></body></html>
+[...]</pre></div></div><br class="example-break" /></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="ioblktimesect.html"><strong>Prev</strong>5.2.7. Periodically Print I/O Block Time</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="paracallgraph.html"><strong>Next</strong>5.3.2. Call Graph Tracing</a></li></ul></body></html>
index e61f734434896c41345ced23883e1c54ecee8fcf..2032d8327783fc538d0ee1807430397f0033df47 100644 (file)
@@ -1,89 +1,55 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3.2. Call Graph Tracing</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="prev" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="next" href="threadtimessect.html" title="4.3.3. Determining Time Spent in Kernel and User Space" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-profiling.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="threadtimessect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.3.2. Call Graph Tracing" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="paracallgraph">4.3.2. Call Graph Tracing</h3></div></div></div><a id="id503111" class="indexterm"></a><a id="id543285" class="indexterm"></a><a id="id543595" class="indexterm"></a><a id="id493108" class="indexterm"></a><a id="id496725" class="indexterm"></a><a id="id539672" class="indexterm"></a><a id="id610248" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3.2. Call Graph Tracing</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="prev" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="next" href="threadtimessect.html" title="5.3.3. Determining Time Spent in Kernel and User Space" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-profiling.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="threadtimessect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="paracallgraph" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="paracallgraph">5.3.2. Call Graph Tracing</h3></div></div></div><a id="id533399" class="indexterm"></a><a id="id620069" class="indexterm"></a><a id="id727480" class="indexterm"></a><a id="id1939180" class="indexterm"></a><a id="id599793" class="indexterm"></a><a id="id503114" class="indexterm"></a><a id="id424208" class="indexterm"></a><div class="para">
                This section describes how to trace incoming and outgoing function calls.
-       </div><div class="formalpara"><h5 class="formalpara" id="scriptcallgraph">para-callgraph-simple.stp</h5>
+       </div><div class="formalpara" id="scriptcallgraph"><h5 class="formalpara">para-callgraph.stp</h5>
                        
-<pre class="programlisting">
-function trace(entry_p) {&#13;
-  if(tid() in trace)&#13;
-    printf("%s%s%s\n",thread_indent(entry_p),&#13;
-           (entry_p&gt;0?"-&gt;":"&lt;-"),&#13;
-           probefunc())&#13;
-}&#13;
-&#13;
-global trace&#13;
-probe kernel.function(@1).call {&#13;
-  if (execname() == "stapio") next # skip our own helper process&#13;
-  trace[tid()] = 1&#13;
-  trace(1)&#13;
-}&#13;
-probe kernel.function(@1).return {&#13;
-  trace(-1)&#13;
-  delete trace[tid()]&#13;
-}&#13;
-&#13;
-probe kernel.function(@2).call { trace(1) }&#13;
-probe kernel.function(@2).return { trace(-1) }&#13;
-function trace(entry_p) {&#13;
-  if(tid() in trace)&#13;
-    printf("%s%s%s\n",thread_indent(entry_p),&#13;
-           (entry_p&gt;0?"-&gt;":"&lt;-"),&#13;
-           probefunc())&#13;
-}&#13;
-&#13;
-global trace&#13;
-probe kernel.function(@1).call {&#13;
-  if (execname() == "stapio") next # skip our own helper process&#13;
-  trace[tid()] = 1&#13;
-  trace(1)&#13;
-}&#13;
-probe kernel.function(@1).return {&#13;
-  trace(-1)&#13;
-  delete trace[tid()]&#13;
-}&#13;
-&#13;
-probe kernel.function(@2).call { trace(1) }&#13;
-probe kernel.function(@2).return { trace(-1) }&#13;
+<pre class="programlisting">#! /usr/bin/env stap
 
+function trace(entry_p, extra) {
+  %( $# &gt; 1 %? if (tid() in trace) %)
+  printf("%s%s%s %s\n",
+         thread_indent (entry_p),
+         (entry_p&gt;0?"-&gt;":"&lt;-"),
+         probefunc (),
+         extra)
+}
+
+
+%( $# &gt; 1 %?
+global trace
+probe $2.call {
+  trace[tid()] = 1
+}
+probe $2.return {
+  delete trace[tid()]
+}
+%)
+
+probe $1.call   { trace(1, $$parms) }
+probe $1.return { trace(-1, $$return) }
 </pre>
-               </div><a id="id500549" class="indexterm"></a><a id="id645313" class="indexterm"></a><a id="id642135" class="indexterm"></a><a id="id493075" class="indexterm"></a><div class="para">
-               <a class="xref" href="paracallgraph.html#scriptcallgraph" title="para-callgraph-simple.stp">para-callgraph-simple.stp</a> takes two command-line arguments:
-       </div><a id="id612142" class="indexterm"></a><a id="id587198" class="indexterm"></a><a id="id601101" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                               A <em class="firstterm">trigger function</em> (<code class="command">@1</code>), which enables or disables tracing on a per-thread basis. Tracing in each thread will continue as long as the trigger function has not exited yet.
+               </div><a id="id533391" class="indexterm"></a><a id="id436390" class="indexterm"></a><a id="id504648" class="indexterm"></a><a id="id1953783" class="indexterm"></a><div class="para">
+               <a class="xref" href="paracallgraph.html#scriptcallgraph">para-callgraph.stp</a> takes two command-line arguments:
+       </div><a id="id602598" class="indexterm"></a><a id="id538988" class="indexterm"></a><a id="id1946194" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
+                               The function/s whose entry/exit call you'd like to trace (<code class="command">$1</code>).
                        </div></li><li class="listitem"><div class="para">
-                               The kernel function/s whose entry/exit call you'd like to trace (<code class="command">@2</code>).
-                       </div></li></ul></div><a id="id609083" class="indexterm"></a><a id="id596004" class="indexterm"></a><a id="id502623" class="indexterm"></a><div class="para">
-               <a class="xref" href="paracallgraph.html#scriptcallgraph" title="para-callgraph-simple.stp">para-callgraph-simple.stp</a> uses <code class="command">thread_indent()</code>; as such, its output contains the timestamp, process name, and thread ID of <code class="command">@2</code> (i.e. the probe function you are tracing). For more information about <code class="command">thread_indent()</code>, refer to its entry in <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a>.
+                               A second optional <em class="firstterm">trigger function</em> (<code class="command">$2</code>), which enables or disables tracing on a per-thread basis. Tracing in each thread will continue as long as the trigger function has not exited yet.
+                       </div></li></ul></div><a id="id1031423" class="indexterm"></a><a id="id1030077" class="indexterm"></a><a id="id539000" class="indexterm"></a><div class="para">
+               <a class="xref" href="paracallgraph.html#scriptcallgraph">para-callgraph.stp</a> uses <code class="command">thread_indent()</code>; as such, its output contains the timestamp, process name, and thread ID of <code class="command">$1</code> (i.e. the probe function you are tracing). For more information about <code class="command">thread_indent()</code>, refer to its entry in <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a>.
        </div><div class="para">
-               The following example contains an excerpt from the output for <code class="command">stap para-callgraph.stp sys_read '*@fs/*.c'</code>:
-       </div><div class="example" id="paracallgraphoutput"><div class="example-contents"><pre class="screen">
-[...]
-     0 klogd(1391):-&gt;sys_read
-    14 klogd(1391): -&gt;fget_light
-    22 klogd(1391): &lt;-fget_light
-    27 klogd(1391): -&gt;vfs_read
-    35 klogd(1391):  -&gt;rw_verify_area
-    43 klogd(1391):  &lt;-rw_verify_area
-    49 klogd(1391):  -&gt;kmsg_read
-     0 sendmail(1696):-&gt;sys_read
-    17 sendmail(1696): -&gt;fget_light
-    26 sendmail(1696): &lt;-fget_light
-    34 sendmail(1696): -&gt;vfs_read
-    44 sendmail(1696):  -&gt;rw_verify_area
-    52 sendmail(1696):  &lt;-rw_verify_area
-    58 sendmail(1696):  -&gt;proc_file_read
-    70 sendmail(1696):   -&gt;loadavg_read_proc
-    84 sendmail(1696):    -&gt;proc_calc_metrics
-    92 sendmail(1696):    &lt;-proc_calc_metrics
-    95 sendmail(1696):   &lt;-loadavg_read_proc
-   101 sendmail(1696):  &lt;-proc_file_read
-   106 sendmail(1696):  -&gt;dnotify_parent
-   115 sendmail(1696):  &lt;-dnotify_parent
-   119 sendmail(1696):  -&gt;inotify_dentry_parent_queue_event
-   127 sendmail(1696):  &lt;-inotify_dentry_parent_queue_event
-   133 sendmail(1696):  -&gt;inotify_inode_queue_event
-   141 sendmail(1696):  &lt;-inotify_inode_queue_event
-   146 sendmail(1696): &lt;-vfs_read
-   151 sendmail(1696):&lt;-sys_read
-</pre></div><h6>Example 4.14. <a class="xref" href="paracallgraph.html#scriptcallgraph" title="para-callgraph-simple.stp">para-callgraph-simple.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-profiling.html"><strong>Prev</strong>4.3. Profiling</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="threadtimessect.html"><strong>Next</strong>4.3.3. Determining Time Spent in Kernel and User ...</a></li></ul></body></html>
+               The following example contains an excerpt from the output for <code class="command">stap para-callgraph.stp 'kernel.function("*@fs/*.c")' 'kernel.function("sys_read")'</code>:
+       </div><div class="example" id="paracallgraphoutput"><h6>Example 5.14. <a class="xref" href="paracallgraph.html#scriptcallgraph">para-callgraph.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
+   267 gnome-terminal(2921): &lt;-do_sync_read return=0xfffffffffffffff5
+   269 gnome-terminal(2921):&lt;-vfs_read return=0xfffffffffffffff5
+     0 gnome-terminal(2921):-&gt;fput file=0xffff880111eebbc0
+     2 gnome-terminal(2921):&lt;-fput
+     0 gnome-terminal(2921):-&gt;fget_light fd=0x3 fput_needed=0xffff88010544df54
+     3 gnome-terminal(2921):&lt;-fget_light return=0xffff8801116ce980
+     0 gnome-terminal(2921):-&gt;vfs_read file=0xffff8801116ce980 buf=0xc86504 count=0x1000 pos=0xffff88010544df48
+     4 gnome-terminal(2921): -&gt;rw_verify_area read_write=0x0 file=0xffff8801116ce980 ppos=0xffff88010544df48 count=0x1000
+     7 gnome-terminal(2921): &lt;-rw_verify_area return=0x1000
+    12 gnome-terminal(2921): -&gt;do_sync_read filp=0xffff8801116ce980 buf=0xc86504 len=0x1000 ppos=0xffff88010544df48
+    15 gnome-terminal(2921): &lt;-do_sync_read return=0xfffffffffffffff5
+    18 gnome-terminal(2921):&lt;-vfs_read return=0xfffffffffffffff5
+     0 gnome-terminal(2921):-&gt;fput file=0xffff8801116ce980</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="mainsect-profiling.html"><strong>Prev</strong>5.3. Profiling</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="threadtimessect.html"><strong>Next</strong>5.3.3. Determining Time Spent in Kernel and User ...</a></li></ul></body></html>
index da92bb33835ed32e70a3972299c5d56056db0de2..a662c7a74f12f8210a01dc01fd30a8f2c13f94fa 100644 (file)
@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2. We Need Feedback!</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /><link rel="prev" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /><link rel="next" href="introduction.html" title="Chapter 1. Introduction" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="SystemTap_Beginners_Guide-Preface.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="introduction.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="2. We Need Feedback!" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="id489831">2. We Need Feedback!</h2></div></div></div><a id="id489843" class="indexterm"></a><div class="para">
-               If you find a typographical error in this manual, or if you have thought of a way to make this manual better, we would love to hear from you! Please submit a report in Bugzilla: <a href="http://bugzilla.redhat.com/bugzilla/">http://bugzilla.redhat.com/bugzilla/</a> against the product <span class="application"><strong>Red_Hat_Enterprise_Linux 5.</strong></span>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2. We Need Feedback!</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /><link rel="prev" href="SystemTap_Beginners_Guide-Preface.html" title="Preface" /><link rel="next" href="introduction.html" title="Chapter 1. Introduction" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="SystemTap_Beginners_Guide-Preface.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="introduction.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="id642169">2. We Need Feedback!</h2></div></div></div><a id="id642178" class="indexterm"></a><div class="para">
+               If you find a typographical error in this manual, or if you have thought of a way to make this manual better, we would love to hear from you! Please submit a report in Bugzilla: <a href="http://bugzilla.redhat.com/bugzilla/">http://bugzilla.redhat.com/bugzilla/</a> against the product <span class="application"><strong>systemtap</strong></span>.
        </div><div class="para">
-               When submitting a bug report, be sure to mention the manual's identifier: <em class="citetitle">SystemTap_Beginners_Guide</em>
+               When submitting a report, be sure to include the specific file or URL the report refers to and the manual's identifier: <em class="citetitle">SystemTap_Beginners_Guide</em>
        </div><div class="para">
                If you have a suggestion for improving the documentation, try to be as specific as possible when describing it. If you have found an error, please include the section number and some of the surrounding text so we can find it easily.
        </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="SystemTap_Beginners_Guide-Preface.html"><strong>Prev</strong>Preface</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="introduction.html"><strong>Next</strong>Chapter 1. Introduction</a></li></ul></body></html>
index da962fde8aa80e27145c0d5b6b1fcccdada40b86..9499b84e5d13f898f648a779292bd81068ce9043 100644 (file)
@@ -1,21 +1,23 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 6. References</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="runtimeerror.html" title="5.2. Run Time Errors and Warnings" /><link rel="next" href="appe-Publican-Revision_History.html" title="Appendix A. Revision History" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="runtimeerror.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="appe-Publican-Revision_History.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 6. References" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="references">Chapter 6. References</h2></div></div></div><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 7. References</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="runtimeerror.html" title="6.2. Run Time Errors and Warnings" /><link rel="next" href="appe-Publican-Revision_History.html" title="Appendix A. Revision History" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="runtimeerror.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="appe-Publican-Revision_History.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="references" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 7. References</h2></div></div></div><div class="para">
                This chapter enumerates other references for more information about SystemTap. It is advisable that you refer to these sources in the course of writing advanced probes and tapsets.
-       </div><div class="variablelist"><dl><dt><span class="term">SystemTap Wiki</span></dt><dd><div class="para">
-                                       The <em class="citetitle">SystemTap Wiki</em> is a collection of links and articles related to the deployment, usage, and development of SystemTap. You can find it in <a href=" http://sourceware.org/systemtap/wiki/HomePage"> http://sourceware.org/systemtap/wiki/HomePage</a>.
-                               </div></dd><dt><span class="term">SystemTap Tutorial</span></dt><dd><div class="para">
+       </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">SystemTap Wiki</span></dt><dd><div class="para">
+                                       The <em class="citetitle">SystemTap Wiki</em> is a collection of links and articles related to the deployment, usage, and development of SystemTap. You can find it at <a href=" http://sourceware.org/systemtap/wiki/HomePage"> http://sourceware.org/systemtap/wiki/HomePage</a>.
+                               </div></dd><dt class="varlistentry"><span class="term">SystemTap Tutorial</span></dt><dd><div class="para">
                                        Much of the content in this book comes from the <em class="citetitle">SystemTap Tutorial</em>. The <em class="citetitle">SystemTap Tutorial</em> is a more appropriate reference for users with intermediate to advanced knowledge of C++ and kernel development, and can be found at <a href="http://sourceware.org/systemtap/tutorial/">http://sourceware.org/systemtap/tutorial/</a>.
-                               </div></dd><dt><span class="term">man stapprobes</span></dt><dd><div class="para">
-                                       The <code class="filename">stapprobes</code> man page enumerates a variety of probe points supported by SystemTap, along with additional aliases defined by the SystemTap tapset library. The bottom of the man page includes a list of other man pages enumerating similar probe points for specific system components, such as <code class="filename">stapprobes.scsi</code>, <code class="filename">stapprobes.kprocess</code>, <code class="filename">stapprobes.signal</code>, etc.
-                               </div></dd><dt><span class="term">man stapfuncs</span></dt><dd><div class="para">
+                               </div></dd><dt class="varlistentry"><span class="term">man stapprobes</span></dt><dd><div class="para">
+                                       The <code class="filename">stapprobes</code> man page enumerates a variety of probe points supported by SystemTap, along with additional aliases defined by the SystemTap tapset library. The bottom of the man page includes a list of other man pages enumerating similar probe points for specific system components, such as <code class="filename">tapset::scsi</code>, <code class="filename">tapset::kprocess</code>, <code class="filename">tapset::signal</code>, etc.
+                               </div></dd><dt class="varlistentry"><span class="term">man stapfuncs</span></dt><dd><div class="para">
                                        The <code class="filename">stapfuncs</code> man page enumerates numerous functions supported by the SystemTap tapset library, along with the prescribed syntax for each one. Note, however, that this is not a complete list of <span class="emphasis"><em>all</em></span> supported functions; there are more undocumented functions available.
-                               </div></dd><dt><span class="term">SystemTap Language Reference</span></dt><dd><div class="para">
+                               </div></dd><dt class="varlistentry"><span class="term">SystemTap Tapset Reference Manual</span></dt><dd><div class="para">
+                                       The <em class="citetitle">SystemTap Tapset Reference Manual</em> at <a href="http://sourceware.org/systemtap/tapsets/">http://sourceware.org/systemtap/tapsets/</a> describes the individual predefined functions and probe points of the tapsets greater detail.
+                               </div></dd><dt class="varlistentry"><span class="term">SystemTap Language Reference</span></dt><dd><div class="para">
                                        This document is a comprehensive reference of SystemTap's language constructs and syntax. It is recommended for users with a rudimentary to intermediate knowledge of C++ and other similar programming languages. The <em class="citetitle">SystemTap Language Reference</em> is available to all users at <a href="http://sourceware.org/systemtap/langref/">http://sourceware.org/systemtap/langref/</a>
-                               </div></dd><dt><span class="term">Tapset Developers Guide</span></dt><dd><div class="para">
+                               </div></dd><dt class="varlistentry"><span class="term">Tapset Developers Guide</span></dt><dd><div class="para">
                                        Once you have sufficient proficiency in writing SystemTap scripts, you can then try your hand out on writing your own tapsets. The <em class="citetitle">Tapset Developers Guide</em> describes how to add functions to your tapset library.
-                               </div></dd><dt><span class="term">Test Suite</span></dt><dd><div class="para">
-                                       The <code class="filename">systemtap-testsuite</code> package allows you to test the entire SystemTap toolchain without having to build from source. In addition, it also contains numerous examples of SystemTap scripts you can study and test; some of these scripts are also documented in <a class="xref" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts">Chapter 4, <i>Useful SystemTap Scripts</i></a>.
+                               </div></dd><dt class="varlistentry"><span class="term">Test Suite</span></dt><dd><div class="para">
+                                       The <code class="filename">systemtap-testsuite</code> package allows you to test the entire SystemTap toolchain without having to build from source. In addition, it also contains numerous examples of SystemTap scripts you can study and test; some of these scripts are also documented in <a class="xref" href="useful-systemtap-scripts.html">Chapter 5, <i>Useful SystemTap Scripts</i></a>.
                                </div><div class="para">
                                        By default, the example scripts included in <code class="filename">systemtap-testsuite</code> are located in <code class="filename">/usr/share/systemtap/testsuite/systemtap.examples</code>.
-                               </div></dd></dl></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="runtimeerror.html"><strong>Prev</strong>5.2. Run Time Errors and Warnings</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="appe-Publican-Revision_History.html"><strong>Next</strong>Appendix A. Revision History</a></li></ul></body></html>
+                               </div></dd></dl></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="runtimeerror.html"><strong>Prev</strong>6.2. Run Time Errors and Warnings</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="appe-Publican-Revision_History.html"><strong>Next</strong>Appendix A. Revision History</a></li></ul></body></html>
index db97603c4209a52b66f8d86fc309a93c5793149c..c3071850cab5eec060936c1a135d290ddfc01a6b 100644 (file)
@@ -1,21 +1,21 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2. Run Time Errors and Warnings</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="errors.html" title="Chapter 5. Understanding SystemTap Errors" /><link rel="prev" href="errors.html" title="Chapter 5. Understanding SystemTap Errors" /><link rel="next" href="references.html" title="Chapter 6. References" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="errors.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="references.html"><strong>Next</strong></a></li></ul><div class="section" title="5.2. Run Time Errors and Warnings"><div class="titlepage"><div><div><h2 class="title" id="runtimeerror">5.2. Run Time Errors and Warnings</h2></div></div></div><a id="id508784" class="indexterm"></a><a id="id508796" class="indexterm"></a><a id="id508808" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>6.2. Run Time Errors and Warnings</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="errors.html" title="Chapter 6. Understanding SystemTap Errors" /><link rel="prev" href="errors.html" title="Chapter 6. Understanding SystemTap Errors" /><link rel="next" href="references.html" title="Chapter 7. References" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="errors.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="references.html"><strong>Next</strong></a></li></ul><div class="section" id="runtimeerror"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="runtimeerror">6.2. Run Time Errors and Warnings</h2></div></div></div><a id="id551670" class="indexterm"></a><a id="id551682" class="indexterm"></a><a id="id551694" class="indexterm"></a><div class="para">
                        Runtime errors and warnings occur when the SystemTap instrumentation has been installed and is collecting data on the system.
-               </div><div class="formalpara"><h5 class="formalpara" id="id508825">WARNING: Number of errors: <em class="replaceable"><code>N</code></em>, skipped probes: <em class="replaceable"><code>M</code></em></h5><a id="id615302" class="indexterm"></a><a id="id615318" class="indexterm"></a><a id="id615334" class="indexterm"></a><a id="id615351" class="indexterm"></a>
+               </div><div class="formalpara"><h5 class="formalpara" id="id596584">WARNING: Number of errors: <em class="replaceable"><code>N</code></em>, skipped probes: <em class="replaceable"><code>M</code></em></h5><a id="id596600" class="indexterm"></a><a id="id596615" class="indexterm"></a><a id="id540687" class="indexterm"></a><a id="id540702" class="indexterm"></a>
                                Errors and/or skipped probes occurred during this run. Both <em class="replaceable"><code>N</code></em> and <em class="replaceable"><code>M</code></em> are the counts of the number of probes that were not executed due to conditions such as too much time required to execute event handlers over an interval of time.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id536957">division by 0</h5><a id="id536966" class="indexterm"></a><a id="id536982" class="indexterm"></a><a id="id490895" class="indexterm"></a><a id="id490910" class="indexterm"></a><a id="id490927" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id540733">division by 0</h5><a id="id579608" class="indexterm"></a><a id="id579624" class="indexterm"></a><a id="id579640" class="indexterm"></a><a id="id592509" class="indexterm"></a><a id="id592525" class="indexterm"></a>
                                The script code performed an invalid division.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id492422">aggregate element not found</h5><a id="id492431" class="indexterm"></a><a id="id492447" class="indexterm"></a><a id="id492463" class="indexterm"></a><a id="id584384" class="indexterm"></a>
-                               An statistics extractor function other than <code class="command">@count</code> was invoked on an aggregate that has not had any values accumulated yet. This is similar to a division by zero.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id584410">aggregation overflow</h5><a id="id584419" class="indexterm"></a><a id="id542641" class="indexterm"></a><a id="id542657" class="indexterm"></a><a id="id542673" class="indexterm"></a><a id="id543617" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id592546">aggregate element not found</h5><a id="id1972103" class="indexterm"></a><a id="id1972119" class="indexterm"></a><a id="id1972134" class="indexterm"></a><a id="id538289" class="indexterm"></a>
+                               A statistics extractor function other than <code class="command">@count</code> was invoked on an aggregate that has not had any values accumulated yet. This is similar to a division by zero.
+                       </div><div class="formalpara"><h5 class="formalpara" id="id538314">aggregation overflow</h5><a id="id538323" class="indexterm"></a><a id="id555656" class="indexterm"></a><a id="id555672" class="indexterm"></a><a id="id555688" class="indexterm"></a><a id="id448895" class="indexterm"></a>
                                An array containing aggregate values contains too many distinct key pairs at this time.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id543642">MAXNESTING exceeded</h5><a id="id543648" class="indexterm"></a><a id="id543665" class="indexterm"></a><a id="id590888" class="indexterm"></a><a id="id590905" class="indexterm"></a><a id="id590921" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id448919">MAXNESTING exceeded</h5><a id="id448926" class="indexterm"></a><a id="id609014" class="indexterm"></a><a id="id609030" class="indexterm"></a><a id="id609046" class="indexterm"></a><a id="id546393" class="indexterm"></a>
                                Too many levels of function call nesting were attempted. The default nesting of function calls allowed is 10.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id589600">MAXACTION exceeded</h5><a id="id589610" class="indexterm"></a><a id="id589626" class="indexterm"></a><a id="id589642" class="indexterm"></a><a id="id535933" class="indexterm"></a><a id="id535949" class="indexterm"></a>
-                               The probe handler attempted to execute too many statements in the probe handler. The default number of actions allow in a probe handler is 1000.
-                       </div><div class="formalpara"><h5 class="formalpara" id="id535971">kernel/user string copy fault at <em class="replaceable"><code>ADDR</code></em></h5><a id="id490395" class="indexterm"></a><a id="id490411" class="indexterm"></a><a id="id490427" class="indexterm"></a><a id="id490443" class="indexterm"></a>
-                               The probe handler attempted to copy a string from kernel or user space at an invalid address (<em class="replaceable"><code>ADDR</code></em>).
-                       </div><div class="formalpara"><h5 class="formalpara" id="id648711">pointer dereference fault</h5><a id="id648720" class="indexterm"></a><a id="id648736" class="indexterm"></a><a id="id597875" class="indexterm"></a><a id="id597891" class="indexterm"></a>
+                       </div><div class="formalpara"><h5 class="formalpara" id="id546415">MAXACTION exceeded</h5><a id="id546424" class="indexterm"></a><a id="id517029" class="indexterm"></a><a id="id517045" class="indexterm"></a><a id="id517060" class="indexterm"></a><a id="id535186" class="indexterm"></a>
+                               The probe handler attempted to execute too many statements in the probe handler. The default number of actions allowed in a probe handler is 1000.
+                       </div><div class="formalpara"><h5 class="formalpara" id="id535208">kernel/user string copy fault at <em class="replaceable"><code>ADDR</code></em></h5><a id="id535220" class="indexterm"></a><a id="id645591" class="indexterm"></a><a id="id645607" class="indexterm"></a><a id="id645623" class="indexterm"></a>
+                               The probe handler attempted to copy a string from kernel or user-space at an invalid address (<em class="replaceable"><code>ADDR</code></em>).
+                       </div><div class="formalpara"><h5 class="formalpara" id="id495149">pointer dereference fault</h5><a id="id495158" class="indexterm"></a><a id="id495174" class="indexterm"></a><a id="id1900381" class="indexterm"></a><a id="id1900397" class="indexterm"></a>
                                There was a fault encountered during a pointer dereference operation such as a target variable evaluation.
-                       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="errors.html"><strong>Prev</strong>Chapter 5. Understanding SystemTap Errors</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="references.html"><strong>Next</strong>Chapter 6. References</a></li></ul></body></html>
+                       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="errors.html"><strong>Prev</strong>Chapter 6. Understanding SystemTap Errors</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="references.html"><strong>Next</strong>Chapter 7. References</a></li></ul></body></html>
index 90376e2a5369a6791c911d573797d6946721b74d..5e7d2bddb71a194c687c3fc69d581f085d4ae9b0 100644 (file)
@@ -1,13 +1,12 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3. Basic SystemTap Handler Constructs</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="systemtapscript-handler.html" title="3.2.2. Systemtap Handler/Body" /><link rel="next" href="handlerconditionalstatements.html" title="3.3.2. Conditional Statements" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="systemtapscript-handler.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="handlerconditionalstatements.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="3.3. Basic SystemTap Handler Constructs" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="scriptconstructions">3.3. Basic SystemTap Handler Constructs</h2></div></div></div><a id="id631574" class="indexterm"></a><a id="id610416" class="indexterm"></a><a id="id584594" class="indexterm"></a><a id="id586224" class="indexterm"></a><a id="id631919" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3. Basic SystemTap Handler Constructs</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="systemtapscript-handler.html" title="3.2.2. Systemtap Handler/Body" /><link rel="next" href="targetvariables.html" title="3.3.2. Target Variables" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="systemtapscript-handler.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="targetvariables.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="scriptconstructions" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="scriptconstructions">3.3. Basic SystemTap Handler Constructs</h2></div></div></div><a id="id559644" class="indexterm"></a><a id="id559630" class="indexterm"></a><a id="id597246" class="indexterm"></a><a id="id597230" class="indexterm"></a><a id="id995477" class="indexterm"></a><div class="para">
                SystemTap supports the use of several basic constructs in handlers. The syntax for most of these handler constructs are mostly based on C and <code class="command">awk</code> syntax. This section describes several of the most useful SystemTap handler constructs, which should provide you with enough information to write simple yet useful SystemTap scripts.
-       </div><div class="section" title="3.3.1. Variables"><div class="titlepage"><div><div><h3 class="title" id="variablesconstructs">3.3.1. Variables</h3></div></div></div><a id="id598780" class="indexterm"></a><a id="id535044" class="indexterm"></a><a id="id602484" class="indexterm"></a><a id="id642614" class="indexterm"></a><div class="para">
-                       Variables can be used freely throughout a handler; simply choose a name, assign a value from a function or expression to it, and use it in an expression. SystemTap automatically identifies whether a variable should be typed as a string or integer, based on the type of the values assigned to it. For instance, if you use set the variable <code class="command">foo</code> to <code class="command">gettimeofday_s()</code> (as in <code class="command">foo = gettimeofday_s()</code>), then <code class="command">foo</code> is typed as an number and can be printed in a <code class="command">printf()</code> with the integer format specifier (<code class="command">%d</code>).
-               </div><a id="id637012" class="indexterm"></a><a id="id510008" class="indexterm"></a><a id="id511685" class="indexterm"></a><div class="para">
+       </div><div class="section" id="variablesconstructs"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="variablesconstructs">3.3.1. Variables</h3></div></div></div><a id="id605535" class="indexterm"></a><a id="id995336" class="indexterm"></a><a id="id597250" class="indexterm"></a><a id="id686127" class="indexterm"></a><div class="para">
+                       Variables can be used freely throughout a handler; simply choose a name, assign a value from a function or expression to it, and use it in an expression. SystemTap automatically identifies whether a variable should be typed as a string or integer, based on the type of the values assigned to it. For instance, if you use set the variable <code class="command">foo</code> to <code class="command">gettimeofday_s()</code> (as in <code class="command">foo = gettimeofday_s()</code>), then <code class="command">foo</code> is typed as a number and can be printed in a <code class="command">printf()</code> with the integer format specifier (<code class="command">%d</code>).
+               </div><a id="id406302" class="indexterm"></a><a id="id559626" class="indexterm"></a><a id="id559018" class="indexterm"></a><div class="para">
                        Note, however, that by default variables are only local to the probe they are used in. This means that variables are initialized, used and disposed at each probe handler invocation. To share a variable between probes, declare the variable name using <code class="command">global</code> outside of the probes. Consider the following example:
-               </div><div class="example" id="timerjiffies"><div class="example-contents"><pre class="programlisting">
-global count_jiffies, count_ms
+               </div><div class="example" id="timerjiffies"><h6>Example 3.8. timer-jiffies.stp</h6><div class="example-contents"><pre class="programlisting">global count_jiffies, count_ms
 probe timer.jiffies(100) { count_jiffies ++ }
 probe timer.ms(100) { count_ms ++ }
 probe timer.ms(12345)
@@ -16,13 +15,10 @@ probe timer.ms(12345)
   printf ("jiffies:ms ratio %d:%d =&gt; CONFIG_HZ=%d\n",
     count_jiffies, count_ms, hz)
   exit ()
-}
-</pre></div><h6>Example 3.8. timer-jiffies.stp</h6></div><br class="example-break" /><a id="id581955" class="indexterm"></a><div class="para">
-                       <a class="xref" href="scriptconstructions.html#timerjiffies" title="Example 3.8. timer-jiffies.stp">Example 3.8, “timer-jiffies.stp”</a> computes the <code class="command">CONFIG_HZ</code> setting of the kernel using timers that count jiffies and milliseconds, then computing accordingly. The <code class="command">global</code> statement allows the script to use the variables <code class="command">count_jiffies</code> and <code class="command">count_ms</code> (set in their own respective probes) to be shared with <code class="command">probe timer.ms(12345)</code>.
-               </div><div class="note"><h2>Note</h2><div class="para">
-                               The <code class="command">++</code> notation in <a class="xref" href="scriptconstructions.html#timerjiffies" title="Example 3.8. timer-jiffies.stp">Example 3.8, “timer-jiffies.stp”</a> (i.e. <code class="command">count_jiffies ++</code> and <code class="command">count_ms ++</code>) is used to increment the value of a variable by 1. In the following probe, <code class="command">count_jiffies</code> is incremented by 1 every 100 jiffies:
-                       </div><pre class="screen">
-probe timer.jiffies(100) { count_jiffies ++ }
-</pre><div class="para">
+}</pre></div></div><br class="example-break" /><a id="id486986" class="indexterm"></a><div class="para">
+                       <a class="xref" href="scriptconstructions.html#timerjiffies">Example 3.8, “timer-jiffies.stp”</a> computes the <code class="command">CONFIG_HZ</code> setting of the kernel using timers that count jiffies and milliseconds, then computing accordingly. The <code class="command">global</code> statement allows the script to use the variables <code class="command">count_jiffies</code> and <code class="command">count_ms</code> (set in their own respective probes) to be shared with <code class="command">probe timer.ms(12345)</code>.
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
+                               The <code class="command">++</code> notation in <a class="xref" href="scriptconstructions.html#timerjiffies">Example 3.8, “timer-jiffies.stp”</a> (i.e. <code class="command">count_jiffies ++</code> and <code class="command">count_ms ++</code>) is used to increment the value of a variable by 1. In the following probe, <code class="command">count_jiffies</code> is incremented by 1 every 100 jiffies:
+                       </div><pre class="screen">probe timer.jiffies(100) { count_jiffies ++ }</pre><div class="para">
                                In this instance, SystemTap understands that <code class="command">count_jiffies</code> is an integer. Because no initial value was assigned to <code class="command">count_jiffies</code>, its initial value is zero by default.
-                       </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="systemtapscript-handler.html"><strong>Prev</strong>3.2.2. Systemtap Handler/Body</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="handlerconditionalstatements.html"><strong>Next</strong>3.3.2. Conditional Statements</a></li></ul></body></html>
+                       </div></div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="systemtapscript-handler.html"><strong>Prev</strong>3.2.2. Systemtap Handler/Body</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="targetvariables.html"><strong>Next</strong>3.3.2. Target Variables</a></li></ul></body></html>
index 77839d1a786598aa54c312734644286786b3f78c..10070eb1863026879ac9129eb56368d34dff99e7 100644 (file)
@@ -1,83 +1,73 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.2. SystemTap Scripts</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="next" href="systemtapscript-handler.html" title="3.2.2. Systemtap Handler/Body" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-how-systemtap-works.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="systemtapscript-handler.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="3.2. SystemTap Scripts" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="scripts">3.2. SystemTap Scripts</h2></div></div></div><a id="id632652" class="indexterm"></a><a id="id632642" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.2. SystemTap Scripts</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="next" href="systemtapscript-handler.html" title="3.2.2. Systemtap Handler/Body" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-how-systemtap-works.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="systemtapscript-handler.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="scripts" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="scripts">3.2. SystemTap Scripts</h2></div></div></div><a id="id526500" class="indexterm"></a><a id="id526488" class="indexterm"></a><div class="para">
                For the most part, SystemTap scripts are the foundation of each SystemTap session. SystemTap scripts instruct SystemTap on what type of information to collect, and what to do once that information is collected.
-       </div><a id="id632627" class="indexterm"></a><a id="id632613" class="indexterm"></a><a id="id632598" class="indexterm"></a><a id="id632584" class="indexterm"></a><a id="id632570" class="indexterm"></a><a id="id632556" class="indexterm"></a><div class="para">
-               As stated in <a class="xref" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works">Chapter 3, <i>Understanding How SystemTap Works</i></a>, SystemTap scripts are made up of two components: <span class="emphasis"><em>events</em></span> and <span class="emphasis"><em>handlers</em></span>. Once a SystemTap session is underway, SystemTap monitors the operating system for the specified events and executes the handlers as they occur.
-       </div><div class="note"><h2>Note</h2><a id="id632522" class="indexterm"></a><a id="id632508" class="indexterm"></a><a id="id632494" class="indexterm"></a><div class="para">
+       </div><a id="id526471" class="indexterm"></a><a id="id464173" class="indexterm"></a><a id="id464153" class="indexterm"></a><a id="id464137" class="indexterm"></a><a id="id464120" class="indexterm"></a><a id="id464104" class="indexterm"></a><div class="para">
+               As stated in <a class="xref" href="understanding-how-systemtap-works.html">Chapter 3, <i>Understanding How SystemTap Works</i></a>, SystemTap scripts are made up of two components: <span class="emphasis"><em>events</em></span> and <span class="emphasis"><em>handlers</em></span>. Once a SystemTap session is underway, SystemTap monitors the operating system for the specified events and executes the handlers as they occur.
+       </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><a id="id464065" class="indexterm"></a><a id="id464049" class="indexterm"></a><a id="id464032" class="indexterm"></a><div class="para">
                        An event and its corresponding handler is collectively called a <span class="emphasis"><em>probe</em></span>. A SystemTap script can have multiple probes.
                </div><div class="para">
                        A probe's handler is commonly referred to as a <span class="emphasis"><em>probe body</em></span>.
-               </div></div><div class="para">
+               </div></div></div><div class="para">
                In terms of application development, using events and handlers is similar to instrumenting the code by inserting diagnostic print statements in a program's sequence of commands. These diagnostic print statements allow you to view a history of commands executed once the program is run.
        </div><div class="para">
                SystemTap scripts allow insertion of the instrumentation code without recompilation of the code and allows more flexibility with regard to handlers. Events serve as the triggers for handlers to run; handlers can be specified to record specified data and print it in a certain manner.
-       </div><div class="formalpara"><h5 class="formalpara" id="scriptformats">Format</h5><a id="id632427" class="indexterm"></a><a id="id632433" class="indexterm"></a><a id="id632416" class="indexterm"></a><a id="id632402" class="indexterm"></a>
+       </div><div class="formalpara" id="scriptformats"><h5 class="formalpara">Format</h5><a id="id732660" class="indexterm"></a><a id="id732645" class="indexterm"></a><a id="id732629" class="indexterm"></a><a id="id732613" class="indexterm"></a>
                        SystemTap scripts use the file extension <code class="filename">.stp</code>, and contains probes written in the following format:
-               </div><pre class="screen">
-probe  <em class="replaceable"><code>event</code></em> {<em class="replaceable"><code>statements</code></em>}
-</pre><div class="para">
+               </div><pre class="screen">probe <em class="replaceable"><code>event</code></em> {<em class="replaceable"><code>statements</code></em>}</pre><div class="para">
                SystemTap supports multiple events per probe; multiple events are delimited by a comma (<code class="command">,</code>). If multiple events are specified in a single probe, SystemTap will execute the handler when any of the specified events occur.
-       </div><a id="id632366" class="indexterm"></a><a id="id632350" class="indexterm"></a><a id="id632334" class="indexterm"></a><div class="para">
+       </div><a id="id732567" class="indexterm"></a><a id="id732552" class="indexterm"></a><a id="id542308" class="indexterm"></a><div class="para">
                Each probe has a corresponding <em class="firstterm">statement block</em>. This statement block is enclosed in braces (<code class="command">{ }</code>) and contains the statements to be executed per event. SystemTap executes these statements in sequence; special separators or terminators are generally not necessary between multiple statements.
-       </div><div class="note"><h2>Note</h2><div class="para">
+       </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
                        Statement blocks in SystemTap scripts follow the same syntax and semantics as the C programming language. A statement block can be nested within another statement block.
-               </div></div><a id="id632293" class="indexterm"></a><a id="id632280" class="indexterm"></a><a id="id632266" class="indexterm"></a><div class="para">
+               </div></div></div><a id="id542263" class="indexterm"></a><a id="id542247" class="indexterm"></a><a id="id542231" class="indexterm"></a><div class="para">
                Systemtap allows you to write functions to factor out code to be used by a number of probes. Thus, rather than repeatedly writing the same series of statements in multiple probes, you can just place the instructions in a <em class="firstterm">function</em>, as in:
-       </div><pre class="screen">
-function <em class="replaceable"><code>function_name</code></em>(<em class="replaceable"><code>arguments</code></em>) {<em class="replaceable"><code>statements</code></em>}
-probe <em class="replaceable"><code>event</code></em> {<em class="replaceable"><code>function_name</code></em>(<em class="replaceable"><code>arguments</code></em>)}
-</pre><div class="para">
+       </div><pre class="screen">function <em class="replaceable"><code>function_name</code></em>(<em class="replaceable"><code>arguments</code></em>) {<em class="replaceable"><code>statements</code></em>}
+probe <em class="replaceable"><code>event</code></em> {<em class="replaceable"><code>function_name</code></em>(<em class="replaceable"><code>arguments</code></em>)}</pre><div class="para">
                The <code class="command"><em class="replaceable"><code>statements</code></em></code> in <em class="replaceable"><code>function_name</code></em> are executed when the probe for <em class="replaceable"><code>event</code></em> executes. The <em class="replaceable"><code>arguments</code></em> are optional values passed into the function.
-       </div><div class="important"><h2>Important</h2><div class="para">
-                       <a class="xref" href="scripts.html" title="3.2. SystemTap Scripts">Section 3.2, “SystemTap Scripts”</a> is designed to introduce readers to the basics of SystemTap scripts. To understand SystemTap scripts better, it is advisable that you refer to <a class="xref" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts">Chapter 4, <i>Useful SystemTap Scripts</i></a>; each section therein provides a detailed explanation of the script, its events, handlers, and expected output.
-               </div></div><div class="section" title="3.2.1. Event"><div class="titlepage"><div><div><h3 class="title" id="systemtapscript-events">3.2.1. Event</h3></div></div></div><a id="id632171" class="indexterm"></a><div class="para">
+       </div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
+                       <a class="xref" href="scripts.html">Section 3.2, “SystemTap Scripts”</a> is designed to introduce readers to the basics of SystemTap scripts. To understand SystemTap scripts better, it is advisable that you refer to <a class="xref" href="useful-systemtap-scripts.html">Chapter 5, <i>Useful SystemTap Scripts</i></a>; each section therein provides a detailed explanation of the script, its events, handlers, and expected output.
+               </div></div></div><div class="section" id="systemtapscript-events"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="systemtapscript-events">3.2.1. Event</h3></div></div></div><a id="id501809" class="indexterm"></a><div class="para">
                        SystemTap events can be broadly classified into two types: <em class="firstterm">synchronous</em> and <em class="firstterm">asynchronous</em>.
-               </div><div class="formalpara"><h5 class="formalpara" id="id632147">Synchronous Events</h5><a id="id632143" class="indexterm"></a><a id="id632132" class="indexterm"></a>
+               </div><div class="formalpara"><h5 class="formalpara" id="id501780">Synchronous Events</h5><a id="id501775" class="indexterm"></a><a id="id501763" class="indexterm"></a>
                                A <em class="firstterm">synchronous</em> event occurs when any process executes an instruction at a particular location in kernel code. This gives other events a reference point from which more contextual data may be available.
-                       </div><a id="id632113" class="indexterm"></a><a id="id632103" class="indexterm"></a><div class="para">
+                       </div><a id="id501737" class="indexterm"></a><a id="id501725" class="indexterm"></a><div class="para">
                        Examples of synchronous events include:
-               </div><div class="variablelist"><dl><dt><span class="term">syscall.<em class="replaceable"><code>system_call</code></em></span></dt><dd><a id="id632073" class="indexterm"></a><a id="id632059" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">syscall.<em class="replaceable"><code>system_call</code></em></span></dt><dd><a id="id501691" class="indexterm"></a><a id="id571245" class="indexterm"></a><div class="para">
                                                The entry to the system call <em class="replaceable"><code>system_call</code></em>. If the exit from a syscall is desired, appending a <code class="command">.return</code> to the event monitor the exit of the system call instead. For example, to specify the entry and exit of the system call <code class="command">close</code>, use <code class="command">syscall.close</code> and <code class="command">syscall.close.return</code> respectively.
-                                       </div></dd><dt><span class="term">vfs.<em class="replaceable"><code>file_operation</code></em></span></dt><dd><a id="id632009" class="indexterm"></a><a id="id631995" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">vfs.<em class="replaceable"><code>file_operation</code></em></span></dt><dd><a id="id571193" class="indexterm"></a><a id="id571177" class="indexterm"></a><div class="para">
                                                The entry to the <em class="replaceable"><code>file_operation</code></em> event for Virtual File System (VFS). Similar to <code class="command">syscall</code> event, appending a <code class="command">.return</code> to the event monitors the exit of the <em class="replaceable"><code>file_operation</code></em> operation.
-                                       </div></dd><dt><span class="term">kernel.function("<em class="replaceable"><code>function</code></em>")</span></dt><dd><a id="id631949" class="indexterm"></a><a id="id631923" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel.function("<em class="replaceable"><code>function</code></em>")</span></dt><dd><a id="id571117" class="indexterm"></a><a id="id571095" class="indexterm"></a><div class="para">
                                                The entry to the kernel function <em class="replaceable"><code>function</code></em>. For example, <code class="command">kernel.function("sys_open")</code> refers to the "event" that occurs when the kernel function <code class="command">sys_open</code> is called by any thread in the system. To specify the <span class="emphasis"><em>return</em></span> of the kernel function <code class="command">sys_open</code>, append the <code class="command">return</code> string to the event statement; i.e. <code class="command">kernel.function("sys_open").return</code>.
-                                       </div><a id="id631875" class="indexterm"></a><a id="id631864" class="indexterm"></a><a id="id631858" class="indexterm"></a><div class="para">
+                                       </div><a id="id682419" class="indexterm"></a><a id="id682407" class="indexterm"></a><a id="id682392" class="indexterm"></a><div class="para">
                                                When defining probe events, you can use asterisk (<code class="literal">*</code>) for wildcards. You can also trace the entry or exit of a function in a kernel source file. Consider the following example:
-                                       </div><div class="example" id="wildcards"><div class="example-contents"><pre class="programlisting">
-probe kernel.function("*@net/socket.c") { }
-probe kernel.function("*@net/socket.c").return { }
-</pre></div><h6>Example 3.1. wildcards.stp</h6></div><br class="example-break" /><div class="para">
+                                       </div><div class="example" id="wildcards"><h6>Example 3.1. wildcards.stp</h6><div class="example-contents"><pre class="programlisting">probe kernel.function("*@net/socket.c") { }
+probe kernel.function("*@net/socket.c").return { }</pre></div></div><br class="example-break" /><div class="para">
                                                In the previous example, the first probe's event specifies the entry of ALL functions in the kernel source file <code class="filename">net/socket.c</code>. The second probe specifies the exit of all those functions. Note that in this example, there are no statements in the handler; as such, no information will be collected or displayed.
-                                       </div></dd><dt><span class="term">kernel.trace("<em class="replaceable"><code>tracepoint</code></em>")</span></dt><dd><a id="id631800" class="indexterm"></a><a id="id631793" class="indexterm"></a><a id="id631778" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel.trace("<em class="replaceable"><code>tracepoint</code></em>")</span></dt><dd><a id="id682330" class="indexterm"></a><a id="id682322" class="indexterm"></a><a id="id741078" class="indexterm"></a><div class="para">
                                                The static probe for <em class="replaceable"><code>tracepoint</code></em>. Recent kernels (2.6.30 and newer) include instrumentation for specific events in the kernel. These events are statically marked with tracepoints. One example of a tracepoint available in systemtap is <code class="command">kernel.trace("kfree_skb")</code> which indicates each time a network buffer is freed in the kernel.
-                                       </div></dd><dt><span class="term">module("<em class="replaceable"><code>module</code></em>").function("<em class="replaceable"><code>function</code></em>")</span></dt><dd><a id="id631732" class="indexterm"></a><a id="id631701" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">module("<em class="replaceable"><code>module</code></em>").function("<em class="replaceable"><code>function</code></em>")</span></dt><dd><a id="id741031" class="indexterm"></a><a id="id741006" class="indexterm"></a><div class="para">
                                                Allows you to probe functions within modules. For example:
-                                       </div><div class="example" id="eventsmodules"><div class="example-contents"><pre class="programlisting">
-probe module("ext3").function("*") { }
-probe module("ext3").function("*").return { }
-</pre></div><h6>Example 3.2. moduleprobe.stp</h6></div><br class="example-break" /><div class="para">
-                                               The first probe in <a class="xref" href="scripts.html#eventsmodules" title="Example 3.2. moduleprobe.stp">Example 3.2, “moduleprobe.stp”</a> points to the entry of <span class="emphasis"><em>all</em></span> functions for the <code class="filename">ext3</code> module. The second probe points to the exits of all functions for that same module; the use of the <code class="command">.return</code> suffix is similar to <code class="command">kernel.function()</code>. Note that the probes in <a class="xref" href="scripts.html#eventsmodules" title="Example 3.2. moduleprobe.stp">Example 3.2, “moduleprobe.stp”</a> do not contain statements in the probe handlers, and as such will not print any useful data (as in <a class="xref" href="scripts.html#wildcards" title="Example 3.1. wildcards.stp">Example 3.1, “wildcards.stp”</a>).
+                                       </div><div class="example" id="eventsmodules"><h6>Example 3.2. moduleprobe.stp</h6><div class="example-contents"><pre class="programlisting">probe module("ext3").function("*") { }
+probe module("ext3").function("*").return { }</pre></div></div><br class="example-break" /><div class="para">
+                                               The first probe in <a class="xref" href="scripts.html#eventsmodules">Example 3.2, “moduleprobe.stp”</a> points to the entry of <span class="emphasis"><em>all</em></span> functions for the <code class="filename">ext3</code> module. The second probe points to the exits of all functions for that same module; the use of the <code class="command">.return</code> suffix is similar to <code class="command">kernel.function()</code>. Note that the probes in <a class="xref" href="scripts.html#eventsmodules">Example 3.2, “moduleprobe.stp”</a> do not contain statements in the probe handlers, and as such will not print any useful data (as in <a class="xref" href="scripts.html#wildcards">Example 3.1, “wildcards.stp”</a>).
                                        </div><div class="para">
-                                               A system's kernel modules are typically located in <code class="filename">/lib/modules/<em class="replaceable"><code>kernel_version</code></em></code>, where <em class="replaceable"><code>kernel_version</code></em> refers to the currently loaded kernel version. Modules use the filename extension <code class="filename">.ko</code>.
-                                       </div></dd></dl></div><div class="formalpara"><h5 class="formalpara" id="id631633">Asynchronous Events</h5><a id="id631625" class="indexterm"></a><a id="id631615" class="indexterm"></a>
+                                               A system's kernel modules are typically located in <code class="filename">/lib/modules/<em class="replaceable"><code>kernel_version</code></em></code>, where <em class="replaceable"><code>kernel_version</code></em> refers to the currently loaded kernel version. Modules use the file name extension <code class="filename">.ko</code>.
+                                       </div></dd></dl></div><div class="formalpara"><h5 class="formalpara" id="id569516">Asynchronous Events</h5><a id="id569494" class="indexterm"></a><a id="id569498" class="indexterm"></a>
                                <em class="firstterm">Asynchronous</em> events are not tied to a particular instruction or location in code. This family of probe points consists mainly of counters, timers, and similar constructs.
                        </div><div class="para">
                        Examples of asynchronous events include:
-               </div><div class="variablelist"><dl><dt><span class="term">begin</span></dt><dd><a id="id631581" class="indexterm"></a><a id="id631563" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">begin</span></dt><dd><a id="id569456" class="indexterm"></a><a id="id569435" class="indexterm"></a><div class="para">
                                                The startup of a SystemTap session; i.e. as soon as the SystemTap script is run.
-                                       </div></dd><dt><span class="term">end</span></dt><dd><a id="id631537" class="indexterm"></a><a id="id631528" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">end</span></dt><dd><a id="id569408" class="indexterm"></a><a id="id569393" class="indexterm"></a><div class="para">
                                                The end of a SystemTap session.
-                                       </div></dd><dt><span class="term">timer events</span></dt><dd><a id="id631483" class="indexterm"></a><a id="id631488" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">timer events</span></dt><dd><a id="id569364" class="indexterm"></a><a id="id533887" class="indexterm"></a><div class="para">
                                                An event that specifies a handler to be executed periodically. For example:
-                                       </div><div class="example" id="timer"><div class="example-contents"><pre class="programlisting">
-probe timer.s(4)
+                                       </div><div class="example" id="timer"><h6>Example 3.3. timer-s.stp</h6><div class="example-contents"><pre class="programlisting">probe timer.s(4)
 {
   printf("hello world\n")
-}
-</pre></div><h6>Example 3.3. timer-s.stp</h6></div><br class="example-break" /><div class="para">
-                                               <a class="xref" href="scripts.html#timer" title="Example 3.3. timer-s.stp">Example 3.3, “timer-s.stp”</a> is an example of a probe that prints <code class="command">hello world</code> every 4 seconds. Note that you can also use the following timer events:
+}</pre></div></div><br class="example-break" /><div class="para">
+                                               <a class="xref" href="scripts.html#timer">Example 3.3, “timer-s.stp”</a> is an example of a probe that prints <code class="command">hello world</code> every 4 seconds. Note that you can also use the following timer events:
                                        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                                                <code class="command">timer.ms(<em class="replaceable"><code>milliseconds</code></em>)</code>
                                                        </div></li><li class="listitem"><div class="para">
@@ -90,6 +80,6 @@ probe timer.s(4)
                                                                <code class="command">timer.jiffies(<em class="replaceable"><code>jiffies</code></em>)</code>
                                                        </div></li></ul></div><div class="para">
                                                When used in conjunction with other probes that collect information, timer events allows you to print out get periodic updates and see how that information changes over time.
-                                       </div></dd></dl></div><div class="important"><h2>Important</h2><div class="para">
+                                       </div></dd></dl></div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
                                SystemTap supports the use of a large collection of probe events. For more information about supported events, refer to <code class="command">man stapprobes</code>. The <em class="citetitle">SEE ALSO</em> section of <code class="command">man stapprobes</code> also contains links to other <code class="command">man</code> pages that discuss supported events for specific subsystems and components.
-                       </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-how-systemtap-works.html"><strong>Prev</strong>Chapter 3. Understanding How SystemTap Works</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="systemtapscript-handler.html"><strong>Next</strong>3.2.2. Systemtap Handler/Body</a></li></ul></body></html>
+                       </div></div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-how-systemtap-works.html"><strong>Prev</strong>Chapter 3. Understanding How SystemTap Works</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="systemtapscript-handler.html"><strong>Next</strong>3.2.2. Systemtap Handler/Body</a></li></ul></body></html>
index fca74b39948e115199d287944f735458645a7388..d634981d45292ab307da0d198c2ae63b1c96b895 100644 (file)
@@ -1,11 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3.6. Tracking System Call Volume Per Process</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="prev" href="topsyssect.html" title="4.3.5. Tracking Most Frequently Used System Calls" /><link rel="next" href="futexcontentionsect.html" title="4.4. Identifying Contended User-Space Locks" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="topsyssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="futexcontentionsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.3.6. Tracking System Call Volume Per Process" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="syscallsbyprocpidsect">4.3.6. Tracking System Call Volume Per Process</h3></div></div></div><a id="id607799" class="indexterm"></a><a id="id595716" class="indexterm"></a><a id="id581855" class="indexterm"></a><a id="id589216" class="indexterm"></a><div class="para">
-               This section illustrates how to determine which processes are performing the highest volume of system calls. In previous sections, we've described how to monitor the top system calls used by the system over time (<a class="xref" href="topsyssect.html" title="4.3.5. Tracking Most Frequently Used System Calls">Section 4.3.5, “Tracking Most Frequently Used System Calls”</a>). We've also described how to identify which applications use a specific set of "polling suspect" system calls the most (<a class="xref" href="timeoutssect.html" title="4.3.4. Monitoring Polling Applications">Section 4.3.4, “Monitoring Polling Applications”</a>). Monitoring the volume of system calls made by each process provides more data in investigating your system for polling processes and other resource hogs.
-       </div><div class="formalpara"><h5 class="formalpara" id="syscallsbyprocpid">syscalls_by_proc.stp</h5>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3.6. Tracking System Call Volume Per Process</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="prev" href="topsyssect.html" title="5.3.5. Tracking Most Frequently Used System Calls" /><link rel="next" href="futexcontentionsect.html" title="5.4. Identifying Contended User-Space Locks" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="topsyssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="futexcontentionsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="syscallsbyprocpidsect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="syscallsbyprocpidsect">5.3.6. Tracking System Call Volume Per Process</h3></div></div></div><a id="id690392" class="indexterm"></a><a id="id512508" class="indexterm"></a><a id="id1970964" class="indexterm"></a><a id="id490065" class="indexterm"></a><div class="para">
+               This section illustrates how to determine which processes are performing the highest volume of system calls. In previous sections, we've described how to monitor the top system calls used by the system over time (<a class="xref" href="topsyssect.html">Section 5.3.5, “Tracking Most Frequently Used System Calls”</a>). We've also described how to identify which applications use a specific set of "polling suspect" system calls the most (<a class="xref" href="timeoutssect.html">Section 5.3.4, “Monitoring Polling Applications”</a>). Monitoring the volume of system calls made by each process provides more data in investigating your system for polling processes and other resource hogs.
+       </div><div class="formalpara" id="syscallsbyprocpid"><h5 class="formalpara">syscalls_by_proc.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 # Copyright (C) 2006 IBM Corp.
 #
@@ -33,12 +32,10 @@ probe end {
   foreach (proc in syscalls-)
     printf("%-10d %-s\n", syscalls[proc], proc)
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="syscallsbyprocpidsect.html#syscallsbyprocpid" title="syscalls_by_proc.stp">syscalls_by_proc.stp</a> lists the top 20 processes performing the highest number of system calls. It also lists how many system calls each process performed during the time period. Refer to <a class="xref" href="syscallsbyprocpidsect.html#syscallsbyprocpidoutput" title="Example 4.18. topsys.stp Sample Output">Example 4.18, “topsys.stp Sample Output”</a> for a sample output.
-       </div><div class="example" id="syscallsbyprocpidoutput"><div class="example-contents"><pre class="screen">
-Collecting data... Type Ctrl-C to exit and display results
+               <a class="xref" href="syscallsbyprocpidsect.html#syscallsbyprocpid">syscalls_by_proc.stp</a> lists the top 20 processes performing the highest number of system calls. It also lists how many system calls each process performed during the time period. Refer to <a class="xref" href="syscallsbyprocpidsect.html#syscallsbyprocpidoutput">Example 5.18, “topsys.stp Sample Output”</a> for a sample output.
+       </div><div class="example" id="syscallsbyprocpidoutput"><h6>Example 5.18. <a class="xref" href="topsyssect.html#topsys">topsys.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">Collecting data... Type Ctrl-C to exit and display results
 #SysCalls  Process Name
 1577       multiload-apple
 692        synergyc
@@ -53,13 +50,11 @@ Collecting data... Type Ctrl-C to exit and display results
 84         scim-bridge
 78         gnome-screensav
 66         scim-launcher
-[...]
-</pre></div><h6>Example 4.18. <a class="xref" href="topsyssect.html#topsys" title="topsys.stp">topsys.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
+[...]</pre></div></div><br class="example-break" /><div class="para">
                If you prefer the output to display the process IDs instead of the process names, use the following script instead.
-       </div><div class="formalpara"><h5 class="formalpara" id="syscallsbypid">syscalls_by_pid.stp</h5>
+       </div><div class="formalpara" id="syscallsbypid"><h5 class="formalpara">syscalls_by_pid.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 # Copyright (C) 2006 IBM Corp.
 #
@@ -87,13 +82,10 @@ probe end {
   foreach (pid in syscalls-)
     printf("%-10d %-d\n", syscalls[pid], pid)
 }
-
 </pre>
                </div><div class="para">
                As indicated in the output, you need to manually exit the script in order to display the results. You can add a timed expiration to either script by simply adding a <code class="command">timer.s()</code> probe; for example, to instruct the script to expire after 5 seconds, add the following probe to the script:
-       </div><pre class="screen">
-probe timer.s(5)
+       </div><pre class="screen">probe timer.s(5)
 {
        exit()
-}
-</pre></div><ul class="docnav"><li class="previous"><a accesskey="p" href="topsyssect.html"><strong>Prev</strong>4.3.5. Tracking Most Frequently Used System Calls</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="futexcontentionsect.html"><strong>Next</strong>4.4. Identifying Contended User-Space Locks</a></li></ul></body></html>
+}</pre></div><ul class="docnav"><li class="previous"><a accesskey="p" href="topsyssect.html"><strong>Prev</strong>5.3.5. Tracking Most Frequently Used System Calls</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="futexcontentionsect.html"><strong>Next</strong>5.4. Identifying Contended User-Space Locks</a></li></ul></body></html>
index 6758783cbb3bfc24e286363c36b39831e3643550..e49d9c0fe81c839da722cd0be0dc7a1a7b34d8f3 100644 (file)
@@ -1,62 +1,55 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.2.2. Systemtap Handler/Body</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scripts.html" title="3.2. SystemTap Scripts" /><link rel="prev" href="scripts.html" title="3.2. SystemTap Scripts" /><link rel="next" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="scripts.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="scriptconstructions.html"><strong>Next</strong></a></li></ul><div class="section" title="3.2.2. Systemtap Handler/Body"><div class="titlepage"><div><div><h3 class="title" id="systemtapscript-handler">3.2.2. Systemtap Handler/Body</h3></div></div></div><a id="id631337" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.2.2. Systemtap Handler/Body</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scripts.html" title="3.2. SystemTap Scripts" /><link rel="prev" href="scripts.html" title="3.2. SystemTap Scripts" /><link rel="next" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="scripts.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="scriptconstructions.html"><strong>Next</strong></a></li></ul><div class="section" id="systemtapscript-handler"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="systemtapscript-handler">3.2.2. Systemtap Handler/Body</h3></div></div></div><a id="id427349" class="indexterm"></a><div class="para">
                        Consider the following sample script:
-               </div><div class="example" id="helloworld"><div class="example-contents"><pre class="programlisting">
-probe begin
+               </div><div class="example" id="helloworld"><h6>Example 3.4. helloworld.stp</h6><div class="example-contents"><pre class="programlisting">probe begin
 {
   printf ("hello world\n")
   exit ()
-}
-</pre></div><h6>Example 3.4. helloworld.stp</h6></div><br class="example-break" /><div class="para">
-                       In <a class="xref" href="systemtapscript-handler.html#helloworld" title="Example 3.4. helloworld.stp">Example 3.4, “helloworld.stp”</a>, the event <code class="command">begin</code> (i.e. the start of the session) triggers the handler enclosed in <code class="command">{ }</code>, which simply prints <code class="command">hello world</code> followed by a new-line, then exits.
-               </div><div class="note"><h2>Note</h2><a id="id631277" class="indexterm"></a><a id="id631269" class="indexterm"></a><div class="para">
+}</pre></div></div><br class="example-break" /><div class="para">
+                       In <a class="xref" href="systemtapscript-handler.html#helloworld">Example 3.4, “helloworld.stp”</a>, the event <code class="command">begin</code> (i.e. the start of the session) triggers the handler enclosed in <code class="command">{ }</code>, which simply prints <code class="command">hello world</code> followed by a new-line, then exits.
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><a id="id427290" class="indexterm"></a><a id="id427276" class="indexterm"></a><div class="para">
                                SystemTap scripts continue to run until the <code class="command">exit()</code> function executes. If the users wants to stop the execution of the script, it can interrupted manually with <span class="keycap"><strong>Ctrl</strong></span>+<span class="keycap"><strong>C</strong></span>.
-                       </div></div><div class="formalpara"><h5 class="formalpara" id="printf">printf ( ) Statements</h5><a id="id631236" class="indexterm"></a>
+                       </div></div></div><div class="formalpara" id="printf"><h5 class="formalpara">printf ( ) Statements</h5><a id="id427238" class="indexterm"></a>
                                The <code class="command">printf ()</code> statement is one of the simplest functions for printing data. <code class="command">printf ()</code> can also be used to display data using a wide variety of SystemTap functions in the following format:
-                       </div><pre class="programlisting">
-               printf ("<em class="replaceable"><code>format string</code></em>\n", <em class="replaceable"><code>arguments</code></em>)
-</pre><a id="id631199" class="indexterm"></a><a id="id631187" class="indexterm"></a><div class="para">
-                       The <em class="replaceable"><code>format string</code></em> specifies how <em class="replaceable"><code>arguments</code></em> should be printed. The format string of <a class="xref" href="systemtapscript-handler.html#helloworld" title="Example 3.4. helloworld.stp">Example 3.4, “helloworld.stp”</a> simply instructs SystemTap to print <code class="command">hello world</code>, and contains no format specifiers.
-               </div><a id="id631160" class="indexterm"></a><a id="id631148" class="indexterm"></a><div class="para">
+                       </div><pre class="programlisting">              printf ("<em class="replaceable"><code>format string</code></em>\n", <em class="replaceable"><code>arguments</code></em>)
+</pre><a id="id738652" class="indexterm"></a><a id="id738638" class="indexterm"></a><div class="para">
+                       The <em class="replaceable"><code>format string</code></em> specifies how <em class="replaceable"><code>arguments</code></em> should be printed. The format string of <a class="xref" href="systemtapscript-handler.html#helloworld">Example 3.4, “helloworld.stp”</a> simply instructs SystemTap to print <code class="command">hello world</code>, and contains no format specifiers.
+               </div><a id="id738605" class="indexterm"></a><a id="id738591" class="indexterm"></a><div class="para">
                        You can use the format specifiers <code class="command">%s</code> (for strings) and <code class="command">%d</code> (for numbers) in format strings, depending on your list of arguments. Format strings can have multiple format specifiers, each matching a corresponding argument; multiple arguments are delimited by a comma (<code class="command">,</code>).
-               </div><div class="note"><h2>Note</h2><a id="id610834" class="indexterm"></a><a id="id610803" class="indexterm"></a><a id="id610804" class="indexterm"></a><div class="para">
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><a id="id738556" class="indexterm"></a><a id="id738544" class="indexterm"></a><a id="id457778" class="indexterm"></a><div class="para">
                                Semantically, the SystemTap <code class="command">printf</code> function is very similar to its C language counterpart. The aforementioned syntax and format for SystemTap's <code class="command">printf</code> function is identical to that of the C-style <code class="command">printf</code>.
-                       </div></div><div class="para">
+                       </div></div></div><div class="para">
                        To illustrate this, consider the following probe example:
-               </div><div class="example" id="syscall-open"><div class="example-contents"><pre class="programlisting">
-probe syscall.open
+               </div><div class="example" id="syscall-open"><h6>Example 3.5. variables-in-printf-statements.stp</h6><div class="example-contents"><pre class="programlisting">probe syscall.open
 {
   printf ("%s(%d) open\n", execname(), pid())
-}
-</pre></div><h6>Example 3.5. variables-in-printf-statements.stp</h6></div><br class="example-break" /><div class="para">
-                       <a class="xref" href="systemtapscript-handler.html#syscall-open" title="Example 3.5. variables-in-printf-statements.stp">Example 3.5, “variables-in-printf-statements.stp”</a> instructs SystemTap to probe all entries to the system call <code class="command">open</code>; for each event, it prints the current <code class="command">execname()</code> (a string with the executable name) and <code class="command">pid()</code> (the current process ID number), followed by the word <code class="command">open</code>. A snippet of this probe's output would look like:
-               </div><pre class="screen">
-vmware-guestd(2206) open
+}</pre></div></div><br class="example-break" /><div class="para">
+                       <a class="xref" href="systemtapscript-handler.html#syscall-open">Example 3.5, “variables-in-printf-statements.stp”</a> instructs SystemTap to probe all entries to the system call <code class="command">open</code>; for each event, it prints the current <code class="command">execname()</code> (a string with the executable name) and <code class="command">pid()</code> (the current process ID number), followed by the word <code class="command">open</code>. A snippet of this probe's output would look like:
+               </div><pre class="screen">vmware-guestd(2206) open
 hald(2360) open
 hald(2360) open
 hald(2360) open
 df(3433) open
 df(3433) open
 df(3433) open
-hald(2360) open
-</pre><div class="formalpara"><h5 class="formalpara" id="systemtapscript-functions">SystemTap Functions</h5><a id="id610727" class="indexterm"></a><a id="id610720" class="indexterm"></a><a id="id610713" class="indexterm"></a>
-                               SystemTap supports a wide variety of functions that can be used as <code class="command">printf ()</code> arguments. <a class="xref" href="systemtapscript-handler.html#syscall-open" title="Example 3.5. variables-in-printf-statements.stp">Example 3.5, “variables-in-printf-statements.stp”</a> uses the SystemTap functions <code class="command">execname()</code> (name of the process that called a kernel function/performed a system call) and <code class="command">pid()</code> (current process ID).
+hald(2360) open</pre><div class="formalpara" id="systemtapscript-functions"><h5 class="formalpara">SystemTap Functions</h5><a id="id457700" class="indexterm"></a><a id="id457693" class="indexterm"></a><a id="id457685" class="indexterm"></a>
+                               SystemTap supports a wide variety of functions that can be used as <code class="command">printf ()</code> arguments. <a class="xref" href="systemtapscript-handler.html#syscall-open">Example 3.5, “variables-in-printf-statements.stp”</a> uses the SystemTap functions <code class="command">execname()</code> (name of the process that called a kernel function/performed a system call) and <code class="command">pid()</code> (current process ID).
                        </div><div class="para">
                        The following is a list of commonly-used SystemTap functions:
-               </div><div class="variablelist"><dl><dt><span class="term">tid()</span></dt><dd><a id="id610668" class="indexterm"></a><a id="id610654" class="indexterm"></a><a id="id610641" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">tid()</span></dt><dd><a id="id457629" class="indexterm"></a><a id="id1930957" class="indexterm"></a><a id="id1930941" class="indexterm"></a><div class="para">
                                                The ID of the current thread.
-                                       </div></dd><dt><span class="term">uid()</span></dt><dd><a id="id610611" class="indexterm"></a><a id="id610596" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">uid()</span></dt><dd><a id="id1930907" class="indexterm"></a><a id="id1930888" class="indexterm"></a><div class="para">
                                                The ID of the current user.
-                                       </div></dd><dt><span class="term">cpu()</span></dt><dd><a id="id610569" class="indexterm"></a><a id="id610553" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">cpu()</span></dt><dd><a id="id1930855" class="indexterm"></a><a id="id1930822" class="indexterm"></a><div class="para">
                                                The current CPU number.
-                                       </div></dd><dt><span class="term">gettimeofday_s()</span></dt><dd><a id="id610524" class="indexterm"></a><a id="id610508" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">gettimeofday_s()</span></dt><dd><a id="id580433" class="indexterm"></a><a id="id580399" class="indexterm"></a><div class="para">
                                                The number of seconds since UNIX epoch (January 1, 1970).
-                                       </div></dd><dt><span class="term">ctime()</span></dt><dd><a id="id610480" class="indexterm"></a><a id="id610458" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">ctime()</span></dt><dd><a id="id580380" class="indexterm"></a><a id="id580356" class="indexterm"></a><div class="para">
                                                Convert number of seconds since UNIX epoch to date.
-                                       </div></dd><dt><span class="term">pp()</span></dt><dd><a id="id610419" class="indexterm"></a><a id="id610403" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">pp()</span></dt><dd><a id="id580311" class="indexterm"></a><a id="id580293" class="indexterm"></a><div class="para">
                                                A string describing the probe point currently being handled.
-                                       </div></dd><dt><span class="term">thread_indent()</span></dt><dd><a id="id511183" class="indexterm"></a><a id="id511170" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">thread_indent()</span></dt><dd><a id="id622768" class="indexterm"></a><a id="id622751" class="indexterm"></a><div class="para">
                                                This particular function is quite useful, providing you with a way to better organize your print results. The function takes one argument, an indentation delta, which indicates how many spaces to add or remove from a thread's "indentation counter". It then returns a string with some generic trace data along with an appropriate number of indentation spaces.
                                        </div><div class="para">
                                                The generic data included in the returned string includes a timestamp (number of microseconds since the first call to <code class="command">thread_indent()</code> by the thread), a process name, and the thread ID. This allows you to identify what functions were called, who called them, and the duration of each function call.
@@ -64,19 +57,16 @@ hald(2360) open
                                                If call entries and exits immediately precede each other, it is easy to match them. However, in most cases, after a first function call entry is made several other call entries and exits may be made before the first call exits. The indentation counter helps you match an entry with its corresponding exit by indenting the next function call if it is not the exit of the previous one.
                                        </div><div class="para">
                                                Consider the following example on the use of <code class="command">thread_indent()</code>:
-                                       </div><div class="example" id="thread_indent"><div class="example-contents"><pre class="programlisting">
-probe kernel.function("*@net/socket.c") 
+                                       </div><div class="example" id="thread_indent"><h6>Example 3.6. thread_indent.stp</h6><div class="example-contents"><pre class="programlisting">probe kernel.function("*@net/socket.c")
 {
   printf ("%s -&gt; %s\n", thread_indent(1), probefunc())
 }
-probe kernel.function("*@net/socket.c").return 
+probe kernel.function("*@net/socket.c").return
 {
   printf ("%s &lt;- %s\n", thread_indent(-1), probefunc())
-}
-</pre></div><h6>Example 3.6. thread_indent.stp</h6></div><br class="example-break" /><div class="para">
-                                               <a class="xref" href="systemtapscript-handler.html#thread_indent" title="Example 3.6. thread_indent.stp">Example 3.6, “thread_indent.stp”</a> prints out the <code class="command">thread_indent()</code> and probe functions at each event in the following format:
-                                       </div><pre class="screen">
-0 ftp(7223): -&gt; sys_socketcall
+}</pre></div></div><br class="example-break" /><div class="para">
+                                               <a class="xref" href="systemtapscript-handler.html#thread_indent">Example 3.6, “thread_indent.stp”</a> prints out the <code class="command">thread_indent()</code> and probe functions at each event in the following format:
+                                       </div><pre class="screen">0 ftp(7223): -&gt; sys_socketcall
 1159 ftp(7223):  -&gt; sys_socket
 2173 ftp(7223):   -&gt; __sock_create
 2286 ftp(7223):    -&gt; sock_alloc_inode
@@ -91,28 +81,25 @@ probe kernel.function("*@net/socket.c").return
 4699 ftp(7223):    &lt;- sock_map_file
 4715 ftp(7223):   &lt;- sock_map_fd
 4732 ftp(7223):  &lt;- sys_socket
-4775 ftp(7223): &lt;- sys_socketcall
-</pre><div class="para">
+4775 ftp(7223): &lt;- sys_socketcall</pre><div class="para">
                                                This sample output contains the following information:
                                        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                                                               The time (in microseconds) since the initial <code class="command">thread_ident()</code> call for the thread (included in the string from <code class="command">thread_ident()</code>).
+                                                               The time (in microseconds) since the initial <code class="command">thread_indent()</code> call for the thread (included in the string from <code class="command">thread_indent()</code>).
                                                        </div></li><li class="listitem"><div class="para">
-                                                               The process name (and its corresponding ID) that made the function call (included in the string from <code class="command">thread_ident()</code>).
+                                                               The process name (and its corresponding ID) that made the function call (included in the string from <code class="command">thread_indent()</code>).
                                                        </div></li><li class="listitem"><div class="para">
                                                                An arrow signifying whether the call was an entry (<code class="computeroutput">&lt;-</code>) or an exit (<code class="computeroutput">-&gt;</code>); the indentations help you match specific function call entries with their corresponding exits.
                                                        </div></li><li class="listitem"><div class="para">
                                                                The name of the function called by the process.
-                                                       </div></li></ul></div></dd><dt><span class="term">name</span></dt><dd><a id="id496344" class="indexterm"></a><a id="id496334" class="indexterm"></a><a id="id495638" class="indexterm"></a><div class="para">
+                                                       </div></li></ul></div></dd><dt class="varlistentry"><span class="term">name</span></dt><dd><a id="id490194" class="indexterm"></a><a id="id490182" class="indexterm"></a><a id="id490169" class="indexterm"></a><div class="para">
                                                Identifies the name of a specific system call. This variable can only be used in probes that use the event <code class="command">syscall.<em class="replaceable"><code>system_call</code></em></code>.
-                                       </div></dd><dt><span class="term">target()</span></dt><dd><a id="id495601" class="indexterm"></a><a id="id495584" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">target()</span></dt><dd><a id="id574480" class="indexterm"></a><a id="id574459" class="indexterm"></a><div class="para">
                                                Used in conjunction with <code class="command">stap <em class="replaceable"><code>script</code></em> -x <em class="replaceable"><code>process ID</code></em></code> or <code class="command">stap <em class="replaceable"><code>script</code></em> -c <em class="replaceable"><code>command</code></em></code>. If you want to specify a script to take an argument of a process ID or command, use <code class="command">target()</code> as the variable in the script to refer to it. For example:
-                                       </div><div class="example" id="targetexample"><div class="example-contents"><pre class="programlisting">
-probe syscall.* {
+                                       </div><div class="example" id="targetexample"><h6>Example 3.7. targetexample.stp</h6><div class="example-contents"><pre class="programlisting">probe syscall.* {
   if (pid() == target())
     printf("%s/n", name)
-}
-</pre></div><h6>Example 3.7. targetexample.stp</h6></div><br class="example-break" /><div class="para">
-                                               When <a class="xref" href="systemtapscript-handler.html#targetexample" title="Example 3.7. targetexample.stp">Example 3.7, “targetexample.stp”</a> is run with the argument <code class="command">-x <em class="replaceable"><code>process ID</code></em></code>, it watches all system calls (as specified by the event <code class="command">syscall.*</code>) and prints out the name of all system calls made by the specified process.
+}</pre></div></div><br class="example-break" /><div class="para">
+                                               When <a class="xref" href="systemtapscript-handler.html#targetexample">Example 3.7, “targetexample.stp”</a> is run with the argument <code class="command">-x <em class="replaceable"><code>process ID</code></em></code>, it watches all system calls (as specified by the event <code class="command">syscall.*</code>) and prints out the name of all system calls made by the specified process.
                                        </div><div class="para">
                                                This has the same effect as specifying <code class="command">if (pid() == <em class="replaceable"><code>process ID</code></em>)</code> each time you wish to target a specific process. However, using <code class="command">target()</code> makes it easier for you to re-use the script, giving you the ability to simply pass a process ID as an argument each time you wish to run the script (e.g. <code class="command">stap targetexample.stp -x <em class="replaceable"><code>process ID</code></em></code>).
                                        </div></dd></dl></div><div class="para">
diff --git a/SystemTap_Beginners_Guide/targetavailable.html b/SystemTap_Beginners_Guide/targetavailable.html
new file mode 100644 (file)
index 0000000..efa2bcf
--- /dev/null
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.2.3. Checking Target Variable Availablility</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="targetvariables.html" title="3.3.2. Target Variables" /><link rel="prev" href="typecasting.html" title="3.3.2.2. Typecasting" /><link rel="next" href="handlerconditionalstatements.html" title="3.3.3. Conditional Statements" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="typecasting.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="handlerconditionalstatements.html"><strong>Next</strong></a></li></ul><div class="section" id="targetavailable"><div class="titlepage"><div><div keep-together.within-column="always"><h4 class="title" id="targetavailable">3.3.2.3. Checking Target Variable Availablility</h4></div></div></div><a id="id529238" class="indexterm"></a><div class="para">
+                               As code evolves the target variables available may change. The <code class="command">@defined</code> makes it easier to handle those variations in the available target variables. The <code class="command">@defined</code> provides a test to see if a particular target variable is available. The result of this test can be used to select the appropriate expression.
+                       </div><div class="para">
+                               The <a class="xref" href="targetavailable.html#available">Example 3.10, “Testing target variable available Example”</a> from the <code class="command">memory.stp</code> tapset provides an probe event alias. Some version of the kernel functions being probed have an argument <code class="command">$flags</code>. When available, the <code class="command">$flags</code> argument is used to generate the local variable <code class="command">write_access</code>. The versions of the probed functions that do not have the <code class="command">$flags</code> argument have a <code class="command">$write</code> argument and that is used instead for the local variable <code class="command">write_access</code>.
+                       </div><div class="example" id="available"><h6>Example 3.10. Testing target variable available Example</h6><div class="example-contents"><pre class="programlisting">probe vm.pagefault = kernel.function("__handle_mm_fault@mm/memory.c") ?,
+                     kernel.function("handle_mm_fault@mm/memory.c") ?
+{
+        name = "pagefault"
+        write_access = (@defined($flags)
+                       ? $flags &amp; FAULT_FLAG_WRITE : $write_access)
+       address =  $address
+}
+</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="typecasting.html"><strong>Prev</strong>3.3.2.2. Typecasting</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="handlerconditionalstatements.html"><strong>Next</strong>3.3.3. Conditional Statements</a></li></ul></body></html>
diff --git a/SystemTap_Beginners_Guide/targetvariables.html b/SystemTap_Beginners_Guide/targetvariables.html
new file mode 100644 (file)
index 0000000..5522212
--- /dev/null
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.2. Target Variables</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="prev" href="scriptconstructions.html" title="3.3. Basic SystemTap Handler Constructs" /><link rel="next" href="typecasting.html" title="3.3.2.2. Typecasting" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="scriptconstructions.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="typecasting.html"><strong>Next</strong></a></li></ul><div class="section" id="targetvariables"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="targetvariables">3.3.2. Target Variables</h3></div></div></div><a id="id602646" class="indexterm"></a><a id="id637815" class="indexterm"></a><div class="para">
+                       The probe events that map to actual locations in the code (for example <code class="command">kernel.function("<em class="replaceable"><code>function</code></em>")</code> and <code class="command">kernel.statement("<em class="replaceable"><code>statement</code></em>")</code>) allow the use of <span class="emphasis"><em>target variables</em></span> to obtain the value of variables visible at that location in the code. You can use the <code class="command">-L</code> option to list the target variable available at a probe point. If the debug information is installed for the running kernel, you can run the following command to find out what target variables are available for the <code class="command">vfs_read</code> function:
+               </div><pre class="screen">stap -L 'kernel.function("vfs_read")'</pre><div class="para">
+                       This will yield something similar to the following:
+               </div><pre class="screen">kernel.function("vfs_read@fs/read_write.c:277") $file:struct file* $buf:char* $count:size_t $pos:loff_t*</pre><div class="para">
+                       Each target variable is proceeded by a <span class="quote">“<span class="quote"><code class="command">$</code></span>”</span> and the type of the target variable follows the <span class="quote">“<span class="quote"><code class="command">:</code></span>”</span>. The kernel's <code class="command">vfs_read</code> function has <code class="command">$file</code> (pointer to structure describing the file), <code class="command">$buf</code> (pointer to the user-space memory to store the read data), <code class="command">$count</code> (number of bytes to read), and <code class="command">$pos</code> (position to start reading from in the file) target variables at the entry to the function.
+               </div><div class="para">
+                       SystemTap tracks the typing information of the target variable and can examine the fields of a structure with the <code class="command">-&gt;</code> operator. The <code class="command">-&gt;</code> operator can be chained to look at data structures contained within data structures and follow pointers to other data structures. The <code class="command">-&gt;</code> operator will obtain the value in the field of the structure. The <code class="command">-&gt;</code> operator is used regardless whether accessing a field in a substructure or accessing another structure through a pointer.
+               </div><div class="para">
+                       For pointers to base types such as integers and strings there are a number of functions listed below to access kernel-space data. The first argument for each functions is the pointer to the data item. Similar functions are described in <a class="xref" href="utargetvariable.html">Section 4.2, “Accessing User-Space Target Variables”</a> for accessing target variables in user-space code.
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">kernel_char(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the character at <em class="replaceable"><code>address</code></em> from kernel memory.
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel_short(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the short at <em class="replaceable"><code>address</code></em> from kernel memory.
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel_int(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the int at <em class="replaceable"><code>address</code></em> from kernel memory.
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel_long(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the long at <em class="replaceable"><code>address</code></em> from kernel memory
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel_string(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the string at <em class="replaceable"><code>address</code></em> from kernel memory.
+                                       </div></dd><dt class="varlistentry"><span class="term">kernel_string_n(<em class="replaceable"><code>address</code></em>, <em class="replaceable"><code>n</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the string at <em class="replaceable"><code>address</code></em> from the kernel memory and limits the string to <em class="replaceable"><code>n</code></em> bytes.
+                                       </div></dd></dl></div><div class="section" id="targetprettyprinting"><div class="titlepage"><div><div keep-together.within-column="always"><h4 class="title" id="targetprettyprinting">3.3.2.1. Pretty Printing Target Variables</h4></div></div></div><a id="id586373" class="indexterm"></a><div class="para">
+                               SystemTap scripts are often used to observe what is happening within the code. In many cases just printing the values of the various context variables is sufficient. SystemTap makes a number operations available that can generate printable strings for target variables:
+                       </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">$$vars</span></dt><dd><div class="para">
+                                                       Expands to a character string that is equivalent to <code class="command">sprintf("parm1=%x ... parmN=%x var1=%x ... varN=%x", parm1, ..., parmN, var1, ..., varN)</code> for each variable in scope at the probe point. Some values may be printed as <span class="quote">“<span class="quote"><code class="command">=?</code></span>”</span> if their run-time location cannot be found.
+                                               </div></dd><dt class="varlistentry"><span class="term">$$locals</span></dt><dd><div class="para">
+                                                       Expands to a subset of <code class="command">$$vars</code> containing only the local variables.
+                                               </div></dd><dt class="varlistentry"><span class="term">$$parms</span></dt><dd><div class="para">
+                                                       Expands to a subset of <code class="command">$$vars</code> containing only the function parameters.
+                                               </div></dd><dt class="varlistentry"><span class="term">$$return</span></dt><dd><div class="para">
+                                                       Is available in return probes only. It expands to a string that is equivalent to <code class="command">sprintf("return=%x", $return)</code> if the probed function has a return value, or else an empty string.
+                                               </div></dd></dl></div><div class="para">
+                               Below is a command-line script that prints the values of the parameters passed into the function <code class="command">vfs_read</code>:
+                       </div><pre class="programlisting">stap -e 'probe kernel.function("vfs_read") {printf("%s\n", $$parms); exit(); }'</pre><div class="para">
+                               There are four parameters passed into <code class="command">vfs_read</code>: <code class="command">file</code>, <code class="command">buf</code>, <code class="command">count</code>, and <code class="command">pos</code>. The <code class="command">$$parms</code> generates a string for the parameters passed into the function. In this case all but the <code class="command">count</code> parameter are pointers. The following is an example of the output from the previous command-line script:
+                       </div><pre class="programlisting">file=0xffff8800b40d4c80 buf=0x7fff634403e0 count=0x2004 pos=0xffff8800af96df48</pre><div class="para">
+                               Having the address a pointer points to may not be useful. You might be more interested in the fields of the data structure the pointer points to. You can use the the <span class="quote">“<span class="quote"><code class="command">$</code></span>”</span> suffix to pretty print the data structure. The following command-line example uses the pretty printing suffix to print more details about the data structures passed into the function <code class="command">vfs_read</code>:
+                       </div><pre class="programlisting">stap -e 'probe kernel.function("vfs_read") {printf("%s\n", $$parms$); exit(); }'</pre><div class="para">
+                               The previous command line will generate something similar to the following with the fields of the data structure included in the output:
+                       </div><pre class="programlisting">file={.f_u={...}, .f_path={...}, .f_op=0xffffffffa06e1d80, .f_lock={...}, .f_count={...}, .f_flags=34818, .f_mode=31, .f_pos=0, .f_owner={...}, .f_cred=0xffff88013148fc80, .f_ra={...}, .f_version=0, .f_security=0xffff8800b8dce560, .private_data=0x0, .f_ep_links={...}, .f_mapping=0xffff880037f8fdf8} buf="" count=8196 pos=-131938753921208</pre><div class="para">
+                               With the <span class="quote">“<span class="quote"><code class="command">$</code></span>”</span> suffix fields that are composed of data structures are not expanded. The <span class="quote">“<span class="quote"><code class="command">$$</code></span>”</span> suffix will print the values contained within the nested data structures. Below is an example using the <span class="quote">“<span class="quote"><code class="command">$$</code></span>”</span> suffix:
+                       </div><pre class="programlisting">stap -e 'probe kernel.function("vfs_read") {printf("%s\n", $$parms$$); exit(); }'</pre><div class="para">
+                               The <span class="quote">“<span class="quote"><code class="command">$$</code></span>”</span> suffix, like all strings, is limited to the maximum string size. Below is a represenative output from the previous command-line script, which is truncated because of the string size limit:
+                       </div><pre class="programlisting">file={.f_u={.fu_list={.next=0xffff8801336ca0e8, .prev=0xffff88012ded0840}, .fu_rcuhead={.next=0xffff8801336ca0e8, .func=0xffff88012ded0840}}, .f_path={.mnt=0xffff880132fc97c0, .dentry=0xffff88001a889cc0}, .f_op=0xffffffffa06f64c0, .f_lock={.raw_lock={.slock=196611}}, .f_count={.counter=2}, .f_flags=34818, .f_mode=31, .f_pos=0, .f_owner={.lock={.raw_lock={.lock=16777216}}, .pid=0x0, .pid_type=0, .uid=0, .euid=0, .signum=0}, .f_cred=0xffff880130129a80, .f_ra={.start=0, .size=0, .async_size=0, .ra_pages=32, .</pre></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="scriptconstructions.html"><strong>Prev</strong>3.3. Basic SystemTap Handler Constructs</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="typecasting.html"><strong>Next</strong>3.3.2.2. Typecasting</a></li></ul></body></html>
index 3c26ad0d4b8f4649cc5e24d91aa57d6e7d73b8a8..6561d5090f281a129636baaa0cb8b1938f1ed464 100644 (file)
@@ -1,20 +1,21 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3.3. Determining Time Spent in Kernel and User Space</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="prev" href="paracallgraph.html" title="4.3.2. Call Graph Tracing" /><link rel="next" href="timeoutssect.html" title="4.3.4. Monitoring Polling Applications" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="paracallgraph.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="timeoutssect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.3.3. Determining Time Spent in Kernel and User Space" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="threadtimessect">4.3.3. Determining Time Spent in Kernel and User Space</h3></div></div></div><a id="id584873" class="indexterm"></a><a id="id507727" class="indexterm"></a><a id="id584930" class="indexterm"></a><a id="id490342" class="indexterm"></a><a id="id533873" class="indexterm"></a><a id="id546070" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3.3. Determining Time Spent in Kernel and User Space</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="prev" href="paracallgraph.html" title="5.3.2. Call Graph Tracing" /><link rel="next" href="timeoutssect.html" title="5.3.4. Monitoring Polling Applications" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="paracallgraph.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="timeoutssect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="threadtimessect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="threadtimessect">5.3.3. Determining Time Spent in Kernel and User Space</h3></div></div></div><a id="id1933163" class="indexterm"></a><a id="id573009" class="indexterm"></a><a id="id486475" class="indexterm"></a><a id="id635437" class="indexterm"></a><a id="id652708" class="indexterm"></a><a id="id472095" class="indexterm"></a><div class="para">
                This section illustrates how to determine the amount of time any given thread is spending in either kernel or user-space.
-       </div><div class="formalpara"><h5 class="formalpara" id="threadtimes">thread-times.stp</h5>
+       </div><div class="formalpara" id="threadtimes"><h5 class="formalpara">thread-times.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/stap
+<pre class="programlisting">#! /usr/bin/env stap
 
-probe timer.profile {
-  tid=tid()
+probe perf.sw.cpu_clock!, timer.profile {
+  // NB: To avoid contention on SMP machines, no global scalars/arrays used,
+  // only contention-free statistics aggregates.
+  tid=tid(); e=execname()
   if (!user_mode())
-    kticks[tid] &lt;&lt;&lt; 1
+    kticks[e,tid] &lt;&lt;&lt; 1
   else
-    uticks[tid] &lt;&lt;&lt; 1
+    uticks[e,tid] &lt;&lt;&lt; 1
   ticks &lt;&lt;&lt; 1
-  tids[tid] &lt;&lt;&lt; 1
+  tids[e,tid] &lt;&lt;&lt; 1
 }
 
 global uticks, kticks, ticks
@@ -23,13 +24,13 @@ global tids
 
 probe timer.s(5), end {
   allticks = @count(ticks)
-  printf ("%5s %7s %7s (of %d ticks)\n",
-          "tid", "%user", "%kernel", allticks)
-  foreach (tid in tids- limit 20) {
-    uscaled = @count(uticks[tid])*10000/allticks
-    kscaled = @count(kticks[tid])*10000/allticks
-    printf ("%5d %3d.%02d%% %3d.%02d%%\n",
-      tid, uscaled/100, uscaled%100, kscaled/100, kscaled%100)
+  printf ("%16s %5s %7s %7s (of %d ticks)\n",
+          "comm", "tid", "%user", "%kernel", allticks)
+  foreach ([e,tid] in tids- limit 20) {
+    uscaled = @count(uticks[e,tid])*10000/allticks
+    kscaled = @count(kticks[e,tid])*10000/allticks
+    printf ("%16s %5d %3d.%02d%% %3d.%02d%%\n",
+      e, tid, uscaled/100, uscaled%100, kscaled/100, kscaled%100)
   }
   printf("\n")
 
@@ -38,14 +39,12 @@ probe timer.s(5), end {
   delete ticks
   delete tids
 }
-
 </pre>
-               </div><a id="id638003" class="indexterm"></a><a id="id638806" class="indexterm"></a><a id="id590478" class="indexterm"></a><div class="para">
-               <a class="xref" href="threadtimessect.html#threadtimes" title="thread-times.stp">thread-times.stp</a> lists the top 20 processes currently taking up CPU time within a 5-second sample, along with the total number of CPU ticks made during the sample. The output of this script also notes the percentage of CPU time each process used, as well as whether that time was spent in kernel space or user space.
+               </div><a id="id448717" class="indexterm"></a><a id="id615532" class="indexterm"></a><a id="id737806" class="indexterm"></a><div class="para">
+               <a class="xref" href="threadtimessect.html#threadtimes">thread-times.stp</a> lists the top 20 processes currently taking up CPU time within a 5-second sample, along with the total number of CPU ticks made during the sample. The output of this script also notes the percentage of CPU time each process used, as well as whether that time was spent in kernel space or user space.
        </div><div class="para">
-               <a class="xref" href="threadtimessect.html#threadtimesoutput" title="Example 4.15. thread-times.stp Sample Output">Example 4.15, “thread-times.stp Sample Output”</a> contains a 5-second sample of the output for <a class="xref" href="threadtimessect.html#threadtimes" title="thread-times.stp">thread-times.stp</a>:
-       </div><div class="example" id="threadtimesoutput"><div class="example-contents"><pre class="screen">
-  tid   %user %kernel (of 20002 ticks)
+               <a class="xref" href="threadtimessect.html#threadtimesoutput">Example 5.15, “thread-times.stp Sample Output”</a> contains a 5-second sample of the output for <a class="xref" href="threadtimessect.html#threadtimes">thread-times.stp</a>:
+       </div><div class="example" id="threadtimesoutput"><h6>Example 5.15. <a class="xref" href="threadtimessect.html#threadtimes">thread-times.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">  tid   %user %kernel (of 20002 ticks)
     0   0.00%  87.88%
 32169   5.24%   0.03%
  9815   3.33%   0.36%
@@ -65,5 +64,4 @@ probe timer.s(5), end {
  3883   0.00%   0.00%
  3775   0.00%   0.00%
  3943   0.00%   0.00%
- 3873   0.00%   0.00%
-</pre></div><h6>Example 4.15. <a class="xref" href="threadtimessect.html#threadtimes" title="thread-times.stp">thread-times.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="paracallgraph.html"><strong>Prev</strong>4.3.2. Call Graph Tracing</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="timeoutssect.html"><strong>Next</strong>4.3.4. Monitoring Polling Applications</a></li></ul></body></html>
+ 3873   0.00%   0.00%</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="paracallgraph.html"><strong>Prev</strong>5.3.2. Call Graph Tracing</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="timeoutssect.html"><strong>Next</strong>5.3.4. Monitoring Polling Applications</a></li></ul></body></html>
index 1f55f503424cfef1f5b54523593400bb412bd0ab..4639a702ff01078d72a3020a738cce0ece711fe7 100644 (file)
@@ -1,11 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3.4. Monitoring Polling Applications</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="prev" href="threadtimessect.html" title="4.3.3. Determining Time Spent in Kernel and User Space" /><link rel="next" href="topsyssect.html" title="4.3.5. Tracking Most Frequently Used System Calls" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="threadtimessect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="topsyssect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.3.4. Monitoring Polling Applications" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="timeoutssect">4.3.4. Monitoring Polling Applications</h3></div></div></div><a id="id587835" class="indexterm"></a><a id="id589229" class="indexterm"></a><a id="id643296" class="indexterm"></a><a id="id504491" class="indexterm"></a><div class="para">
-               This section how to identify and monitor which applications are polling. Doing so allows you to track unnecessary or excessive polling, which can help you pinpoint areas for improvement in terms of CPU usage and power savings.
-       </div><div class="formalpara"><h5 class="formalpara" id="timeouts">timeout.stp</h5>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3.4. Monitoring Polling Applications</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="prev" href="threadtimessect.html" title="5.3.3. Determining Time Spent in Kernel and User Space" /><link rel="next" href="topsyssect.html" title="5.3.5. Tracking Most Frequently Used System Calls" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="threadtimessect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="topsyssect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="timeoutssect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="timeoutssect">5.3.4. Monitoring Polling Applications</h3></div></div></div><a id="id508795" class="indexterm"></a><a id="id619646" class="indexterm"></a><a id="id1938273" class="indexterm"></a><a id="id693667" class="indexterm"></a><div class="para">
+               This section describes how to identify and monitor which applications are polling. Doing so allows you to track unnecessary or excessive polling, which can help you pinpoint areas for improvement in terms of CPU usage and power savings.
+       </div><div class="formalpara" id="timeouts"><h5 class="formalpara">timeout.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 # Copyright (C) 2009 Red Hat, Inc.
 # Written by Ulrich Drepper &lt;drepper@redhat.com&gt;
 # Modified by William Cohen &lt;wcohen@redhat.com&gt;
@@ -107,10 +106,9 @@ probe timer.s(1) {
               signal_timeout[p], process[p])
   }
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="timeoutssect.html#timeouts" title="timeout.stp">timeout.stp</a> tracks how many times each application used the following system calls over time:
+               <a class="xref" href="timeoutssect.html#timeouts">timeout.stp</a> tracks how many times each of the following system calls completed due to time expiring rather than due to an actual event occurring:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                <code class="command">poll</code>
                        </div></li><li class="listitem"><div class="para">
@@ -125,10 +123,7 @@ probe timer.s(1) {
                                <code class="command">nanosleep</code>
                        </div></li><li class="listitem"><div class="para">
                                <code class="command">signal</code>
-                       </div></li></ul></div><div class="para">
-               In some applications, these system calls are used excessively. As such, they are normally identified as "likely culprits" for polling applications. Note, however, that an application may be using a different system call to poll excessively; sometimes, it is useful to find out the top system calls used by the system (refer to <a class="xref" href="topsyssect.html" title="4.3.5. Tracking Most Frequently Used System Calls">Section 4.3.5, “Tracking Most Frequently Used System Calls”</a> for instructions). Doing so can help you identify any additional suspects, which you can add to <a class="xref" href="timeoutssect.html#timeouts" title="timeout.stp">timeout.stp</a> for tracking.
-       </div><a id="id645819" class="indexterm"></a><a id="id500561" class="indexterm"></a><a id="id524228" class="indexterm"></a><div class="example" id="timeoutsoutput"><div class="example-contents"><pre class="screen">
-  uid |   poll  select   epoll  itimer   futex nanosle  signal| process
+                       </div></li></ul></div><a id="id466448" class="indexterm"></a><a id="id581040" class="indexterm"></a><a id="id496115" class="indexterm"></a><div class="example" id="timeoutsoutput"><h6>Example 5.16. <a class="xref" href="timeoutssect.html#timeouts">timeout.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">  uid |   poll  select   epoll  itimer   futex nanosle  signal| process
 28937 | 148793       0       0    4727   37288       0       0| firefox
 22945 |      0   56949       0       1       0       0       0| scim-bridge
     0 |      0       0       0   36414       0       0       0| swapper
@@ -148,7 +143,6 @@ probe timer.s(1) {
  4248 |   1591       0       0       0       0       0       0| nm-applet
  3165 |      0    1441       0       0       0       0       0| xterm
 29548 |      0    1440       0       0       0       0       0| httpd
- 1862 |      0       0       0       0       0    1438       0| iscsid
-</pre></div><h6>Example 4.16. <a class="xref" href="timeoutssect.html#timeouts" title="timeout.stp">timeout.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
-               You can increase the sample time by editing the timer in the second probe (<code class="command">timer.s()</code>). The output of <a class="xref" href="mainsect-profiling.html#countcalls" title="functioncallcount.stp">functioncallcount.stp</a> contains the name and UID of the top 20 polling applications, along with how many times each application performed each polling system call (over time). <a class="xref" href="timeoutssect.html#timeoutsoutput" title="Example 4.16. timeout.stp Sample Output">Example 4.16, “timeout.stp Sample Output”</a> contains an excerpt of the script:
-       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="threadtimessect.html"><strong>Prev</strong>4.3.3. Determining Time Spent in Kernel and User ...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="topsyssect.html"><strong>Next</strong>4.3.5. Tracking Most Frequently Used System Calls</a></li></ul></body></html>
+ 1862 |      0       0       0       0       0    1438       0| iscsid</pre></div></div><br class="example-break" /><div class="para">
+               You can increase the sample time by editing the second probe (<code class="command">timer.s(1)</code>). The output of <a class="xref" href="timeoutssect.html#timeouts">timeout.stp</a> contains the name and UID of the top 20 polling applications, along with how many times each application performed each polling system call (over time). <a class="xref" href="timeoutssect.html#timeoutsoutput">Example 5.16, “timeout.stp Sample Output”</a> contains an excerpt of the script. In this particular example firefox is doing an excessive amount of polling due to a plugin module.
+       </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="threadtimessect.html"><strong>Prev</strong>5.3.3. Determining Time Spent in Kernel and User ...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="topsyssect.html"><strong>Next</strong>5.3.5. Tracking Most Frequently Used System Calls</a></li></ul></body></html>
index 7496760a22d8b98a61f3ee94915ce9ffbc424a06..b6356fe8a4c4992af369f0de656c29566eb01503 100644 (file)
@@ -1,27 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3.5. Tracking Most Frequently Used System Calls</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="4.3. Profiling" /><link rel="prev" href="timeoutssect.html" title="4.3.4. Monitoring Polling Applications" /><link rel="next" href="syscallsbyprocpidsect.html" title="4.3.6. Tracking System Call Volume Per Process" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="timeoutssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="syscallsbyprocpidsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.3.5. Tracking Most Frequently Used System Calls" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="topsyssect">4.3.5. Tracking Most Frequently Used System Calls</h3></div></div></div><a id="id644601" class="indexterm"></a><a id="id507101" class="indexterm"></a><a id="id601169" class="indexterm"></a><a id="id541719" class="indexterm"></a><div class="para">
-               <a class="xref" href="timeoutssect.html#timeouts" title="timeout.stp">timeout.stp</a> from <a class="xref" href="timeoutssect.html" title="4.3.4. Monitoring Polling Applications">Section 4.3.4, “Monitoring Polling Applications”</a> helps you identify which applications are polling by pointing out which ones used the following system calls most frequently:
-       </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
-                               <code class="command">poll</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">select</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">epoll</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">itimer</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">futex</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">nanosleep</code>
-                       </div></li><li class="listitem"><div class="para">
-                               <code class="command">signal</code>
-                       </div></li></ul></div><div class="para">
-               However, in some systems, a different system call might be responsible for excessive polling. If you suspect that a polling application might is using a different system call to poll, you need to identify first the top system calls used by the system. To do this, use <a class="xref" href="topsyssect.html#topsys" title="topsys.stp">topsys.stp</a>.
-       </div><div class="formalpara"><h5 class="formalpara" id="topsys">topsys.stp</h5>
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.3.5. Tracking Most Frequently Used System Calls</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-profiling.html" title="5.3. Profiling" /><link rel="prev" href="timeoutssect.html" title="5.3.4. Monitoring Polling Applications" /><link rel="next" href="syscallsbyprocpidsect.html" title="5.3.6. Tracking System Call Volume Per Process" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="timeoutssect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="syscallsbyprocpidsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="topsyssect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="topsyssect">5.3.5. Tracking Most Frequently Used System Calls</h3></div></div></div><a id="id570680" class="indexterm"></a><a id="id582476" class="indexterm"></a><a id="id1942941" class="indexterm"></a><a id="id1908636" class="indexterm"></a><div class="para">
+               <a class="xref" href="timeoutssect.html#timeouts">timeout.stp</a> from <a class="xref" href="timeoutssect.html">Section 5.3.4, “Monitoring Polling Applications”</a> helps you identify which applications are polling by examining a small subset of system calls ( <code class="command">poll</code>, <code class="command">select</code>, <code class="command">epoll</code>, <code class="command">itimer</code>, <code class="command">futex</code>, <code class="command">nanosleep</code>, and <code class="command">signal</code>). However, in some systems, an excessive number of system calls outside that small subset might be responsible for time spent in the kernel. If you suspect that an application is using system calls excessively, you need to identify the most frequently used system calls on the system. To do this, use <a class="xref" href="topsyssect.html#topsys">topsys.stp</a>.
+       </div><div class="formalpara" id="topsys"><h5 class="formalpara">topsys.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 #
 # This script continuously lists the top 20 systemcalls in the interval 
 # 5 seconds
@@ -45,12 +28,10 @@ probe timer.s(5) {
   print_systop ()
   printf("--------------------------------------------------------------\n")
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="topsyssect.html#topsys" title="topsys.stp">topsys.stp</a> lists the top 20 system calls used by the system per 5-second interval. It also lists how many times each system call was used during that period. Refer to <a class="xref" href="topsyssect.html#topsysoutput" title="Example 4.17. topsys.stp Sample Output">Example 4.17, “topsys.stp Sample Output”</a> for a sample output.
-       </div><a id="id644057" class="indexterm"></a><a id="id509782" class="indexterm"></a><a id="id648673" class="indexterm"></a><div class="example" id="topsysoutput"><div class="example-contents"><pre class="screen">
---------------------------------------------------------------
+               <a class="xref" href="topsyssect.html#topsys">topsys.stp</a> lists the top 20 system calls used by the system per 5-second interval. It also lists how many times each system call was used during that period. Refer to <a class="xref" href="topsyssect.html#topsysoutput">Example 5.17, “topsys.stp Sample Output”</a> for a sample output.
+       </div><a id="id579766" class="indexterm"></a><a id="id1946272" class="indexterm"></a><a id="id1913996" class="indexterm"></a><div class="example" id="topsysoutput"><h6>Example 5.17. <a class="xref" href="topsyssect.html#topsys">topsys.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">--------------------------------------------------------------
                   SYSCALL      COUNT
              gettimeofday       1857
                      read       1821
@@ -72,5 +53,4 @@ probe timer.s(5) {
                      time         81
                 sigreturn         72
                     fstat         66
---------------------------------------------------------------
-</pre></div><h6>Example 4.17. <a class="xref" href="topsyssect.html#topsys" title="topsys.stp">topsys.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="timeoutssect.html"><strong>Prev</strong>4.3.4. Monitoring Polling Applications</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="syscallsbyprocpidsect.html"><strong>Next</strong>4.3.6. Tracking System Call Volume Per Process</a></li></ul></body></html>
+--------------------------------------------------------------</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="timeoutssect.html"><strong>Prev</strong>5.3.4. Monitoring Polling Applications</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="syscallsbyprocpidsect.html"><strong>Next</strong>5.3.6. Tracking System Call Volume Per Process</a></li></ul></body></html>
index b8629c14b0ba54dcb9982d6eb2879975654cdf60..c4a76e5ecc1332518fcd7f04682c5e19a1d7a7d4 100644 (file)
@@ -1,11 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.4. I/O Monitoring (By Device)</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="traceiosect.html" title="4.2.3. Track Cumulative IO" /><link rel="next" href="inodewatchsect.html" title="4.2.5. Monitoring Reads and Writes to a File" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="traceiosect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="inodewatchsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.4. I/O Monitoring (By Device)" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="traceio2sect">4.2.4. I/O Monitoring (By Device)</h3></div></div></div><a id="id608365" class="indexterm"></a><a id="id648515" class="indexterm"></a><a id="id490877" class="indexterm"></a><a id="id638631" class="indexterm"></a><a id="id598042" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.4. I/O Monitoring (By Device)</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="traceiosect.html" title="5.2.3. Track Cumulative IO" /><link rel="next" href="inodewatchsect.html" title="5.2.5. Monitoring Reads and Writes to a File" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="traceiosect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="inodewatchsect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="traceio2sect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="traceio2sect">5.2.4. I/O Monitoring (By Device)</h3></div></div></div><a id="id603144" class="indexterm"></a><a id="id573701" class="indexterm"></a><a id="id583259" class="indexterm"></a><a id="id582108" class="indexterm"></a><a id="id671785" class="indexterm"></a><div class="para">
                This section describes how to monitor I/O activity on a specific device.
-       </div><div class="formalpara"><h5 class="formalpara" id="traceio2">traceio2.stp</h5>
+       </div><div class="formalpara" id="traceio2"><h5 class="formalpara">traceio2.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 global device_of_interest
 
@@ -24,22 +23,19 @@ probe vfs.write, vfs.read
     printf ("%s(%d) %s 0x%x\n",
             execname(), pid(), probefunc(), dev)
 }
-
 </pre>
-               </div><a id="id605956" class="indexterm"></a><a id="id637505" class="indexterm"></a><a id="id613080" class="indexterm"></a><a id="id590467" class="indexterm"></a><a id="id657809" class="indexterm"></a><a id="id491924" class="indexterm"></a><div class="para">
-               <a class="xref" href="traceio2sect.html#traceio2" title="traceio2.stp">traceio2.stp</a> takes 1 argument: the whole device number. To get this number, use <code class="command">stat -c "0x%D" <em class="replaceable"><code>directory</code></em></code>, where <code class="command"><em class="replaceable"><code>directory</code></em></code> is located in the device you wish to monitor.
-       </div><a id="id538748" class="indexterm"></a><a id="id588481" class="indexterm"></a><a id="id528919" class="indexterm"></a><div class="para">
+               </div><a id="id658396" class="indexterm"></a><a id="id580036" class="indexterm"></a><a id="id702568" class="indexterm"></a><a id="id1961215" class="indexterm"></a><a id="id408637" class="indexterm"></a><a id="id1963221" class="indexterm"></a><div class="para">
+               <a class="xref" href="traceio2sect.html#traceio2">traceio2.stp</a> takes 1 argument: the whole device number. To get this number, use <code class="command">stat -c "0x%D" <em class="replaceable"><code>directory</code></em></code>, where <code class="command"><em class="replaceable"><code>directory</code></em></code> is located in the device you wish to monitor.
+       </div><a id="id414754" class="indexterm"></a><a id="id656037" class="indexterm"></a><a id="id574112" class="indexterm"></a><div class="para">
                The <code class="command">usrdev2kerndev()</code> function converts the whole device number into the format understood by the kernel. The output produced by <code class="command">usrdev2kerndev()</code> is used in conjunction with the <code class="command">MKDEV()</code>, <code class="command">MINOR()</code>, and <code class="command">MAJOR()</code> functions to determine the major and minor numbers of a specific device.
        </div><div class="para">
-               The output of <a class="xref" href="traceio2sect.html#traceio2" title="traceio2.stp">traceio2.stp</a> includes the name and ID of any process performing a read/write, the function it is performing (i.e. <code class="command">vfs_read</code> or <code class="command">vfs_write</code>), and the kernel device number.
+               The output of <a class="xref" href="traceio2sect.html#traceio2">traceio2.stp</a> includes the name and ID of any process performing a read/write, the function it is performing (i.e. <code class="command">vfs_read</code> or <code class="command">vfs_write</code>), and the kernel device number.
        </div><div class="para">
                The following example is an excerpt from the full output of <code class="command">stap traceio2.stp 0x805</code>, where <code class="literal">0x805</code> is the whole device number of <code class="filename">/home</code>. <code class="filename">/home</code> resides in <code class="filename">/dev/sda5</code>, which is the device we wish to monitor.
-       </div><div class="example" id="traceio2output"><div class="example-contents"><pre class="screen">
-[...]
+       </div><div class="example" id="traceio2output"><h6>Example 5.9. <a class="xref" href="traceio2sect.html#traceio2">traceio2.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 synergyc(3722) vfs_read 0x800005
 synergyc(3722) vfs_read 0x800005
 cupsd(2889) vfs_write 0x800005
 cupsd(2889) vfs_write 0x800005
 cupsd(2889) vfs_write 0x800005
-[...]
-</pre></div><h6>Example 4.9. <a class="xref" href="traceio2sect.html#traceio2" title="traceio2.stp">traceio2.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="traceiosect.html"><strong>Prev</strong>4.2.3. Track Cumulative IO</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="inodewatchsect.html"><strong>Next</strong>4.2.5. Monitoring Reads and Writes to a File</a></li></ul></body></html>
+[...]</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="traceiosect.html"><strong>Prev</strong>5.2.3. Track Cumulative IO</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="inodewatchsect.html"><strong>Next</strong>5.2.5. Monitoring Reads and Writes to a File</a></li></ul></body></html>
index ec098f20a5298941cb1e6e3b4adf01b28772fe0a..81c8943206a111a04e96364365ee4b0aebc06244 100644 (file)
@@ -1,11 +1,10 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2.3. Track Cumulative IO</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="4.2. Disk" /><link rel="prev" href="iotimesect.html" title="4.2.2. Tracking I/O Time For Each File Read or Write" /><link rel="next" href="traceio2sect.html" title="4.2.4. I/O Monitoring (By Device)" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="iotimesect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="traceio2sect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" title="4.2.3. Track Cumulative IO" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="traceiosect">4.2.3. Track Cumulative IO</h3></div></div></div><a id="id596722" class="indexterm"></a><a id="id511362" class="indexterm"></a><a id="id506483" class="indexterm"></a><a id="id594903" class="indexterm"></a><a id="id507061" class="indexterm"></a><a id="id539121" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>5.2.3. Track Cumulative IO</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="mainsect-disk.html" title="5.2. Disk" /><link rel="prev" href="iotimesect.html" title="5.2.2. Tracking I/O Time For Each File Read or Write" /><link rel="next" href="traceio2sect.html" title="5.2.4. I/O Monitoring (By Device)" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="iotimesect.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="traceio2sect.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="section" id="traceiosect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="traceiosect">5.2.3. Track Cumulative IO</h3></div></div></div><a id="id699014" class="indexterm"></a><a id="id608343" class="indexterm"></a><a id="id491003" class="indexterm"></a><a id="id550702" class="indexterm"></a><a id="id1933263" class="indexterm"></a><a id="id494252" class="indexterm"></a><div class="para">
                This section describes how to track the cumulative amount of I/O to the system.
-       </div><div class="formalpara"><h5 class="formalpara" id="traceio">traceio.stp</h5>
+       </div><div class="formalpara" id="traceio"><h5 class="formalpara">traceio.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 # traceio.stp
 # Copyright (C) 2007 Red Hat, Inc., Eugene Teo &lt;eteo@redhat.com&gt;
 # Copyright (C) 2009 Kai Meyer &lt;kai@unixlords.com&gt;
@@ -50,14 +49,12 @@ probe timer.s(1) {
   # Note we don't zero out reads, writes and total_io,
   # so the values are cumulative since the script started.
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="traceiosect.html#traceio" title="traceio.stp">traceio.stp</a> prints the top ten executables generating I/O traffic over time. In addition, it also tracks the cumulative amount of I/O reads and writes done by those ten executables. This information is tracked and printed out in 1-second intervals, and in descending order.
-       </div><a id="id529910" class="indexterm"></a><a id="id613095" class="indexterm"></a><a id="id597672" class="indexterm"></a><div class="para">
-               Note that <a class="xref" href="traceiosect.html#traceio" title="traceio.stp">traceio.stp</a> also uses the local variable <code class="command">$return</code>, which is also used by <a class="xref" href="mainsect-disk.html#scriptdisktop" title="disktop.stp">disktop.stp</a> from <a class="xref" href="mainsect-disk.html#disktop" title="4.2.1. Summarizing Disk Read/Write Traffic">Section 4.2.1, “Summarizing Disk Read/Write Traffic”</a>.
-       </div><div class="example" id="traceiooutput"><div class="example-contents"><pre class="screen">
-[...]
+               <a class="xref" href="traceiosect.html#traceio">traceio.stp</a> prints the top ten executables generating I/O traffic over time. In addition, it also tracks the cumulative amount of I/O reads and writes done by those ten executables. This information is tracked and printed out in 1-second intervals, and in descending order.
+       </div><a id="id645638" class="indexterm"></a><a id="id712158" class="indexterm"></a><a id="id639084" class="indexterm"></a><div class="para">
+               Note that <a class="xref" href="traceiosect.html#traceio">traceio.stp</a> also uses the local variable <code class="command">$return</code>, which is also used by <a class="xref" href="mainsect-disk.html#scriptdisktop">disktop.stp</a> from <a class="xref" href="mainsect-disk.html#disktop">Section 5.2.1, “Summarizing Disk Read/Write Traffic”</a>.
+       </div><div class="example" id="traceiooutput"><h6>Example 5.8. <a class="xref" href="traceiosect.html#traceio">traceio.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
            Xorg r:   583401 KiB w:        0 KiB
        floaters r:       96 KiB w:     7130 KiB
 multiload-apple r:      538 KiB w:      537 KiB
@@ -78,5 +75,4 @@ pam_timestamp_c r:      138 KiB w:        0 KiB
           snmpd r:       46 KiB w:        0 KiB
           pcscd r:       28 KiB w:        0 KiB
      irqbalance r:       27 KiB w:        4 KiB
-          cupsd r:        4 KiB w:       18 KiB
-</pre></div><h6>Example 4.8. <a class="xref" href="traceiosect.html#traceio" title="traceio.stp">traceio.stp</a> Sample Output</h6></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="iotimesect.html"><strong>Prev</strong>4.2.2. Tracking I/O Time For Each File Read or Wr...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="traceio2sect.html"><strong>Next</strong>4.2.4. I/O Monitoring (By Device)</a></li></ul></body></html>
+          cupsd r:        4 KiB w:       18 KiB</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="iotimesect.html"><strong>Prev</strong>5.2.2. Tracking I/O Time For Each File Read or Wr...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="traceio2sect.html"><strong>Next</strong>5.2.4. I/O Monitoring (By Device)</a></li></ul></body></html>
diff --git a/SystemTap_Beginners_Guide/typecasting.html b/SystemTap_Beginners_Guide/typecasting.html
new file mode 100644 (file)
index 0000000..5aa3a41
--- /dev/null
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.3.2.2. Typecasting</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="targetvariables.html" title="3.3.2. Target Variables" /><link rel="prev" href="targetvariables.html" title="3.3.2. Target Variables" /><link rel="next" href="targetavailable.html" title="3.3.2.3. Checking Target Variable Availablility" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="targetvariables.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="targetavailable.html"><strong>Next</strong></a></li></ul><div class="section" id="typecasting"><div class="titlepage"><div><div keep-together.within-column="always"><h4 class="title" id="typecasting">3.3.2.2. Typecasting</h4></div></div></div><a id="id439623" class="indexterm"></a><div class="para">
+                               In most cases SystemTap can determine a variable's type from the debug information. However, code may use void pointers for variables (for example memory allocation routines) and typing information is not available. Also the typing information available within a probe handler is not available within a function; SystemTap functions arguments use a long in place of a typed pointer. SystemTap's <code class="command">@cast</code> operator (first available in SystemTap 0.9) can be used to indicate the correct type of the object.
+                       </div><div class="para">
+                               The <a class="xref" href="typecasting.html#casting">Example 3.9, “Casting Example”</a> is from the <code class="command">task.stp</code> tapset. The function returns the value of the <code class="command">state</code> field from a <code class="command">task_struct</code> pointed to by the long <code class="command">task</code>. The first argument of the <code class="command">@cast</code> operator, <code class="command">task</code>, is the pointer to the object. The second argument is the type to cast the object to, <code class="command">task_struct</code>. The third arument lists what file that the type definition information comes from and is optional. With the <code class="command">@cast</code> operator the various fields of this particular <code class="command">task_struct</code> <code class="command">task</code> can be accessed; in this example the <code class="command">state</code> field is obtained.
+                       </div><div class="example" id="casting"><h6>Example 3.9. Casting Example</h6><div class="example-contents"><pre class="programlisting">function task_state:long (task:long)
+{
+    return @cast(task, "task_struct", "kernel&lt;linux/sched.h&gt;")-&gt;state
+}
+</pre></div></div><br class="example-break" /></div><ul class="docnav"><li class="previous"><a accesskey="p" href="targetvariables.html"><strong>Prev</strong>3.3.2. Target Variables</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="targetavailable.html"><strong>Next</strong>3.3.2.3. Checking Target Variable Availablility</a></li></ul></body></html>
index 5d865ce4553d96cf9fda04ad520f03ce93bdb222..e29d79f40a7f196107ae1b3fba1c5d3b78ea6ed3 100644 (file)
@@ -1,22 +1,22 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 3. Understanding How SystemTap Works</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="using-usage.html" title="2.3. Running SystemTap Scripts" /><link rel="next" href="scripts.html" title="3.2. SystemTap Scripts" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="using-usage.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="scripts.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 3. Understanding How SystemTap Works" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="understanding-how-systemtap-works">Chapter 3. Understanding How SystemTap Works</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="understanding-how-systemtap-works.html#understanding-architecture-tools">3.1. Architecture</a></span></dt><dt><span class="section"><a href="scripts.html">3.2. SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="scripts.html#systemtapscript-events">3.2.1. Event</a></span></dt><dt><span class="section"><a href="systemtapscript-handler.html">3.2.2. Systemtap Handler/Body</a></span></dt></dl></dd><dt><span class="section"><a href="scriptconstructions.html">3.3. Basic SystemTap Handler Constructs</a></span></dt><dd><dl><dt><span class="section"><a href="scriptconstructions.html#variablesconstructs">3.3.1. Variables</a></span></dt><dt><span class="section"><a href="handlerconditionalstatements.html">3.3.2. Conditional Statements</a></span></dt><dt><span class="section"><a href="commandlineargssect.html">3.3.3. Command-Line Arguments</a></span></dt></dl></dd><dt><span class="section"><a href="associativearrays.html">3.4. Associative Arrays</a></span></dt><dt><span class="section"><a href="arrayoperators.html">3.5. Array Operations in SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="arrayoperators.html#arrayops-assignvalue">3.5.1. Assigning an Associated Value</a></span></dt><dt><span class="section"><a href="arrayops-readvalues.html">3.5.2. Reading Values From Arrays</a></span></dt><dt><span class="section"><a href="arrayops-increment.html">3.5.3. Incrementing Associated Values</a></span></dt><dt><span class="section"><a href="arrayops-foreach.html">3.5.4. Processing Multiple Elements in an Array</a></span></dt><dt><span class="section"><a href="arrayops-deleting.html">3.5.5. Clearing/Deleting Arrays and Array Elements</a></span></dt><dt><span class="section"><a href="arrayops-conditionals.html">3.5.6. Using Arrays in Conditional Statements</a></span></dt><dt><span class="section"><a href="arrayops-aggregates.html">3.5.7. Computing for Statistical Aggregates</a></span></dt></dl></dd><dt><span class="section"><a href="understanding-tapsets.html">3.6. Tapsets</a></span></dt></dl></div><a id="id632901" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 3. Understanding How SystemTap Works</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="using-usage.html" title="2.3. Running SystemTap Scripts" /><link rel="next" href="scripts.html" title="3.2. SystemTap Scripts" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="using-usage.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="scripts.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="understanding-how-systemtap-works" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 3. Understanding How SystemTap Works</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="understanding-how-systemtap-works.html#understanding-architecture-tools">3.1. Architecture</a></span></dt><dt><span class="section"><a href="scripts.html">3.2. SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="scripts.html#systemtapscript-events">3.2.1. Event</a></span></dt><dt><span class="section"><a href="systemtapscript-handler.html">3.2.2. Systemtap Handler/Body</a></span></dt></dl></dd><dt><span class="section"><a href="scriptconstructions.html">3.3. Basic SystemTap Handler Constructs</a></span></dt><dd><dl><dt><span class="section"><a href="scriptconstructions.html#variablesconstructs">3.3.1. Variables</a></span></dt><dt><span class="section"><a href="targetvariables.html">3.3.2. Target Variables</a></span></dt><dt><span class="section"><a href="handlerconditionalstatements.html">3.3.3. Conditional Statements</a></span></dt><dt><span class="section"><a href="commandlineargssect.html">3.3.4. Command-Line Arguments</a></span></dt></dl></dd><dt><span class="section"><a href="associativearrays.html">3.4. Associative Arrays</a></span></dt><dt><span class="section"><a href="arrayoperators.html">3.5. Array Operations in SystemTap</a></span></dt><dd><dl><dt><span class="section"><a href="arrayoperators.html#arrayops-assignvalue">3.5.1. Assigning an Associated Value</a></span></dt><dt><span class="section"><a href="arrayops-readvalues.html">3.5.2. Reading Values From Arrays</a></span></dt><dt><span class="section"><a href="arrayops-increment.html">3.5.3. Incrementing Associated Values</a></span></dt><dt><span class="section"><a href="arrayops-foreach.html">3.5.4. Processing Multiple Elements in an Array</a></span></dt><dt><span class="section"><a href="arrayops-deleting.html">3.5.5. Clearing/Deleting Arrays and Array Elements</a></span></dt><dt><span class="section"><a href="arrayops-conditionals.html">3.5.6. Using Arrays in Conditional Statements</a></span></dt><dt><span class="section"><a href="arrayops-aggregates.html">3.5.7. Computing for Statistical Aggregates</a></span></dt></dl></dd><dt><span class="section"><a href="understanding-tapsets.html">3.6. Tapsets</a></span></dt></dl></div><a id="id658915" class="indexterm"></a><div class="para">
                SystemTap allows users to write and reuse simple scripts to deeply examine the activities of a running Linux system. These scripts can be designed to extract data, filter it, and summarize it quickly (and safely), enabling the diagnosis of complex performance (or even functional) problems.
-       </div><a id="id632891" class="indexterm"></a><a id="id632878" class="indexterm"></a><a id="id632850" class="indexterm"></a><div class="para">
+       </div><a id="id658903" class="indexterm"></a><a id="id658888" class="indexterm"></a><a id="id658863" class="indexterm"></a><div class="para">
                The essential idea behind a SystemTap script is to name <span class="emphasis"><em>events</em></span>, and to give them <span class="emphasis"><em>handlers</em></span>. When SystemTap runs the script, SystemTap monitors for the event; once the event occurs, the Linux kernel then runs the handler as a quick sub-routine, then resumes.
-       </div><a id="id632841" class="indexterm"></a><a id="id632819" class="indexterm"></a><div class="para">
+       </div><a id="id658848" class="indexterm"></a><a id="id658839" class="indexterm"></a><div class="para">
                There are several kind of events; entering/exiting a function, timer expiration, session termination, etc. A handler is a series of script language statements that specify the work to be done whenever the event occurs. This work normally includes extracting data from the event context, storing them into internal variables, and printing results.
-       </div><div class="section" title="3.1. Architecture"><div class="titlepage"><div><div><h2 class="title" id="understanding-architecture-tools">3.1. Architecture</h2></div></div></div><a id="id632802" class="indexterm"></a><a id="id632778" class="indexterm"></a><a id="id632784" class="indexterm"></a><div class="para">
+       </div><div class="section" id="understanding-architecture-tools"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="understanding-architecture-tools">3.1. Architecture</h2></div></div></div><a id="id658802" class="indexterm"></a><a id="id658790" class="indexterm"></a><a id="id658782" class="indexterm"></a><div class="para">
                        A SystemTap session begins when you run a SystemTap script. This session occurs in the following fashion:
-               </div><div class="procedure" id="systemtapsession"><h6>Procedure 3.1. SystemTap Session</h6><a id="id632764" class="indexterm"></a><a id="id632753" class="indexterm"></a><a id="id632746" class="indexterm"></a><ol class="1"><li class="step" title="Step 1"><div class="para">
+               </div><div class="procedure" id="systemtapsession"><h6>Procedure 3.1. SystemTap Session</h6><a id="id526630" class="indexterm"></a><a id="id526622" class="indexterm"></a><a id="id526598" class="indexterm"></a><ol class="1"><li class="step"><div class="para">
                                        First, SystemTap checks the script against the existing tapset library (normally in <code class="filename">/usr/share/systemtap/tapset/</code> for any tapsets used. SystemTap will then substitute any located tapsets with their corresponding definitions in the tapset library.
-                               </div></li><li class="step" title="Step 2"><div class="para">
-                                       SystemTap then translates the script to C, running the system C compiler to create a kernel module from it. The tools that perform this step are contained in the <code class="filename">systemtap</code> package (refer to <a class="xref" href="using-systemtap.html#installproper" title="2.1.1. Installing SystemTap">Section 2.1.1, “Installing SystemTap”</a> for more information).
-                               </div></li><li class="step" title="Step 3"><div class="para">
-                                       SystemTap loads the module, then enables all the probes (events and handlers) in the script. The <code class="command">staprun</code> in the <code class="filename">systemtap-runtime</code> package (refer to <a class="xref" href="using-systemtap.html#installproper" title="2.1.1. Installing SystemTap">Section 2.1.1, “Installing SystemTap”</a> for more information) provides this functionality.
-                               </div></li><li class="step" title="Step 4"><div class="para">
+                               </div></li><li class="step"><div class="para">
+                                       SystemTap then translates the script to C, running the system C compiler to create a kernel module from it. The tools that perform this step are contained in the <code class="filename">systemtap</code> package (refer to <a class="xref" href="using-systemtap.html#installproper">Section 2.1.1, “Installing SystemTap”</a> for more information).
+                               </div></li><li class="step"><div class="para">
+                                       SystemTap loads the module, then enables all the probes (events and handlers) in the script. The <code class="command">staprun</code> in the <code class="filename">systemtap-runtime</code> package (refer to <a class="xref" href="using-systemtap.html#installproper">Section 2.1.1, “Installing SystemTap”</a> for more information) provides this functionality.
+                               </div></li><li class="step"><div class="para">
                                        As the events occur, their corresponding handlers are executed.
-                               </div></li><li class="step" title="Step 5"><div class="para">
+                               </div></li><li class="step"><div class="para">
                                        Once the SystemTap session is terminated, the probes are disabled, and the kernel module is unloaded.
                                </div></li></ol></div><div class="para">
                        This sequence is driven from a single command-line program: <code class="command">stap</code>. This program is SystemTap's main front-end tool. For more information about <code class="command">stap</code>, refer to <code class="command">man stap</code> (once SystemTap is properly installed on your machine).
index 543ed5523d68c5aef378d178a5879acf3ad7ff6e..13e3d28a73be08b4b11f22e0bf73924c73ae07c7 100644 (file)
@@ -1,11 +1,11 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.6. Tapsets</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="arrayops-aggregates.html" title="3.5.7. Computing for Statistical Aggregates" /><link rel="next" href="useful-systemtap-scripts.html" title="Chapter 4. Useful SystemTap Scripts" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-aggregates.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="useful-systemtap-scripts.html"><strong>Next</strong></a></li></ul><div class="section" title="3.6. Tapsets"><div class="titlepage"><div><div><h2 class="title" id="understanding-tapsets">3.6. Tapsets</h2></div></div></div><a id="id489862" class="indexterm"></a><div class="para">
-                       <em class="firstterm">Tapsets</em> are scripts that form a library of pre-written probes and functions to be used in SystemTap scripts. When a user runs a SystemTap script, SystemTap checks the script's probe events and handlers against the tapset library; SystemTap then loads the corresponding probes and functions before translating the script to C (refer to <a class="xref" href="understanding-how-systemtap-works.html#understanding-architecture-tools" title="3.1. Architecture">Section 3.1, “Architecture”</a> for information on what transpires in a SystemTap session).
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>3.6. Tapsets</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /><link rel="prev" href="arrayops-aggregates.html" title="3.5.7. Computing for Statistical Aggregates" /><link rel="next" href="userspace-probing.html" title="Chapter 4. User-Space Probing" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-aggregates.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="userspace-probing.html"><strong>Next</strong></a></li></ul><div class="section" id="understanding-tapsets"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="understanding-tapsets">3.6. Tapsets</h2></div></div></div><a id="id592566" class="indexterm"></a><div class="para">
+                       <em class="firstterm">Tapsets</em> are scripts that form a library of pre-written probes and functions to be used in SystemTap scripts. When a user runs a SystemTap script, SystemTap checks the script's probe events and handlers against the tapset library; SystemTap then loads the corresponding probes and functions before translating the script to C (refer to <a class="xref" href="understanding-how-systemtap-works.html#understanding-architecture-tools">Section 3.1, “Architecture”</a> for information on what transpires in a SystemTap session).
                </div><div class="para">
-                       Like SystemTap scripts, tapsets use the filename extension <code class="filename">.stp</code>. The standard library of tapsets is located in <code class="filename">/usr/share/systemtap/tapset/</code> by default. However, unlike SystemTap scripts, tapsets are not meant for direct execution; rather, they constitute the library from which other scripts can pull definitions.
+                       Like SystemTap scripts, tapsets use the file name extension <code class="filename">.stp</code>. The standard library of tapsets is located in <code class="filename">/usr/share/systemtap/tapset/</code> by default. However, unlike SystemTap scripts, tapsets are not meant for direct execution; rather, they constitute the library from which other scripts can pull definitions.
                </div><div class="para">
                        Simply put, the tapset library is an abstraction layer designed to make it easier for users to define events and functions. In a manner of speaking, tapsets provide useful aliases for functions that users may want to specify as an event; knowing the proper alias to use is, for the most part, easier than remembering specific kernel functions that might vary between kernel versions.
                </div><div class="para">
-                       Several handlers and functions in <a class="xref" href="scripts.html#systemtapscript-events" title="3.2.1. Event">Section 3.2.1, “Event”</a> and <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a> are defined in tapsets. For example, <code class="command">thread_indent()</code> is defined in <code class="filename">indent.stp</code>.
-               </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-aggregates.html"><strong>Prev</strong>3.5.7. Computing for Statistical Aggregates</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="useful-systemtap-scripts.html"><strong>Next</strong>Chapter 4. Useful SystemTap Scripts</a></li></ul></body></html>
+                       Several handlers and functions in <a class="xref" href="scripts.html#systemtapscript-events">Section 3.2.1, “Event”</a> and <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a> are defined in tapsets. For example, <code class="command">thread_indent()</code> is defined in <code class="filename">indent.stp</code>.
+               </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="arrayops-aggregates.html"><strong>Prev</strong>3.5.7. Computing for Statistical Aggregates</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="userspace-probing.html"><strong>Next</strong>Chapter 4. User-Space Probing</a></li></ul></body></html>
index c6e8d400175255f99725c2b248c1c2f902faaa06..a940ca271237af22c2a7c461036b90df6566d931 100644 (file)
@@ -1,15 +1,14 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 4. Useful SystemTap Scripts</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="understanding-tapsets.html" title="3.6. Tapsets" /><link rel="next" href="mainsect-disk.html" title="4.2. Disk" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-tapsets.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="mainsect-disk.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 4. Useful SystemTap Scripts" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="useful-systemtap-scripts">Chapter 4. Useful SystemTap Scripts</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#mainsect-network">4.1. Network</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#nettopsect">4.1.1. Network Profiling</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#sockettracesect">4.1.2. Tracing Functions Called in Network Socket Code</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpconnectionssect">4.1.3. Monitoring Incoming TCP Connections</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpdumplikesect">4.1.4. Monitoring TCP Packets</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#dropwatchsect">4.1.5. Monitoring Network Packets Drops in Kernel</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-disk.html">4.2. Disk</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-disk.html#disktop">4.2.1. Summarizing Disk Read/Write Traffic</a></span></dt><dt><span class="section"><a href="iotimesect.html">4.2.2. Tracking I/O Time For Each File Read or Write</a></span></dt><dt><span class="section"><a href="traceiosect.html">4.2.3. Track Cumulative IO</a></span></dt><dt><span class="section"><a href="traceio2sect.html">4.2.4. I/O Monitoring (By Device)</a></span></dt><dt><span class="section"><a href="inodewatchsect.html">4.2.5. Monitoring Reads and Writes to a File</a></span></dt><dt><span class="section"><a href="inodewatch2sect.html">4.2.6. Monitoring Changes to File Attributes</a></span></dt><dt><span class="section"><a href="ioblktimesect.html">4.2.7. Periodically Print I/O Block Time</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-profiling.html">4.3. Profiling</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-profiling.html#countcallssect">4.3.1. Counting Function Calls Made</a></span></dt><dt><span class="section"><a href="paracallgraph.html">4.3.2. Call Graph Tracing</a></span></dt><dt><span class="section"><a href="threadtimessect.html">4.3.3. Determining Time Spent in Kernel and User Space</a></span></dt><dt><span class="section"><a href="timeoutssect.html">4.3.4. Monitoring Polling Applications</a></span></dt><dt><span class="section"><a href="topsyssect.html">4.3.5. Tracking Most Frequently Used System Calls</a></span></dt><dt><span class="section"><a href="syscallsbyprocpidsect.html">4.3.6. Tracking System Call Volume Per Process</a></span></dt></dl></dd><dt><span class="section"><a href="futexcontentionsect.html">4.4. Identifying Contended User-Space Locks</a></span></dt></dl></div><a id="id599736" class="indexterm"></a><a id="id599726" class="indexterm"></a><a id="id599720" class="indexterm"></a><a id="id599713" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 5. Useful SystemTap Scripts</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="ustack.html" title="4.3. User-Space Stack Backtraces" /><link rel="next" href="mainsect-disk.html" title="5.2. Disk" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="ustack.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="mainsect-disk.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="useful-systemtap-scripts" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 5. Useful SystemTap Scripts</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#mainsect-network">5.1. Network</a></span></dt><dd><dl><dt><span class="section"><a href="useful-systemtap-scripts.html#nettopsect">5.1.1. Network Profiling</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#sockettracesect">5.1.2. Tracing Functions Called in Network Socket Code</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpconnectionssect">5.1.3. Monitoring Incoming TCP Connections</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#tcpdumplikesect">5.1.4. Monitoring TCP Packets</a></span></dt><dt><span class="section"><a href="useful-systemtap-scripts.html#dropwatchsect">5.1.5. Monitoring Network Packets Drops in Kernel</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-disk.html">5.2. Disk</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-disk.html#disktop">5.2.1. Summarizing Disk Read/Write Traffic</a></span></dt><dt><span class="section"><a href="iotimesect.html">5.2.2. Tracking I/O Time For Each File Read or Write</a></span></dt><dt><span class="section"><a href="traceiosect.html">5.2.3. Track Cumulative IO</a></span></dt><dt><span class="section"><a href="traceio2sect.html">5.2.4. I/O Monitoring (By Device)</a></span></dt><dt><span class="section"><a href="inodewatchsect.html">5.2.5. Monitoring Reads and Writes to a File</a></span></dt><dt><span class="section"><a href="inodewatch2sect.html">5.2.6. Monitoring Changes to File Attributes</a></span></dt><dt><span class="section"><a href="ioblktimesect.html">5.2.7. Periodically Print I/O Block Time</a></span></dt></dl></dd><dt><span class="section"><a href="mainsect-profiling.html">5.3. Profiling</a></span></dt><dd><dl><dt><span class="section"><a href="mainsect-profiling.html#countcallssect">5.3.1. Counting Function Calls Made</a></span></dt><dt><span class="section"><a href="paracallgraph.html">5.3.2. Call Graph Tracing</a></span></dt><dt><span class="section"><a href="threadtimessect.html">5.3.3. Determining Time Spent in Kernel and User Space</a></span></dt><dt><span class="section"><a href="timeoutssect.html">5.3.4. Monitoring Polling Applications</a></span></dt><dt><span class="section"><a href="topsyssect.html">5.3.5. Tracking Most Frequently Used System Calls</a></span></dt><dt><span class="section"><a href="syscallsbyprocpidsect.html">5.3.6. Tracking System Call Volume Per Process</a></span></dt></dl></dd><dt><span class="section"><a href="futexcontentionsect.html">5.4. Identifying Contended User-Space Locks</a></span></dt></dl></div><a id="id652817" class="indexterm"></a><a id="id652806" class="indexterm"></a><a id="id652798" class="indexterm"></a><a id="id652790" class="indexterm"></a><div class="para">
                This chapter enumerates several SystemTap scripts you can use to monitor and investigate different subsystems. All of these scripts are available at <code class="filename">/usr/share/systemtap/testsuite/systemtap.examples/</code> once you install the <code class="filename">systemtap-testsuite</code> RPM.
-       </div><div class="section" title="4.1. Network"><div class="titlepage"><div><div><h2 class="title" id="mainsect-network">4.1. Network</h2></div></div></div><div class="para">
+       </div><div class="section" id="mainsect-network"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="mainsect-network">5.1. Network</h2></div></div></div><div class="para">
                        The following sections showcase scripts that trace network-related functions and build a profile of network activity.
-               </div><div xml:lang="en-US" class="section" title="4.1.1. Network Profiling" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="nettopsect">4.1.1. Network Profiling</h3></div></div></div><a id="id637802" class="indexterm"></a><a id="id637792" class="indexterm"></a><a id="id637780" class="indexterm"></a><a id="id529965" class="indexterm"></a><a id="id529955" class="indexterm"></a><div class="para">
-               This section describes how to profile network activity. <a class="xref" href="useful-systemtap-scripts.html#nettop" title="nettop.stp">nettop.stp</a> provides a glimpse into how much network traffic each process is generating on a machine.
-       </div><div class="formalpara"><h5 class="formalpara" id="nettop">nettop.stp</h5>
+               </div><div xml:lang="en-US" class="section" id="nettopsect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="nettopsect">5.1.1. Network Profiling</h3></div></div></div><a id="id408895" class="indexterm"></a><a id="id408883" class="indexterm"></a><a id="id408870" class="indexterm"></a><a id="id1926023" class="indexterm"></a><a id="id1926011" class="indexterm"></a><div class="para">
+               This section describes how to profile network activity. <a class="xref" href="useful-systemtap-scripts.html#nettop">nettop.stp</a> provides a glimpse into how much network traffic each process is generating on a machine.
+       </div><div class="formalpara" id="nettop"><h5 class="formalpara">nettop.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 global ifxmit, ifrecv
 global ifmerged
@@ -57,22 +56,17 @@ probe timer.ms(5000), end, error
 {
   print_activity()
 }
-
 </pre>
-               </div><a id="id502458" class="indexterm"></a><a id="id535685" class="indexterm"></a><a id="id594688" class="indexterm"></a><div class="para">
+               </div><a id="id727032" class="indexterm"></a><a id="id501483" class="indexterm"></a><a id="id1925984" class="indexterm"></a><div class="para">
                Note that <code class="command">function print_activity()</code> uses the following expressions:
-       </div><pre class="screen">
-n_xmit ? @sum(ifxmit[pid, dev, exec, uid])/1024 : 0
-n_recv ? @sum(ifrecv[pid, dev, exec, uid])/1024 : 0
-</pre><div class="para">
+       </div><pre class="screen">n_xmit ? @sum(ifxmit[pid, dev, exec, uid])/1024 : 0
+n_recv ? @sum(ifrecv[pid, dev, exec, uid])/1024 : 0</pre><div class="para">
                These expressions are if/else conditionals. The first statement is simply a more concise way of writing the following psuedo code:
-       </div><pre class="screen">
-if n_recv != 0 then
+       </div><pre class="screen">if n_recv != 0 then
   @sum(ifrecv[pid, dev, exec, uid])/1024
 else
-  0
-</pre><div class="para">
-               <a class="xref" href="useful-systemtap-scripts.html#nettop" title="nettop.stp">nettop.stp</a> tracks which processes are generating network traffic on the system, and provides the following information about each process:
+  0</pre><div class="para">
+               <a class="xref" href="useful-systemtap-scripts.html#nettop">nettop.stp</a> tracks which processes are generating network traffic on the system, and provides the following information about each process:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                <code class="computeroutput">PID</code> — the ID of the listed process.
                        </div></li><li class="listitem"><div class="para">
@@ -88,38 +82,35 @@ else
                        </div></li><li class="listitem"><div class="para">
                                <code class="computeroutput">RECV_KB</code> — amount of data received by the service, in kilobytes
                        </div></li></ul></div><div class="para">
-               <a class="xref" href="useful-systemtap-scripts.html#nettop" title="nettop.stp">nettop.stp</a> provides network profile sampling every 5 seconds. You can change this setting by editing <code class="command">probe timer.ms(5000)</code> accordingly. <a class="xref" href="useful-systemtap-scripts.html#nettopoutput" title="Example 4.1. nettop.stp Sample Output">Example 4.1, “nettop.stp Sample Output”</a> contains an excerpt of the output from <a class="xref" href="useful-systemtap-scripts.html#nettop" title="nettop.stp">nettop.stp</a> over a 20-second period:
-       </div><div class="example" id="nettopoutput"><div class="example-contents"><pre class="screen">
-[...]
-  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND        
-    0     0 eth0          0       5       0       0 swapper        
-11178     0 eth0          2       0       0       0 synergyc       
+               <a class="xref" href="useful-systemtap-scripts.html#nettop">nettop.stp</a> provides network profile sampling every 5 seconds. You can change this setting by editing <code class="command">probe timer.ms(5000)</code> accordingly. <a class="xref" href="useful-systemtap-scripts.html#nettopoutput">Example 5.1, “nettop.stp Sample Output”</a> contains an excerpt of the output from <a class="xref" href="useful-systemtap-scripts.html#nettop">nettop.stp</a> over a 20-second period:
+       </div><div class="example" id="nettopoutput"><h6>Example 5.1. <a class="xref" href="useful-systemtap-scripts.html#nettop">nettop.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
+  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND
+    0     0 eth0          0       5       0       0 swapper
+11178     0 eth0          2       0       0       0 synergyc
 
-  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND        
- 2886     4 eth0         79       0       5       0 cups-polld     
-11362     0 eth0          0      61       0       5 firefox        
-    0     0 eth0          3      32       0       3 swapper        
- 2886     4 lo            4       4       0       0 cups-polld     
-11178     0 eth0          3       0       0       0 synergyc       
+  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND
+ 2886     4 eth0         79       0       5       0 cups-polld
+11362     0 eth0          0      61       0       5 firefox
+    0     0 eth0          3      32       0       3 swapper
+ 2886     4 lo            4       4       0       0 cups-polld
+11178     0 eth0          3       0       0       0 synergyc
 
-  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND        
-    0     0 eth0          0       6       0       0 swapper        
- 2886     4 lo            2       2       0       0 cups-polld     
-11178     0 eth0          3       0       0       0 synergyc       
- 3611     0 eth0          0       1       0       0 Xorg           
+  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND
+    0     0 eth0          0       6       0       0 swapper
+ 2886     4 lo            2       2       0       0 cups-polld
+11178     0 eth0          3       0       0       0 synergyc
+ 3611     0 eth0          0       1       0       0 Xorg
 
-  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND        
-    0     0 eth0          3      42       0       2 swapper        
-11178     0 eth0         43       1       3       0 synergyc       
-11362     0 eth0          0       7       0       0 firefox        
+  PID   UID DEV     XMIT_PK RECV_PK XMIT_KB RECV_KB COMMAND
+    0     0 eth0          3      42       0       2 swapper
+11178     0 eth0         43       1       3       0 synergyc
+11362     0 eth0          0       7       0       0 firefox
  3897     0 eth0          0       1       0       0 multiload-apple
-[...]
-</pre></div><h6>Example 4.1. <a class="xref" href="useful-systemtap-scripts.html#nettop" title="nettop.stp">nettop.stp</a> Sample Output</h6></div><br class="example-break" /></div><div xml:lang="en-US" class="section" title="4.1.2. Tracing Functions Called in Network Socket Code" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="sockettracesect">4.1.2. Tracing Functions Called in Network Socket Code</h3></div></div></div><a id="id536072" class="indexterm"></a><a id="id590533" class="indexterm"></a><a id="id494232" class="indexterm"></a><a id="id541731" class="indexterm"></a><a id="id502278" class="indexterm"></a><a id="id636062" class="indexterm"></a><a id="id648445" class="indexterm"></a><a id="id582823" class="indexterm"></a><div class="para">
+[...]</pre></div></div><br class="example-break" /></div><div xml:lang="en-US" class="section" id="sockettracesect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="sockettracesect">5.1.2. Tracing Functions Called in Network Socket Code</h3></div></div></div><a id="id546984" class="indexterm"></a><a id="id526225" class="indexterm"></a><a id="id734233" class="indexterm"></a><a id="id425060" class="indexterm"></a><a id="id512466" class="indexterm"></a><a id="id1955870" class="indexterm"></a><a id="id452609" class="indexterm"></a><a id="id578184" class="indexterm"></a><div class="para">
                This section describes how to trace functions called from the kernel's <code class="filename">net/socket.c</code> file. This task helps you identify, in finer detail, how each process interacts with the network at the kernel level.
-       </div><div class="formalpara"><h5 class="formalpara" id="sockettrace">socket-trace.stp</h5>
+       </div><div class="formalpara" id="sockettrace"><h5 class="formalpara">socket-trace.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 probe kernel.function("*@net/socket.c").call {
   printf ("%s -&gt; %s\n", thread_indent(1), probefunc())
@@ -127,12 +118,10 @@ probe kernel.function("*@net/socket.c").call {
 probe kernel.function("*@net/socket.c").return {
   printf ("%s &lt;- %s\n", thread_indent(-1), probefunc())
 }
-
 </pre>
                </div><div class="para">
-               <a class="xref" href="useful-systemtap-scripts.html#sockettrace" title="socket-trace.stp">socket-trace.stp</a> is identical to <a class="xref" href="systemtapscript-handler.html#thread_indent" title="Example 3.6. thread_indent.stp">Example 3.6, “thread_indent.stp”</a>, which was earlier used in <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a> to illustrate how <code class="command">thread_indent()</code> works.
-       </div><div class="example" id="sockettraceoutput"><div class="example-contents"><pre class="screen">
-[...]
+               <a class="xref" href="useful-systemtap-scripts.html#sockettrace">socket-trace.stp</a> is identical to <a class="xref" href="systemtapscript-handler.html#thread_indent">Example 3.6, “thread_indent.stp”</a>, which was earlier used in <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a> to illustrate how <code class="command">thread_indent()</code> works.
+       </div><div class="example" id="sockettraceoutput"><h6>Example 5.2. <a class="xref" href="useful-systemtap-scripts.html#sockettrace">socket-trace.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">[...]
 0 Xorg(3611): -&gt; sock_poll
 3 Xorg(3611): &lt;- sock_poll
 0 Xorg(3611): -&gt; sock_poll
@@ -151,15 +140,13 @@ probe kernel.function("*@net/socket.c").return {
 28 scim-bridge(3883):   &lt;- sys_recvfrom
 31 scim-bridge(3883):  &lt;- sys_recv
 35 scim-bridge(3883): &lt;- sys_socketcall
-[...]
-</pre></div><h6>Example 4.2. <a class="xref" href="useful-systemtap-scripts.html#sockettrace" title="socket-trace.stp">socket-trace.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
-               <a class="xref" href="useful-systemtap-scripts.html#sockettraceoutput" title="Example 4.2. socket-trace.stp Sample Output">Example 4.2, “socket-trace.stp Sample Output”</a> contains a 3-second excerpt of the output for <a class="xref" href="useful-systemtap-scripts.html#sockettrace" title="socket-trace.stp">socket-trace.stp</a>. For more information about the output of this script as provided by <code class="command">thread_indent()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a> <a class="xref" href="systemtapscript-handler.html#thread_indent" title="Example 3.6. thread_indent.stp">Example 3.6, “thread_indent.stp”</a>.
-       </div></div><div xml:lang="en-US" class="section" title="4.1.3. Monitoring Incoming TCP Connections" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="tcpconnectionssect">4.1.3. Monitoring Incoming TCP Connections</h3></div></div></div><a id="id644014" class="indexterm"></a><a id="id499295" class="indexterm"></a><a id="id535645" class="indexterm"></a><a id="id613963" class="indexterm"></a><a id="id498306" class="indexterm"></a><div class="para">
+[...]</pre></div></div><br class="example-break" /><div class="para">
+               <a class="xref" href="useful-systemtap-scripts.html#sockettraceoutput">Example 5.2, “socket-trace.stp Sample Output”</a> contains a 3-second excerpt of the output for <a class="xref" href="useful-systemtap-scripts.html#sockettrace">socket-trace.stp</a>. For more information about the output of this script as provided by <code class="command">thread_indent()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a> <a class="xref" href="systemtapscript-handler.html#thread_indent">Example 3.6, “thread_indent.stp”</a>.
+       </div></div><div xml:lang="en-US" class="section" id="tcpconnectionssect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="tcpconnectionssect">5.1.3. Monitoring Incoming TCP Connections</h3></div></div></div><a id="id461080" class="indexterm"></a><a id="id508814" class="indexterm"></a><a id="id592856" class="indexterm"></a><a id="id447848" class="indexterm"></a><a id="id401284" class="indexterm"></a><div class="para">
                This section illustrates how to monitor incoming TCP connections. This task is useful in identifying any unauthorized, suspicious, or otherwise unwanted network access requests in real time.
-       </div><div class="formalpara"><h5 class="formalpara" id="tcpconnections">tcp_connections.stp</h5>
+       </div><div class="formalpara" id="tcpconnections"><h5 class="formalpara">tcp_connections.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 probe begin {
   printf("%6s %16s %6s %6s %16s\n",
@@ -173,10 +160,9 @@ probe kernel.function("tcp_accept").return?,
     printf("%6d %16s %6d %6d %16s\n", uid(), execname(), pid(),
            inet_get_local_port(sock), inet_get_ip_source(sock))
 }
-
 </pre>
                </div><div class="para">
-               While <a class="xref" href="useful-systemtap-scripts.html#tcpconnections" title="tcp_connections.stp">tcp_connections.stp</a> is running, it will print out the following information about any incoming TCP connections accepted by the system in real time:
+               While <a class="xref" href="useful-systemtap-scripts.html#tcpconnections">tcp_connections.stp</a> is running, it will print out the following information about any incoming TCP connections accepted by the system in real time:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                Current <code class="command">UID</code>
                        </div></li><li class="listitem"><div class="para">
@@ -187,16 +173,13 @@ probe kernel.function("tcp_accept").return?,
                                Port used by the connection
                        </div></li><li class="listitem"><div class="para">
                                IP address from which the TCP connection originated
-                       </div></li></ul></div><div class="example" id="tcpconnectionsoutput"><div class="example-contents"><pre class="screen">
-UID            CMD    PID   PORT        IP_SOURCE
+                       </div></li></ul></div><div class="example" id="tcpconnectionsoutput"><h6>Example 5.3. <a class="xref" href="useful-systemtap-scripts.html#tcpconnections">tcp_connections.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">UID            CMD    PID   PORT        IP_SOURCE
 0             sshd   3165     22      10.64.0.227
-0             sshd   3165     22      10.64.0.227
-</pre></div><h6>Example 4.3. <a class="xref" href="useful-systemtap-scripts.html#tcpconnections" title="tcp_connections.stp">tcp_connections.stp</a> Sample Output</h6></div><br class="example-break" /></div><div xml:lang="en-US" class="section" title="4.1.4. Monitoring TCP Packets" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="tcpdumplikesect">4.1.4. Monitoring TCP Packets</h3></div></div></div><a id="id615978" class="indexterm"></a><a id="id529873" class="indexterm"></a><a id="id587848" class="indexterm"></a><a id="id509513" class="indexterm"></a><a id="id637310" class="indexterm"></a><div class="para">
+0             sshd   3165     22      10.64.0.227</pre></div></div><br class="example-break" /></div><div xml:lang="en-US" class="section" id="tcpdumplikesect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="tcpdumplikesect">5.1.4. Monitoring TCP Packets</h3></div></div></div><a id="id1031363" class="indexterm"></a><a id="id602350" class="indexterm"></a><a id="id461475" class="indexterm"></a><a id="id607382" class="indexterm"></a><a id="id435025" class="indexterm"></a><div class="para">
                This section illustrates how to monitor TCP packets received by the system. This is useful in analyzing network traffic generated by applications running on the system.
-       </div><div class="formalpara"><h5 class="formalpara" id="tcpdumplike">tcpdumplike.stp</h5>
+       </div><div class="formalpara" id="tcpdumplike"><h5 class="formalpara">tcpdumplike.stp</h5>
                        
-<pre class="programlisting">
-       #! /usr/bin/env stap
+<pre class="programlisting">   #! /usr/bin/env stap
 
 // A TCP dump like example
 
@@ -210,10 +193,9 @@ probe tcp.receive {
   printf(" %15s %15s  %5d  %5d  %d  %d  %d  %d  %d  %d\n",
          saddr, daddr, sport, dport, urg, ack, psh, rst, syn, fin)
 }
-
 </pre>
                </div><div class="para">
-               While <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike" title="tcpdumplike.stp">tcpdumplike.stp</a> is running, it will print out the following information about any received TCP packets in real time:
+               While <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike">tcpdumplike.stp</a> is running, it will print out the following information about any received TCP packets in real time:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                Source and destination IP address (<code class="command">saddr</code>, <code class="command">daddr</code>, respectively)
                        </div></li><li class="listitem"><div class="para">
@@ -221,7 +203,7 @@ probe tcp.receive {
                        </div></li><li class="listitem"><div class="para">
                                Packet flags
                        </div></li></ul></div><div class="para">
-               To determine the flags used by the packet, <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike" title="tcpdumplike.stp">tcpdumplike.stp</a> uses the following functions:
+               To determine the flags used by the packet, <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike">tcpdumplike.stp</a> uses the following functions:
        </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                <code class="command">urg</code> - urgent
                        </div></li><li class="listitem"><div class="para">
@@ -236,8 +218,7 @@ probe tcp.receive {
                                <code class="command">fin</code> - finished
                        </div></li></ul></div><div class="para">
                The aforementioned functions return <code class="command">1</code> or <code class="command">0</code> to specify whether the packet uses the corresponding flag.
-       </div><div class="example" id="tcpdumplikeoutput"><div class="example-contents"><pre class="screen">
------------------------------------------------------------------
+       </div><div class="example" id="tcpdumplikeoutput"><h6>Example 5.4. <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike">tcpdumplike.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">-----------------------------------------------------------------
        Source IP         Dest IP  SPort  DPort  U  A  P  R  S  F
 -----------------------------------------------------------------
   209.85.229.147       10.0.2.15     80  20373  0  1  1  0  0  0
@@ -251,14 +232,12 @@ probe tcp.receive {
   209.85.229.147       10.0.2.15     80  21141  0  1  1  0  0  0
   209.85.229.147       10.0.2.15     80  21141  0  1  1  0  0  0
   209.85.229.118       10.0.2.15     80  63433  0  1  1  0  0  0
-[...]
-</pre></div><h6>Example 4.4. <a class="xref" href="useful-systemtap-scripts.html#tcpdumplike" title="tcpdumplike.stp">tcpdumplike.stp</a> Sample Output</h6></div><br class="example-break" /></div><div xml:lang="en-US" class="section" title="4.1.5. Monitoring Network Packets Drops in Kernel" lang="en-US"><div class="titlepage"><div><div><h3 class="title" id="dropwatchsect">4.1.5. Monitoring Network Packets Drops in Kernel</h3></div></div></div><a id="id529640" class="indexterm"></a><a id="id645001" class="indexterm"></a><a id="id500043" class="indexterm"></a><a id="id610081" class="indexterm"></a><a id="id498568" class="indexterm"></a><div class="para">
-               <a id="id639191" class="indexterm"></a>
-                The network stack in Linux can discard packets for various reasons. Some Linux kernels include a tracepoint, <code class="command">kernel.trace("kfree_skb")</code>, which easily tracks where packets are discarded. <a class="xref" href="useful-systemtap-scripts.html#dropwatch" title="dropwatch.stp">dropwatch.stp</a> uses <code class="command">kernel.trace("kfree_skb")</code> to trace packet discards; the script summarizes which locations discard packets every five-second interval.
-       </div><div class="formalpara"><h5 class="formalpara" id="dropwatch">dropwatch.stp</h5>
+[...]</pre></div></div><br class="example-break" /></div><div xml:lang="en-US" class="section" id="dropwatchsect" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="dropwatchsect">5.1.5. Monitoring Network Packets Drops in Kernel</h3></div></div></div><a id="id713930" class="indexterm"></a><a id="id761092" class="indexterm"></a><a id="id1966422" class="indexterm"></a><a id="id727408" class="indexterm"></a><a id="id407758" class="indexterm"></a><div class="para">
+               <a id="id441443" class="indexterm"></a>
+                The network stack in Linux can discard packets for various reasons. Some Linux kernels include a tracepoint, <code class="command">kernel.trace("kfree_skb")</code>, which easily tracks where packets are discarded. <a class="xref" href="useful-systemtap-scripts.html#dropwatch">dropwatch.stp</a> uses <code class="command">kernel.trace("kfree_skb")</code> to trace packet discards; the script summarizes which locations discard packets every five-second interval.
+       </div><div class="formalpara" id="dropwatch"><h5 class="formalpara">dropwatch.stp</h5>
                        
-<pre class="programlisting">
-#! /usr/bin/env stap
+<pre class="programlisting">#! /usr/bin/env stap
 
 ############################################################
 # Dropwatch.stp
@@ -280,44 +259,40 @@ probe kernel.trace("kfree_skb") { locations[$location] &lt;&lt;&lt; 1 }
 # Every 5 seconds report our drop locations
 probe timer.sec(5)
 {
-       printf("\n")
-       foreach (l in locations-) {
-               printf("%d packets dropped at location %p\n",
-                          @count(locations[l]), l)
-       }
-       delete locations
+  printf("\n")
+  foreach (l in locations-) {
+    printf("%d packets dropped at %s\n",
+           @count(locations[l]), symname(l))
+  }
+  delete locations
 }
-
-
 </pre>
                </div><div class="para">
-               The <code class="command">kernel.trace("kfree_skb")</code> traces which places in the kernel drop network packets. The <code class="command">kernel.trace("kfree_skb")</code> has two arguments: a pointer to the buffer being freed (<code class="command">$skb</code>) and the location in kernel code the buffer is being freed (<code class="command">$location</code>).
-       </div><div class="para">
-               Running the dropwatch.stp script 15 seconds would result in output similar in <a class="xref" href="useful-systemtap-scripts.html#dropwatchoutput" title="Example 4.5. dropwatch.stp Sample Output">Example 4.5, “dropwatch.stp Sample Output”</a>. The output lists the number of misses for tracepoint address and the actual address.
-       </div><div class="example" id="dropwatchoutput"><div class="example-contents"><pre class="screen">
-Monitoring for dropped packets
+               The <code class="command">kernel.trace("kfree_skb")</code> traces which places in the kernel drop network packets. The <code class="command">kernel.trace("kfree_skb")</code> has two arguments: a pointer to the buffer being freed (<code class="command">$skb</code>) and the location in kernel code the buffer is being freed (<code class="command">$location</code>). The <a class="xref" href="useful-systemtap-scripts.html#dropwatch">dropwatch.stp</a> script provides the function containing <code class="command">$location</code> where possible. The information to map <code class="command">$location</code> back to the function is not in the instrumentation by default. On Systemtap 1.4 the <code class="command">--all-modules</code> option will include the required mapping information and the following command can be used to run the script:
+       </div><pre class="programlisting">stap --all-modules dropwatch.stp</pre><div class="para">
+               On older versions of Systemtap you can use the following command to emulate the <code class="command">--all-modules</code> option:
+       </div><pre class="programlisting">stap -dkernel \
+`cat /proc/modules | awk 'BEGIN { ORS = " " } {print "-d"$1}'` \
+dropwatch.stp</pre><div class="para">
+               Running the dropwatch.stp script 15 seconds would result in output similar in <a class="xref" href="useful-systemtap-scripts.html#dropwatchoutput">Example 5.5, “dropwatch.stp Sample Output”</a>. The output lists the number of misses for each tracepoint location with either the function name or the address.
+       </div><div class="example" id="dropwatchoutput"><h6>Example 5.5. <a class="xref" href="useful-systemtap-scripts.html#dropwatch">dropwatch.stp</a> Sample Output</h6><div class="example-contents"><pre class="screen">Monitoring for dropped packets
 
-51 packets dropped at location 0xffffffff8024cd0f
-2 packets dropped at location 0xffffffff8044b472
+1762 packets dropped at unix_stream_recvmsg
+4 packets dropped at tun_do_read
+2 packets dropped at nf_hook_slow
 
-51 packets dropped at location 0xffffffff8024cd0f
-1 packets dropped at location 0xffffffff8044b472
+467 packets dropped at unix_stream_recvmsg
+20 packets dropped at nf_hook_slow
+6 packets dropped at tun_do_read
 
-97 packets dropped at location 0xffffffff8024cd0f
-1 packets dropped at location 0xffffffff8044b472
+446 packets dropped at unix_stream_recvmsg
+4 packets dropped at tun_do_read
+4 packets dropped at nf_hook_slow
 Stopping dropped packet monitor
-</pre></div><h6>Example 4.5. <a class="xref" href="useful-systemtap-scripts.html#dropwatch" title="dropwatch.stp">dropwatch.stp</a> Sample Output</h6></div><br class="example-break" /><div class="para">
-               To make the location of packet drops more meaningful, refer to the <code class="filename">/boot/System.map-`uname -r`</code> file. This file lists the starting addresses for each function, allowing you to map the addresses in the output of <a class="xref" href="useful-systemtap-scripts.html#dropwatchoutput" title="Example 4.5. dropwatch.stp Sample Output">Example 4.5, “dropwatch.stp Sample Output”</a> to a specific function name. Given the following snippet of the <code class="filename">/boot/System.map-`uname -r`</code> file, the address 0xffffffff8024cd0f maps to the function <code class="command">unix_stream_recvmsg</code> and the address 0xffffffff8044b472 maps to the function <code class="command">arp_rcv</code>:
-       </div><pre class="screen">
-[...]
-ffffffff8024c5cd T unlock_new_inode
-ffffffff8024c5da t unix_stream_sendmsg
-ffffffff8024c920 t unix_stream_recvmsg
-ffffffff8024cea1 t udp_v4_lookup_longway
-[...]
-ffffffff8044addc t arp_process
-ffffffff8044b360 t arp_rcv
-ffffffff8044b487 t parp_redo
-ffffffff8044b48c t arp_solicit
-[...]
-</pre></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-tapsets.html"><strong>Prev</strong>3.6. Tapsets</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="mainsect-disk.html"><strong>Next</strong>4.2. Disk</a></li></ul></body></html>
+</pre></div></div><br class="example-break" /><div class="para">
+               When the script is being compiled on one machine and run on another the <code class="command">--all-modules</code> and <code class="filename">/proc/modules</code> directory are not available; the <code class="command">symname</code> function will just print out the raw address. To make the raw address of packet drops more meaningful, refer to the <code class="filename">/boot/System.map-`uname -r`</code> file. This file lists the starting addresses for each function, allowing you to map the addresses in the output of <a class="xref" href="useful-systemtap-scripts.html#dropwatchoutput">Example 5.5, “dropwatch.stp Sample Output”</a> to a specific function name. Given the following snippet of the <code class="filename">/boot/System.map-`uname -r`</code> file, the address 0xffffffff8149a8ed maps to the function <code class="command">unix_stream_recvmsg</code>:
+       </div><pre class="screen">[...]
+ffffffff8149a420 t unix_dgram_poll
+ffffffff8149a5e0 t unix_stream_recvmsg
+ffffffff8149ad00 t unix_find_other
+[...]</pre></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="ustack.html"><strong>Prev</strong>4.3. User-Space Stack Backtraces</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="mainsect-disk.html"><strong>Next</strong>5.2. Disk</a></li></ul></body></html>
diff --git a/SystemTap_Beginners_Guide/userspace-probing.html b/SystemTap_Beginners_Guide/userspace-probing.html
new file mode 100644 (file)
index 0000000..d82d2e9
--- /dev/null
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 4. User-Space Probing</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="understanding-tapsets.html" title="3.6. Tapsets" /><link rel="next" href="utargetvariable.html" title="4.2. Accessing User-Space Target Variables" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-tapsets.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="utargetvariable.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="userspace-probing" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 4. User-Space Probing</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="userspace-probing.html#uevents">4.1. User-Space Events</a></span></dt><dt><span class="section"><a href="utargetvariable.html">4.2. Accessing User-Space Target Variables</a></span></dt><dt><span class="section"><a href="ustack.html">4.3. User-Space Stack Backtraces</a></span></dt></dl></div><div class="para">
+               SystemTap initially focused on kernel-space probing. However, there are many instances where user-space probing can help diagnose a problem. SystemTap 0.6 added support to allow probing user-space processes. SystemTap includes support for probing the entry into and return from a function in user-space processes, probing predefined markers in user-space code, and monitoring user-process events.
+       </div><div class="para">
+               The SystemTap user-space probing requires the utrace kernel extensions which provide an API for tracking various user-space events. More details about the utrace infrastructure are available at <a href="http://sourceware.org/systemtap/wiki/utrace">http://sourceware.org/systemtap/wiki/utrace</a>. The following command determines whether the currently running Linux kernel provides the needed utrace support:
+       </div><pre class="screen">grep CONFIG_UTRACE /boot/config-`uname -r`</pre><div class="para">
+               If the Linux kernel support user-space probing, the following output is printed:
+       </div><pre class="screen">CONFIG_UTRACE=y</pre><div class="para">
+               The SystemTap user-space probing also needs the uprobes kernel module. If the uprobes kernel module is not available, you will see an error message like the following when attempting to run a script that requires the uprobes kernel module:
+       </div><pre class="screen">SystemTap's version of uprobes is out of date.
+As root, or a member of the 'root' group, run
+"make -C /usr/share/systemtap/runtime/uprobes".
+Pass 4: compilation failed.  Try again with another '--vp 0001' option.</pre><div class="para">
+               If this occurs, you need to generate a uprobes.ko module for the kernel as directed.
+       </div><div class="section" id="uevents"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="uevents">4.1. User-Space Events</h2></div></div></div><a id="id507504" class="indexterm"></a><div class="para">
+                       All user-space event probes begin with <span class="emphasis"><em>process</em></span>. The process events can be limited to a specific running process by specifying the process ID. The process events can also be limited to monitoring a particular executable by specifying the path to executable (PATH). SystemTap makes use of the <code class="command">PATH</code> environment variable, so both the name used on the command-line to start the executable and the absolute path to the executable can be used. Several of user-space probe events limit their scope to a particular executable name (PATH) because SystemTap must use debug information to statically analyzed where to places the probes, but for many user-space probes events the process ID and executable name are optional. Any <code class="command">process</code> event in the list below that include process ID or the path to the executable must include those arguments. The process ID and path to the executable are optional for the <code class="command">process</code> events that do not list them:
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">process("<em class="replaceable"><code>PATH</code></em>").function("<em class="replaceable"><code>function</code></em>")</span></dt><dd><div class="para">
+                                               The entry to the user-space function <em class="replaceable"><code>function</code></em> for the executable <em class="replaceable"><code>PATH</code></em>. This event is the user-space analogue of the <code class="command">kernel.function("<em class="replaceable"><code>function</code></em>")</code> event. It allows wildcards for the function <em class="replaceable"><code>function</code></em> and <code class="command">.return</code> suffix.
+                                       </div></dd><dt class="varlistentry"><span class="term">process("<em class="replaceable"><code>PATH</code></em>").statement("<em class="replaceable"><code>statement</code></em>")</span></dt><dd><div class="para">
+                                               The earliest instruction in the code for <em class="replaceable"><code>statement</code></em>. This is the user-space analogue of <code class="command">kernel.statement("<em class="replaceable"><code>statement</code></em>")</code>.
+                                       </div></dd><dt class="varlistentry"><span class="term">process("<em class="replaceable"><code>PATH</code></em>").mark("<em class="replaceable"><code>marker</code></em>")</span></dt><dd><div class="para">
+                                               The static probe point <em class="replaceable"><code>marker</code></em> defined in <em class="replaceable"><code>PATH</code></em>. Wildcards can be used for <em class="replaceable"><code>marker</code></em> to specify mutiple marks with a single probe. The static probe points may also have numbered arguments ($1, $2, etc.) available to the probe. A variety of user-space packages such as Java include these static probe points. Most packages that provide static probe points also provide aliases for the raw user-space mark events. Below is one such alias for the x86_64 Java hotspot JVM:
+                                       </div><pre class="screen">probe hotspot.gc_begin =
+  process("/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/amd64/server/libjvm.so").mark("gc__begin")</pre></dd><dt class="varlistentry"><span class="term">process.begin</span></dt><dd><div class="para">
+                                               User-space process is created. This can be limited to a a particular process ID or a full path to the executable.
+                                       </div></dd><dt class="varlistentry"><span class="term">process.thread.begin</span></dt><dd><div class="para">
+                                               User-space thread is created. This can be limited to a a particular process ID or a full path to the executable.
+                                       </div></dd><dt class="varlistentry"><span class="term">process.end</span></dt><dd><div class="para">
+                                               User-space process died. This can be limited to a a particular process ID or a full path to the executable.
+                                       </div></dd><dt class="varlistentry"><span class="term">process.thread.end</span></dt><dd><div class="para">
+                                               User-space thread is destroyed. This can be limited to a a particular process ID or a full path to the executable.
+                                       </div></dd><dt class="varlistentry"><span class="term">process.syscall</span></dt><dd><div class="para">
+                                               User-space process makes a system call. The system call number is available via $syscall context variable, and the fist six arguments are available via $arg1 through $arg6. The ".return" suffix will place the probe at the return from the system call. For the "syscall.return" the return value is available through the $return context variable. This can be limited to a a particular process ID or a full path to the executable.
+                                       </div></dd></dl></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="understanding-tapsets.html"><strong>Prev</strong>3.6. Tapsets</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="utargetvariable.html"><strong>Next</strong>4.2. Accessing User-Space Target Variables</a></li></ul></body></html>
index 31f91e193d4892d66ff423bd3542225d2d232a3e..b1cd191d36440b7cfe0a926e72ad08aaefbf743a 100644 (file)
@@ -1,22 +1,22 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 2. Using SystemTap</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="intro-systemtap-vs-others.html" title="1.2. SystemTap Capabilities" /><link rel="next" href="cross-compiling.html" title="2.2. Generating Instrumentation for Other Computers" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="intro-systemtap-vs-others.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="cross-compiling.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" title="Chapter 2. Using SystemTap" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="using-systemtap">Chapter 2. Using SystemTap</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="using-systemtap.html#using-setup">2.1. Installation and Setup</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#installproper">2.1.1. Installing SystemTap</a></span></dt><dt><span class="section"><a href="using-systemtap.html#install-kinfo">2.1.2. Installing Required Kernel Information RPMs</a></span></dt><dt><span class="section"><a href="using-systemtap.html#testing">2.1.3. Initial Testing</a></span></dt></dl></dd><dt><span class="section"><a href="cross-compiling.html">2.2. Generating Instrumentation for Other Computers</a></span></dt><dt><span class="section"><a href="using-usage.html">2.3. Running SystemTap Scripts</a></span></dt></dl></div><a id="id647288" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 2. Using SystemTap</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="index.html" title="SystemTap Beginners Guide" /><link rel="prev" href="intro-systemtap-vs-others.html" title="1.2. SystemTap Capabilities" /><link rel="next" href="cross-compiling.html" title="2.2. Generating Instrumentation for Other Computers" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="intro-systemtap-vs-others.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="cross-compiling.html"><strong>Next</strong></a></li></ul><div xml:lang="en-US" class="chapter" id="using-systemtap" lang="en-US"><div class="titlepage"><div><div><h2 class="title">Chapter 2. Using SystemTap</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="using-systemtap.html#using-setup">2.1. Installation and Setup</a></span></dt><dd><dl><dt><span class="section"><a href="using-systemtap.html#installproper">2.1.1. Installing SystemTap</a></span></dt><dt><span class="section"><a href="using-systemtap.html#install-kinfo">2.1.2. Installing Required Kernel Information RPMs</a></span></dt><dt><span class="section"><a href="using-systemtap.html#testing">2.1.3. Initial Testing</a></span></dt></dl></dd><dt><span class="section"><a href="cross-compiling.html">2.2. Generating Instrumentation for Other Computers</a></span></dt><dt><span class="section"><a href="using-usage.html">2.3. Running SystemTap Scripts</a></span></dt><dd><dl><dt><span class="section"><a href="using-usage.html#flight-recorder">2.3.1. SystemTap Flight Recorder Mode</a></span></dt></dl></dd></dl></div><a id="id720247" class="indexterm"></a><div class="para">
                This chapter instructs users how to install SystemTap, and provides an introduction on how to run SystemTap scripts.
-       </div><div xml:lang="en-US" class="section" title="2.1. Installation and Setup" lang="en-US"><div class="titlepage"><div><div><h2 class="title" id="using-setup">2.1. Installation and Setup</h2></div></div></div><a id="id647258" class="indexterm"></a><a id="id647248" class="indexterm"></a><div class="para">
+       </div><div xml:lang="en-US" class="section" id="using-setup" lang="en-US"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="using-setup">2.1. Installation and Setup</h2></div></div></div><a id="id745822" class="indexterm"></a><a id="id745810" class="indexterm"></a><div class="para">
                To deploy SystemTap, you need to install the SystemTap packages along with the corresponding set of <code class="filename">-devel</code>, <code class="filename">-debuginfo</code> and <code class="filename">-debuginfo-common</code> packages for your kernel. If your system has multiple kernels installed, and you wish to use SystemTap on more than one kernel kernel, you will need to install the <code class="filename">-devel</code> and <code class="filename">-debuginfo</code> packages for <span class="emphasis"><em>each</em></span> of those kernel versions.
        </div><div class="para">
                These procedures will be discussed in detail in the following sections.
-       </div><div class="important"><h2>Important</h2><div class="para">
+       </div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
                        Many users confuse <code class="filename">-debuginfo</code> with <code class="filename">-debug</code>. Remember that the deployment of SystemTap requires the installation of the <code class="filename">-debuginfo</code> package of the kernel, not the <code class="filename">-debug</code> version of the kernel.
-               </div></div><div class="section" title="2.1.1. Installing SystemTap"><div class="titlepage"><div><div><h3 class="title" id="installproper">2.1.1. Installing SystemTap</h3></div></div></div><div class="para">
+               </div></div></div><div class="section" id="installproper"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="installproper">2.1.1. Installing SystemTap</h3></div></div></div><div class="para">
                        To deploy Systemtap, you will need to to install the following RPMs:
-               </div><a id="id647184" class="indexterm"></a><a id="id647146" class="indexterm"></a><a id="id647165" class="indexterm"></a><a id="id647156" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
+               </div><a id="id745734" class="indexterm"></a><a id="id745718" class="indexterm"></a><a id="id745710" class="indexterm"></a><a id="id1919934" class="indexterm"></a><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                        <code class="filename">systemtap</code>
                                </div></li><li class="listitem"><div class="para">
                                        <code class="filename">systemtap-runtime</code>
                                </div></li></ul></div><div class="para">
                        Assuming that <code class="command">yum</code> is installed in the system, these two rpms can be installed with <code class="command">yum install systemtap systemtap-runtime</code>. Note that before you can use SystemTap, you will still need to install the required kernel information RPMs.
-               </div></div><div class="section" title="2.1.2. Installing Required Kernel Information RPMs"><div class="titlepage"><div><div><h3 class="title" id="install-kinfo">2.1.2. Installing Required Kernel Information RPMs</h3></div></div></div><a id="id647107" class="indexterm"></a><a id="id647100" class="indexterm"></a><a id="id647093" class="indexterm"></a><a id="id647087" class="indexterm"></a><a id="id647081" class="indexterm"></a><a id="id647071" class="indexterm"></a><div class="para">
+               </div></div><div class="section" id="install-kinfo"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="install-kinfo">2.1.2. Installing Required Kernel Information RPMs</h3></div></div></div><a id="id548438" class="indexterm"></a><a id="id1919865" class="indexterm"></a><a id="id1919855" class="indexterm"></a><a id="id1919846" class="indexterm"></a><a id="id1919839" class="indexterm"></a><a id="id1919825" class="indexterm"></a><div class="para">
                        SystemTap needs information about the kernel in order to place instrumentation in it (i.e. probe it). This information also allows SystemTap to generate the code for the instrumentation. This information is contained in the matching <code class="filename">-devel</code>, <code class="filename">-debuginfo</code>, and <code class="filename">-debuginfo-common</code> packages for your kernel. The necessary <code class="filename">-devel</code> and <code class="filename">-debuginfo</code> packages for the ordinary "vanilla" kernel are as follows:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                        <code class="filename">kernel-debuginfo</code>
                                        <code class="filename">kernel-devel</code>
                                </div></li></ul></div><div class="para">
                        Likewise, the necessary packages for the PAE kernel would be <code class="filename">kernel-PAE-debuginfo</code>, <code class="filename">kernel-PAE-debuginfo-common</code>, and <code class="filename">kernel-PAE-devel</code>.
-               </div><a id="id582242" class="indexterm"></a><a id="id582232" class="indexterm"></a><a id="id582223" class="indexterm"></a><a id="id582212" class="indexterm"></a><div class="para">
+               </div><a id="id548454" class="indexterm"></a><a id="id548442" class="indexterm"></a><a id="id548425" class="indexterm"></a><a id="id701832" class="indexterm"></a><div class="para">
                        To determine what kernel your system is currently using, use:
-               </div><pre class="screen">
-uname -r
-</pre><div class="para">
+               </div><pre class="screen">uname -r</pre><div class="para">
                        For example, if you wish to use SystemTap on kernel version <code class="filename">2.6.18-53.el5</code> on an i686 machine, then you would need to download and install the following RPMs:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                        <code class="filename">kernel-debuginfo-2.6.18-53.1.13.el5.i686.rpm</code>
@@ -38,20 +36,10 @@ uname -r
                                        <code class="filename">kernel-debuginfo-common-2.6.18-53.1.13.el5.i686.rpm</code>
                                </div></li><li class="listitem"><div class="para">
                                        <code class="filename">kernel-devel-2.6.18-53.1.13.el5.i686.rpm</code>
-                               </div></li></ul></div><div class="important"><h2>Important</h2><div class="para">
+                               </div></li></ul></div><div class="important"><div class="admonition_header"><h2>Important</h2></div><div class="admonition"><div class="para">
                                The version, variant, and architecture of the <code class="filename">-devel</code>, <code class="filename">-debuginfo</code> and <code class="filename">-debuginfo-common</code> packages must match the kernel you wish to probe with SystemTap <span class="emphasis"><em>exactly</em></span>.
-                       </div></div><div class="para">
-                       The easiest way to install the required kernel information packages is through <code class="command">yum install</code> and <code class="command">debuginfo-install</code>. <code class="command">debuginfo-install</code> is included with later versions of the <code class="filename">yum-utils</code> package (for example, version 1.1.10), and also requires an appropriate <code class="command">yum</code> repository from which to download and install <code class="command">-debuginfo</code>/<code class="filename">-debuginfo-common</code> packages.
-               </div><div class="para">
-                       Most of the required kernel packages can be found at <a href="http://download.fedoraproject.org/pub/fedora/linux/releases/">http://download.fedoraproject.org/pub/fedora/linux/releases/</a>. Configure <code class="command">yum</code> accordingly by adding a new "debug" <code class="command">yum</code> repository file under <code class="filename">/etc/yum.repos.d</code> containing the following lines:
-               </div><pre class="programlisting">
-[fedora-debuginfo]
-name=Fedora $releasever - $basearch - Debug
-failovermethod=priority
-baseurl=http://download.fedoraproject.org/pub/fedora/linux/releases/$releasever/Everything/$basearch/debug/
-enabled=1
-</pre><div class="para">
-                       After configuring <code class="command">yum</code> with the appropriate repository, you can now install the required <code class="filename">-devel</code>, <code class="filename">-debuginfo</code>, and <code class="filename">-debuginfo-common</code> packages for your kernel. To install the corresponding packages for a specific kernel, run the following commands:
+                       </div></div></div><div class="para">
+                       The easiest way to install the required kernel information packages is through <code class="command">yum install</code> and <code class="command">debuginfo-install</code> commands. <code class="command">debuginfo-install</code> is included with later versions of the <code class="filename">yum-utils</code> package (for example, version 1.1.10), and also requires an appropriate <code class="command">yum</code> repository from which to download and install <code class="command">-debuginfo</code>/<code class="filename">-debuginfo-common</code> packages. You can install the required <code class="filename">-devel</code>, <code class="filename">-debuginfo</code>, and <code class="filename">-debuginfo-common</code> packages for your kernel. To install the corresponding packages for a specific kernel, run the following commands:
                </div><div class="itemizedlist"><ul><li class="listitem"><div class="para">
                                        <code class="command">yum install <em class="replaceable"><code>kernelname</code></em>-devel-<em class="replaceable"><code>version</code></em></code>
                                </div></li><li class="listitem"><div class="para">
@@ -64,10 +52,9 @@ enabled=1
                                        <code class="command">debuginfo-install kernel-PAE-2.6.18-53.1.13.el5</code>
                                </div></li></ul></div><div class="para">
                        If you do not have <code class="command">yum</code> and <code class="command">yum-utils</code> installed (and you are unable to install them), you will have to manually download and install the required kernel information packages. To generate the URL from which to download the required packages, use the following script:
-               </div><a id="id538951" class="indexterm"></a><a id="id645491" class="indexterm"></a><div class="formalpara"><h5 class="formalpara" id="id601092">fedoradebugurl.sh</h5>
+               </div><a id="id1970328" class="indexterm"></a><a id="id1970310" class="indexterm"></a><div class="formalpara"><h5 class="formalpara" id="id751992">fedoradebugurl.sh</h5>
                                
-<pre class="programlisting">
-#! /bin/bash
+<pre class="programlisting">#! /bin/bash
 echo -n "Enter nvr of kernel-debuginfo (e.g. 2.6.25-14.fc9.x86_64) " ; \
 read NVR; \
 BASE=`uname -m` ; \
@@ -76,22 +63,19 @@ VERSION=`echo $NVR | awk -F- '{print $1}'` ; \
 RELEASE=`echo $NVR | awk -F- '{print $2}'` ; \
 echo "http://kojipkgs.fedoraproject.org/\
 packages/kernel/$VERSION/$RELEASE/$BASE/"
-
 </pre>
                        </div><div class="para">
                        Once you have manually downloaded the required packages to the machine, install the RPMs by running <code class="command">rpm --force -ivh <em class="replaceable"><code>package_names</code></em></code>.
-               </div></div><div class="section" title="2.1.3. Initial Testing"><div class="titlepage"><div><div><h3 class="title" id="testing">2.1.3. Initial Testing</h3></div></div></div><a id="id495362" class="indexterm"></a><a id="id543961" class="indexterm"></a><a id="id498877" class="indexterm"></a><div class="para">
+               </div></div><div class="section" id="testing"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="testing">2.1.3. Initial Testing</h3></div></div></div><a id="id603973" class="indexterm"></a><a id="id755810" class="indexterm"></a><a id="id755803" class="indexterm"></a><div class="para">
                        If you are currently using the kernel you wish to probe with SystemTap, you can immediately test whether the deployment was successful. If not, you will need to reboot and load the appropriate kernel.
                </div><div class="para">
                        To start the test, run the command <code class="command">stap -v -e 'probe vfs.read {printf("read performed\n"); exit()}'</code>. This command simply instructs SystemTap to print <code class="computeroutput">read performed</code> then exit properly once a virtual file system read is detected. If the SystemTap deployment was successful, you should get output similar to the following:
-               </div><pre class="screen">
-Pass 1: parsed user script and 45 library script(s) in 340usr/0sys/358real ms.
+               </div><pre class="screen">Pass 1: parsed user script and 45 library script(s) in 340usr/0sys/358real ms.
 Pass 2: analyzed script: 1 probe(s), 1 function(s), 0 embed(s), 0 global(s) in 290usr/260sys/568real ms.
 Pass 3: translated to C into "/tmp/stapiArgLX/stap_e5886fa50499994e6a87aacdc43cd392_399.c" in 490usr/430sys/938real ms.
 Pass 4: compiled C into "stap_e5886fa50499994e6a87aacdc43cd392_399.ko" in 3310usr/430sys/3714real ms.
 Pass 5: starting run.
 read performed
-Pass 5: run completed in 10usr/40sys/73real ms.
-</pre><div class="para">
-                       The last three lines of the output (i.e. beginning with <code class="computeroutput">Pass 5</code> indicate that SystemTap was able to successfully create the instrumentation to probe the kernel, run the instrumentation, detect the event being probed (in this case, a virtual file system read), and execute a valid handler (print text then close it with no errors).
+Pass 5: run completed in 10usr/40sys/73real ms.</pre><div class="para">
+                       The last three lines of the output (i.e. beginning with <code class="computeroutput">Pass 5</code>) indicate that SystemTap was able to successfully create the instrumentation to probe the kernel, run the instrumentation, detect the event being probed (in this case, a virtual file system read), and execute a valid handler (print text then close it with no errors).
                </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="intro-systemtap-vs-others.html"><strong>Prev</strong>1.2. SystemTap Capabilities</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="cross-compiling.html"><strong>Next</strong>2.2. Generating Instrumentation for Other Compute...</a></li></ul></body></html>
index 962a91e809fa766c56fc17eda52562e82be86f59..00b6d524761b0e07758c3aa949b3c485e5d3440f 100644 (file)
@@ -1,43 +1,64 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2.3. Running SystemTap Scripts</title><link rel="stylesheet" href="./Common_Content/css/default.css" type="text/css" /><meta name="generator" content="publican 1.3" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.0-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="prev" href="cross-compiling.html" title="2.2. Generating Instrumentation for Other Computers" /><link rel="next" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /></head><body class=""><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="cross-compiling.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="understanding-how-systemtap-works.html"><strong>Next</strong></a></li></ul><div class="section" title="2.3. Running SystemTap Scripts"><div class="titlepage"><div><div><h2 class="title" id="using-usage">2.3. Running SystemTap Scripts</h2></div></div></div><a id="id495344" class="indexterm"></a><a id="id495371" class="indexterm"></a><a id="id506202" class="indexterm"></a><a id="id506214" class="indexterm"></a><a id="id507770" class="indexterm"></a><a id="id507782" class="indexterm"></a><div class="para">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>2.3. Running SystemTap Scripts</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="using-systemtap.html" title="Chapter 2. Using SystemTap" /><link rel="prev" href="cross-compiling.html" title="2.2. Generating Instrumentation for Other Computers" /><link rel="next" href="understanding-how-systemtap-works.html" title="Chapter 3. Understanding How SystemTap Works" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="cross-compiling.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="understanding-how-systemtap-works.html"><strong>Next</strong></a></li></ul><div class="section" id="using-usage"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="using-usage">2.3. Running SystemTap Scripts</h2></div></div></div><a id="id1939674" class="indexterm"></a><a id="id635404" class="indexterm"></a><a id="id691714" class="indexterm"></a><a id="id691726" class="indexterm"></a><a id="id713298" class="indexterm"></a><a id="id502548" class="indexterm"></a><div class="para">
                        SystemTap scripts are run through the command <code class="command">stap</code>. <code class="command">stap</code> can run SystemTap scripts from standard input or from file.
-               </div><a id="id493862" class="indexterm"></a><div class="para">
+               </div><a id="id703422" class="indexterm"></a><div class="para">
                        Running <code class="command">stap</code> and <code class="command">staprun</code> requires elevated privileges to the system. However, not all users can be granted root access just to run SystemTap. In some cases, for instance, you may want to allow a non-privileged user to run SystemTap instrumentation on his machine.
                </div><div class="para">
                        To allow ordinary users to run SystemTap without root access, add them to one of these user groups:
-               </div><div class="variablelist"><dl><dt><span class="term">stapdev</span></dt><dd><a id="id640768" class="indexterm"></a><a id="id539806" class="indexterm"></a><div class="para">
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">stapdev</span></dt><dd><a id="id734564" class="indexterm"></a><a id="id751522" class="indexterm"></a><div class="para">
                                                Members of this group can use <code class="command">stap</code> to run SystemTap scripts, or <code class="command">staprun</code> to run SystemTap instrumentation modules.
                                        </div><div class="para">
                                                Running <code class="command">stap</code> involves compiling SystemTap scripts into kernel modules and loading them into the kernel. This requires elevated privileges to the system, which are granted to <code class="command">stapdev</code> members. Unfortunately, such privileges also grant effective root access to <code class="command">stapdev</code> members. As such, you should only grant <code class="command">stapdev</code> group membership to users whom you can trust root access.
-                                       </div></dd><dt><span class="term">stapusr</span></dt><dd><a id="id639520" class="indexterm"></a><a id="id538959" class="indexterm"></a><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">stapusr</span></dt><dd><a id="id612950" class="indexterm"></a><a id="id400515" class="indexterm"></a><div class="para">
                                                Members of this group can only run <code class="command">staprun</code> to run SystemTap instrumentation modules. In addition, they can only run those modules from <code class="filename">/lib/modules/<em class="replaceable"><code>kernel_version</code></em>/systemtap/</code>. Note that this directory must be owned only by the root user, and must only be writable by the root user.
                                        </div></dd></dl></div><div class="para">
                        Below is a list of commonly used <code class="command">stap</code> options:
-               </div><a id="id596209" class="indexterm"></a><a id="id511251" class="indexterm"></a><div class="variablelist"><a id="id511266" class="indexterm"></a><dl><dt><span class="term">-v</span></dt><dd><div class="para">
+               </div><a id="id727066" class="indexterm"></a><a id="id727078" class="indexterm"></a><div class="variablelist"><a id="id633483" class="indexterm"></a><dl><dt class="varlistentry"><span class="term">-v</span></dt><dd><div class="para">
                                                Makes the output of the SystemTap session more verbose. You can repeat this option (for example, <code class="command">stap -vvv script.stp</code>) to provide more details on the script's execution. This option is particularly useful if you encounter any errors in running the script.
                                        </div><div class="para">
-                                               For more information about common SystemTap script errors, refer to <a class="xref" href="errors.html" title="Chapter 5. Understanding SystemTap Errors">Chapter 5, <i>Understanding SystemTap Errors</i></a>.
-                                       </div></dd><dt><span class="term">-o <em class="replaceable"><code>filename</code></em></span></dt><dd><div class="para">
+                                               For more information about common SystemTap script errors, refer to <a class="xref" href="errors.html">Chapter 6, <i>Understanding SystemTap Errors</i></a>.
+                                       </div></dd><dt class="varlistentry"><span class="term">-o <em class="replaceable"><code>filename</code></em></span></dt><dd><div class="para">
                                                Sends the standard output to file (<em class="replaceable"><code>filename</code></em>).
-                                       </div></dd><dt><span class="term">-x <em class="replaceable"><code>process ID</code></em></span></dt><dd><div class="para">
-                                               Sets the SystemTap handler function <code class="command">target()</code> to the specified process ID. For more information about <code class="command">target()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a>.
-                                       </div></dd><dt><span class="term">-c <em class="replaceable"><code>command</code></em></span></dt><dd><div class="para">
-                                               Sets the SystemTap handler function <code class="command">target()</code> to the specified command. Note that you must use the full path to the specified command; for example, instead of specifying <code class="command">cp</code>, use <code class="command">/bin/cp</code> (as in <code class="command">stap <em class="replaceable"><code>script</code></em> -c /bin/cp</code>). For more information about <code class="command">target()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions" title="SystemTap Functions">SystemTap Functions</a>.
-                                       </div></dd><dt><span class="term">-e '<em class="replaceable"><code>script</code></em>'</span></dt><dd><div class="para">
+                                       </div></dd><dt class="varlistentry"><span class="term">-S <em class="replaceable"><code>size</code></em>,<em class="replaceable"><code>count</code></em></span></dt><dd><div class="para">
+                                               Limit files to <em class="replaceable"><code>size</code></em> megabytes and limit the the number of files kept around to <em class="replaceable"><code>count</code></em>. The file names will have a sequence number suffix. This option implements logrotate operations for SystemTap.
+                                       </div></dd><dt class="varlistentry"><span class="term">-x <em class="replaceable"><code>process ID</code></em></span></dt><dd><div class="para">
+                                               Sets the SystemTap handler function <code class="command">target()</code> to the specified process ID. For more information about <code class="command">target()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a>.
+                                       </div></dd><dt class="varlistentry"><span class="term">-c '<em class="replaceable"><code>command</code></em>'</span></dt><dd><div class="para">
+                                               Sets the SystemTap handler function <code class="command">target()</code> to the specified command and runs the SystemTap instrumentation for the duration of the specified command. For more information about <code class="command">target()</code>, refer to <a class="xref" href="systemtapscript-handler.html#systemtapscript-functions">SystemTap Functions</a>.
+                                       </div></dd><dt class="varlistentry"><span class="term">-e '<em class="replaceable"><code>script</code></em>'</span></dt><dd><div class="para">
                                                Use <code class="command"><em class="replaceable"><code>script</code></em></code> string rather than a file as input for systemtap translator.
+                                       </div></dd><dt class="varlistentry"><span class="term">-F</span></dt><dd><div class="para">
+                                               Use SystemTap's Flight recorder mode and make the script a background process. For more information about flight recorder mode, refer to <a class="xref" href="using-usage.html#flight-recorder">Section 2.3.1, “SystemTap Flight Recorder Mode”</a>.
                                        </div></dd></dl></div><div class="para">
                        You can also instruct <code class="command">stap</code> to run scripts from standard input using the switch <code class="command">-</code>. To illustrate:
-               </div><a id="id508094" class="indexterm"></a><a id="id508107" class="indexterm"></a><a id="id508119" class="indexterm"></a><div class="example" id="stdinstap"><div class="example-contents"><pre class="programlisting">
-echo "probe timer.s(1) {exit()}" | stap -
-</pre></div><h6>Example 2.1. Running Scripts From Standard Input</h6></div><br class="example-break" /><div class="para">
-                       <a class="xref" href="using-usage.html#stdinstap" title="Example 2.1. Running Scripts From Standard Input">Example 2.1, “Running Scripts From Standard Input”</a> instructs <code class="command">stap</code> to run the script passed by <code class="command">echo</code> to standard input. Any <code class="command">stap</code> options you wish to use should be inserted before the <code class="command">-</code> switch; for instance, to make the example in <a class="xref" href="using-usage.html#stdinstap" title="Example 2.1. Running Scripts From Standard Input">Example 2.1, “Running Scripts From Standard Input”</a> more verbose, the command would be:
+               </div><a id="id727518" class="indexterm"></a><a id="id570894" class="indexterm"></a><a id="id570905" class="indexterm"></a><div class="example" id="stdinstap"><h6>Example 2.1. Running Scripts From Standard Input</h6><div class="example-contents"><pre class="programlisting">echo "probe timer.s(1) {exit()}" | stap -</pre></div></div><br class="example-break" /><div class="para">
+                       <a class="xref" href="using-usage.html#stdinstap">Example 2.1, “Running Scripts From Standard Input”</a> instructs <code class="command">stap</code> to run the script passed by <code class="command">echo</code> to standard input. Any <code class="command">stap</code> options you wish to use should be inserted before the <code class="command">-</code> switch; for instance, to make the example in <a class="xref" href="using-usage.html#stdinstap">Example 2.1, “Running Scripts From Standard Input”</a> more verbose, the command would be:
                </div><div class="para">
                        <code class="command">echo "probe timer.s(1) {exit()}" | stap -v -</code>
                </div><div class="para">
                        For more information about <code class="command">stap</code>, refer to <code class="command">man stap</code>.
                </div><div class="para">
-                       To run SystemTap instrumentation (i.e. the kernel module built from SystemTap scripts during a cross-instrumentation), use <code class="command">staprun</code> instead. For more information about <code class="command">staprun</code> and cross-instrumentation, refer to <a class="xref" href="cross-compiling.html" title="2.2. Generating Instrumentation for Other Computers">Section 2.2, “Generating Instrumentation for Other Computers”</a>.
-               </div><div class="note"><h2>Note</h2><div class="para">
+                       To run SystemTap instrumentation (i.e. the kernel module built from SystemTap scripts during a cross-instrumentation), use <code class="command">staprun</code> instead. For more information about <code class="command">staprun</code> and cross-instrumentation, refer to <a class="xref" href="cross-compiling.html">Section 2.2, “Generating Instrumentation for Other Computers”</a>.
+               </div><div class="note"><div class="admonition_header"><h2>Note</h2></div><div class="admonition"><div class="para">
                                The <code class="command">stap</code> options <code class="command">-v</code> and <code class="command">-o</code> also work for <code class="command">staprun</code>. For more information about <code class="command">staprun</code>, refer to <code class="command">man staprun</code>.
-                       </div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="cross-compiling.html"><strong>Prev</strong>2.2. Generating Instrumentation for Other Compute...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="understanding-how-systemtap-works.html"><strong>Next</strong>Chapter 3. Understanding How SystemTap Works</a></li></ul></body></html>
+                       </div></div></div><div class="section" id="flight-recorder"><div class="titlepage"><div><div keep-together.within-column="always"><h3 class="title" id="flight-recorder">2.3.1. SystemTap Flight Recorder Mode</h3></div></div></div><a id="id568975" class="indexterm"></a><div class="para">
+                               SystemTap's flight recorder mode allows you to run a SystemTap script run for long periods and just focus on recent output. The flight recorder mode (the <code class="command">-F</code> option) limits the amount of output generated. There are two variations of the flight recorder mode: in-memory and file mode. In both cases the SystemTap script runs as a background process.
+                       </div><div class="section" id="memory-flight-recorder"><div class="titlepage"><div><div keep-together.within-column="always"><h4 class="title" id="memory-flight-recorder">2.3.1.1. In-memory Flight Recorder</h4></div></div></div><a id="id586129" class="indexterm"></a><div class="para">
+                                       When flight recorder mode (the <code class="command">-F</code> option) is used without a file name SystemTap uses a buffer in kernel memory to store the output of the script. The SystemTap instrumentation module will load and the probes start running, the instrumentation will then detach and be put in the background. When the interesting event occurs, you can reattach to the instrumentation and see the recent output in the memory buffer and any continuing output. The following command starts a script using the flight recorder in-memory mode:
+                               </div><pre class="screen">stap -F iotime.stp</pre><div class="para">
+                                       Once the script starts, you will see a message like the following that provides the command to reconnect to the running script:
+                               </div><pre class="screen">Disconnecting from systemtap module.
+To reconnect, type "staprun -A stap_5dd0073edcb1f13f7565d8c343063e68_19556"</pre><div class="para">
+                                       When the interesting event occurs, you reattach to the currently running script and output the recent data in the memory buffer and get continuing output with the following command:
+                               </div><pre class="screen">staprun -A stap_5dd0073edcb1f13f7565d8c343063e68_19556</pre><div class="para">
+                                       By default the kernel buffer is 1MB in size and it can be increased with the <code class="command">-s</code> option specifying the size in megabytes (rounded up to the next power over 2) for the buffer. For example <code class="command">-s2</code> on the SystemTap command line would specify 2MB for the buffer.
+                               </div></div><div class="section" id="file-flight-recorder"><div class="titlepage"><div><div keep-together.within-column="always"><h4 class="title" id="file-flight-recorder">2.3.1.2. File Flight Recorder</h4></div></div></div><a id="id560247" class="indexterm"></a><div class="para">
+                                       The flight recorder mode can also store data to files. The number and size of the files kept is controlled by the <code class="command">-S</code> option followed by two numerical arguments separated by a comma. The first argument is the maximum size in megabytes for the each output file. The second argument is the number of recent files to keep. The file name is specified by the <code class="command">-o</code> option followed by the name. SystemTap will add a number suffix to the file name to indicate the order of the files. The following will start SystemTap in file flight recorder mode with the output going to files named <code class="command">/tmp/iotime.log.</code><em class="replaceable"><code>[0-9]+</code></em> and each file 1MB or smaller and keeping latest two files:
+                               </div><pre class="screen">stap -F -o /tmp/pfaults.log -S 1,2  pfaults.stp</pre><div class="para">
+                                       The number printed by the command is the process ID. Sending a SIGTERM to the process will shutdown the SystemTap script and stop the data collection. For example if the previous command listed the 7590 as the process ID, the following command whould shutdown the systemtap script:
+                               </div><pre class="screen">kill -s SIGTERM 7590</pre><div class="para">
+                                       Only the most recent two file generated by the script are kept and the older files are been removed. Thus, <code class="command">ls -sh /tmp/pfaults.log.*</code> shows the only two files:
+                               </div><pre class="screen">1020K /tmp/pfaults.log.5    44K /tmp/pfaults.log.6</pre><div class="para">
+                                       One can look at the highest number file for the latest data, in this case /tmp/pfaults.log.6.
+                               </div></div></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="cross-compiling.html"><strong>Prev</strong>2.2. Generating Instrumentation for Other Compute...</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="understanding-how-systemtap-works.html"><strong>Next</strong>Chapter 3. Understanding How SystemTap Works</a></li></ul></body></html>
diff --git a/SystemTap_Beginners_Guide/ustack.html b/SystemTap_Beginners_Guide/ustack.html
new file mode 100644 (file)
index 0000000..72b2a0c
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.3. User-Space Stack Backtraces</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="userspace-probing.html" title="Chapter 4. User-Space Probing" /><link rel="prev" href="utargetvariable.html" title="4.2. Accessing User-Space Target Variables" /><link rel="next" href="useful-systemtap-scripts.html" title="Chapter 5. Useful SystemTap Scripts" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="utargetvariable.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="useful-systemtap-scripts.html"><strong>Next</strong></a></li></ul><div class="section" id="ustack"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="ustack">4.3. User-Space Stack Backtraces</h2></div></div></div><a id="id592790" class="indexterm"></a><div class="para">
+                       The probe point (<code class="command">pp</code>) function indicates which particular event triggered the the SystemTap event handler. A probe on the entry into a function would list the function name. However, in many cases the same probe point event may be triggered by many different modules in the program; this is particularly true for functions in shared libraries. A SystemTap backtrace of the user-space stack can provide additional context on how the probe point event is triggered.
+               </div><div class="para">
+                       The user-space stack backtrace generation is complicated by the compiler producing code optimized to eliminate stack frame pointers. However, the compiler also includes information in the debug information section to allow debugging tools to produce stack backtraces. SystemTap user-space stack backtrace mechanism makes use of that debug information to walk the stack to generate stack traces for 32-bit and 64-bit x86 processors; other processor architectures do not yet support the use of debug information to unwind the user-space stack. You will need to use the <code class="command">-d <em class="replaceable"><code>executable</code></em></code> for the application executable and <code class="command">-ldd</code> for shared libraries to ensure that the needed debug information is used to produce the user-space stack backtraces.
+               </div><div class="para">
+                       If you want to see how the function <code class="command">xmalloc</code> function is being called by the command <code class="command">ls</code>, you could use the user-space backtrack functions to provide that information. With the debuginfo for the <code class="command">ls</code> command installed the following SystemTap command will provide a backtrace each time the <code class="command">xmalloc</code> function is called:
+               </div><pre class="screen">stap -d /bin/ls --ldd \
+-e 'probe process("ls").function("xmalloc") {print_ustack(ubacktrace())}' \
+-c "ls /"</pre><div class="para">
+                       When the SystemTap script runs will have output similar to the following:
+               </div><pre class="screen">
+bin    dev   lib         media  net         proc       sbin     sys  var
+boot   etc   lib64       misc   op_session  profilerc  selinux  tmp
+cgroup home  lost+found  mnt    opt         root       srv      usr
+ 0x4116c0 : xmalloc+0x0/0x20 [/bin/ls]
+ 0x4116fc : xmemdup+0x1c/0x40 [/bin/ls]
+ 0x40e68b : clone_quoting_options+0x3b/0x50 [/bin/ls]
+ 0x4087e4 : main+0x3b4/0x1900 [/bin/ls]
+ 0x3fa441ec5d : __libc_start_main+0xfd/0x1d0 [/lib64/libc-2.12.so]
+ 0x402799 : _start+0x29/0x2c [/bin/ls]
+ 0x4116c0 : xmalloc+0x0/0x20 [/bin/ls]
+ 0x4116fc : xmemdup+0x1c/0x40 [/bin/ls]
+ 0x40e68b : clone_quoting_options+0x3b/0x50 [/bin/ls]
+ 0x40884a : main+0x41a/0x1900 [/bin/ls]
+ 0x3fa441ec5d : __libc_start_main+0xfd/0x1d0 [/lib64/libc-2.12.so]
+ ...
+</pre><div class="para">
+                       For more details on the functions available for user-space stack backtraces look at the <code class="command">ucontext-symbols.stp</code> and <code class="command">ucontext-unwind.stp</code> tapsets. The descriptions of the functions in those tapsets can also be found in the <em class="citetitle">SystemTap Tapset Reference Manual</em>.
+               </div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="utargetvariable.html"><strong>Prev</strong>4.2. Accessing User-Space Target Variables</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="useful-systemtap-scripts.html"><strong>Next</strong>Chapter 5. Useful SystemTap Scripts</a></li></ul></body></html>
diff --git a/SystemTap_Beginners_Guide/utargetvariable.html b/SystemTap_Beginners_Guide/utargetvariable.html
new file mode 100644 (file)
index 0000000..b604904
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.2. Accessing User-Space Target Variables</title><link rel="stylesheet" href="Common_Content/css/default.css" type="text/css" /><link rel="stylesheet" media="print" href="Common_Content/css/print.css" type="text/css" /><meta name="generator" content="publican 2.5" /><meta name="package" content="Systemtap-SystemTap_Beginners_Guide-1.4-en-US-2.0-2" /><link rel="home" href="index.html" title="SystemTap Beginners Guide" /><link rel="up" href="userspace-probing.html" title="Chapter 4. User-Space Probing" /><link rel="prev" href="userspace-probing.html" title="Chapter 4. User-Space Probing" /><link rel="next" href="ustack.html" title="4.3. User-Space Stack Backtraces" /></head><body><p id="title"><a class="left" href="http://www.fedoraproject.org"><img src="Common_Content/images/image_left.png" alt="Product Site" /></a><a class="right" href="http://docs.fedoraproject.org"><img src="Common_Content/images/image_right.png" alt="Documentation Site" /></a></p><ul class="docnav"><li class="previous"><a accesskey="p" href="userspace-probing.html"><strong>Prev</strong></a></li><li class="next"><a accesskey="n" href="ustack.html"><strong>Next</strong></a></li></ul><div class="section" id="utargetvariable"><div class="titlepage"><div><div keep-together.within-column="always"><h2 class="title" id="utargetvariable">4.2. Accessing User-Space Target Variables</h2></div></div></div><a id="id1920418" class="indexterm"></a><div class="para">
+                       User-space target variables can be accessed in the same manner as described in <a class="xref" href="targetvariables.html">Section 3.3.2, “Target Variables”</a>. However, in Linux there are separate address spaces for the user and kernel code. When using "-&gt;" operator SystemTap will access the appropriate address space. For pointers to base types such as integers and strings there are a number of functions listed below to access user-space data. The first argument for each functions is the pointer to the data item.
+               </div><div class="variablelist"><dl><dt class="varlistentry"><span class="term">user_char(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the character at <em class="replaceable"><code>address</code></em> for the current user process.
+                                       </div></dd><dt class="varlistentry"><span class="term">user_short(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the short at <em class="replaceable"><code>address</code></em> for the current user process.
+                                       </div></dd><dt class="varlistentry"><span class="term">user_int(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the int at <em class="replaceable"><code>address</code></em> for the current user process.
+                                       </div></dd><dt class="varlistentry"><span class="term">user_long(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the long at <em class="replaceable"><code>address</code></em> for the current user process.
+                                       </div></dd><dt class="varlistentry"><span class="term">user_string(<em class="replaceable"><code>address</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the string at <em class="replaceable"><code>address</code></em> for the current user process.
+                                       </div></dd><dt class="varlistentry"><span class="term">user_string_n(<em class="replaceable"><code>address</code></em>, <em class="replaceable"><code>n</code></em>)</span></dt><dd><div class="para">
+                                               Obtain the string at <em class="replaceable"><code>address</code></em> for the current user process and limits the string to <em class="replaceable"><code>n</code></em> bytes.
+                                       </div></dd></dl></div></div><ul class="docnav"><li class="previous"><a accesskey="p" href="userspace-probing.html"><strong>Prev</strong>Chapter 4. User-Space Probing</a></li><li class="up"><a accesskey="u" href="#"><strong>Up</strong></a></li><li class="home"><a accesskey="h" href="index.html"><strong>Home</strong></a></li><li class="next"><a accesskey="n" href="ustack.html"><strong>Next</strong>4.3. User-Space Stack Backtraces</a></li></ul></body></html>
This page took 0.388483 seconds and 5 git commands to generate.