Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 Jan 1999 21:19:37 +0100
From:      Mattias Pantzare <pantzer@ludd.luth.se>
To:        "Kenneth D. Merry" <ken@plutotech.com>
Cc:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: Device statistics 
Message-ID:  <199901282019.VAA06412@zed.ludd.luth.se>
In-Reply-To: Your message of "Thu, 28 Jan 1999 13:02:14 MST." <199901282002.NAA75707@panzer.plutotech.com> 

next in thread | previous in thread | raw e-mail | index | archive | help

> What's wrong with just looking at the busy_time value that the kernel keeps
> track of?

That is only updated when busy_count is 0, it may never get uppdated if you put 
a high load on the disks (that is realy easy to do...).

If you take samples every second and the disk get realy bussy 0.5 seconds 
after the first sample you will miss half the time that the disk is in use. 0% 
instead of the real value 50%.

You will find that this is the case realy fast if you try to use busy_time.

So, you have to look at busy_time, busy_coun, start_time and the sample time 
to do anyting good of busy_time.

> If you really want an accurate version of the current system uptime, you
> should probably talk to Poul-Henning about it.  Providing the current
> uptime is more of a generic service, and not something that would "fit"
> into devstat..

Well, not realy. :-) The time that is interesting is when the sample is taken, 
not when my program get a chance to get the current system uptime. But a 
generic service may be good enough.



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901282019.VAA06412>