Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
rsync setup: use rsyncd or not?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
nahpets
Veteran
Veteran


Joined: 05 Oct 2003
Posts: 1178
Location: Montreal, Canada

PostPosted: Tue Jul 20, 2004 9:10 pm    Post subject: rsync setup: use rsyncd or not? Reply with quote

I have two computers which have a few directories that I want to keep in sync. The guides I've read all seem to use the rsync daemon "rsyncd". I read the manpages and found that I can do rsync from the command line without the daemon:
Code:

$ rsync -avz remote.machine.net:/some/dir/ /some/dir


So should I use the daemon or not?
Back to top
View user's profile Send private message
curtis119
Bodhisattva
Bodhisattva


Joined: 10 Mar 2003
Posts: 2160
Location: Toledo, Ohio,USA, North America, Earth, SOL System, Milky Way, The Universe, The Cosmos, and Beyond.

PostPosted: Tue Jul 20, 2004 9:17 pm    Post subject: Reply with quote

The daemon is good if you have a filesystem that changes a lot and needs to stay in sync. If you just need to replicate files every once in a while I would just put the rsync command line in a script and make it executable. Just use it when you need it.
_________________
Gentoo: it's like wiping your ass with silk.
Back to top
View user's profile Send private message
nahpets
Veteran
Veteran


Joined: 05 Oct 2003
Posts: 1178
Location: Montreal, Canada

PostPosted: Tue Jul 20, 2004 10:38 pm    Post subject: Reply with quote

If I use the daemon on the server machine, I still need to execute the rsync command myself, even if it's only periodically. As far as I can tell, there's really no difference from the client side. Is one method better than the other?
Back to top
View user's profile Send private message
curtis119
Bodhisattva
Bodhisattva


Joined: 10 Mar 2003
Posts: 2160
Location: Toledo, Ohio,USA, North America, Earth, SOL System, Milky Way, The Universe, The Cosmos, and Beyond.

PostPosted: Tue Jul 20, 2004 11:26 pm    Post subject: Reply with quote

Sorry I wasn't very clear in my first post. That's what I get for not proofreading!

You can put your rsync client script in a cron job to automate it. That way it always stays in sync with the rsync server. The server must have the rsync daemon running or started from within a shell or console. if you just need to use it every few weeks or so. you can ssh to the server machine start rsyncd, do the sync and then shut down rsyncd on the server and close the ssh session. Hope this is little more useful than the drivel I posted earlier :lol:
_________________
Gentoo: it's like wiping your ass with silk.
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Wed Jul 21, 2004 4:12 am    Post subject: Reply with quote

We do it by setting up host keys between machines. Then the cron look like

Code:

rsync -av -e ssh /local/path/ user@host:/remote/path/


The whole thing happend over ssh and there is not reason to run rsyncd on either server.

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
nahpets
Veteran
Veteran


Joined: 05 Oct 2003
Posts: 1178
Location: Montreal, Canada

PostPosted: Wed Jul 21, 2004 6:03 pm    Post subject: Reply with quote

kashani wrote:
We do it by setting up host keys between machines. Then the cron look like

Code:

rsync -av -e ssh /local/path/ user@host:/remote/path/


The whole thing happend over ssh and there is not reason to run rsyncd on either server.

kashani


Got it. So in terms of security, would you say that going through ssh is more secure since we don't have to open up another port for the rsync daemon?
Back to top
View user's profile Send private message
kashani
Advocate
Advocate


Joined: 02 Sep 2002
Posts: 2032
Location: San Francisco

PostPosted: Wed Jul 21, 2004 6:50 pm    Post subject: Reply with quote

That's the way we feel about it. Also there have been at least 2 serious bugs in the rsync daemon in the past year IIRC. You sacrifice some speed, but don't have to deal with yet another service you'll need to secure.

I have noticed some speed increases by setting blowfish to be the default crypto since it's easier on the CPU.

kashani
_________________
Will personally fix your server in exchange for motorcycle related shop tools in good shape.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum