Bug#609443: rsnapshot: backup fails with space in path destination

January 09th, 2011 - 10:10 am ET by Ptit g | Report spam
Package: rsnapshot
Version: 1.3.1-1
Severity: normal

config: backup /tmp/test/ dest\ backup/test/

# rsnapshot -t hourly
echo 5365 > /var/run/rsnapshot.pid
mkdir -m 0755 -p /var/cache/rsnapshot/hourly.0/dest\ backup/
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
/tmp/test /var/cache/rsnapshot/hourly.0/dest\ backup/test/
touch /var/cache/rsnapshot/hourly.0/

# rsnapshot hourly
rsync: mkdir "/var/cache/rsnapshot/hourly.0/dest backup/test" failed: No such file or directory (2)
rsync error: error in file IO (code 11) at main.c(595) [Receiver=3.0.7]
rsync: connection unexpectedly closed (9 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [sender=3.0.7]
-
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot hourly
-
ERROR: /usr/bin/rsync returned 12 while processing /tmp/test/


rsync uses the destination folder 'dest backup', but rsnapshot creates a folder named 'dest\ backup'.



Debian Release: 6.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'stable'), (100, 'unstable'), (10, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/1 CPU core)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages rsnapshot depends on:
ii liblchown-perl 1.01-1 Perl interface to the lchown() sys
ii logrotate 3.7.8-6 Log rotation utility
ii perl 5.10.1-16 Larry Wall's Practical Extraction
ii rsync 3.0.7-2 fast remote file copy program (lik

Versions of packages rsnapshot recommends:
ii openssh-client 1:5.5p1-6 secure shell (SSH) client, for sec

rsnapshot suggests no packages.

/etc/rsnapshot.conf changed:
config_version 1.2
snapshot_root /var/cache/rsnapshot/
cmd_rm /bin/rm
cmd_rsync /usr/bin/rsync
cmd_logger /usr/bin/logger
interval hourly 6
interval daily 7
interval weekly 4
verbose 2
loglevel 3
lockfile /var/run/rsnapshot.pid
backup /tmp/test/ dest\ backup/test/





To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
email Follow the discussionReplies 3 repliesReplies Make a reply

Similar topics

Replies

#1 Guillaume Delacour
January 11th, 2011 - 07:10 pm ET | Report spam

Bonjour,

Le dimanche 09 janvier 2011 à  16:07 +0100, P'tit g a écrit :
Package: rsnapshot
Version: 1.3.1-1
Severity: normal

config: backup /tmp/test/ dest\ backup/test/

# rsnapshot -t hourly
echo 5365 > /var/run/rsnapshot.pid
mkdir -m 0755 -p /var/cache/rsnapshot/hourly.0/dest\ backup/
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
/tmp/test /var/cache/rsnapshot/hourly.0/dest\ backup/test/
touch /var/cache/rsnapshot/hourly.0/

# rsnapshot hourly
rsync: mkdir "/var/cache/rsnapshot/hourly.0/dest backup/test" failed: No such file or directory (2)



Not excatly; the problem is that you can't specify "dest backup" because
of parsing in /etc/rsnapshot.conf and "dest\ backup" was created on the
filesystem by mkpath() but the second "test" directory fail to be
created under "dest\ backup" (because the directory is now "dest\\\
backup"; one \ to escape the \ in the name, the second is already in the
name, and a third for escaping the space).

If it's not a constraint, i absolutely recommend to replace spaces in
destdir by "_" or anyother special character you like.

As a fix, the backslash must be deleted to leave mkpath and rsync manage
it the right way with space characters (in sub create_backup_point_dir,
line 4125):

$destpath =~ s/\\+//;

rsync error: error in file IO (code 11) at main.c(595) [Receiver=3.0.7]
rsync: connection unexpectedly closed (9 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [sender=3.0.7]
-
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot hourly
-
ERROR: /usr/bin/rsync returned 12 while processing /tmp/test/


rsync uses the destination folder 'dest backup', but rsnapshot creates a folder named 'dest\ backup'.



Debian Release: 6.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'stable'), (100, 'unstable'), (10, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/1 CPU core)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages rsnapshot depends on:
ii liblchown-perl 1.01-1 Perl interface to the lchown() sys
ii logrotate 3.7.8-6 Log rotation utility
ii perl 5.10.1-16 Larry Wall's Practical Extraction
ii rsync 3.0.7-2 fast remote file copy program (lik

Versions of packages rsnapshot recommends:
ii openssh-client 1:5.5p1-6 secure shell (SSH) client, for sec

rsnapshot suggests no packages.

/etc/rsnapshot.conf changed:
config_version 1.2
snapshot_root /var/cache/rsnapshot/
cmd_rm /bin/rm
cmd_rsync /usr/bin/rsync
cmd_logger /usr/bin/logger
interval hourly 6
interval daily 7
interval weekly 4
verbose 2
loglevel 3
lockfile /var/run/rsnapshot.pid
backup /tmp/test/ dest\ backup/test/







Guillaume Delacour






To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact
Replies Reply to this message
#2 Guillaume Delacour
January 11th, 2011 - 07:10 pm ET | Report spam

Bonjour,

Le dimanche 09 janvier 2011 à  16:07 +0100, P'tit g a écrit :
Package: rsnapshot
Version: 1.3.1-1
Severity: normal

config: backup /tmp/test/ dest\ backup/test/

# rsnapshot -t hourly
echo 5365 > /var/run/rsnapshot.pid
mkdir -m 0755 -p /var/cache/rsnapshot/hourly.0/dest\ backup/
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
/tmp/test /var/cache/rsnapshot/hourly.0/dest\ backup/test/
touch /var/cache/rsnapshot/hourly.0/

# rsnapshot hourly
rsync: mkdir "/var/cache/rsnapshot/hourly.0/dest backup/test" failed: No such file or directory (2)



Not excatly; the problem is that you can't specify "dest backup" because
of parsing in /etc/rsnapshot.conf and "dest\ backup" was created on the
filesystem by mkpath() but the second "test" directory fail to be
created under "dest\ backup" (because the directory is now "dest\\\
backup"; one \ to escape the \ in the name, the second is already in the
name, and a third for escaping the space).

If it's not a constraint, i absolutely recommend to replace spaces in
destdir by "_" or anyother special character you like.

As a fix, the backslash must be deleted to leave mkpath and rsync manage
it the right way with space characters (in sub create_backup_point_dir,
line 4125):

$destpath =~ s/\\+//;

rsync error: error in file IO (code 11) at main.c(595) [Receiver=3.0.7]
rsync: connection unexpectedly closed (9 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [sender=3.0.7]
-
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot hourly
-
ERROR: /usr/bin/rsync returned 12 while processing /tmp/test/


rsync uses the destination folder 'dest backup', but rsnapshot creates a folder named 'dest\ backup'.



Debian Release: 6.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'stable'), (100, 'unstable'), (10, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/1 CPU core)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages rsnapshot depends on:
ii liblchown-perl 1.01-1 Perl interface to the lchown() sys
ii logrotate 3.7.8-6 Log rotation utility
ii perl 5.10.1-16 Larry Wall's Practical Extraction
ii rsync 3.0.7-2 fast remote file copy program (lik

Versions of packages rsnapshot recommends:
ii openssh-client 1:5.5p1-6 secure shell (SSH) client, for sec

rsnapshot suggests no packages.

/etc/rsnapshot.conf changed:
config_version 1.2
snapshot_root /var/cache/rsnapshot/
cmd_rm /bin/rm
cmd_rsync /usr/bin/rsync
cmd_logger /usr/bin/logger
interval hourly 6
interval daily 7
interval weekly 4
verbose 2
loglevel 3
lockfile /var/run/rsnapshot.pid
backup /tmp/test/ dest\ backup/test/







Guillaume Delacour






To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact
Replies Reply to this message
#3 Guillaume Delacour
January 11th, 2011 - 07:10 pm ET | Report spam

Bonjour,

Le dimanche 09 janvier 2011 à  16:07 +0100, P'tit g a écrit :
Package: rsnapshot
Version: 1.3.1-1
Severity: normal

config: backup /tmp/test/ dest\ backup/test/

# rsnapshot -t hourly
echo 5365 > /var/run/rsnapshot.pid
mkdir -m 0755 -p /var/cache/rsnapshot/hourly.0/dest\ backup/
/usr/bin/rsync -a --delete --numeric-ids --relative --delete-excluded \
/tmp/test /var/cache/rsnapshot/hourly.0/dest\ backup/test/
touch /var/cache/rsnapshot/hourly.0/

# rsnapshot hourly
rsync: mkdir "/var/cache/rsnapshot/hourly.0/dest backup/test" failed: No such file or directory (2)



Not excatly; the problem is that you can't specify "dest backup" because
of parsing in /etc/rsnapshot.conf and "dest\ backup" was created on the
filesystem by mkpath() but the second "test" directory fail to be
created under "dest\ backup" (because the directory is now "dest\\\
backup"; one \ to escape the \ in the name, the second is already in the
name, and a third for escaping the space).

If it's not a constraint, i absolutely recommend to replace spaces in
destdir by "_" or anyother special character you like.

As a fix, the backslash must be deleted to leave mkpath and rsync manage
it the right way with space characters (in sub create_backup_point_dir,
line 4125):

$destpath =~ s/\\+//;

rsync error: error in file IO (code 11) at main.c(595) [Receiver=3.0.7]
rsync: connection unexpectedly closed (9 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [sender=3.0.7]
-
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot hourly
-
ERROR: /usr/bin/rsync returned 12 while processing /tmp/test/


rsync uses the destination folder 'dest backup', but rsnapshot creates a folder named 'dest\ backup'.



Debian Release: 6.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'stable'), (100, 'unstable'), (10, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/1 CPU core)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages rsnapshot depends on:
ii liblchown-perl 1.01-1 Perl interface to the lchown() sys
ii logrotate 3.7.8-6 Log rotation utility
ii perl 5.10.1-16 Larry Wall's Practical Extraction
ii rsync 3.0.7-2 fast remote file copy program (lik

Versions of packages rsnapshot recommends:
ii openssh-client 1:5.5p1-6 secure shell (SSH) client, for sec

rsnapshot suggests no packages.

/etc/rsnapshot.conf changed:
config_version 1.2
snapshot_root /var/cache/rsnapshot/
cmd_rm /bin/rm
cmd_rsync /usr/bin/rsync
cmd_logger /usr/bin/logger
interval hourly 6
interval daily 7
interval weekly 4
verbose 2
loglevel 3
lockfile /var/run/rsnapshot.pid
backup /tmp/test/ dest\ backup/test/







Guillaume Delacour






To UNSUBSCRIBE, email to
with a subject of "unsubscribe". Trouble? Contact
email Follow the discussion Replies Reply to this message
Help Create a new topicReplies Make a reply
Search Make your own search