Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Jul 1997 12:02:47 -0500 (CDT)
From:      Lars Fredriksen <lars@fredriks-1.pr.mcs.net>
To:        current@freebsd.org
Subject:   patches to make MSG_BSIZE a tunable
Message-ID:  <199707101702.MAA00958@fredriks-1.pr.mcs.net>

next in thread | raw e-mail | index | archive | help
Hi,
	In ~lars/dmesg.diffs (it is actually a tar file of diffs, sorry about
	the name mangling), you can find diffs to the current tree that 
	defines MSG_BSIZE as a tunable and osmsgbufsize a MIB variable that
	one can uses sysctl to get the value of. There are also patches to
	dmesg and syslogd to use sysctl to find the size of the log buffer.

	With respect to dmesg there is kind of a cludge. Since dmesg can be
	used to extract the log out of a core dump, I also had to put in
	code that would actually read the osmsgbufsize out of the kernel
	the old fashion way. One could argue that dmesg shouldn't mess with
	using sysctl just because of this. I haven't tested this otption yet
	to make sure it works.

	Now, that being said, I am happy to receive feedback on this. One thing
	I didn't like is that I had to define osmsgbufsize as an extern in a
	few kernel files. This should probably be in a header somewhere(like
	msgbuf.h, and it should probably have a typedef that one could use to
	make sure that the sizes matches. I don't think that will ever be a
	probelm, but it looks much cleaner that way.


	Hope someone has time to look at this.

Lars
-- 
-------------------------------------------------------------------
Lars Fredriksen		fredriks@mcs.com		(home)
			lars@fredriks-1.pr.mcs.net	(home-home)



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