From owner-freebsd-isp@FreeBSD.ORG Sat Feb 28 13:23:23 2004 Return-Path: Delivered-To: freebsd-isp@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6434A16A4CE for ; Sat, 28 Feb 2004 13:23:23 -0800 (PST) Received: from cah.talon.net (cah.talon.net [199.224.105.22]) by mx1.FreeBSD.org (Postfix) with ESMTP id D0DC443D1F for ; Sat, 28 Feb 2004 13:23:22 -0800 (PST) (envelope-from ssj@scottah.com) Received: from www.scottah.com (localhost.talon.net [127.0.0.1]) by cah.talon.net (8.12.10/8.12.9) with ESMTP id i1SLJC2B041879; Sat, 28 Feb 2004 16:19:12 -0500 (EST) (envelope-from ssj@scottah.com) From: "Scott St. John" To: Bob Martin Date: Sat, 28 Feb 2004 16:19:12 -0500 Message-Id: <20040228211439.M89441@scottah.com> In-Reply-To: <4040F1A8.1070108@buckhorn.net> References: <20040228191105.M42305@scottah.com> <4040F1A8.1070108@buckhorn.net> X-Mailer: Open WebMail 2.10 20030617 X-OriginatingIP: 68.54.132.230 (scott) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 cc: freebsd-isp@freebsd.org Subject: Re: Final conversion questions X-BeenThere: freebsd-isp@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Internet Services Providers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Feb 2004 21:23:23 -0000 Bob- I do not have a NFS connection between the two boxes, I am using scp to transfer files between the Linux and the new FreebSD boxes. I used John The Ripper to merge my passwd and shadow files and then used some awk scripts from the OpenBSD site to format, then create my new passwd file for BSD. I am almost sure the UID/GID will NOT be the same since BSD starts at a different # than Linux where my first UID is 1000. If you have it, it sounds like the perl script would be the better trick since it would check the passwd file instead of assuming the UID/GID were the same. Thanks! -Scott On Sat, 28 Feb 2004 13:53:12 -0600, Bob Martin wrote > Scott, > I haven't followed this thread closely enough, but from what you're > saying, it sounds like you have a NFS connection between the 2 boxen. > That being the case, and since the UID/GID's are the same on both boxen > (IIRC you moved the Linux accounts to the BSD box), the following > command will get all of the files, and maintain the permissions: > > cp -pRP / > If the UID/GID's have changed, then this command will fix them for you: > (Note, this assumes you use bash as your shell) > cd /home > for a in `ls -1 /home`;do chown -R $a:users $a;done > > That command does assume that you have a 1 to 1 relationship between > home directories and usernames. If not, let me know and I'll find my > little perl script that reads /etc/passwd and sets the permissions.