Search code examples
sshrsyncpermission-denied

rsync weird behaviour


I have to sync some folders from a linux server, to another. We have created the RSA-Key and the authentication goes well.

When we launch an rsync command, some of the files gave birth to errors like:

  • rsync: readlink "/var/www/sestantemultimedia.it/xxecommerce/pub/.htaccess" failed: Permission denied (13)

Now, the directory /var/ (as well as other subdirectory) have the permits set to 755. The files into the last directories have permits set like 644.

So, theoretically, permits as set right and I can read from the other server and copy my files.

What I am missing?


Solution

  • Ok, I just figured it out.

    Someone (because we work together as a team) had done a change on the "final folder" so that "apache" user's group can't execute (so can't traverse) the folder itself.

    In that way, although it is possibile for "other group" to execute, the sum of permits that we receive (we were into "apache" group) isn't enough for "execute" the folder and retrive the file.

    We just change that scenario and now it works properly!