Error with path names greater than 255 characters

Edward King edk at cendatsys.com
Tue Jun 10 23:25:54 EST 2003


Rsync 2.5.6 has a problem with pathnames or filenames longer than 255.  
I redefined them in rsync.h, which generated errors on make pointing to 
the previous definitions which look fine. Any ideas on where to check next?

Here's the error I got trying to rsync:

receiving file list ... done
media/zip.backup.2003-06-03.1415/windows.backup.2003-06-03.1415/oracle.backup.2003-06-03.1415/Dev6i.backup.2003-06-03.1415/win32.backup.2003-06-03.1415/d2dh.backup.2003-06-03.1415/6_0_8_11_4.backup.2003-06-03.1415/doc.backup.2003-06-03.1415/
media/zip.backup.2003-06-03.1415/windows.backup.2003-06-03.1415/oracle.backup.2003-06-03.1415/Dev6i.backup.2003-06-03.1415/win32.backup.2003-06-03.1415/d2dh.backup.2003-06-03.1415/6_0_8_11_4.backup.2003-06-03.1415/doc.backup.2003-06-03.1415/d2ky2kwp4.pdf.backup.2003-06-03.1415
write failed on 
media/zip.backup.2003-06-03.1415/windows.backup.2003-06-03.1415/oracle.backup.2003-06-03.1415/Dev6i.backup.2003-06-03.1415/win32.backup.2003-06-03.1415/d2dh.backup.2003-06-03.1415/6_0_8_11_4.backup.2003-06-03.1415/doc.backup.2003-06-03.1415/d2ky2kwp4.pdf.backup.2003-06-03.1415 
: Success
rsync error: error in file IO (code 11) at receiver.c(243)
rsync: connection unexpectedly closed (5844537 bytes read so far)
rsync error: error in rsync protocol data stream (code 12) at io.c(165)


Here's what make produced after redefining the constants:

[root at festiva rsync-2.5.6]# make
gcc -I. -I. -g -O2 -DHAVE_CONFIG_H -Wall -W  -c rsync.c -o rsync.o
In file included from rsync.c:23:
rsync.h:325: warning: `PATH_MAX' redefined
/usr/include/linux/limits.h:14: warning: this is the location of the 
previous definition
rsync.h:326: warning: `MAXPATHLEN' redefined
/usr/include/sys/param.h:35: warning: this is the location of the 
previous definition


And checking for the previous values of PATH_MAX and MAXPATHLEN I found:
***/usr/include/linux/limits.h***
#define NAME_MAX         255    /* # chars in a file name */
#define PATH_MAX        4095    /* # chars in a path name */

***/usr/include/sys/param.h***
#define MAXPATHLEN      PATH_MAX

Thanks!

Ed King




More information about the rsync mailing list