From owner-freebsd-questions@FreeBSD.ORG Wed Apr 7 01:23:13 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B3B2116A4CE for ; Wed, 7 Apr 2004 01:23:13 -0700 (PDT) Received: from smtp.infracaninophile.co.uk (smtp.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7562843D2D for ; Wed, 7 Apr 2004 01:23:12 -0700 (PDT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost.infracaninophile.co.uk [IPv6:::1])i378LS2k003970 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 7 Apr 2004 09:21:29 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost)id i378LSwj003969; Wed, 7 Apr 2004 09:21:28 +0100 (BST) (envelope-from matthew) Date: Wed, 7 Apr 2004 09:21:28 +0100 From: Matthew Seaman To: Jerry Hatok Message-ID: <20040407082128.GC3321@happy-idiot-talk.infracaninophile.co.uk> Mail-Followup-To: Matthew Seaman , Jerry Hatok , freebsd-questions@freebsd.org References: <000801c41c77$35828a50$2e01a8c0@Craig> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="f0KYrhQ4vYSV2aJu" Content-Disposition: inline In-Reply-To: <000801c41c77$35828a50$2e01a8c0@Craig> User-Agent: Mutt/1.5.6i X-Spam-Status: No, hits=-4.9 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=2.63 X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on happy-idiot-talk.infracaninophile.co.uk X-Virus-Scanned: clamd / ClamAV version devel-20040323, clamav-milter version 0.70a cc: freebsd-questions@freebsd.org Subject: Re: howto X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Apr 2004 08:23:13 -0000 --f0KYrhQ4vYSV2aJu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Apr 07, 2004 at 04:06:18AM -0400, Jerry Hatok wrote: > I am trying to copy files from a cd I have into my usr directory. The= cd has one directory with a lot of subdirectories and files. Is there a c= ommand that I can copy everything at once? If so what is it? If not what w= ould you suggest being the fastest way to copy everything? There's many, many ways of doing this sort of thing under Unix. Assuming that your CD Rom is mounted under /cdrom and you want to copy everything onto /home/jerry/cdimage then: % cd /cdrom % mkdir /home/jerry/cdimage % tar -cvf - . | ( cd /home/jerry/cdimage ; tar -xvpf - ) However there are any number of commands you could substitute for that 3rd line: % find . -depth -print | cpio -pdmu /home/jerry/cdimage or, if you're installed the net/rsync port: % rsync -avx --delete /cdrom/ /home/jerry/cdimage/ That last one is particularly good if you've already got a partial copy in the destination directory, as it will avoid copying stuff it doesn't need to, and it will remove stuff under the destination not present in the source. None of these will be particularly faster than any of the others if you're copying from scratch -- the limiting factor should be the IO bandwidth of your hardware. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK --f0KYrhQ4vYSV2aJu Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAc7oIdtESqEQa7a0RAtTWAJwLaagDKQQERNro5jH1AC6JWk1m9gCffG6d sn7byX2Udoez7am1jKVUzac= =DwZR -----END PGP SIGNATURE----- --f0KYrhQ4vYSV2aJu--