Date: Fri, 06 Apr 2001 13:03:59 +0200 From: Oscar-Ivan Lepe-Aldama <oscar@ac.upc.es> To: hackers@FreeBSD.ORG Subject: Sysctl question Message-ID: <3ACDA29F.8AF9993B@ac.upc.es>
next in thread | raw e-mail | index | archive | help
Hi! is there a maximum for the size of an object that sysctl can handle? I'm asking this because I have inserted in a 4.1.1 kernel an array defined as struct buf_entry { unsgined int id; u_int64_t tsc; u_int64_t pmec1; u_int64_t pcem2; } mybuffer[NUMENTRIES]; SYSCTL_NODE(, CTL_NAVI, experiments, CTLFLAG_RW, 0,"Experiments"); SYSCTL_OPAQUE(_experiments, OID_AUTO, buffer, CTLFLAG_RD, &mybuffer, sizeof(mybuffer), "", ""); When NUMENTRIES equals 100000 (100 thousand) everything works well; that is, I can read the content of the array using sysctl -b experiments.mybuffer > somefile.raw But when NUMENTRIES equals 1000000 (1 million) and I use the above command to read the content of the array, the system stops working properly; that is, all virtual terminals freezed so I can't sent any command to the system, although the kernel seams to be alive as it responds to ICMP echo packets. I do want to have a large array within the kernel's memory space as I'm measuring the performance of some kernel's routines using the Pentium's Performance Monitoring Event Counters, and the more performance data I could get in one experiment the best. By the way, the system under test has 64 MB of RAM and 20 GB of free space on disk. Any explanation on the possibility or the impossibility of having such large array within the kernel memory-space and having it exported through sysctlt will be verry much appreciated. Thanks, -- ======================================================================== 0 0 0 Oscar-Ivan Lepe-Aldama | UPC-Campus Nord, DAC 0 0 0 e-mail: oscar@ac.upc.es | Modul D6, despatx 116 0 0 0 phone: +34 93 401 7187 | Jordi Girona, 1-3 U P C fax: +34 93 401 7055 | 08034 Barcelona - SPAIN WWW: http://www.ac.upc.es/homes/oscar/ ======================================================================== 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?3ACDA29F.8AF9993B>