Self-Service Linux®: Mastering the Art of Problem Determination Mark Wilding and Dan Behman Self-Service Linux®

Total Page:16

File Type:pdf, Size:1020Kb

Self-Service Linux®: Mastering the Art of Problem Determination Mark Wilding and Dan Behman Self-Service Linux® Self-Service Linux® perens_series_7x9.25.fm Page 1 Tuesday, August 16, 2005 2:17 PM BRUCE PERENS’ OPEN SOURCE SERIES www.phptr.com/perens ◆ Java™ Application Development on Linux® Carl Albing and Michael Schwarz ◆ C++ GUI Programming with Qt 3 Jasmin Blanchette and Mark Summerfield ◆ Managing Linux Systems with Webmin: System Administration and Module Development Jamie Cameron ◆ Understanding the Linux Virtual Memory Manager Mel Gorman ◆ PHP 5 Power Programming Andi Gutmans, Stig Bakken, and Derick Rethans ◆ Linux® Quick Fix Notebook Peter Harrison ◆ Implementing CIFS: The Common Internet File System Christopher Hertel ◆ Open Source Security Tools: A Practical Guide to Security Applications Tony Howlett ◆ Apache Jakarta Commons: Reusable Java™ Components Will Iverson ◆ Embedded Software Development with eCos Anthony Massa ◆ Rapid Application Development with Mozilla Nigel McFarlane ◆ Subversion Version Control: Using the Subversion Version Control System in Development Projects William Nagel ◆ Intrusion Detection with SNORT: Advanced IDS Techniques Using SNORT, Apache, MySQL, PHP, and ACID Rafeeq Ur Rehman ◆ Cross-Platform GUI Programming with wxWidgets Julian Smart and Kevin Hock with Stefan Csomor ◆ Samba-3 by Example, Second Edition: Practical Exercises to Successful Deployment John H. Terpstra ◆ The Official Samba-3 HOWTO and Reference Guide, Second Edition John H. Terpstra and Jelmer R. Vernooij, Editors ◆ Self-Service Linux®: Mastering the Art of Problem Determination Mark Wilding and Dan Behman Self-Service Linux® Mastering the Art of Problem Determination Mark Wilding and Dan Behman PRENTICE HALL Professional Technical Reference Upper Saddle River, NJ ● Boston ● Indianapolis ● San Francisco ● New York ● Toronto ● Montreal ● London ● Munich ● Paris ● Madrid ● Capetown ● Sydney ● Tokyo ● Singapore ● Mexico City Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and the publisher was aware of a trademark claim, the designations have been printed with initial capital letters or in all capitals. The authors and publisher have taken care in the preparation of this book, but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for incidental or consequential damages in connection with or arising out of the use of the information or programs contained herein. The publisher offers excellent discounts on this book when ordered in quantity for bulk purchases or special sales, which may include electronic versions and/or custom covers and content particular to your business, training goals, marketing focus, and branding interests. For more information, please contact: U. S. Corporate and Government Sales (800) 382-3419 [email protected] For sales outside the U. S., please contact: International Sales [email protected] Visit us on the Web: www.phptr.com Library of Congress Number: 2005927150 Copyright © 2006 Pearson Education, Inc. This material may be distributed only subject to the terms and conditions set forth in the Open Publication License, v1.0 or later (the latest version is presently available at http:// www.opencontent.org/openpub/). ISBN 0-13-147751-X Text printed in the United States on recycled paper at R.R. Donnelley in Crawfordsville, Indiana. First printing, September, 2005 I would like to dedicate this book to my wife, Caryna, whose relentless nagging and badgering forced me to continue working on this book when nothing else could. Just kidding... Without Caryna’s support and understanding, I could never have written this book. Not only did she help me find time to write, she also spent countless hours formatting the entire book for production. I would also like to dedicate this book to my two sons, Rhys and Dylan, whose boundless energy acted as inspiration throughout the writing of this book. Mark Wilding Without the enduring love and patience of my wife Kim, this laborous project would have halted long ago. I dedicate this book to her, as well as to my beautiful son Nicholas, my family, and all of the Botzangs and Mayos. Dan Behman Gutmans_Frontmatter Page vi Thursday, September 23, 2004 9:05 AM Contents Preface Chapter 1: Best Practices and Initial Investigation Chapter 2: strace and System Call Tracing Explained Chapter 3: The /proc Filesystem Chapter 4: Compiling Chapter 5: The Stack Chapter 6: The GNU Debugger (GDB) Chapter 7: Linux System Crashes and Hangs Chapter 8: Kernel Debugging with KDB Chapter 9: ELF: Executable and Linking Format A: The Toolbox B: Data Collection Script Index Contents ○○○○○○○○○○○○○○○○○ Preface○○○○○○○○○○○○○○○○○○ xvii 1 Best Practices and Initial Investigation○○○○○○○○○○○○○○ 1 1.1 Introduction○○○○○○○○○○○○○○○○○○○○○○○○○○○○○ 1 1.2 Getting Your System(s) Ready for Effective Problem ○○○○○○○○○○○○○ Determination○○○○○○○○○○○○○○○ 2 1.3 The Four Phases of Investigation○○○○○○○○○○○○○○○○○ 3 1.3.1 Phase #1: Initial Investigation Using Your Own Skills 5 1.3.2 Phase #2: Searching the Internet Effectively○○○○○○ 9 1.3.3 Phase #3: Begin Deeper Investigation (Good Problem Investigation Practices)○○○○○○○○○○○○○○○○○○ 12 ○○○○○ 1.3.4 Phase #4: Getting Help or New Ideas○○○○○○ 21 ○○○○○○○ 1.4 Technical Investigation○○○○○○○○○○○○○○○○ 28 ○○○○○ 1.4.1 Symptom Versus Cause○○○○○○○○○○○○○ 28 1.5 Troubleshooting Commercial Products○○○○○○○○○○○○○○○ 38 1.6 Conclusion○○○○○○○○○○○○○○○○○○○○○○○○○○○○○○○ 39 2 strace and System Call Tracing Explained○○○○○○○○○○○○○ 41 ○○○○○○○○○○ 2.1 Introduction○○○○○○○○○○○○○○○○○○○ 41 2.2 What Is strace?○○○○○○○○○○○○○○○○○○○○○○○○○○○○ 41 2.2.1 More Information from the Kernel Side○○○○○○○○○○ 45 2.2.2 When to Use It○○○○○○○○○○○○○○○○○○○○○○○○ 48 ○○○○○○○○○○○○○○○ 2.2.3 Simple Example○○○○○○○○ 49 ○○○○○○○○ 2.2.4 Same Program Built Statically○○○○○○○ 53 2.3 Important strace Options○○○○○○○○○○○○○○○○○○○○○○ 54 ○○○○○○○○ 2.3.1 Following Child Processes○○○○○○○○○ 54 2.3.2 Timing System Call Activity○○○○○○○○○○○○○○○○ 55 x Contents ○○○○○○○○○○ 2.3.3 Verbose Mode○○○○○○○○○○○○○○ 57 ○○○○○○○○○○○○ 2.3.4 Tracing a Running Process○○○○○ 59 2.4 Effects and Issues of Using strace○○○○○○○○○○○○○○○○○ 60 ○○○○○○○○○○○○○○○ 2.4.1 strace and EINTR○○○○○○○ 61 ○○○○○○○○○○○○○○○ 2.5 Real Debugging Examples○○○○○○○ 62 2.5.1 Reducing Start Up Time by Fixing ○○○○○○○○○○ LD_LIBRARY_PATH○○○○○○○○○○ 62 2.5.2 The PATH Environment Variable○○○○○○○○○○○○○ 65 2.5.3 stracing inetd or xinetd (the Super Server)○○○○○○○○ 66 ○○○○○○○○○○○ 2.5.4 Communication Errors○○○○○○○○ 68 2.5.5 Investigating a Hang Using strace○○○○○○○○○○○○ 69 2.5.6 Reverse Engineering (How the strace Tool Itself Works) 71 2.6 System Call Tracing Examples○○○○○○○○○○○○○○○○○○○ 74 ○○○○○○ 2.6.1 Sample Code○○○○○○○○○○○○○○○○○○○ 75 2.6.2 The System Call Tracing Code Explained○○○○○○○○ 87 ○○○○○○○○○○ 2.7 Conclusion○○○○○○○○○○○○○○○○○○○○○ 88 3 The /proc Filesystem○○○○○○○○○○○○○○○○○○○○○○○○○○○ 89 ○○○○○○○○ 3.1 Introduction○○○○○○○○○○○○○○○○○○○○○○ 89 ○○○○○○○○○○○○ 3.2 Process Information○○○○○○○○○○○○○ 90 3.2.1 /proc/self○○○○○○○○○○○○○○○○○○○○○○○○○○○ 90 ○○○○○○○○ 3.2.2 /proc/<pid> in More Detail○○○○○○○○○ 91 ○○○○○○○○○○○ 3.2.3 /proc/<pid>/cmdline○○○○○○○○○○ 107 ○○○○○○○○○○○○○○ 3.2.4 /proc/<pid>/environ○○○○○○○ 107 ○○○○○○ 3.2.5 /proc/<pid>/mem○○○○○○○○○○○○○○○○○ 107 ○○○○○○○○ 3.2.6 /proc/<pid>/fd○○○○○○○○○○○○○○○○ 108 3.2.7 /proc/<pid>/mapped base○○○○○○○○○○○○○○○○○○ 108 3.3 Kernel Information and Manipulation○○○○○○○○○○○○○○○ 109 ○○○○○○○ 3.3.1 /proc/cmdline○○○○○○○○○○○○○○○○○○ 109 3.3.2 /proc/config.gz or /proc/sys/config.gz○○○○○○○○○○○○ 109 3.3.3 /proc/cpufreq○○○○○○○○○○○○○○○○○○○○○○○○○ 109 3.3.4 /proc/cpuinfo○○○○○○○○○○○○○○○○○○○○○○○○○ 110 ○○○○○○○○○○○○ 3.3.5 /proc/devices○○○○○○○○○○○○○ 110 ○○○○○○○○○○○○○○○○○○ 3.3.6 /proc/kcore○○○○○○○○ 111 3.3.7 /proc/locks○○○○○○○○○○○○○○○○○○○○○○○○○○ 111 3.3.8 /proc/meminfo○○○○○○○○○○○○○○○○○○○○○○○○ 111 ○○○○○ 3.3.9 /proc/mm○○○○○○○○○○○○○○○○○○○○○○ 111 ○○○○○○○○○○○○○○○○ 3.3.10 /proc/modules○○○○○○○○○ 112 ○○○○○○○ 3.3.11 /proc/net○○○○○○○○○○○○○○○○○○○○ 112 3.3.12 /proc/partitions○○○○○○○○○○○○○○○○○○○○○○○○ 112 ○○○○○○○○○○○○○ 3.3.13 /proc/pci○○○○○○○○○○○○○○○ 113 ○○○○○○○○ 3.3.14 /proc/slabinfo○○○○○○○○○○○○○○○○○ 113 Contents xi 3.4 System Information and Manipulation○○○○○○○○○○○○○○ 113 ○○○○○○○○○○ 3.4.1 /proc/sys/fs○○○○○○○○○○○○○○○○ 113 ○○○○○○○○○○○○○○○ 3.4.2 /proc/sys/kernel○○○○○○○○ 115 ○○○○○○○○○ 3.4.3 /proc/sys/vm○○○○○○○○○○○○○○○○ 120 ○○○○○○○○○○○○○○○○○○○○○○○○ 3.5 Conclusion○○○○○○ 120 ○○○○○○○ 4 Compiling○○○○○○○○○○○○○○○○○○○○○○○○○○ 121 ○○○○○○○○○○○○○○○○○○○○○○ 4.1 Introduction○○○○○○○ 121 ○○○○○○○○○○○○○○○ 4.2 The GNU Compiler Collection○○○○ 121 4.2.1 A Brief History of GCC○○○○○○○○○○○○○○○○○○○ 121 ○○○○○○○○○○○ 4.2.2 GCC Version Compatibility○○○○○○ 122 ○○○○○○○○○○○ 4.3 Other Compilers○○○○○○○○○○○○○○○○ 122 ○○○○○○ 4.4 Compiling the Linux Kernel○○○○○○○○○○○○○○ 123 ○○○○○○○○ 4.4.1 Obtaining the Kernel Source○○○○○○○○ 123 4.4.2 Architecture Specific Source○○○○○○○○○○○○○○○○ 124 4.4.3 Working with Kernel Source Compile Errors○○○○○○○ 124 ○○○○○○○ 4.4.4 General Compilation Problems○○○○○○○ 128 ○○○○○○○○○○ 4.5 Assembly Listings○○○○○○○○○○○○○○○○ 133 4.5.1 Purpose of Assembly Listings○○○○○○○○○○○○○○○ 134 4.5.2 Generating Assembly Listings○○○○○○○○○○○○○○○ 135 4.5.3 Reading and Understanding an Assembly Listing○○○○ 136 4.6 Compiler Optimizations○○○○○○○○○○○○○○○○○○○○○○○ 140 ○○○○○○○○○○○○○○○○○○○○○○○○○○○ 4.7 Conclusion○○○○ 149 ○○○○○○○○○ 5 The Stack○○○○○○○○○○○○○○○○○○○○○○○○ 151 ○○○○○○○○○○○○ 5.1 Introduction○○○○○○○○○○○○○○○○○○ 151 ○○○○○○○○○○○○○○○ 5.2 A Real-World Analogy○○○○○○○○○ 152 ○○○○○○ 5.3 Stacks in x86 and x86-64 Architectures○○○○○○○○ 153 5.4 What Is a Stack Frame?○○○○○○○○○○○○○○○○○○○○○○○
Recommended publications
  • Oracle® Linux 7 Monitoring and Tuning the System
    Oracle® Linux 7 Monitoring and Tuning the System F32306-03 October 2020 Oracle Legal Notices Copyright © 2020, Oracle and/or its affiliates. This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, then the following notice is applicable: U.S. GOVERNMENT END USERS: Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs) and Oracle computer documentation or other Oracle data delivered to or accessed by U.S. Government end users are "commercial computer software" or "commercial computer software documentation" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, reproduction, duplication, release, display, disclosure, modification, preparation of derivative works, and/or adaptation of i) Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs), ii) Oracle computer documentation and/or iii) other Oracle data, is subject to the rights and limitations specified in the license contained in the applicable contract.
    [Show full text]
  • SFLC V Conservancy
    Trademark Trial and Appeal Board Electronic Filing System. http://estta.uspto.gov ESTTA Tracking number: ESTTA863914 Filing date: 12/11/2017 IN THE UNITED STATES PATENT AND TRADEMARK OFFICE BEFORE THE TRADEMARK TRIAL AND APPEAL BOARD Proceeding 92066968 Party Defendant Software Freedom Conservancy Correspondence PAMELA S CHESTECK Address CHESTEK LEGAL P O BOX 2492 RALEIGH, NC 27602 UNITED STATES Email: [email protected] Submission Motion for Summary Judgment Yes, the Filer previously made its initial disclosures pursuant to Trademark Rule 2.120(a); OR the motion for summary judgment is based on claim or issue pre- clusion, or lack of jurisdiction. The deadline for pretrial disclosures for the first testimony period as originally set or reset: 07/20/2018 Filer's Name Pamela S Chestek Filer's email [email protected] Signature /Pamela S Chestek/ Date 12/11/2017 Attachments Motion for SJ on affirmative defenses-signed.pdf(756280 bytes ) Kuhn-Declara- tion_summary-judgment_as-submitted_reduced-size-signed.pdf(2181238 bytes ) Sandler-declara- tion_summary-judgment_as-submitted-reduced-size-signed.pdf(1777273 bytes ) Chestek declaration_summary-judgment-signed-with-exhibits.pdf(2003142 bytes ) IN THE UNITED STATES PATENT AND TRADEMARK OFFICE BEFORE THE TRADEMARK TRIAL AND APPEAL BOARD In the Mater of Registraion No. 4212971 Mark: SOFTWARE FREEDOM CONSERVANCY Registraion date: September 25, 2012 Sotware Freedom Law Center Peiioner, v. Cancellaion No. 92066968 Sotware Freedom Conservancy Registrant. RESPONDENT’S MOTION FOR SUMMARY JUDGMENT ON ITS AFFIRMATIVE DEFENSES Introducion The Peiioner, Sotware Freedom Law Center (“SFLC”), is a provider of legal services. It had the idea to create an independent enity that would ofer inancial and administraive services for free and open source sotware projects.
    [Show full text]
  • Using the GNU Compiler Collection (GCC)
    Using the GNU Compiler Collection (GCC) Using the GNU Compiler Collection by Richard M. Stallman and the GCC Developer Community Last updated 23 May 2004 for GCC 3.4.6 For GCC Version 3.4.6 Published by: GNU Press Website: www.gnupress.org a division of the General: [email protected] Free Software Foundation Orders: [email protected] 59 Temple Place Suite 330 Tel 617-542-5942 Boston, MA 02111-1307 USA Fax 617-542-2652 Last printed October 2003 for GCC 3.3.1. Printed copies are available for $45 each. Copyright c 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with the Invariant Sections being \GNU General Public License" and \Funding Free Software", the Front-Cover texts being (a) (see below), and with the Back-Cover Texts being (b) (see below). A copy of the license is included in the section entitled \GNU Free Documentation License". (a) The FSF's Front-Cover Text is: A GNU Manual (b) The FSF's Back-Cover Text is: You have freedom to copy and modify this GNU Manual, like GNU software. Copies published by the Free Software Foundation raise funds for GNU development. i Short Contents Introduction ...................................... 1 1 Programming Languages Supported by GCC ............ 3 2 Language Standards Supported by GCC ............... 5 3 GCC Command Options .........................
    [Show full text]
  • The GNU Configure and Build System
    The GNU configure and build system Ian Lance Taylor Copyright c 1998 Cygnus Solutions Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies. Permission is granted to copy and distribute modified versions of this manual under the con- ditions for verbatim copying, provided that the entire resulting derived work is distributed under the terms of a permission notice identical to this one. Permission is granted to copy and distribute translations of this manual into another lan- guage, under the above conditions for modified versions, except that this permission notice may be stated in a translation approved by the Free Software Foundation. i Table of Contents 1 Introduction ............................... 1 1.1 Goals................................................... 1 1.2 Tools ................................................... 1 1.3 History ................................................. 1 1.4 Building ................................................ 2 2 Getting Started............................ 3 2.1 Write configure.in ....................................... 4 2.2 Write Makefile.am ....................................... 6 2.3 Write acconfig.h......................................... 7 2.4 Generate files ........................................... 8 2.5 Example................................................ 8 2.5.1 First Try....................................... 9 2.5.2 Second Try.................................... 10 2.5.3 Third
    [Show full text]
  • Linux at 25 PETERHISTORY H
    Linux at 25 PETERHISTORY H. SALUS Peter H. Salus is the author of A n June 1991, at the USENIX conference in Nashville, BSD NET-2 was Quarter Century of UNIX (1994), announced. Two months later, on August 25, Linus Torvalds announced Casting the Net (1995), and The his new operating system on comp.os.minix. Today, Android, Google’s Daemon, the Gnu and the Penguin I (2008). [email protected] version of Linux, is used on over two billion smartphones and other appli- ances. In this article, I provide some history about the early years of Linux. Linus was born into the Swedish minority of Finland (about 5% of the five million Finns). He was a “math guy” throughout his schooling. Early on, he “inherited” a Commodore VIC- 20 (released in June 1980) from his grandfather; in 1987 he spent his savings on a Sinclair QL (released in January 1984, the “Quantum Leap,” with a Motorola 68008 running at 7.5 MHz and 128 kB of RAM, was intended for small businesses and the serious hobbyist). It ran Q-DOS, and it was what got Linus involved: One of the things I hated about the QL was that it had a read-only operating system. You couldn’t change things ... I bought a new assembler ... and an editor.... Both ... worked fine, but they were on the microdrives and couldn’t be put on the EEPROM. So I wrote my own editor and assembler and used them for all my programming. Both were written in assembly language, which is incredibly stupid by today’s standards.
    [Show full text]
  • Customizing Debian Benjamin Mako Hill
    Customizing Debian “Fork Yours with Debian GNU/Linux” Benjamin Mako Hill [email protected] http://mako.yukidoke.org Ubuntu Debian Project Software in the Public Interest Benjamin Mako Hill LCA - Debian MiniConf4 http://mako.yukidoke.org The World of Debian Customizers There are 115 distributions derived from Debian. AbulÉdu • Adamantix • AGNULA GNU/Linux Audio Distribution • ANTEMIUM Linux • Arabbix • ARMA aka Omoikane GNU/Linux • ASLinux • Auditor Security Linux • Augustux • B2D Linux • BEERnix • Biadix • BIG LINUX • Bioknoppix • BlackRhino • Bluewall GNU/Linux • Bonzai Linux • BrlSpeak • Càtix • CensorNet • Clusterix • ClusterKNOPPIX • Condorux • Damn Small Linux • Danix • DebXPde • eduKnoppix • ERPOSS • ESware • Euronode • FAMELIX • Feather Linux • Flonix • Vital Data Forensic or Rescue Kit (FoRK) • Freeduc-cd • GEOLivre Linux • Gibraltar Firewall • GNIX-Vivo • Gnoppix Linux • gnuLinEx • GNU/Linux Kinneret • GNUstep Live CD • grml • Guadalinex • Helix • Hiweed Linux • Impi Linux • Julex • K-DEMar • Kaella • Knoppix Linux Azur • Kalango Linux • KANOTIX • KlusTriX • knopILS • Knoppel • Knoppix • Knoppix 64 • Knoppix STD • KnoppiXMAME • KnoppMyth • Kurumin Linux • LAMPPIX • Libranet GNU/Linux • LIIS Linux • LinEspa • Linspire • Linux Live Game Project • Linux Loco • LinuxDefender Live! CD • Linuxin • LiVux • Local Area Security Linux (L.A.S.) • Luinux • Luit Linux • MAX: Madrid_Linux • Mediainlinux • MEPIS Linux • Metadistro-Pequelin • MIKO GNYO/Linux • Morphix • Munjoy Linux • Nature's Linux • NordisKnoppix • OGo Knoppix • Oralux • Overclockix
    [Show full text]
  • Pingdirectory Administration Guide Version
    Release 7.3.0.3 Server Administration Guide PingDirectory | Contents | ii Contents PingDirectory™ Product Documentation................................................ 20 Overview of the Server............................................................................. 20 Server Features.................................................................................................................................20 Administration Framework.................................................................................................................21 Server Tools Location....................................................................................................................... 22 Preparing Your Environment....................................................................22 Before You Begin.............................................................................................................................. 22 System requirements..............................................................................................................22 Installing Java......................................................................................................................... 23 Preparing the Operating System (Linux).......................................................................................... 24 Configuring the File Descriptor Limits.................................................................................... 24 File System Tuning.................................................................................................................25
    [Show full text]
  • Linux Performance Tools
    Linux Performance Tools Brendan Gregg Senior Performance Architect Performance Engineering Team [email protected] @brendangregg This Tutorial • A tour of many Linux performance tools – To show you what can be done – With guidance for how to do it • This includes objectives, discussion, live demos – See the video of this tutorial Observability Benchmarking Tuning Stac Tuning • Massive AWS EC2 Linux cloud – 10s of thousands of cloud instances • FreeBSD for content delivery – ~33% of US Internet traffic at night • Over 50M subscribers – Recently launched in ANZ • Use Linux server tools as needed – After cloud monitoring (Atlas, etc.) and instance monitoring (Vector) tools Agenda • Methodologies • Tools • Tool Types: – Observability – Benchmarking – Tuning – Static • Profiling • Tracing Methodologies Methodologies • Objectives: – Recognize the Streetlight Anti-Method – Perform the Workload Characterization Method – Perform the USE Method – Learn how to start with the questions, before using tools – Be aware of other methodologies My system is slow… DEMO & DISCUSSION Methodologies • There are dozens of performance tools for Linux – Packages: sysstat, procps, coreutils, … – Commercial products • Methodologies can provide guidance for choosing and using tools effectively • A starting point, a process, and an ending point An#-Methodologies • The lack of a deliberate methodology… Street Light An<-Method 1. Pick observability tools that are: – Familiar – Found on the Internet – Found at random 2. Run tools 3. Look for obvious issues Drunk Man An<-Method • Tune things at random until the problem goes away Blame Someone Else An<-Method 1. Find a system or environment component you are not responsible for 2. Hypothesize that the issue is with that component 3. Redirect the issue to the responsible team 4.
    [Show full text]
  • UNIX OS Agent User's Guide
    IBM Tivoli Monitoring Version 6.3.0 UNIX OS Agent User's Guide SC22-5452-00 IBM Tivoli Monitoring Version 6.3.0 UNIX OS Agent User's Guide SC22-5452-00 Note Before using this information and the product it supports, read the information in “Notices” on page 399. This edition applies to version 6, release 3 of IBM Tivoli Monitoring (product number 5724-C04) and to all subsequent releases and modifications until otherwise indicated in new editions. © Copyright IBM Corporation 1994, 2013. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Tables ...............vii Solaris System CPU Workload workspace ....28 Solaris Zone Processes workspace .......28 Chapter 1. Using the monitoring agent . 1 Solaris Zones workspace ..........28 System Details workspace .........28 New in this release ............2 System Information workspace ........29 Components of the monitoring agent ......3 Top CPU-Memory %-VSize Details workspace . 30 User interface options ...........4 UNIX OS workspace ...........30 UNIX Detail workspace ..........31 Chapter 2. Requirements for the Users workspace ............31 monitoring agent ...........5 Enabling the Monitoring Agent for UNIX OS to run Chapter 4. Attributes .........33 as a nonroot user .............7 Agent Availability Management Status attributes . 36 Securing your IBM Tivoli Monitoring installation 7 Agent Active Runtime Status attributes .....37 Setting overall file ownership and permissions for AIX AMS attributes............38
    [Show full text]
  • Release 0.11 Todd Gamblin
    Spack Documentation Release 0.11 Todd Gamblin Feb 07, 2018 Basics 1 Feature Overview 3 1.1 Simple package installation.......................................3 1.2 Custom versions & configurations....................................3 1.3 Customize dependencies.........................................4 1.4 Non-destructive installs.........................................4 1.5 Packages can peacefully coexist.....................................4 1.6 Creating packages is easy........................................4 2 Getting Started 7 2.1 Prerequisites...............................................7 2.2 Installation................................................7 2.3 Compiler configuration..........................................9 2.4 Vendor-Specific Compiler Configuration................................ 13 2.5 System Packages............................................. 16 2.6 Utilities Configuration.......................................... 18 2.7 GPG Signing............................................... 20 2.8 Spack on Cray.............................................. 21 3 Basic Usage 25 3.1 Listing available packages........................................ 25 3.2 Installing and uninstalling........................................ 42 3.3 Seeing installed packages........................................ 44 3.4 Specs & dependencies.......................................... 46 3.5 Virtual dependencies........................................... 50 3.6 Extensions & Python support...................................... 53 3.7 Filesystem requirements........................................
    [Show full text]
  • Praise for the Official Ubuntu Book
    Praise for The Official Ubuntu Book “The Official Ubuntu Book is a great way to get you started with Ubuntu, giving you enough information to be productive without overloading you.” —John Stevenson, DZone Book Reviewer “OUB is one of the best books I’ve seen for beginners.” —Bill Blinn, TechByter Worldwide “This book is the perfect companion for users new to Linux and Ubuntu. It covers the basics in a concise and well-organized manner. General use is covered separately from troubleshooting and error-handling, making the book well-suited both for the beginner as well as the user that needs extended help.” —Thomas Petrucha, Austria Ubuntu User Group “I have recommended this book to several users who I instruct regularly on the use of Ubuntu. All of them have been satisfied with their purchase and have even been able to use it to help them in their journey along the way.” —Chris Crisafulli, Ubuntu LoCo Council, Florida Local Community Team “This text demystifies a very powerful Linux operating system . in just a few weeks of having it, I’ve used it as a quick reference a half dozen times, which saved me the time I would have spent scouring the Ubuntu forums online.” —Darren Frey, Member, Houston Local User Group This page intentionally left blank The Official Ubuntu Book Sixth Edition This page intentionally left blank The Official Ubuntu Book Sixth Edition Benjamin Mako Hill Matthew Helmke Amber Graner Corey Burger With Jonathan Jesse, Kyle Rankin, and Jono Bacon Upper Saddle River, NJ • Boston • Indianapolis • San Francisco New York • Toronto • Montreal • London • Munich • Paris • Madrid Capetown • Sydney • Tokyo • Singapore • Mexico City Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks.
    [Show full text]
  • System Analysis and Tuning Guide System Analysis and Tuning Guide SUSE Linux Enterprise Server 15 SP1
    SUSE Linux Enterprise Server 15 SP1 System Analysis and Tuning Guide System Analysis and Tuning Guide SUSE Linux Enterprise Server 15 SP1 An administrator's guide for problem detection, resolution and optimization. Find how to inspect and optimize your system by means of monitoring tools and how to eciently manage resources. Also contains an overview of common problems and solutions and of additional help and documentation resources. Publication Date: September 24, 2021 SUSE LLC 1800 South Novell Place Provo, UT 84606 USA https://documentation.suse.com Copyright © 2006– 2021 SUSE LLC and contributors. All rights reserved. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or (at your option) version 1.3; with the Invariant Section being this copyright notice and license. A copy of the license version 1.2 is included in the section entitled “GNU Free Documentation License”. For SUSE trademarks, see https://www.suse.com/company/legal/ . All other third-party trademarks are the property of their respective owners. Trademark symbols (®, ™ etc.) denote trademarks of SUSE and its aliates. Asterisks (*) denote third-party trademarks. All information found in this book has been compiled with utmost attention to detail. However, this does not guarantee complete accuracy. Neither SUSE LLC, its aliates, the authors nor the translators shall be held liable for possible errors or the consequences thereof. Contents About This Guide xii 1 Available Documentation xiii
    [Show full text]