Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Feb 2006 13:01:20 -0500
From:      "Ben House" <bhouse2@unifiednetworkservices.ca>
To:        "Chuck Swiger" <cswiger@mac.com>, "Matias Surdi" <matiassurdi@gmail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   RE: equivalent to linux cp -al
Message-ID:  <LCEKKIHHOEPBNNHJKNIOKEJCDCAA.bhouse2@unifiednetworkservices.ca>
In-Reply-To: <43F88B4E.4010104@mac.com>

next in thread | previous in thread | raw e-mail | index | archive | help
What about cpio?  cpio -dplm should do what you need it to.

This operates in pass-through to give you a recreation of the directories
rather than an archive.  Input is from standard i/p.

HTH.

BH

-----Original Message-----
From: owner-freebsd-questions@freebsd.org
[mailto:owner-freebsd-questions@freebsd.org]On Behalf Of Chuck Swiger
Sent: Sunday, February 19, 2006 10:14 AM
To: Matias Surdi
Cc: freebsd-questions@freebsd.org
Subject: Re: equivalent to linux cp -al


Matias Surdi wrote:
> I've a script on a linux box wich makes backups, it uses the "cp -al"
> command to make hard links and preserve atributes.
>
> Is there an equivalent on FreeBSD?

"cp -p" comes reasonably close, but will duplicate files rather than
creating
hard links.  If you need to preserve hard links, consider using tar or maybe
rsync to do the copying instead.

--
-Chuck
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?LCEKKIHHOEPBNNHJKNIOKEJCDCAA.bhouse2>