On Tue, 9 May 2000, Vsevolod Semenov wrote:
>
> pw showuser shows user tens times slowly then
> grep user /etc/[master.]passwd
DB files provide you with already parsed and indexed information, more
suitable for use in API. grep can't perform many operations from getpw*
family... also, the library routines getpw* would have to parse
/etc/passwd each time you call them...
Try to increase hashsize when using pw and related utilities. It makes a
real difference in speed for large user databases.
>
> pwd_mkdb can't create [s]pwd.db files for 1000000 users.
I believe we still have a limit of 65535 user ids in many places in the
system, although uid_t is in fact u_int32_t. Or...?
>
> what reason to use db stuff in libc/gen/getpwent.c?
Speed and efficiency :-)
Andrzej Bialecki
// <[EMAIL PROTECTED]> WebGiro AB, Sweden (http://www.webgiro.com)
// -------------------------------------------------------------------
// ------ FreeBSD: The Power to Serve. http://www.freebsd.org --------
// --- Small & Embedded FreeBSD: http://www.freebsd.org/~picobsd/ ----
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message