automated Rsync to remote host, preserve owner - Tools

This is a discussion on automated Rsync to remote host, preserve owner - Tools ; Hello all, I'm trying to set up a backup server using rsync. I would prefer to push data from one server to another, automated through a cron job. It is quite important to preserve the owner/group and permissions. google and ...

+ Reply to Thread
Results 1 to 5 of 5

Thread: automated Rsync to remote host, preserve owner

  1. automated Rsync to remote host, preserve owner

    Hello all,
    I'm trying to set up a backup server using rsync.
    I would prefer to push data from one server to another, automated through a
    cron job. It is quite important to preserve the owner/group and permissions.

    google and the archives haven't gotten me very far.

    the two servers each have a seperate IP address, but they also have access to
    the same private, trusted LAN.
    I'm having trouble figuring out how to set this up.
    Each server is freebsd 7.0
    I haven't quit figured this out, but this is what I think so far:
    setup rsync daemon using inetd on the receiving end so that it only listens on
    192.168.*.*. Set uid and gid to root in rsyncd.conf
    and then on the sending end issue the command (through cron)
    rsync -arlpogtUH --delete-delay --password-file /path/to/pass /path/to/files
    user@example.com:/path/to/files

    This isn't working yet, so any help would be very much appreciated
    Ray
    --
    Please use reply-all for most replies to avoid omitting the mailing list.
    To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
    Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


  2. Re: automated Rsync to remote host, preserve owner

    On Thu, 2008-09-25 at 14:58 -0600, RAY wrote:
    > I'm trying to set up a backup server using rsync.
    > I would prefer to push data from one server to another, automated through a
    > cron job. It is quite important to preserve the owner/group and permissions.
    >
    > google and the archives haven't gotten me very far.
    >
    > the two servers each have a seperate IP address, but they also have access to
    > the same private, trusted LAN.
    > I'm having trouble figuring out how to set this up.
    > Each server is freebsd 7.0
    > I haven't quit figured this out, but this is what I think so far:
    > setup rsync daemon using inetd on the receiving end so that it only listens on
    > 192.168.*.*. Set uid and gid to root in rsyncd.conf
    > and then on the sending end issue the command (through cron)
    > rsync -arlpogtUH --delete-delay --password-file /path/to/pass /path/to/files
    > user@example.com:/path/to/files


    Check the examples at the top of the man page. You need a double colon
    to access an rsync daemon; a single colon indicates a remote shell.

    Matt

    --
    Please use reply-all for most replies to avoid omitting the mailing list.
    To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
    Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


  3. Re: automated Rsync to remote host, preserve owner

    Ray, please CC rsync@lists.samba.org so that others can help you and
    your messages are archived for others' future benefit.

    On Thu, 2008-09-25 at 17:12 -0600, RAY wrote:
    > This is what I have done so far:
    > I have enabled rsync --daemon in inetd, created a rsyncd.conf file.
    >
    > I used the following for confirmation
    > server#rsync admin@host.wserver.tld::
    > www www
    >
    > I then attempted to transfer data in the following way:
    > server# rsync -narvv /usr/local/etc/apache22/data admin@host.wserver.tld::www
    > opening tcp connection to host.wserver.tld port 873
    > sending daemon args: --server -vvnlogDtpre.iL . www/
    > Password:
    > sending incremental file list
    > rsync: link_stat "/usr/local/etc/apache22/data" failed: No such file or
    > directory (2)
    > total: matches=0 hash_hits=0 false_alarms=0 data=0
    >
    > sent 14 bytes received 8 bytes 4.00 bytes/sec
    > total size is 0 speedup is 0.00 (DRY RUN)
    > rsync error: some files could not be transferred (code 23) at main.c(1040)
    > [sender=3.0.3]


    Rsync is telling you that the source directory
    /usr/local/etc/apache22/data does not exist. If you are certain that
    the directory exists, strace rsync to see why rsync thinks it doesn't.

    Matt

    --
    Please use reply-all for most replies to avoid omitting the mailing list.
    To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
    Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


  4. Re: automated Rsync to remote host, preserve owner

    On Thursday 25 September 2008 6:04:55 pm Matt McCutchen wrote:
    > Ray, please CC rsync@lists.samba.org so that others can help you and
    > your messages are archived for others' future benefit.
    >


    Sorry Matt,
    My mistake.
    Ray

    --
    Please use reply-all for most replies to avoid omitting the mailing list.
    To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
    Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


  5. Re: automated Rsync to remote host, preserve owner

    On Thursday 25 September 2008 6:04:55 pm Matt McCutchen wrote:


    >
    > Rsync is telling you that the source directory
    > /usr/local/etc/apache22/data does not exist. If you are certain that
    > the directory exists, strace rsync to see why rsync thinks it doesn't.
    >
    > Matt


    Yeah, your right, source should be /usr/local/www/apache22/data
    /usr/local/etc holds configuration data. I spent over two hours looking for
    the error
    Thanks
    Ray
    --
    Please use reply-all for most replies to avoid omitting the mailing list.
    To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
    Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


+ Reply to Thread