Error reading source directory "": directory not found

Hello,

i’m trying to sync my backup folder on google drive but i have this error.

/usr/sbin/rclone -vv sync /var/backups/web2 cxxo:1_Backup_VPS/
2017/06/20 14:18:25 DEBUG : rclone: Version "v1.36" starting with parameters ["/usr/sbin/rclone" "-vv" "sync" "/var/backups/web2" "cxxo:1_Backup_VPS/"]
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Modify window is 1ms
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Reading ""
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Finished reading ""
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for checks to finish
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for transfers to finish
2017/06/20 14:18:26 ERROR : Google drive root '1_Backup_VPS': not deleting files as there were IO errors
2017/06/20 14:18:26 ERROR : Attempt 1/3 failed with 0 errors and: error reading source directory "": directory not found
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Reading ""
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Finished reading ""
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for checks to finish
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for transfers to finish
2017/06/20 14:18:26 ERROR : Google drive root '1_Backup_VPS': not deleting files as there were IO errors
2017/06/20 14:18:26 ERROR : Attempt 2/3 failed with 0 errors and: error reading source directory "": directory not found
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Reading ""
2017/06/20 14:18:26 DEBUG : Google drive root '1_Backup_VPS': Finished reading ""
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for checks to finish
2017/06/20 14:18:26 INFO  : Google drive root '1_Backup_VPS': Waiting for transfers to finish
2017/06/20 14:18:26 ERROR : Google drive root '1_Backup_VPS': not deleting files as there were IO errors
2017/06/20 14:18:26 ERROR : Attempt 3/3 failed with 0 errors and: error reading source directory "": directory not found
2017/06/20 14:18:26 Failed to sync: error reading source directory "": directory not found

What does that mean?
I searched on google but nothing worked.

I think i found the solution.

i sync in a different remote folder and let rclone create the folder itself.

this way it work.

the error come back at the second sync:

mar. juin 20 15:56:03 CEST 2017 2017/06/20 15:56:03 ERROR : Google drive root '1_Backup': not deleting files as there were IO errors
mar. juin 20 15:56:03 CEST 2017 2017/06/20 15:56:03 ERROR : Attempt 1/3 failed with 0 errors and: error reading source directory "": directory not found

now it work in command line but not from a script…

i modified the script like below and run it 2 times. i can say that delete work and copy don’t work…

#!/bin/bash
/usr/sbin/rclone copy /var/backups/web2 cxxo:1_Backup;
/usr/sbin/rclone --min-age 1m delete cxxo:1_Backup;

you should probably add a -v or even a -vv to see what it is doing.

delete works, copy doesn’t work…

input:

#!/bin/bash
/usr/sbin/rclone -vv --min-age 1m delete bxxxo:1_Backup;
/usr/sbin/rclone -vv copy --ignore-existing /var/backups/web1 bxxxo:1_Backup;

output:

mar. juin 20 19:00:02 CEST 2017 2017/06/20 19:00:02 INFO  : Google drive root '1_Backup': Modify window is 1ms
mar. juin 20 19:00:02 CEST 2017 2017/06/20 19:00:02 INFO  : Waiting for deletions to finish
mar. juin 20 19:00:02 CEST 2017 2017/06/20 19:00:02 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:00:02 CEST 2017 2017/06/20 19:00:02 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 INFO  : db_c1bxxxo_2017-06-20_00-40.sql.gz: Deleted
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 INFO  : web1_2017-06-20_00-01.tar.gz: Deleted
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 DEBUG : Go routines at exit 8
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 DEBUG : rclone: Version "v1.36" finishing with parameters ["/usr/sbin/rclone" "-vv" "--min-age" "1m" "delete" "bxxxo:1_Backup"]
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 DEBUG : rclone: Version "v1.36" starting with parameters ["/usr/sbin/rclone" "-vv" "copy" "--ignore-existing" "/var/backups/web1" "bxxxo:1_Backup"]
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 INFO  : Google drive root '1_Backup': Modify window is 1ms
mar. juin 20 19:00:03 CEST 2017 2017/06/20 19:00:03 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 ERROR : Attempt 1/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 ERROR : Attempt 2/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 ERROR : Attempt 3/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:00:04 CEST 2017 2017/06/20 19:00:04 Failed to copy: error reading source directory "": directory not found

Try this please:

/usr/sbin/rclone -vv copy /var/backups/web1 bxxxo:1_Backup --ignore-existing

mar. juin 20 19:22:01 CEST 2017 2017/06/20 19:22:01 INFO  : Google drive root '1_Backup': Modify window is 1ms
mar. juin 20 19:22:01 CEST 2017 2017/06/20 19:22:01 INFO  : Waiting for deletions to finish
mar. juin 20 19:22:01 CEST 2017 2017/06/20 19:22:01 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Go routines at exit 4
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : rclone: Version "v1.36" finishing with parameters ["/usr/sbin/rclone" "-vv" "--min-age" "1m" "delete" "bxxxo:1_Backup"]
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : rclone: Version "v1.36" starting with parameters ["/usr/sbin/rclone" "-vv" "copy" "/var/backups/web1" "bxxxo:1_Backup" "--ignore-existing"]
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 INFO  : Google drive root '1_Backup': Modify window is 1ms
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 ERROR : Attempt 1/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 ERROR : Attempt 2/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:22:02 CEST 2017 2017/06/20 19:22:02 DEBUG : Google drive root '1_Backup': Reading ""
mar. juin 20 19:22:03 CEST 2017 2017/06/20 19:22:03 DEBUG : Google drive root '1_Backup': Finished reading ""
mar. juin 20 19:22:03 CEST 2017 2017/06/20 19:22:03 INFO  : Google drive root '1_Backup': Waiting for checks to finish
mar. juin 20 19:22:03 CEST 2017 2017/06/20 19:22:03 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
mar. juin 20 19:22:03 CEST 2017 2017/06/20 19:22:03 ERROR : Attempt 3/3 failed with 0 errors and: error reading source directory "": directory not found
mar. juin 20 19:22:03 CEST 2017 2017/06/20 19:22:03 Failed to copy: error reading source directory "": directory not found

What verson are you using? Try the latest beta. I do see some fixes around spaces in file names/remotes.Example: https://github.com/ncw/rclone/issues/1310

i use the version 1.36. How can i download the last beta version?

https://beta.rclone.org Pick the last one…

same error with the last beta version. it’s only bug with cron. i think the key is here.

   mar. juin 20 20:38:02 CEST 2017 2017/06/20 20:38:02 DEBUG : rclone: Version "v1.36-198-g8d77e481β" starting with parameters ["/usr/sbin/rclone" "-vv" "copy" "/var/backups/web1" "bxxx:1_Backup" "--ignore-existing"]
    mar. juin 20 20:38:02 CEST 2017 2017/06/20 20:38:02 INFO  : Google drive root '1_Backup': Modify window is 1ms
    mar. juin 20 20:38:02 CEST 2017 2017/06/20 20:38:02 INFO  : Google drive root '1_Backup': Waiting for checks to finish
    mar. juin 20 20:38:02 CEST 2017 2017/06/20 20:38:02 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
    mar. juin 20 20:38:02 CEST 2017 2017/06/20 20:38:02 ERROR : Attempt 1/3 failed with 0 errors and: error reading source directory "": directory not found
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 INFO  : Google drive root '1_Backup': Waiting for checks to finish
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 ERROR : Attempt 2/3 failed with 0 errors and: error reading source directory "": directory not found
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 INFO  : Google drive root '1_Backup': Waiting for checks to finish
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 INFO  : Google drive root '1_Backup': Waiting for transfers to finish
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 ERROR : Attempt 3/3 failed with 0 errors and: error reading source directory "": directory not found
    mar. juin 20 20:38:03 CEST 2017 2017/06/20 20:38:03 Failed to copy: error reading source directory "": directory not found

and it works before i reinstall centos and it was the exact same version of centos… so i think there is a problem with permissions or something like that. but i am newbie with linux so i don’t know how to fix that.

finally, i have found the problem. and i was true somewhere…
the folder “backup” doesn’t end with an “s”.
with the console, i use the tab to autocomplete so no error.
in the script, the folder “backup” ended with a “s” because it was like that before.

so, 5 hours of search because a small “s”…

(sorry for my bad english, it’s not my first language)