From owner-freebsd-isp Wed Nov 19 09:32:55 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id JAA02962 for isp-outgoing; Wed, 19 Nov 1997 09:32:55 -0800 (PST) (envelope-from owner-freebsd-isp) Received: from rustler.gwc.cccd.edu (rustler.gwc.cccd.edu [159.115.129.108]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id JAA02957 for ; Wed, 19 Nov 1997 09:32:52 -0800 (PST) (envelope-from mpeer@ponyexpress.gwc.cccd.edu) Received: from mpeer (mpeer.csc.gwc.cccd.edu [159.115.129.100]) by rustler.gwc.cccd.edu (8.8.5/8.8.5) with SMTP id JAA19871; Wed, 19 Nov 1997 09:32:35 -0800 (PST) Message-Id: <3.0.1.32.19971119093735.00aa3100@rustler.gwc.cccd.edu> X-Sender: mpeer@rustler.gwc.cccd.edu X-Mailer: Windows Eudora Pro Version 3.0.1 (32) Date: Wed, 19 Nov 1997 09:37:35 -0800 To: Khetan Gajjar , isp@FreeBSD.ORG From: Michael Peer Subject: Re: Adding 700+ users with one or two commands In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Sender: owner-freebsd-isp@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk I took the data, and wrote a perl script to write out the command line for adduser script, I put the -batch parameter first, worked great. Make sure and specify the real path to the users home directory,otherwise rmuser will not get rid of their home directory. I add about 2000 users every 18 weeks. We will soon add 14,000 users every 18 weeks. At 05:30 PM 11/19/97 +0200, Khetan Gajjar wrote: >Hi. > >I've got a list of usernames, in the format that adduser wants them >in a file. > >username groupname '' 'Full Name' password > >I've tried a command like >cat file | xargs -n5 adduser -group groupname -shell nologin -batch, >but this doesn't work quite nicely. Does anybody have a better >solution for me ? > >I need users created, and their usernames appended to the group, and >a home directory created. > >Any ideas ? > >TIA. >--- >Khetan Gajjar - whois kg1779 | khetan@iafrica.com or khetan@os.org.za >http://chain.iafrica.com/~khetan | PGPKey : finger khetan@chain.iafrica.com >UUNET Internet Africa Support | FreeBSD enthusiast-www2.za.freebsd.org >Unix is user friendly; it's just selective about who it calls a friend! > > ---------------------------------------------------------------------- Michael Peer Data Electronics Technician I Golden West College Computer Services Center 15744 Goldenwest St. Huntington Beach, CA 92647 e-mail: mpeer@gwc.cccd.edu Voice: (714)892-7711 ext 55067 WWW: http://pioneer.gwc.cccd.edu FAX: (714)895-8980