Hi, I am trying to transfer a file that has spaces in its name. The rsync gives me below error. Am I doing anything wrong? #ls -l /tmp/test\ file -rw-rw-r-- 1 xxx xxx 0 Jul 5 02:23 /tmp//test file # /usr/local/bin/rsync --archive /u/masanip/ACH/test\\\ file /tmp/mydir/ rsync: link_stat "/tmp/test\ file" failed: No such file or directory (2) Number of files: 0 Number of files transferred: 0 Total file size: 0 bytes Total transferred file size: 0 bytes Literal data: 0 bytes Matched data: 0 bytes File list size: 9 File list generation time: 0.001 seconds File list transfer time: 0.000 seconds Total bytes sent: 121 Total bytes received: 12 sent 121 bytes received 12 bytes 29.56 bytes/sec total size is 0 speedup is 0.00 rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1039) [sender=3.0.6] Thanks. -------------- next part -------------- HTML attachment scrubbed and removed
Please note that double quates is working but I want to make it work with "\\\". For example, ==> /usr/local/bin/rsync --archive "/u/masanip/ACH/test file" /tmp/mydir/ <== is working but ==> /usr/local/bin/rsync --archive /u/masanip/ACH/test\\\ file /tmp/mydir/ <== not. Thanks. On Sun, Jul 5, 2009 at 2:29 AM, paresh masani <masaniparesh@gmail.com>wrote:> Hi, I am trying to transfer a file that has spaces in its name. The rsync > gives me below error. Am I doing anything wrong? > > #ls -l /tmp/test\ file > -rw-rw-r-- 1 xxx xxx 0 Jul 5 02:23 /tmp//test file > > # /usr/local/bin/rsync --archive /u/masanip/ACH/test\\\ file /tmp/mydir/ > rsync: link_stat "/tmp/test\ file" failed: No such file or directory (2) > > Number of files: 0 > Number of files transferred: 0 > Total file size: 0 bytes > Total transferred file size: 0 bytes > Literal data: 0 bytes > Matched data: 0 bytes > File list size: 9 > File list generation time: 0.001 seconds > File list transfer time: 0.000 seconds > Total bytes sent: 121 > Total bytes received: 12 > > sent 121 bytes received 12 bytes 29.56 bytes/sec > total size is 0 speedup is 0.00 > rsync error: some files/attrs were not transferred (see previous errors) > (code 23) at main.c(1039) [sender=3.0.6] > > Thanks. >-------------- next part -------------- HTML attachment scrubbed and removed
Matthias Schniedermeyer
2009-Jul-04 21:22 UTC
Rsync with spaces in source or destination path
On 05.07.2009 02:29, paresh masani wrote:> Hi, I am trying to transfer a file that has spaces in its name. The rsync > gives me below error. Am I doing anything wrong?What you are looking for is "-s" a.k.a. "--protect-args' - man rsync - -s, --protect-args no space-splitting; wildcard chars only - snip - Bis denn -- Real Programmers consider "what you see is what you get" to be just as bad a concept in Text Editors as it is in women. No, the Real Programmer wants a "you asked for it, you got it" text editor -- complicated, cryptic, powerful, unforgiving, dangerous.
Got it work with single slash. :-) # /usr/local/bin/rsync --archive /u/masanip/ACH/test\ file /tmp/mydir/ On Sun, Jul 5, 2009 at 2:34 AM, paresh masani <masaniparesh@gmail.com>wrote:> Please note that double quates is working but I want to make it work with > "\\\". > > For example, ==> /usr/local/bin/rsync --archive "/u/masanip/ACH/test file" > /tmp/mydir/ <== is working but ==> /usr/local/bin/rsync --archive > /u/masanip/ACH/test\\\ file /tmp/mydir/ <== not. > > Thanks. > > > On Sun, Jul 5, 2009 at 2:29 AM, paresh masani <masaniparesh@gmail.com>wrote: > >> Hi, I am trying to transfer a file that has spaces in its name. The rsync >> gives me below error. Am I doing anything wrong? >> >> #ls -l /tmp/test\ file >> -rw-rw-r-- 1 xxx xxx 0 Jul 5 02:23 /tmp//test file >> >> # /usr/local/bin/rsync --archive /u/masanip/ACH/test\\\ file /tmp/mydir/ >> rsync: link_stat "/tmp/test\ file" failed: No such file or directory (2) >> >> Number of files: 0 >> Number of files transferred: 0 >> Total file size: 0 bytes >> Total transferred file size: 0 bytes >> Literal data: 0 bytes >> Matched data: 0 bytes >> File list size: 9 >> File list generation time: 0.001 seconds >> File list transfer time: 0.000 seconds >> Total bytes sent: 121 >> Total bytes received: 12 >> >> sent 121 bytes received 12 bytes 29.56 bytes/sec >> total size is 0 speedup is 0.00 >> rsync error: some files/attrs were not transferred (see previous errors) >> (code 23) at main.c(1039) [sender=3.0.6] >> >> Thanks. >> > >-------------- next part -------------- HTML attachment scrubbed and removed
Hi, On Sun, 5 Jul 2009, paresh masani wrote:> Hi, I am trying to transfer a file that has spaces in its name. The rsync > gives me below error. Am I doing anything wrong? > > #ls -l /tmp/test\ file > -rw-rw-r-- 1 xxx xxx 0 Jul 5 02:23 /tmp//test file > > # /usr/local/bin/rsync --archive /u/masanip/ACH/test\\\ file /tmp/mydir/ > rsync: link_stat "/tmp/test\ file" failed: No such file or directory (2)Don't you see it: one / too much. Viele Gruesse Eberhard Moenkeberg (emoenke@gwdg.de, em@kki.org) -- Eberhard Moenkeberg Arbeitsgruppe IT-Infrastruktur E-Mail: emoenke@gwdg.de Tel.: +49 (0)551 201-1551 ------------------------------------------------------------------------- Gesellschaft fuer wissenschaftliche Datenverarbeitung mbH Goettingen (GWDG) Am Fassberg 11, 37077 Goettingen URL: http://www.gwdg.de E-Mail: gwdg@gwdg.de Tel.: +49 (0)551 201-1510 Fax: +49 (0)551 201-2150 Geschaeftsfuehrer: Prof. Dr. Bernhard Neumair Aufsichtsratsvorsitzender: Dipl.-Kfm. Markus Hoppe Sitz der Gesellschaft: Goettingen Registergericht: Goettingen Handelsregister-Nr. B 598 -------------------------------------------------------------------------
Possibly Parallel Threads
- the protect flag - P doesn't work with --relative option ?
- Possibly bug in rsync-3.0.6 when spaces are there in destination path
- How could be "total transferred file size" more than "total file size" ?
- limiting the number of connections per client
- rsync sleep