From owner-freebsd-isp Thu Aug 19 11: 2:44 1999 Delivered-To: freebsd-isp@freebsd.org Received: from unix.megared.net.mx (megared.net.mx [207.249.162.252]) by hub.freebsd.org (Postfix) with ESMTP id 3769015268 for ; Thu, 19 Aug 1999 11:02:36 -0700 (PDT) (envelope-from ales@megared.net.mx) Received: from ales (pix.megared.net.mx [207.249.162.253]) by unix.megared.net.mx (8.9.3/8.9.3) with SMTP id NAA14548; Thu, 19 Aug 1999 13:01:11 -0500 (CDT) (envelope-from ales@megared.net.mx) Message-ID: <006f01beea6c$ca62e940$d4630a0a@megared.net.mx> From: "Alejandro Ramirez" To: "Mike Harshbarger" , References: Subject: RE: pwd_mkdb and system processes Date: Thu, 19 Aug 1999 13:00:57 -0500 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2014.211 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2014.211 Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Hi, In FreeBSD 3.2, you can do this, from the man page: -u username Only update the record for the specified user. Utilities that op- erate on a single user can use this option to avoid the overhead of rebuilding the entire database. Ales ----- Original Message ----- From: Mike Harshbarger To: Sent: Wednesday, August 18, 1999 1:43 PM Subject: Re: pwd_mkdb and system processes > > Wow! What a change... 12K accounts and the pwd_mkdb run time dropped from > 140 seconds down to 16 seconds. 6 Meg cache seemed optimal for me. > > Also, I've always been disappointed at the speed of the 'pw' command... > especially with all the 'pw usermod's I get to do daily. It seems like it > took 5 minutes. 'pw' seems to have sped up similarly with this change. > > On a related note, is there any chance in the future of the 'pw' command > supporting a command line option like pwd_mkdb's '-u' so it doesn't have > to reconstruct entire password databases? > > ___ ___ ___ > | __/ __|_ _| Mike Harshbarger, First Step Internet > | _|\__ \| | System & Network Administrator > |_| |___/___| (208) 882-8869 / 1-888-676-6377 > > > On Fri, 13 Aug 1999 lambert@cswnet.com wrote: > > > That did it. It went from 4:40 seconds to 20 seconds. I just gave it a > > cache size of 10 MB on the command line args. I could probably tune it > > down from there but I'm not into swap on this box anyway so it isn't > > hurting me and as my userbase grows it will handle the load. > > > > Thanks, > > > > In , on > > 08/13/99 > > at 12:47 PM, Steve Hovey said: > > > > >Or just increase the cache size it uses to it gets done quicker > > > > >On Fri, 13 Aug 1999, Joe Nall wrote: > > > > >> lambert@cswnet.com wrote: > > >> > > > >> > I've been trying to track down a problem on my e-mail server where it > > >> > stops processing smtp and pop processes for 5 minutes at a time. > > >> > > > >> > # wc -l /etc/passwd > > >> > 14945 /etc/passwd > > >> > > > >> > We rebuild this file once per hour to add or remove customers. > > >> > > > >> > I finally caught it with a top session running at the time. > > >> > > > >> > Inetd was accepting new connections and starting popper but people can't > > >> > authenticate. > > >> > Sendmail accepts new connections but they stall until pwd_mkdb goes away. > > >> > When I try to run a command from the command line, it doesn't execute > > >> > until pwd_mkdb gets done. > > >> > The CPU is 97% idle during this time. > > >> > > > >> > Does all file access in the system stop while pwd_mkdb runs? > > >> No but all password lookups do. Both of theses commands rely on the > > >> file you are rebuilding and the files involved are locked during the > > >> process. You might try pwd_mkdp -d /tmp <> followed by a mv of the > > >> relevant files into /etc or try pwd_mkdb -u at the time the > > >> passwd file gets modified and avoid the overhead of the total rebuild. > > >> YMMV, I haven't used the -d option. > > >> Joe > > >> > > >> > > >> To Unsubscribe: send mail to majordomo@FreeBSD.org > > >> with "unsubscribe freebsd-isp" in the body of the message > > >> > > > > > > > > -- > > Scott Lambert > > lambert@cswnet.com > > Systems and Security Administrator > > CSW Net, Inc. > > ================================================================ > > Written: Friday, August 13, 1999 - 12:40 PM > > > > > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > > with "unsubscribe freebsd-isp" in the body of the message > > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-isp" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message