OPEN SOURCE CONFERENCE  2009 MSC Malaysia Satyajit Tripathi ISV-Engineering, Sun Microsystems
Audience <ul><li>Prospective Customer </li></ul><ul><li>Independent Software Vendor (ISV) </li></ul><ul><ul><li>Chief Exec...
OpenSolaris <ul><li>Operating System (OS) </li></ul><ul><ul><li>Code, based on industry leading Enterprise Solaris by Sun ...
Historic Events <ul><li>Solaris 2.0 : June 1992 Development started in 1988. Derived from Unix System V4 </li></ul><ul><li...
Solaris Release Model
One Solaris Platform <ul><li>Enterprise class </li></ul><ul><li>Unmatched level of support </li></ul><ul><li>Longer releas...
OpenSolaris Inclusions <ul><li>Software Included </li></ul><ul><ul><li>Firefox Browser </li></ul></ul><ul><ul><li>Thunderb...
OpenSolaris Distro <ul><li>Solaris Express Community Edition </li></ul><ul><li>BeleniX </li></ul><ul><li>Jaris </li></ul><...
OpenSolaris Communities <ul><li>A Social Group to have Open Conversation </li></ul><ul><li>Governance Process </li></ul><u...
OpenSolaris Project <ul><li>Enhance and Improve OpenSolaris </li></ul><ul><li>Build Community of Committed Members </li></...
Participation Is Key <ul><li>Everyone Has Something to Contribute </li></ul><ul><li>Code Of Conduct </li></ul><ul><ul><li>...
What It Means To <ul><li>Prospective Customer </li></ul><ul><ul><li>Low Cost Entrant </li></ul></ul><ul><ul><li>Highly Rel...
What It Means To <ul><li>ISV CXO/ CTO </li></ul><ul><ul><li>High Quality and Industry Standard </li></ul></ul><ul><ul><li>...
What It Means To <ul><li>System Administrator </li></ul><ul><ul><li>Easy Installation, Administration, Monitoring </li></u...
What It Means To <ul><li>Software Developer </li></ul><ul><ul><li>Latest Innovations and Cutting Edge technology </li></ul...
What It Means To <ul><li>Research Scientist and Student </li></ul><ul><ul><li>Diverse Community to discuss and share Ideas...
What It Means To <ul><li>You ! </li></ul><ul><ul><li>Easy To Get </li></ul></ul><ul><ul><li>Easy To Install </li></ul></ul...
OpenSolaris Unleashing Potential
Useful Information <ul><li>OpenSolaris.Com </li></ul><ul><ul><li>Download  http://www.opensolaris.com/get </li></ul></ul><...
<ul><ul><li>Congratulations for Participating </li></ul></ul>
Next Session <ul><li>OpenSolaris and Advanced Technologies </li></ul>
OpenSolaris Advanced Technologies <ul><li>ZFS (Zettabyte File System) </li></ul><ul><li>SMF (Service Management Facility) ...
Zettabyte File System (Zeta = 10 21 ) <ul><li>Better, Safer way to Manage Data </li></ul><ul><li>First 128-bit File System...
ZFS Virtually Unlimited <ul><li>Traditional Volumes </li></ul><ul><li>Abstraction : Virtual disk </li></ul><ul><li>Partiti...
<ul><li>Transaction Group Batch I/O </li></ul><ul><li>Schedule, Aggregate, and   Issue I/O at will </li></ul><ul><li>Loss ...
ZFS Dynamic Stripping <ul><li>BEFORE </li></ul><ul><li>Writes : stripped across all 3 mirrors </li></ul><ul><li>Reads : wh...
ZFS Additional Capabilities <ul><li>Intelligent Prefetch </li></ul><ul><ul><li>Multiple Independent Pre-fetch Streams </li...
Service Management Facility (SMF) <ul><li>Simplified Service Management </li></ul><ul><ul><li>Services are Objects easily ...
SMF Service Components <ul><li>SMF Service Manifest </li></ul><ul><ul><li>Defines Default Service Properties in the Reposi...
Zones and Container <ul><li>Virtualization instrumented within OS Kernel </li></ul><ul><ul><li>Resource Management </li></...
Zone States <ul><li>Configured </li></ul><ul><ul><li>Configuration completed and committed </li></ul></ul><ul><li>Installe...
Zones Usefulness for Developers <ul><li>Virtual OS Environment Partitioning </li></ul><ul><ul><li>One large system can be ...
Branded Zone (BrandZ) <ul><li>BrandZ extends Solaris Zones Infrastructure </li></ul><ul><ul><li>Brand Attribute set at Zon...
Dynamic Tracing (D Trace) <ul><li>DTrace, A Comprehensive Framework for Solaris TM  Operating Environment </li></ul><ul><u...
DTrace World Probes
D Language <ul><li>'D' Language, like 'C' and constructs similar to awk </li></ul><ul><li>Complete Access to Kernel C type...
DTrace Probe <ul><li>Point of Instrumentation within OS Kernel </li></ul><ul><li>Has a  Name </li></ul><ul><li>Identifies ...
DTrace Provider <ul><li>Methodology for Instrumenting Probes </li></ul><ul><li>Provides Probe Access to DTrace Framework <...
DTrace Consumer <ul><li>Process that interacts with DTrace </li></ul><ul><li>Concurrent Consumers unlimited. DTrace handle...
Write an Application Probe <ul><li>Define Provider provider myserv { probe query_receive(string, string); probe query_resp...
Performance Tools <ul><li>Process Stats </li></ul><ul><li>cputrack : per-processor hardware counter </li></ul><ul><li>parg...
Thank You! for Participating
Track back URL <ul><li>http://blogs.sun.com/stripathi </li></ul>
Upcoming SlideShare
Loading in...5
×

OpenSolaris Introduction

2,560

Published on

Satyajit Tripathi has presented and evangelized OpenSolaris and Its Advanced Technologies at MSC OS Conference 2009 at KL Malaysia. He is also blogging on http://blogs.sun.com/stripathi.

Published in: Technology
0 Comments
5 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
2,560
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
0
Likes
5
Embeds 0
No embeds

No notes for slide

Transcript of "OpenSolaris Introduction"

  1. 1. OPEN SOURCE CONFERENCE 2009 MSC Malaysia Satyajit Tripathi ISV-Engineering, Sun Microsystems
  2. 2. Audience <ul><li>Prospective Customer </li></ul><ul><li>Independent Software Vendor (ISV) </li></ul><ul><ul><li>Chief Executive Officer (CXO, CTO) </li></ul></ul><ul><li>System Administrator </li></ul><ul><li>Software Developer </li></ul><ul><li>Research Scientist </li></ul><ul><li>Students </li></ul><ul><li>Rest Of The World </li></ul>NOTE :- The presentation is customized for the mixed audience at MSC OpenSource Conference 2009 Malaysia
  3. 3. OpenSolaris <ul><li>Operating System (OS) </li></ul><ul><ul><li>Code, based on industry leading Enterprise Solaris by Sun Microsystems </li></ul></ul><ul><ul><li>Freely Shareable and Redistributable </li></ul></ul><ul><li>Thriving Community </li></ul><ul><ul><li>Extension of OpenSolaris technology </li></ul></ul><ul><ul><li>Innovation and Collaboration </li></ul></ul><ul><li>Open Source project </li></ul><ul><ul><li>CDDL v1.0, OpenSolaris Binary lic. </li></ul></ul><ul><ul><li>Existing license applicable to the respective community projects </li></ul></ul>
  4. 4. Historic Events <ul><li>Solaris 2.0 : June 1992 Development started in 1988. Derived from Unix System V4 </li></ul><ul><li>Solaris 2.6 : July 1997 </li></ul><ul><li>Solaris 7 : November 1998 </li></ul><ul><li>Solaris 8 : February 2000 </li></ul><ul><li>Solaris 9 : May 2002 (SPARC), January 2003 (x86) </li></ul><ul><li>Solaris 10 : January 2005 </li></ul><ul><li>Solaris open sourced : June 14 th 2005 </li></ul><ul><li>SxDE First Release : February 2007 </li></ul><ul><li>1 st Release of OpenSolaris Distro : May 5 th 2008 </li></ul><ul><li>2 nd Release of OpenSolaris Distro : November 6 th 2008 </li></ul><ul><li>3 rd Release of OpenSolaris Distro : June 1 st 2009 </li></ul>
  5. 5. Solaris Release Model
  6. 6. One Solaris Platform <ul><li>Enterprise class </li></ul><ul><li>Unmatched level of support </li></ul><ul><li>Longer release cycle (3-5 years) </li></ul><ul><li>Web economy </li></ul><ul><li>Latest Innovation and extensions </li></ul><ul><li>Shorter release cycle (every 6 months) </li></ul>
  7. 7. OpenSolaris Inclusions <ul><li>Software Included </li></ul><ul><ul><li>Firefox Browser </li></ul></ul><ul><ul><li>Thunderbird </li></ul></ul><ul><ul><ul><li>Email client </li></ul></ul></ul><ul><ul><ul><li>Event Manager </li></ul></ul></ul><ul><ul><li>GIMP (Image Editor) </li></ul></ul><ul><ul><li>Pidgin (Chat IM) </li></ul></ul><ul><ul><li>Java technology </li></ul></ul><ul><ul><li>Explore for more... </li></ul></ul><ul><li>Software Easy Access </li></ul><ul><ul><li>OpenOffice </li></ul></ul><ul><ul><li>Apache Web Server </li></ul></ul><ul><ul><li>GlassFish ES </li></ul></ul><ul><ul><li>MySQL </li></ul></ul><ul><ul><li>OpenDS </li></ul></ul><ul><ul><li>NetBeans </li></ul></ul><ul><ul><li>PHP, Ruby, Perl </li></ul></ul><ul><ul><li>Explore for more... </li></ul></ul>
  8. 8. OpenSolaris Distro <ul><li>Solaris Express Community Edition </li></ul><ul><li>BeleniX </li></ul><ul><li>Jaris </li></ul><ul><li>MartUX mBE </li></ul><ul><li>MilaX </li></ul><ul><li>NexentaOS </li></ul><ul><li>SchilliX </li></ul>Power Of OpenSolaris with usability of Linux Small size Live CD distribution
  9. 9. OpenSolaris Communities <ul><li>A Social Group to have Open Conversation </li></ul><ul><li>Governance Process </li></ul><ul><li>Roles, Responsibilities </li></ul><ul><ul><li>Endorse Technical Projects </li></ul></ul><ul><ul><li>Start and Own Projects </li></ul></ul><ul><ul><li>Propose New Community Groups </li></ul></ul><ul><li>Participate and Network </li></ul>
  10. 10. OpenSolaris Project <ul><li>Enhance and Improve OpenSolaris </li></ul><ul><li>Build Community of Committed Members </li></ul><ul><li>Multiple Opportunities to Contribution </li></ul><ul><ul><li>Contributing Packages </li></ul></ul><ul><ul><li>Contributing Code </li></ul></ul><ul><ul><li>Documentation </li></ul></ul><ul><ul><li>Testing </li></ul></ul><ul><li>Participate and Build </li></ul>
  11. 11. Participation Is Key <ul><li>Everyone Has Something to Contribute </li></ul><ul><li>Code Of Conduct </li></ul><ul><ul><li>Be Inclusive </li></ul></ul><ul><ul><li>Be Respectful and Honest </li></ul></ul><ul><ul><li>Be Considerate of Diversity </li></ul></ul>
  12. 12. What It Means To <ul><li>Prospective Customer </li></ul><ul><ul><li>Low Cost Entrant </li></ul></ul><ul><ul><li>Highly Reliable, Secure and Robust </li></ul></ul><ul><ul><li>Unmatched Support </li></ul></ul><ul><ul><li>Widely Compatible </li></ul></ul><ul><ul><li>Scalable and Highly Available </li></ul></ul><ul><ul><li>Easily Maintainable </li></ul></ul>
  13. 13. What It Means To <ul><li>ISV CXO/ CTO </li></ul><ul><ul><li>High Quality and Industry Standard </li></ul></ul><ul><ul><li>Out-Of-Box Performance </li></ul></ul><ul><ul><li>Platform Neutrality </li></ul></ul><ul><ul><li>Access to Expert Advise </li></ul></ul><ul><ul><li>Skill Availability </li></ul></ul><ul><ul><li>Wide Compatibility </li></ul></ul><ul><ul><li>Clear Roadmap </li></ul></ul>
  14. 14. What It Means To <ul><li>System Administrator </li></ul><ul><ul><li>Easy Installation, Administration, Monitoring </li></ul></ul><ul><ul><li>Cool Features & Tools </li></ul></ul><ul><ul><ul><li>ZFS and Auto backup </li></ul></ul></ul><ul><ul><ul><li>Virtualization with Container </li></ul></ul></ul><ul><ul><ul><li>FMA and SMF </li></ul></ul></ul><ul><ul><ul><li>Observability with DTrace </li></ul></ul></ul><ul><ul><ul><li>Live Upgrade with Minimum Downtime </li></ul></ul></ul>
  15. 15. What It Means To <ul><li>Software Developer </li></ul><ul><ul><li>Latest Innovations and Cutting Edge technology </li></ul></ul><ul><ul><li>Ready Environment for Software Development </li></ul></ul><ul><ul><li>High Productivity with Open Source Software </li></ul></ul><ul><ul><li>Free Access to Knowledge base and Documentation </li></ul></ul><ul><ul><li>Fruitful Career and Growth </li></ul></ul>
  16. 16. What It Means To <ul><li>Research Scientist and Student </li></ul><ul><ul><li>Diverse Community to discuss and share Ideas </li></ul></ul><ul><ul><li>Access to Open Source technologies & Knowledge </li></ul></ul><ul><ul><li>Applicability to the Industry </li></ul></ul><ul><ul><li>High Visibility & Outreach </li></ul></ul>
  17. 17. What It Means To <ul><li>You ! </li></ul><ul><ul><li>Easy To Get </li></ul></ul><ul><ul><li>Easy To Install </li></ul></ul><ul><ul><li>Easy To Use </li></ul></ul><ul><ul><li>Easy To Maintain </li></ul></ul><ul><ul><li>Easy To Share </li></ul></ul>
  18. 18. OpenSolaris Unleashing Potential
  19. 19. Useful Information <ul><li>OpenSolaris.Com </li></ul><ul><ul><li>Download http://www.opensolaris.com/get </li></ul></ul><ul><ul><li>Support Subscription http://www.sun.com/service/opensolaris </li></ul></ul><ul><li>OpenSolaris.Org </li></ul><ul><ul><li>Community http://www.opensolaris.org </li></ul></ul><ul><ul><li>Packaging Repository http://pkg.opensolaris.org </li></ul></ul><ul><ul><li>Documentation http://www.opensolaris.org/os/documentation </li></ul></ul><ul><li>Sun Partner Advantage Program http://www.sun.com/isv </li></ul><ul><li>Contact ISV-Engineering < [email_address] > </li></ul>
  20. 20. <ul><ul><li>Congratulations for Participating </li></ul></ul>
  21. 21. Next Session <ul><li>OpenSolaris and Advanced Technologies </li></ul>
  22. 22. OpenSolaris Advanced Technologies <ul><li>ZFS (Zettabyte File System) </li></ul><ul><li>SMF (Service Management Facility) </li></ul><ul><li>Zones and Containers </li></ul><ul><li>DTrace </li></ul><ul><li>And more ... </li></ul>
  23. 23. Zettabyte File System (Zeta = 10 21 ) <ul><li>Better, Safer way to Manage Data </li></ul><ul><li>First 128-bit File System </li></ul><ul><ul><li>Capacity 1 billion TB. Virtually unlimited. </li></ul></ul><ul><li>Fast and High Performance </li></ul><ul><li>No Silent Data Corruption </li></ul><ul><ul><li>End-to-end integrity </li></ul></ul><ul><ul><li>Aggressive 256-bit checksums </li></ul></ul><ul><li>Instantaneous Snapshots </li></ul><ul><ul><li>Almost Zero Overhead and Easy Rollback </li></ul></ul><ul><li>Application Compatibility </li></ul><ul><li>Easy Administration. No Volume Manager </li></ul><ul><li>Efficient Mirroring and Remote Replication </li></ul>
  24. 24. ZFS Virtually Unlimited <ul><li>Traditional Volumes </li></ul><ul><li>Abstraction : Virtual disk </li></ul><ul><li>Partition for each FS </li></ul><ul><li>Grow or shrink manually </li></ul><ul><li>Storage is fragmented, stranded </li></ul><ul><li>ZFS Pooled Storage </li></ul><ul><li>Abstraction : malloc, free </li></ul><ul><li>No partition to manage </li></ul><ul><li>Grow or shrink automatic </li></ul><ul><li>Storage in the Pool is shared </li></ul>Volume FS Volume FS Volume FS ZFS Storage Pool ZFS ZFS
  25. 25. <ul><li>Transaction Group Batch I/O </li></ul><ul><li>Schedule, Aggregate, and Issue I/O at will </li></ul><ul><li>Loss of Power. No Resync </li></ul><ul><li>Runs at platter speed </li></ul><ul><li>Object based Transaction </li></ul><ul><li>Make these N# changes to these M# objects </li></ul><ul><li>Atomic (all-or-nothing) </li></ul><ul><li>Transaction Group Commit </li></ul><ul><li>Atomic for entire group </li></ul><ul><li>Always consistent on disk </li></ul><ul><li>No Journal. Not needed </li></ul>ZFS I/O Stack ZPL ZFS POSIX Layer SPA Storage Pool Allocator DMU Data Management Unit <ul><li>Block Device Interface </li></ul><ul><li>“ Write this block, then that block, ...” </li></ul><ul><li>Loss of Power. Loss of on-disk consistency </li></ul><ul><li>Workaround : Journaling, which is slow and complex </li></ul><ul><li>Block Device Interface </li></ul><ul><li>Write each block to each disk immediately to keep mirrors in sync </li></ul><ul><li>Loss of Power. Resync. </li></ul><ul><li>Synchronous and slow </li></ul>FS Volume
  26. 26. ZFS Dynamic Stripping <ul><li>BEFORE </li></ul><ul><li>Writes : stripped across all 3 mirrors </li></ul><ul><li>Reads : wherever data was written </li></ul><ul><li>Block Allocation Policy Considers </li></ul><ul><ul><li>Capacity </li></ul></ul><ul><ul><li>Performance (latency, BW) </li></ul></ul><ul><ul><li>Health (degraded mirrors) </li></ul></ul><ul><li>AFTER </li></ul><ul><li>Writes : stripped across all 4 mirrors </li></ul><ul><li>Reads : wherever data was written </li></ul><ul><li>No need to migrate existing data </li></ul><ul><ul><li>Old data stripped across 1-3 </li></ul></ul><ul><ul><li>New data stripped across 1-4 </li></ul></ul><ul><ul><li>Copy-On-Write (COW) gently reallocates old data </li></ul></ul>ZFS Storage Pool ZFS ZFS 1 2 3 1 2 3 4 ZFS Storage Pool ZFS ZFS
  27. 27. ZFS Additional Capabilities <ul><li>Intelligent Prefetch </li></ul><ul><ul><li>Multiple Independent Pre-fetch Streams </li></ul></ul><ul><ul><ul><li>Very useful for Streaming Service Provider </li></ul></ul></ul><ul><ul><li>Automatic Length and Stride Detection </li></ul></ul><ul><ul><ul><li>Very useful for HPC Applications </li></ul></ul></ul><ul><li>Variable Block Size </li></ul><ul><li>Built-in Compression. Built-in Encryption </li></ul><ul><li>Per-user and Per-group Quota Support </li></ul><ul><li>Common Internet FS (CIFS) Support </li></ul><ul><li>Integrated with Zones and FMA </li></ul><ul><li>And more ... </li></ul>
  28. 28. Service Management Facility (SMF) <ul><li>Simplified Service Management </li></ul><ul><ul><li>Services are Objects easily managed with few simple commands </li></ul></ul><ul><li>Automated Restart of Failed Services </li></ul><ul><ul><li>SMF Monitors services and Pro actively Restart on Failure </li></ul></ul><ul><li>Persistent Service Configuration </li></ul><ul><ul><li>Service Definition and Configuration persist across reboot </li></ul></ul><ul><li>Explicit Dependencies </li></ul><ul><li>Easier Debugging </li></ul><ul><li>Faster Boot/Shutdown Processes </li></ul><ul><li>Delegated Service Administration </li></ul><ul><ul><li>Administrative Role Delegation to non Root users </li></ul></ul>
  29. 29. SMF Service Components <ul><li>SMF Service Manifest </li></ul><ul><ul><li>Defines Default Service Properties in the Repository </li></ul></ul><ul><ul><li>System Manifest files under /var/svc/manifest. Imported at boot </li></ul></ul><ul><li>Service Start Method(s) </li></ul><ul><ul><li>Defines the Interaction between Service Restarter and the Service </li></ul></ul><ul><li>Service Executable(s) </li></ul><ul><ul><li>Executable called by Method(s) to Implement the Service </li></ul></ul><ul><li>Service Log </li></ul><ul><ul><li>Records the output of the Service. Useful in Debugging Failure </li></ul></ul><ul><ul><li>/var/svc/log/milestone-multi-user-server:default.log </li></ul></ul><ul><li>Service Fault Management Resource Identifier (FMRI) </li></ul><ul><ul><li>Identifies specific Service Instance Example : svc:/milestone/multi-user-server:default </li></ul></ul>
  30. 30. Zones and Container <ul><li>Virtualization instrumented within OS Kernel </li></ul><ul><ul><li>Resource Management </li></ul></ul><ul><ul><ul><li>Controlled and Dynamic Resource Allocation </li></ul></ul></ul><ul><ul><ul><li>Prioritize Applications </li></ul></ul></ul><ul><ul><li>Name space, Security, and Fault Isolation </li></ul></ul><ul><li>Light Weight and No Overhead </li></ul><ul><ul><li>Theoretical limit is 8192 </li></ul></ul><ul><li>Easy to Clone and Migrate </li></ul><ul><ul><li>Rapidly create and multiply OS environment </li></ul></ul><ul><li>Increase System Utilization </li></ul><ul><ul><li>Scales with OS </li></ul></ul><ul><li>Single Point Administration at Global Zone </li></ul>
  31. 31. Zone States <ul><li>Configured </li></ul><ul><ul><li>Configuration completed and committed </li></ul></ul><ul><li>Installed </li></ul><ul><ul><li>Packages installed successfully </li></ul></ul><ul><li>Ready </li></ul><ul><ul><li>Virtual Platform established </li></ul></ul><ul><li>Running </li></ul><ul><ul><li>Zone booted successfully and running </li></ul></ul><ul><li>Shutting Down </li></ul><ul><ul><li>Temporary state in the process of shutting down </li></ul></ul><ul><li>Down </li></ul><ul><ul><li>Temporary state completed shutting down, to go to Installed state </li></ul></ul>
  32. 32. Zones Usefulness for Developers <ul><li>Virtual OS Environment Partitioning </li></ul><ul><ul><li>One large system can be utilized by multiple users non-intrusively </li></ul></ul><ul><li>Rapidly proliferate similar Development Environment </li></ul><ul><ul><li>Clone within the same System </li></ul></ul><ul><ul><li>Migrate to the new System </li></ul></ul><ul><li>Simulate Distributed Application on multiple zones </li></ul><ul><li>Apply latest OS patch Once on the Global Zone </li></ul><ul><ul><li>Available to all Zones </li></ul></ul><ul><li>Preserve the Pre-configured Development or Deployment Environment with simple commands </li></ul>
  33. 33. Branded Zone (BrandZ) <ul><li>BrandZ extends Solaris Zones Infrastructure </li></ul><ul><ul><li>Brand Attribute set at Zone Create time </li></ul></ul><ul><ul><li>Branded Installation Routine for Arbitrary Collection of Software </li></ul></ul><ul><ul><li>Pre/Post-boot scripts for boot-time setup and configuration </li></ul></ul><ul><ul><li>Simple commands zoneadm and zonecfg </li></ul></ul><ul><li>Brand lx to run Linux binary application unmodified within a Zone with Solaris Kernel </li></ul><ul><li>Brand lx runs on x86/x64 booted with 32/64-bit Kernel </li></ul>
  34. 34. Dynamic Tracing (D Trace) <ul><li>DTrace, A Comprehensive Framework for Solaris TM Operating Environment </li></ul><ul><ul><ul><li>Implement New DTrace Providers </li></ul></ul></ul><ul><ul><ul><li>Implement fully Configurable DTrace Probes </li></ul></ul></ul><ul><ul><ul><li>Implement New DTrace Consumers and Data Display </li></ul></ul></ul><ul><li>Observability using DTrace </li></ul><ul><ul><li>Aggregate Arbitrary Behavior of the OS and User Programs </li></ul></ul><ul><ul><li>Dynamically Enable and Manage Probes </li></ul></ul><ul><ul><li>Dynamically Associate Predicates and Actions with Probes </li></ul></ul><ul><ul><li>Dynamically Manage Trace Buffers and Probe Overhead </li></ul></ul><ul><ul><li>Examine Live Production System or a Crash Dump </li></ul></ul>
  35. 35. DTrace World Probes
  36. 36. D Language <ul><li>'D' Language, like 'C' and constructs similar to awk </li></ul><ul><li>Complete Access to Kernel C types </li></ul><ul><li>Complete Access to Statics and Globals </li></ul><ul><li>Rich built-in Variable set </li></ul><ul><li>Complete Support for ANSI-C Operators </li></ul><ul><li>Example : Trace the pid of every process named date with syscall open(2) #!/usr/sbin/dtrace -s syscall::open:entry </li></ul><ul><ul><li>/execname == “date”/ </li></ul></ul><ul><ul><li>{ </li></ul></ul><ul><ul><ul><ul><li>trace(pid); </li></ul></ul></ul></ul><ul><ul><li>} </li></ul></ul>Probe Name o Entry point of open Predicate o Process is named “date” Action o Print the process ID
  37. 37. DTrace Probe <ul><li>Point of Instrumentation within OS Kernel </li></ul><ul><li>Has a Name </li></ul><ul><li>Identifies the Module and Function it Instruments </li></ul><ul><li>Accessible through Provider </li></ul><ul><li>4 Attributes, Name, Module, Function & Provider, defines a tuple to uniquely identify a Probe probe description (provider:module:function:name) </li></ul><ul><ul><ul><li>/ predicate / </li></ul></ul></ul><ul><ul><ul><li>{ </li></ul></ul></ul><ul><ul><ul><ul><li>action statements </li></ul></ul></ul></ul><ul><ul><ul><li>} </li></ul></ul></ul><ul><li>Each Probe is Assigned an Integer Identifier </li></ul>
  38. 38. DTrace Provider <ul><li>Methodology for Instrumenting Probes </li></ul><ul><li>Provides Probe Access to DTrace Framework </li></ul><ul><li>Informed by DTrace to Enable a Probe </li></ul><ul><li>Transfers Control of the Probe to DTrace when Enabled </li></ul>
  39. 39. DTrace Consumer <ul><li>Process that interacts with DTrace </li></ul><ul><li>Concurrent Consumers unlimited. DTrace handles Multiplexing </li></ul><ul><li>dtrace(1M) is DTrace Consumer. Generic front-end to the DTrace Facility </li></ul>
  40. 40. Write an Application Probe <ul><li>Define Provider provider myserv { probe query_receive(string, string); probe query_respond(); } </li></ul><ul><li>Include sdt.h </li></ul><ul><li>Add Probe code to the Application query = wait_for_new_query(); DTRACE_PROBE2(myserv, query_receive, query->clientname, query->msg); process_query(query) </li></ul><ul><li>Compile the Application dtrace -G -32 -s myserv.d src1.o src2.o ... cc -o myserv myserv.o src1.o src2.o ... </li></ul>
  41. 41. Performance Tools <ul><li>Process Stats </li></ul><ul><li>cputrack : per-processor hardware counter </li></ul><ul><li>pargs : process arguments </li></ul><ul><li>pflags : process flags </li></ul><ul><li>pcred : process credentials </li></ul><ul><li>pldd : process library dependency </li></ul><ul><li>psig : process signal disposition </li></ul><ul><li>pstack : process stack dump </li></ul><ul><li>pmap : process memory map </li></ul><ul><li>pfiles : open files and names </li></ul><ul><li>prstat : process statistics </li></ul><ul><li>ptree : process tree </li></ul><ul><li>ptime : process micro-state times </li></ul><ul><li>pwdx : process working directory </li></ul><ul><li>Process Control </li></ul><ul><li>pgrep : grep for processes </li></ul><ul><li>pkill : kill processes list </li></ul><ul><li>pstop : stop processes </li></ul><ul><li>prun : start processes </li></ul><ul><li>prctl : view/set process resources </li></ul><ul><li>pwait : wait for process </li></ul><ul><li>preap : reap a zombie process </li></ul><ul><li>Process Tracing & Debugging </li></ul><ul><li>abitrace : trace ABI interfaces </li></ul><ul><li>dtrace : trace the world </li></ul><ul><li>mdb : debug/control processes </li></ul><ul><li>truss : trace functions,system calls </li></ul><ul><li>Kernel Tracing & Debugging </li></ul><ul><li>dtrace : trace and monitor kernel </li></ul><ul><li>lockstat : monitor locking statistics </li></ul><ul><li>lockstat -k : profile kernel </li></ul><ul><li>mdb : debug live and kernel cores </li></ul><ul><li>System Stats </li></ul><ul><li>acctcom : process accounting </li></ul><ul><li>busstat : Bus hardware counters </li></ul><ul><li>cpustat : CPU hardware counters </li></ul><ul><li>iostat : IO & NFS statistics </li></ul><ul><li>kstat : display kernel statistics </li></ul><ul><li>mpstat : processor statistics </li></ul><ul><li>netstat : network statistics </li></ul><ul><li>nfsstat : nfs server stats </li></ul><ul><li>sar : kitchen sink utility </li></ul><ul><li>vmstat : virtual memory stats </li></ul>
  42. 42. Thank You! for Participating
  43. 43. Track back URL <ul><li>http://blogs.sun.com/stripathi </li></ul>

×