Subject: Re: CVS commit: syssrc (kern/9697)
To: None <tech-kern@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-kern
Date: 03/30/2000 10:43:40
>>>>> [ optimisation changed from FOO to BAR messages ]
>>> Perhaps we may convert the code to use ratecheck() so that the
>>> message [gets] written, but not all the time ?
>> Or reduce it to LOG_INFO?
> Or both ? And write the message to syslog like once in an hour ?
> [...]  As long as the information [gets] through, it doesn't need to
> pop into administrator's face each other second IMHO.

I'm not convinced it even needs to "get through".  Ages ago, I
generated a patch to ffs_alloc.c

--- OLD/sys/ufs/ffs/ffs_alloc.c	Thu Jan  1 00:00:00 1970
+++ NEW/sys/ufs/ffs/ffs_alloc.c	Thu Jan  1 00:00:00 1970
@@ -251,8 +251,10 @@
 		    fs->fs_cstotal.cs_nffree >
 		    fs->fs_dsize * fs->fs_minfree / (2 * 100))
 			break;
+#ifdef FFS_LOG_OPTCHG
 		log(LOG_NOTICE, "%s: optimization changed from SPACE to TIME\n",
 			fs->fs_fsmnt);
+#endif
 		fs->fs_optim = FS_OPTTIME;
 		break;
 	case FS_OPTTIME:
@@ -270,8 +272,10 @@
 		if (fs->fs_cstotal.cs_nffree <
 		    fs->fs_dsize * (fs->fs_minfree - 2) / 100)
 			break;
+#ifdef FFS_LOG_OPTCHG
 		log(LOG_NOTICE, "%s: optimization changed from TIME to SPACE\n",
 			fs->fs_fsmnt);
+#endif
 		fs->fs_optim = FS_OPTSPACE;
 		break;
 	default:

I now wonder if it should be a sysctl or something.  I know I've never
missed those messages.

					der Mouse

			       mouse@rodents.montreal.qc.ca
		     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B