1 |
On Saturday, 19 August 2017 06:33:27 BST John Covici wrote: |
2 |
> On Sat, 19 Aug 2017 00:56:55 -0400, |
3 |
> |
4 |
> Walter Dnes wrote: |
5 |
> > I've RTFM'd, and it looks like there is no way to get rsync to copy |
6 |
> > |
7 |
> > over symlinked directories as symlinks. E.g. I build Pale Moon browser |
8 |
> > from source for 3 machines at home. I prefer downloading the source |
9 |
> > once and symlinking to it from 3 different working directories. I also |
10 |
> > have a personal project where I analyze the same text data files in 3 |
11 |
> > different ways. It makes things so much simpler to use the same code, |
12 |
> > with different runtime parameters. So I symlink the main data directory |
13 |
> > to 3 working directories. Even "better" (or worse) I've got a situation |
14 |
> > where I symlink directories to... other symlinked directories. Yes; |
15 |
> > symlinks pointing to symlinks work, even for directories. |
16 |
> > |
17 |
> > Unfortunately, rsync will not create a symlink where appropriate, but |
18 |
> > |
19 |
> > will de-reference the symlink, and duplicate multiple gigabytes of data |
20 |
> > needlessly. I eventually gave up trying, and made a tarball, and pushed |
21 |
> > it over to my "hot backup" machine, and extracted it there. That works |
22 |
> > OK for the initial setup, but is painfull for "minor incremental" |
23 |
> > updates. |
24 |
> > |
25 |
> > Am I missing something glaringly obvious, or is this a limitation of |
26 |
> > |
27 |
> > rsync? If so, is there another tool that can copy over symlinked |
28 |
> > directories properly? |
29 |
> |
30 |
> I always use -av which copies simlinks correctly. -H is necessary to |
31 |
> copy hardlinks. If you need it -l also ensures this. |
32 |
|
33 |
I've also found that 'rsync -a -l' does the job, but other tools exist to |
34 |
achieve the same: |
35 |
|
36 |
https://www.gnu.org/software/tar/manual/html_node/Incremental-Dumps.html |
37 |
|
38 |
https://linux.die.net/man/1/star (look for the section 'Incremental Backups' |
39 |
|
40 |
HTH. |
41 |
-- |
42 |
Regards, |
43 |
Mick |