*BSD News Article 75229


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.carno.net.au!harbinger.cc.monash.edu.au!munnari.OZ.AU!news.ecn.uoknor.edu!news.eng.convex.com!newshost.convex.com!bcm.tmc.edu!cs.utexas.edu!howland.reston.ans.net!EU.net!Austria.EU.net!01-newsfeed.univie.ac.at!02-newsfeed.univie.ac.at!news.ecrc.de!news.space.net!mac.infodirekt.de!user
From: ts@infodirekt.de (Thomas Schreiber)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Best way to copy directory trees
Date: Thu, 01 Aug 1996 15:59:09 +0200
Organization: infodirekt, Munich, Germany
Lines: 20
Message-ID: <ts-0108961559090001@mac.infodirekt.de>
NNTP-Posting-Host: mac.infodirekt.de

I have installed a second drive on my FreeBSD 2.1 machine
and want to move a few file systems around now.

What is the best way to copy directory trees with preserving
access dates, permissions, links and so on?

I know about

  cp -pr
  tar cf - | (cd destdir; tar xf -)

but both seem to not exactly preserve directory trees.

Thomas

____________________________________________________________
infodirekt - Thomas Schreiber         Tel:  +49 89/324796-50
Frankfurter Ring 193a                 Fax:  +49 89/324796-51
80807 Muenchen, Germany              email: ts@infodirekt.de
________________________ See you at http://www.infodirekt.de