SystemTap Beginners Guide

时间:2022-05-09 20:12:38
SystemTap 3.0

SystemTap Beginners Guide

Introduction to SystemTap

Edition 3.0

 

Red Hat, Inc.

Don Domingo

Engineering Services and Operations Content Services

ddomingo@redhat.com

William Cohen

Engineering Services and Operations Performance Tools

wcohen@redhat.com

Copyright © 2013 Red Hat, Inc

Legal Notice

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.
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.
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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
For more details see the file COPYING in the source distribution of Linux.

Abstract

This guide provides basic instructions on how to use SystemTap to monitor different subsystems of a Linux system in finer detail.
Preface
1. Document Conventions
1.1. Typographic Conventions
1.2. Pull-quote Conventions
1.3. Notes and Warnings
2. We Need Feedback!
1. Introduction
1.1. Documentation Goals
1.2. SystemTap Capabilities
1.3. Limitations of SystemTap
2. Using SystemTap
2.1. Installation and Setup
2.1.1. Installing SystemTap
2.1.2. Installing Required Kernel Information Packages Manually
2.1.3. Initial Testing
2.2. Generating Instrumentation for Other Computers
2.3. Running SystemTap Scripts
2.3.1. SystemTap Flight Recorder Mode
3. Understanding How SystemTap Works
3.1. Architecture
3.2. SystemTap Scripts
3.2.1. Event
3.2.2. SystemTap Handler/Body
3.3. Basic SystemTap Handler Constructs
3.3.1. Variables
3.3.2. Target Variables
3.3.3. Conditional Statements
3.3.4. Command-Line Arguments
3.4. Associative Arrays
3.5. Array Operations in SystemTap
3.5.1. Assigning an Associated Value
3.5.2. Reading Values From Arrays
3.5.3. Incrementing Associated Values
3.5.4. Processing Multiple Elements in an Array
3.5.5. Clearing/Deleting Arrays and Array Elements
3.5.6. Using Arrays in Conditional Statements
3.5.7. Computing for Statistical Aggregates
3.6. Tapsets
4. User-space Probing
4.1. User-Space Events
4.2. Accessing User-Space Target Variables
4.3. User-Space Stack Backtraces
5. Useful SystemTap Scripts
5.1. Network
5.1.1. Network Profiling
5.1.2. Tracing Functions Called in Network Socket Code
5.1.3. Monitoring Incoming TCP Connections
5.1.4. Monitoring TCP Packets
5.1.5. Monitoring Network Packets Drops in Kernel
5.2. Disk
5.2.1. Summarizing Disk Read/Write Traffic
5.2.2. Tracking I/O Time For Each File Read or Write
5.2.3. Track Cumulative IO
5.2.4. I/O Monitoring (By Device)
5.2.5. Monitoring Reads and Writes to a File
5.2.6. Monitoring Changes to File Attributes
5.2.7. Periodically Print I/O Block Time
5.3. Profiling
5.3.1. Counting Function Calls Made
5.3.2. Call Graph Tracing
5.3.3. Determining Time Spent in Kernel and User Space
5.3.4. Monitoring Polling Applications
5.3.5. Tracking Most Frequently Used System Calls
5.3.6. Tracking System Call Volume Per Process
5.4. Identifying Contended User-Space Locks
6. Understanding SystemTap Errors
6.1. Parse and Semantic Errors
6.2. Runtime Errors and Warnings
7. References
A. Revision History
Index

SystemTap Beginners Guide的更多相关文章

  1. Beginners Guide To Learn Dimension Reduction Techniques

    Beginners Guide To Learn Dimension Reduction Techniques Introduction Brevity is the soul of wit This ...

  2. Portrait Photography Beginners Guide

    Please visit photoandtips稻糠亩 for more information. 六级/考研单词: vogue, derive, gorgeous, thereby, strict ...

  3. Beginners Guide To Web Development

    Web Development Front End Development Back End Development

  4. [Selenium.2.Testing.Tools.Beginners.Guide]读书笔记

    Assert, this allows the test to check if the element is on the page, if it is not available then the ...

  5. What is OWIN? A Beginners Guide

    http://www.codedigest.com/posts/1/what-is-owin-a-beginners-guide http://owin.org/html/spec/owin-1.0. ...

  6. SystemTap - 安装

    按照SystemTap Beginners Guide的Installation and Setup部分安装了SystemTap,没想到竟然还有点曲折,在这里纪录一下. 环境 Linux发行版本:Ce ...

  7. Finding the source of signals on Linux with strace, auditd, or systemtap

    inux and UNIX® like operating systems commonly use signals to communicate between processes. The use ...

  8. Examining Huge Pages or Transparent Huge Pages performance

    Posted by William Cohen on March 10, 2014 All modern processors use page-based mechanisms to transla ...

  9. Python 和 C/C++ 拓展程序如何性能优化?看这一篇文就够

    作者:王璐璐 | 旷视 MegEngine 架构师 一. 背景 在 MegEngine imperative runtime 的早期开发中,我们面临着一些的性能优化问题.除了一些已知需要重构的地方(早 ...

随机推荐

  1. 自制Console线(已测试CISCO3560可用)

    D9的顺序是5口在上,4口在下.从右到左分别是1-5,6-9. 5 4 3 2 1 o o o o o o o o o 9 8 7 6 用万用表量出D9的口的对应颜色.然后按照下面的表.把颜色填写上. ...

  2. OkHttpUtils

    对okhttp的封装类,okhttp见:https://github.com/square/okhttp.目前对应okhttp版本3.3.1. 用法: Android Studio compile ' ...

  3. 基于OpenMP的矩阵乘法实现及效率提升分析

    一.  矩阵乘法串行实现 例子选择两个1024*1024的矩阵相乘,根据矩阵乘法运算得到运算结果.其中,两个矩阵中的数为double类型,初值由随机数函数产生.代码如下: #include <i ...

  4. Indy的TCPServer到底能支持多少个连接

    最近一个项目,最开始使用IdTcpServer,在大压力测试的时候,只连接了800个多一点的客户端(每个客户端连接上之后每秒钟发送一个几十字节的报文,服务器应答).但是持续的时间不会超过10分钟,服务 ...

  5. 最近找java实习面试被问到的东西总结(Java方向)

    时间,就是这么很悄悄的溜走了将近两个年华,不知不觉的,研二了,作为一个一般学校的研究生,不知道该说自己是不学无术,还是说有过努力,反正,这两年里,有过坚持,有过堕落,这不,突然间,有种开窍的急迫感,寻 ...

  6. MySQL数据库 Event 定时执行任务&period;

    一.背景 由于项目的业务是不断往前跑的,所以难免数据库的表的量会越来越庞大,不断的挤占硬盘空间.即使再大的空间也支撑不起业务的增长,所以定期删除不必要的数据是很有必要的.在我们项目中由于不清理数据,一 ...

  7. BZOJ5261 Rhyme--广义SAM&plus;拓扑排序

    原题链接,不是权限题 题目大意 有\(n\)个模板串,让你构造一个尽量长的串,使得这个串中任意一个长度为\(k\)的子串都是至少一个模板串的子串 题解 可以先看一下这道题 [POI2000]病毒 虽然 ...

  8. vue浏览器滚动加载更多

    created () { var that = this; window.addEventListener('scroll',this.scroll,true) console.log(this.$r ...

  9. windows 设置CapsLock键开启大写后使用shift键取消大写

    1.打开控制面板——>时钟.语言和区域——>更改键盘或其它输入法——>更改键盘——>高级键设置——>要关闭Caps Lock 2.ok

  10. Netty系列之Netty百万级推送服务设计要点&lpar;转&rpar;

    1. 背景 1.1. 话题来源 最近很多从事移动互联网和物联网开发的同学给我发邮件或者微博私信我,咨询推送服务相关的问题.问题五花八门,在帮助大家答疑解惑的过程中,我也对问题进行了总结,大概可以归纳为 ...