Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Feb 2000 03:37:48 -0800
From:      Alfred Perlstein <bright@wintelcom.net>
To:        =?iso-8859-1?Q?Jos=E9_Lu=EDs_Faria?= <jose@di.uminho.pt>
Cc:        freebsd-doc@FreeBSD.ORG, freebsd-hackers@FreeBSD.ORG
Subject:   Re: kernel
Message-ID:  <20000221033747.N21720@fw.wintelcom.net>
In-Reply-To: <38B1282D.7230C8BC@di.uminho.pt>; from jose@di.uminho.pt on Mon, Feb 21, 2000 at 11:57:33AM %2B0000
References:  <38B1282D.7230C8BC@di.uminho.pt>

next in thread | previous in thread | raw e-mail | index | archive | help
* José Luís Faria <jose@di.uminho.pt> [000221 03:25] wrote:
> Hello 
> 
> I'm creating a litle update to a freebsd 3.4 kernel.
> My program is for account some data: number of
> packets by class, number of packets dropped by class, etc.
> Now I need to pass this values to another program wich in X-Window
> display this values on-line. After, I want to save this values
> in a file.
> 
> I need some docs about how I can do this.
> Which are the primitives in the kernel to do this.
> I use the printf to put this data in /var/log/messages.
> This inappropriate, I dont want this. This is only for testing now.
> 
> Can you help me ?

Perhaps you'd like to use sysctl nodes as counters, they allow a 
pretty clean exporting of kernel internal variables.

try "man sysctl" and looking at various other uses of sysctls in 
the kernel as counters.

good luck,
-Alfred


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?20000221033747.N21720>