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.wildstar.net!cancer.vividnet.com!hunter.premier.net!newsfeed.direct.ca!nntp.teleport.com!news.serv.net!news.serv.net!michaelv From: michaelv@MindBender.serv.net (Michael L. VanLoon) Newsgroups: comp.unix.bsd.freebsd.misc Subject: Re: Best way to copy directory trees Date: 27 Aug 1996 05:15:06 GMT Organization: Michael L. VanLoon Lines: 29 Message-ID: <MICHAELV.96Aug26221506@MindBender.serv.net> References: <ts-0108961559090001@mac.infodirekt.de> <gergDvH52n.6K9@netcom.com> <4vqhm8$ol7@herald.concentric.net> NNTP-Posting-Host: mindbender.serv.net In-reply-to: dantso@cris.com's message of Sun, 25 Aug 96 22:42:30 GMT In article <4vqhm8$ol7@herald.concentric.net> dantso@cris.com (Daniel Ts'o) writes: In article <gergDvH52n.6K9@netcom.com>, gerg@netcom.com (Greg Andrews) wrote: :ts@infodirekt.de (Thomas Schreiber) writes: :>What is the best way to copy directory trees with preserving :>access dates, permissions, links and so on? :I've always used: : cd /path/to/old/dir : find . -depth -print | cpio -pdmv /path/to/new/dir yes, I usually use cpio like above: find dir0 -print | cpio -pldumv dir1 The most common sysadmin method, AFAIK, is the dual-tar: tar cpf - . | ( cd /somedir/ ; tar xpf - ) -- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Michael L. VanLoon michaelv@MindBender.serv.net --< Free your mind and your machine -- NetBSD free un*x >-- NetBSD working ports: 386+PC, Mac 68k, Amiga, Atari 68k, HP300, Sun3, Sun4/4c/4m, DEC MIPS, DEC Alpha, PC532, VAX, MVME68k, arm32... NetBSD ports in progress: PICA, others... - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -