IO errors on mountpoints cause failure with --one-file-system

Andrew Pimlott andrew at
Sun Mar 28 15:17:27 GMT 2004

I ran rsync with the --one-file-system option and observed:

    building file list ... readlink_stat "/home/pimlott/mnt/<hostname>" failed: Input/output error
    IO error encountered - skipping file deletion

Of course, this directory is a remote mount-point, and the remote host
cannot be reached.  I intuitively expected this error to be ignored,
since the directory would not be backed up anyway.  Then I realized that
rsync uses stat to tell that a directory is a mount-point.

Is there any other way to get this information?  I found statfs(2) and
statvfs(2) on my Linux system, but I couldn't get anything useful out of
them (f_fsid was always 0).  If there is some other approach, it would
be nice to use it.  That way, when rsync got an IO error, it could check
whether the path is a mount-point and ignore the error when
one-file-system is set.


More information about the rsync mailing list