mkstemp fails but data still transferred
Steve Harris
sharris at myra.com
Tue Mar 22 21:30:44 GMT 2005
Follow up ;
I'm no C programmer but looking at the receiver.c source and it appears
that the data does just get discarded (look at the receive_data function
for more info),
static void discard_receive_data(int f_in, OFF_T length)
{
receive_data(f_in, NULL, -1, 0, NULL, -1, length);
}
I'm confused why this is the case - is there a reason why this is done ?
Cheers all - Steve
He didn't administer a reign of terror, just the occasional light shower.
- Terry Pratchett, Sourcery
On Tue, 22 Mar 2005, Steve Harris wrote:
> Hi all,
>
> I'm running rsync version 2.6.3 protocol version 28 on Solaris 8 and am
> having a problem.
>
> We have some scripts that wrap around rsync and generate a list of files
> to transfer from the sending system (regardless of whether that directory
> exists on the receiver). I was expecting rsync to fail when transferring
> files with a path that doesn't exist on the receiver (in fact that's
> what I want it to do and I'm not worried about error messages).
>
> What seems to be happening is that even though the directory doesn't exist
> and the temporary file can't be created the data is transferred but
> not written anywher e.g.
>
> /usr/local/bin/rsync --stats -lptgoDvxe ssh
> sender:/source_dir/ORACLE/dsk03/ORACLE/DIR/somefile.dbf
> /dest_dir/dsk03/ORACLE/DIR/somefile.dbf
>
> rsync: mkstemp "/data00/dsk03/ORACLE/DIR/.somefile.jDaGKh"
> failed: No such file or directory (2)
>
> Number of files: 1
> Number of files transferred: 1
> Total file size: 839917568 bytes
> Total transferred file size: 839917568 bytes
> Literal data: 839917568 bytes
> Matched data: 0 bytes
> File list size: 69
> Total bytes sent: 36
> Total bytes received: 840020225
>
> sent 36 bytes received 840020225 bytes 2654092.45 bytes/sec
> total size is 839917568 speedup is 1.00
> rsync error: some files could not be transferred (code 23) at main.c(1146)
>
> An lsof of the rsync processes showed that no file was opened (apart from
> stdin, stdout, stderr and some sockets) that looked like the destination
> file. However a snoop confirms that data was being transferred from the
> sender to the receiver.
>
> I guess what I'm getting at is that if rsync can't create the temporary
> file shouldn't it just bail ?
>
> Any info would be greatfully received.
>
> Cheers - Steve
>
> ========================================================================
> He didn't administer a reign of terror, just the occasional light shower.
> - Terry Pratchett, Sourcery
> --
> To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
> Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
>
More information about the rsync
mailing list