LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Couple rsync security errors i'm not sure of (https://www.linuxquestions.org/questions/linux-software-2/couple-rsync-security-errors-im-not-sure-of-942951/)

anon091 05-02-2012 11:52 AM

Couple rsync security errors i'm not sure of
 
Just setup a new rsync but i'm getting the following errors, any idea what they mean or what i should check? the owner of the folder i'm rsyncing from and to are both root on the respective servers, and the folders are 777.

reverse mapping checking getaddrinfo for different.server.fqdn failed - POSSIBLE BREAK-IN ATTEMPT!
rsync: failed to set times on "/data/FolderImRsyncing/.": Operation not permitted (1)
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1039) [sender=3.0.6]

pan64 05-02-2012 01:12 PM

can you please give us some more details: how did you invoke rsync, do you have also a daemon configured?

anon091 05-02-2012 01:30 PM

tried it by manually running the command from the CLI. i have the same command in a crontab but its not sent to run yet.

rsync -az -e ssh then the two paths

pan64 05-03-2012 01:08 AM

Quote:

reverse mapping checking getaddrinfo for different.server.fqdn failed - POSSIBLE BREAK-IN ATTEMPT!
this one looks like a DNS error, or something around your DNS configuration. see this page.
Quote:

rsync: failed to set times on "/data/FolderImRsyncing/.": Operation not permitted (1)
this looks like an error/warning message of rsync. Maybe that directory cannot be modified by rsync, you need to check it. Is this a mounted filesystem?
Quote:

rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1039) [sender=3.0.6]
this is not an error, just a message at the and of the rsync session: something went wrong (see previous errors)

anon091 05-03-2012 07:32 AM

Thanks for breaking it down pan. I'll look at the link you provided about the DNS thing. that directory is the one that i'm rsync'ing to, which is just a folder on an array on the other server. that path isn't mounted on the server doing the rsyncing.

anon091 05-03-2012 10:10 AM

That article helped me I believe with the first error, I did find an abandoned incorrect reverse DNS entry with that IP and name. Thanks. Still not sure how to proceed on that second error though about the setting times.

pan64 05-03-2012 12:02 PM

That is great, so the first problem is solved.
To the second: you can have more information about what's happening with -v. You can add it several times, it will increase verbosity. You can try --itemize-changes and --dry-run also and I suggest you to check --omit-dir-times. These may give some additional information.
Is this directory ("/data/FolderImRsyncing/.") the root of the destination, or is it inside or ? Does this dir exist before the transfer or rsync should create it?
Which user invokes rsync? How the permissions set on /data (the parent dir)?
Do you have an rsyncd configured on the remote site?

anon091 05-07-2012 12:04 PM

I tried it with two v's and it still said the same thing.

My full statement is rsync -az --delete -e ssh /data/FolderImRsyncing/ account@1.2.3.4:/data/FolderImRsyncing/

Due to the 1st time i ran it, all the folders now exist on the destination server (1.2.3.4 in the example above).

the folder on both servers is 777 with root:root, /data is the same.

chrism01 05-07-2012 08:25 PM

Quote:

rsync: failed to set times on "/data/FolderImRsyncing/.": Operation not permitted (1)
Check the mnt options on the target; it may be set to 'noatime' for extra performance.

anon091 05-08-2012 08:17 AM

Thanks for the reply Chris. How do you check the mnt options on a server? if noatime is the default setting, that's probably the cause, since i don't even know how to change mnt options they're all at defaults I would think.

catkin 05-08-2012 09:52 AM

AFAIK atime is the default so noatime has to be explicitly set, most commonly in /etc/fstab

Another possibility is that the target file system does not support the time rsync is trying to set. What sort of file system is /data/FolderImRsyncing/ on?

For a pretty display of this info, run df -T

Alternatively run mount or, most fundamentally, cat /proc/mounts

anon091 05-08-2012 10:03 AM

its ext3

catkin 05-08-2012 10:16 AM

ext3 should be OK.

And it should not be a permissions problem because you wrote in the OP: "the owner of the folder i'm rsyncing from and to are both root on the respective servers, and the folders are 777".

Mmm ... ? ... what's the line for the file system with the /data/FolderImRsyncing/ in cat /proc/mounts output?

On the target system, can root change timestamps on /data/FolderImRsyncing/. ? What's the output from
Code:

touch -d '12 October 2010' /data/FolderImRsyncing/.
stat /data/FolderImRsyncing/.


anon091 05-08-2012 10:22 AM

from /proc/mounts, it shows this /dev/sdb1 /data ext3 rw,data=ordered 0 0

If I do a stat on a file that was copied over via the rsync, it shows the following. One thing I might have not mentioned, is that my rsync is not in root's crontab, but in another accounts, changed to RsyncAccount in the output below. Or do you have to be the account or owner of that folder to be able to modify the time so that's what is causing the problem since it's root:root rather than RsyncAccount (even though /data is 777)?

Size: 4735117 Blocks: 9280 IO Block: 4096 regular file
Device: 811h/2065d Inode: 83230722 Links: 1
Access: (0777/-rwxrwxrwx) Uid: ( 506/ RsyncAccount) Gid: ( 506/ RsyncAccount)
Access: 2012-05-02 10:28:59.000000000 -0400
Modify: 2011-08-02 08:12:25.000000000 -0400
Change: 2012-05-02 10:28:59.000000000 -0400

pan64 05-09-2012 10:01 AM

have you tried -O (for rsync)?


All times are GMT -5. The time now is 07:19 PM.