Date: Tue, 18 Oct 2016 03:47:25 +0000 From: Luis Miguel <sales6@meritvendor.com> To: freebsd-questions@freebsd.org Subject: Attention required: Important information for your website: freebsd.org Message-ID: <94eb2c07eeeefe7535053f1b8c7d@google.com>
next in thread | raw e-mail | index | archive | help
DQoNCkhpIGZyZWVic2Qub3JnIFRlYW0sDQoNCg0KSSB0cnVzdCB5b3UgYXJlIGRvaW5nIHNwbGVu ZGlkbHkuDQoNCg0KTXkgdGVhbSBoYXMgZ29uZSB0aHJvdWdoIHlvdXIgd2Vic2l0ZSBhbmQgY29t cHJlaGVuZHMgdGhhdCBpdOKAmXMgd2VsbCBidWlsdC4NCk9mIGNvdXJzZSwgdGhlIHNpdGUgY2Fu IGJlIGltcHJvdmVkIGluIHNldmVyYWwgd2F5cyB0byBnZXQgYmV0dGVyIHNhbGVzIGFuZA0KcmV2 ZW51ZS4gSWYgeW91IHdvdWxkIGxpa2UsIEkgY2FuIHNlbmQgeW91IHRoZSBsaXN0IG9mIHVwZ3Jh ZGVzIGFuZA0KaW1wcm92ZW1lbnRzIG5lY2Vzc2FyeSBmb3IgeW91ciBzaXRlLiBBbmQgaWYgeW91 IHJlcXVpcmUsIEkgY2FuIHNlbmQgeW91DQp0aGUgYnJpZWYgcXVvdGF0aW9uIGZvciB5b3VyIHdl YnNpdGUuDQoNCg0KTXkgdGVhbSB0b29rIHRoZSBsaWJlcnR5IHRvIGFsc28gZG8gYW4gaW4tZGVw dGggcmVzZWFyY2ggb2YgeW91ciB3ZWJzaXRlIHRvDQp1bmRlcnN0YW5kIHRoZSB0YXJnZXRlZCBt YXJrZXQuIEZvciBidXNpbmVzcyB0byBwcmV2YWlsIHdpdGhpbiB0aGUgdGFyZ2V0ZWQNCm1hcmtl dCwgd2UgY2FuIGFsc28gZXhlY3V0ZSBlZmZlY3RpdmUgb25saW5lIG1hcmtldGluZyBjYW1wYWln bnMuIE91cg0KbWFya2V0aW5nIGNhbXBhaWducyB0YXJnZXQgbm90IG9ubHkgbG9jYWwgbWFya2V0 LCBidXQgYWxzbyBwcm92aW5jaWFsIGFuZA0KaW50ZXJuYXRpb25hbCBtYXJrZXRzIGFzIHdlbGwu DQoNCg0KV2UgY2FuIGhlbHAgaW5jcmVhc2UgdmlzaWJpbGl0eSBvZiB5b3VyIHdlYnNpdGUgaW4g YWxsIHRoZSBtYWpvciBzZWFyY2gNCmVuZ2luZXMuIEluZGVlZCwgeW91ciB3ZWJzaXRlIHdpbGwg YmUgcG9zaXRpb25lZCBwcm9wZXJseSBzbyB0aGF0IGl0IGNhbiBiZQ0KZm91bmQgYXQgdGhlIG1v c3QgY3JpdGljYWwgcG9pbnRzLiBPdXIgYWltIGlzIHRvIHByb3ZpZGUgeW91IHdpdGggY29tcGxl dGUNCndlYiBtYXJrZXRpbmcgc29sdXRpb25zIHRvIGhlbHAgeW91ciB3ZWJzaXRlIHJhbmsgaGln aCBvbiB0aGUgc2VhcmNoDQplbmdpbmVzLiBZb3Ugd2lsbCBiZSBnZXR0aW5nIGFsbC1pbi1vbmUg c2VydmljZXMgd2hlbiB5b3UgY29udGFjdCB1cy4NCg0KDQpJZiB5b3UgaGF2ZSBhbnkgcXVlc3Rp b25zLCBwbGVhc2Ugbm90IGhlc2l0YXRlIHRvIGNvbnRhY3QuIE15IHRlYW0gYW5kIEkNCmxvb2sg Zm9yd2FyZCB0byBoZWFyaW5nIGZyb20gYW5kIGJlIG9mIGhlbHAgdG8gaW1wcm92ZSB0aGUgdmlz aWJpbGl0eSBvZg0KeW91ciB3ZWJzaXRlLg0KDQoNCkJlc3QgUmVnYXJkcywNCipMdWlzIE1pZ3Vl bCAqDQo= From owner-freebsd-questions@freebsd.org Tue Oct 18 06:44:23 2016 Return-Path: <owner-freebsd-questions@freebsd.org> Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7CD8FC16827 for <freebsd-questions@mailman.ysv.freebsd.org>; Tue, 18 Oct 2016 06:44:23 +0000 (UTC) (envelope-from steve@sohara.org) Received: from smtp3.irishbroadband.ie (smtp3.irishbroadband.ie [62.231.32.5]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 49A5EFE5 for <freebsd-questions@freebsd.org>; Tue, 18 Oct 2016 06:44:22 +0000 (UTC) (envelope-from steve@sohara.org) Received: from [89.127.62.20] (helo=smtp.lan.sohara.org) by smtp3.irishbroadband.ie with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from <steve@sohara.org>) id 1bwO8J-0000dL-Iq for freebsd-questions@freebsd.org; Tue, 18 Oct 2016 07:44:19 +0100 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.87 (FreeBSD)) (envelope-from <steve@sohara.org>) id 1bwO8k-000Bz4-9G for freebsd-questions@freebsd.org; Tue, 18 Oct 2016 06:44:46 +0000 Date: Tue, 18 Oct 2016 07:44:15 +0100 From: Steve O'Hara-Smith <steve@sohara.org> To: freebsd-questions@freebsd.org Subject: Re: pw add user slow Message-Id: <20161018074415.0f6575675db30d0b83d9b8ec@sohara.org> In-Reply-To: <fd1e578c-58ef-5098-9d89-c3db814d7af4@ifdnrg.com> References: <fd1e578c-58ef-5098-9d89-c3db814d7af4@ifdnrg.com> X-Mailer: Sylpheed 3.5.0 (GTK+ 2.24.29; amd64-portbld-freebsd10.1) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions <freebsd-questions.freebsd.org> List-Unsubscribe: <https://lists.freebsd.org/mailman/options/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=unsubscribe> List-Archive: <http://lists.freebsd.org/pipermail/freebsd-questions/> List-Post: <mailto:freebsd-questions@freebsd.org> List-Help: <mailto:freebsd-questions-request@freebsd.org?subject=help> List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=subscribe> X-List-Received-Date: Tue, 18 Oct 2016 06:44:23 -0000 On Mon, 17 Oct 2016 23:36:33 +0100 Paul Macdonald <paul@ifdnrg.com> wrote: > > Hi, > > I have to migrate an imap server, which uses about 6000 local accounts > for mail delivery > > I'm using a script that creates system acounts using: > > /usr/sbin/pw adduser $LOCAL_USER -u$UID-gGID-d $PATH -s/bin/false > > I'm finding this grows ever more slow, up to 10 seconds per account on a > SATA box , and on a test SSD box ( 20 acc's per second initially) even > that slows to about 1 account created per second. > > why does this slow down as more accounts are added? Because for each one it updates text files (passwd and master.passwd) and regenerates databases (pwd.db and spwd.db) from the text files. The fastest way to do this sort of thing is to directly update passwd and master.passwd and then run pwd_mkdb. -- Steve O'Hara-Smith <steve@sohara.org>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?94eb2c07eeeefe7535053f1b8c7d>