Date: Sun, 12 Mar 2000 21:31:34 -0800 From: Arun Sharma <adsharma@sharmas.dhs.org> To: guazzibe@dcc.unicamp.br Cc: freebsd-hackers@freebsd.org Subject: Re: Getting CPU usage in FreeBSD Message-ID: <200003130531.VAA01702@sharmas.dhs.org> In-Reply-To: <Pine.GSO.4.10.10003111424050.6579-100000@xingu.dcc.unicamp.br> References: <Pine.GSO.4.10.10003111424050.6579-100000@xingu.dcc.unicamp.br>
next in thread | previous in thread | raw e-mail | index | archive | help
> On Linux this is what I do to get this value: Measure the number of > scheduled jiffies (hundreths of second), measure elapsed time since last > measurement, divide. I ran into the same problem as you - and took the time to implement it. My patches fix the SMP case as well as getting it via sysctl instead of kvm_read. See: http://www.FreeBSD.org/cgi/getmsg.cgi?fetch=169412+180922+/usr/local/www/db/text/1999/freebsd-hackers/19991212.freebsd-hackers http://www.freebsd.org/cgi/getmsg.cgi?fetch=293002+0+/usr/local/www/db/text/1999/freebsd-hackers/19991226.freebsd-hackers -Arun 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?200003130531.VAA01702>