The individual owning this blog works for Oracle in Germany. The opinions expressed here are his own, are not necessarily reviewed in advance by anyone but the individual author, and neither Oracle nor any other party necessarily agrees with them.
Monday, May 10. 2010
In this installment of the "Meet the Stats" series i want to talk with you about the
Using mpstatLet's execute mpstat on a system. I've used my fileserver for this task on Saturday morning, it's a system with four cores. So mpstat reports 4 lines to me.
InternalsYou need some knowledge about the inner workings of an operating system to really understand the output of this command, but a basic understanding is relatively easy to reach.
A recommended readingIn the following description i sacrified complete correctness for understandability, as i simplified some of the dependencies.To understand the full implications of all the numbers presented by all the
" written by Richard McDougall and Jim Mauro. The ISBN of this great book is 0-13-148209-2.
DTrace examplesThe DTrace examples are from my standard cheat sheet i'm using at customer site. However they aren't mine, i've gathered them from the Prefetch.net's Dtrace Cookbook.
The numbers and their meaning
The other values are a little more difficult to explain. Basically you can divide the columns 2-12 into three groups: The virtual memory part (row 2 and 3), the interrupt part (row 4-7), the scheduling part (8-11) and the locks part (row 11-12)
The virtual memory partTo understand the meaning of the both rows regarding the virtual memory subsystem you should have some knowledge about the concept of virtual memory. But i will try to give you some insight into this part without getting overly complex.
At first it's important to know that memory is organized in pages. Those pages are chunks of memory. The possible sizes of the page are hardware dependent, but let's assume that we have pages in the size of 8 Kilobytes.
As you may know, modern operating system doesn't allocate real memory when your application is requesting for memory. Instead it allocated virtual memory.
When you access a memory page the first time, a page fault occurs. This page fault leads to the mapping of a physical memory page to the virtual memory page.
The mapping is done by adding an entry to the Hash Page Table. And here the minor and major page faults differs:
Obviously major faults have a bigger impact to the system performance than minor faults, as the second one doesn't need to access a rotating rust device aka hard disk. However even minor faults can have a significant impact to performance. But that's enough stuff for an own article or an evening with the book mentioned above.
The interrupt part
Interrupts are important for the operation of the system, however they interrupt (they are called "interrupts" for a reason) the application running on this processor. Thus a high number of interrupts can lead into a situation, where many interrupts significantly slows down the application.
There are some tricks to reduce this interruption. For example you can force the interrupts on a subset of all processors by declaring most of the CPUs as "non-interrupt".
The scheduling part
The locks part.
Do you want to learn more?
Prefetch.net: Dtrace Cookbook
Posted by Joerg Moellenkamp in English, Solaris at 08:10 | Comments (3)
Related entries by tags:
Display comments as (Linear | Threaded)
best mpstat description I've ever seen, and showing how to use dtrace to dig deeper into it...
Agreed! I've been a Sun / Solaris admin for the last 10 years - ok 'admin' is an overstatement, but I was responsible for several servers and boxen.
And this was definitely the easiest and clearest description I've ever seen.
I'll humbly admit I learnt a lot today!
Another clearly explained and and full of good examples document.
The author does not allow comments to this entry
The LKSF book
The book with the consolidated Less known Solaris Tutorials is available for download here
Martin about End of c0t0d0s0.org
Mon, 01.05.2017 11:21
Thank you for many interesting blog posts. Good luck with al l new endeavours!
Hosam about End of c0t0d0s0.org
Mon, 01.05.2017 08:58
Joerg Moellenkamp about tar -x and NFS - or: The devil in the details
Fri, 28.04.2017 13:47
At least with ZFS this isn't c orrect. A rmdir for example do esn't trigger a zil_commit, as long as you don't speci [...]
Thu, 27.04.2017 22:31
You say: "The following dat a modifying procedures are syn chronous: WRITE (with stable f lag set to FILE_SYNC), C [...]