rsync and broken symlinks

Yakov Hrebtov jake at generation.ru
Thu Dec 16 08:38:42 GMT 2004


WD> Your example works fine for me, so run "rsync --version" and ensure that

My results:
# rsync --version
rsync  version 2.6.3  protocol version 28
Copyright (C) 1996-2004 by Andrew Tridgell and others
<http://rsync.samba.org/>
Capabilities: 64-bit files, socketpairs, hard links, symlinks, batchfiles,
              inplace, IPv6, 64-bit system inums, 64-bit internal inums

WD> If it doesn't mention "symlinks", you'll need to compile a new version
WD> (rsync depends on the readlink() function for its symlink support, so
WD> make sure that configure defined HAVE_READLINK).

See my results above

WD> If the output does mention symlinks, try running rsync without -l set
WD> and make sure that it mentions that it is skipping a non-regular file.
WD> Then, try running it something like -v options and ensure that it
WD> appears in the sender's and receiver's file list.

# ls -l src/
total 4
lrwxrwxrwx    1 root     root           22 Dec 16 10:31 broken-link -> file-that-doesnt-exist
-rw-r--r--    1 root     root            4 Dec 16 13:31 file
lrwxrwxrwx    1 root     root            4 Dec 16 13:32 good-link -> file

# rsync -rv src/ dst/
building file list ... done
file
skipping non-regular file "good-link"

sent 121 bytes  received 40 bytes  322.00 bytes/sec
total size is 8  speedup is 0.05

what about symlink "broken-link"?
where is the message -- skipping non-regular file "broken-link"?

-- 
WBR, Yakov                              mailto:jake at generation.ru



More information about the rsync mailing list