Sabtu, 23 November 2013

Bristol Digest, Vol 526, Issue 2

Send Bristol mailing list submissions to
bristol@mailman.lug.org.uk

To subscribe or unsubscribe via the World Wide Web, visit
https://mailman.lug.org.uk/mailman/listinfo/bristol
or, via email, send a message with subject or body 'help' to
bristol-request@mailman.lug.org.uk

You can reach the person managing the list at
bristol-owner@mailman.lug.org.uk

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Bristol digest..."


Today's Topics:

1. Copying links without inadvertently copying the linked files
instead (Chris Makepeace)
2. Re: Copying links without inadvertently copying the linked
files instead (David Smith)
3. Re: Copying links without inadvertently copying the linked
files instead (Conor O'Neill)


----------------------------------------------------------------------

Message: 1
Date: Fri, 22 Nov 2013 17:17:04 +0000
From: Chris Makepeace <chris@makepeace.net>
To: Bristol and Bath Linux User Group <bristol@mailman.lug.org.uk>
Subject: [bristol] Copying links without inadvertently copying the
linked files instead
Message-ID:
<CACOFJnUos-iJ_OgtEeFj657h53uMx9_Ho7+ZF0A6YYC6WeKniQ@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

(Mac-related; act accordingly.)

One of the Mac's little features is Time Machine, their hourly incremental
backup program which, I understand, behaves like rsync, in that each time
it runs it only actually copies changed files and maintains only a tree of
links to the unchanged ones. I have a tree of approx 490GB that needs to
be shifted to another disk. When this tree is looked at via the UI it is
shown as 13TB big, thanks to all the links being expanded in the process.

I have tried cp -R to copy a single day's subtree and the result looked
like it was copying files not links. I get lost trying to sort out
symbolic v hard links and so on, hard though it may be to believe.

What syntax would allow me to just shift the whole tree onto another device
safely, please? And to determine the tree's actual (unexpanded) size?

?Sorry if this is a bit too elementary for you.?

--

ChrisM
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.lug.org.uk/mailman/private/bristol/attachments/20131122/8316b252/attachment-0001.html>

------------------------------

Message: 2
Date: Fri, 22 Nov 2013 17:20:41 +0000
From: David Smith <Dave.Smith@st.com>
To: Bristol and Bath Linux User Group <bristol@mailman.lug.org.uk>
Subject: Re: [bristol] Copying links without inadvertently copying the
linked files instead
Message-ID: <528F9269.9030308@st.com>
Content-Type: text/plain; charset="UTF-8"

On 11/22/13 17:17, Chris Makepeace wrote:
> What syntax would allow me to just shift the whole tree onto another
> device safely, please? And to determine the tree's actual (unexpanded)
> size?

Provided you're using GNU cp, just use "cp -a". It does a recursive
copy, preserving permissions and links.



------------------------------

Message: 3
Date: Sat, 23 Nov 2013 11:12:11 +0000
From: Conor O'Neill <conor_lists@puddle.co.uk>
To: bristol@mailman.lug.org.uk
Subject: Re: [bristol] Copying links without inadvertently copying the
linked files instead
Message-ID: <52908D8B.4040402@puddle.co.uk>
Content-Type: text/plain; charset="iso-8859-1"

On 22/11/13 17:17, Chris Makepeace wrote:
> (Mac-related; act accordingly.)
>
> One of the Mac's little features is Time Machine, their hourly
> incremental backup program which, I understand, behaves like rsync, in
> that each time it runs it only actually copies changed files and
> maintains only a tree of links to the unchanged ones. I have a tree
> of approx 490GB that needs to be shifted to another disk. When this
> tree is looked at via the UI it is shown as 13TB big, thanks to all
> the links being expanded in the process.
>
> I have tried cp -R to copy a single day's subtree and the result
> looked like it was copying files not links. I get lost trying to sort
> out symbolic v hard links and so on, hard though it may be to believe.
>
> What syntax would allow me to just shift the whole tree onto another
> device safely, please? And to determine the tree's actual
> (unexpanded) size?

% du -sh directoryname

This shows directory sizes (du stands for disk usage).
"man du" should tell you about more options.

Regards - Conor

--
Conor O'Neill

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.lug.org.uk/mailman/private/bristol/attachments/20131123/2411548e/attachment-0001.html>

------------------------------

_______________________________________________
Bristol mailing list
Bristol@mailman.lug.org.uk
https://mailman.lug.org.uk/mailman/listinfo/bristol

End of Bristol Digest, Vol 526, Issue 2
***************************************

Tidak ada komentar:

Posting Komentar