Date: Tue, 19 Jan 2010 23:20:19 +0200 From: Kostik Belousov <kostikbel@gmail.com> To: gabor@freebsd.org Cc: attilio@freebsd.org, current@freebsd.org Subject: NLS/strerror efficiency Message-ID: <20100119212019.GL59590@deviant.kiev.zoral.com.ua>
next in thread | raw e-mail | index | archive | help
--j3olVFx0FsM75XyV Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, r189765 enabled NLS support for libc. Now, any strerror(3) call causes 4 (!) failing stat(2) calls. I think this is untolerable. Catopen() does not cache the catalog descriptor, at least for libc, at least for the case where the open failed. On the active web server, these msgcat activities easily become dominant in the CPU time of the web server process. 1715 nginx CALL open(0x804004bc0,O_RDONLY,<unused>0) 1715 nginx NAMI "/usr/home/guests/xenos/var/rvs/docroot/1/l/101/6/g" 1715 nginx RET open -1 errno 2 No such file or directory 1715 nginx CALL stat(0x7fffffffd9b0,0x7fffffffd930) 1715 nginx NAMI "/usr/share/nls/C/libc.cat" 1715 nginx RET stat -1 errno 2 No such file or directory 1715 nginx CALL stat(0x7fffffffd9b0,0x7fffffffd930) 1715 nginx NAMI "/usr/share/nls/libc/C" 1715 nginx RET stat -1 errno 2 No such file or directory 1715 nginx CALL stat(0x7fffffffd9b0,0x7fffffffd930) 1715 nginx NAMI "/usr/local/share/nls/C/libc.cat" 1715 nginx RET stat -1 errno 2 No such file or directory 1715 nginx CALL stat(0x7fffffffd9b0,0x7fffffffd930) 1715 nginx NAMI "/usr/local/share/nls/libc/C" 1715 nginx RET stat -1 errno 2 No such file or directory 1715 nginx CALL write(0x46,0x7fffffffdec0,0x109) 1715 nginx GIO fd 70 wrote 265 bytes "2010/01/19 14:41:09 [error] 1715#0: *40673092 open() "/usr/home/guests\ /xenos/var/rvs/docroot/1/l/101/6/g" failed (2: No such file or directo\ ry), client: YYY.YYY.YYY.YYY, server: do.not.say.this, reque\ st: "GET /1/l/101/6/g HTTP/1.1", host: "XXX.XXX.XXX.XXX" --j3olVFx0FsM75XyV Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (FreeBSD) iEYEARECAAYFAktWIhMACgkQC3+MBN1Mb4iyQgCfZnwjaBWr0mh1LmJa9AgkOdfq kYgAn3RWfD/WTyvwkYMB3B/08UNzeOtj =VCmO -----END PGP SIGNATURE----- --j3olVFx0FsM75XyV--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100119212019.GL59590>