[Bug 10679] New: readlink_stat error results in deletion of mountpoints

samba-bugs at samba.org samba-bugs at samba.org
Fri Jun 27 16:53:58 MDT 2014


https://bugzilla.samba.org/show_bug.cgi?id=10679

           Summary: readlink_stat error results in deletion of mountpoints
           Product: rsync
           Version: 3.1.0
          Platform: Sparc
        OS/Version: Solaris
            Status: NEW
          Severity: normal
          Priority: P5
         Component: core
        AssignedTo: wayned at samba.org
        ReportedBy: bugz101 at andy-t.org
         QAContact: rsync-qa at samba.org


I am trying to rsync Solaris non-global zone from the global running the
following command (from a
script):

rsync -aSzx --del --ignore-errors --stats \
--exclude "sc-gis03/root/proc/*" \
--exclude "sc-gis03/root/var/run/*" \
--exclude "sc-gis03/root/system/contract/process/*" \
boi-blade02:/zones/sc-gis03 /zones

where `sc-gis03' is a running Solaris zone to be copied.

The problem I run into is this.  sc-gis03 has two NFS mounts.  The mountpoints
are /docrep01 and
/backup01.  From rsync perspective, they appear as:
/zones/sc-gis03/root/docrep01
/zones/sc-gis03/root/backup01

Since the two entries above are mountpoints, rsync does not have access to
them, and returns the
following errors:

rsync: readlink_stat("/zones/sc-gis03/root/docrep01") failed: Not owner (1)
rsync: readlink_stat("/zones/sc-gis03/root/backup01") failed: Not owner (1)

This is fine, nothing can be done about it.  What seems to be wrong is that
rsync deletes these
directories in the destination, as can be seen from a verbose run:

deleting sc-gis03/root/docrep01/
deleting sc-gis03/root/backup01/

IMHO, if rsync cannot stat a file because it does not have permissions to do
so, it should just
leave it alone.  In case you are wondering, my script captures those
`readlink_stat' errors, and
creates the directories after rsync exits, so next time the whole cycle is
repeated.

Environment:

# uname -a
SunOS plt-blade06 5.10 Generic_144488-12 sun4v sparc SUNW,Sun-Blade-T6320
#  # rsync --version
rsync  version 3.1.0  protocol version 31
Copyright (C) 1996-2013 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
Capabilities:
    64-bit files, 64-bit inums, 32-bit timestamps, 64-bit long ints,
    socketpairs, hardlinks, symlinks, IPv6, batchfiles, inplace,
    append, ACLs, xattrs, iconv, no symtimes, no prealloc

-- 
Configure bugmail: https://bugzilla.samba.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the rsync mailing list