Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have multiple servers that receive files via rsync on different ports. I'd like to merge them into the same physical server and let the clients continue to direct their files to the same port they do now (ie different alternate ports).

Normally I'd just run /usr/bin/rsync --daemon --port=x for each one, but I'm trying to get it to work via xinetd in centos 6 since that's the 'default' rsync server now. Adding the ports in /etc/services didn't do it (it should have under inetd, but maybe not xinetd?). If I run the daemon manually and let xinetd run one it runs (so I'm not blocked to just get it done), but I'd still like them to both be run by xinetd. My question is can that even be done?

As a side thing, in man rsync:

--port=PORT This specifies an alternate TCP port number for the daemon to listen on rather than the default of 873. See also the lqportrq global option in the rsyncd.conf manpage.

lqportrq doesn't show up in man rsync.d or a google search anywhere. what gives?

share|improve this question
    
Something is funky with your manpage, mine says "See also the "port" global option in the rsyncd.conf manpage." –  mgorven Jul 6 '12 at 22:41
    
Please should your xinetd configuration. –  mgorven Jul 6 '12 at 22:52
    
mgorven- it's just the default from centos, I changed nothing –  Jason Powers Jul 6 '12 at 22:53
add comment

1 Answer

You need to add additional xinetd configuration for each additional port you want to use. Each port needs a unique service name in /etc/services, so for example:

echo "rsync00 900/tcp" >> /etc/services

And then in /etc/xinet.d/rsync00:

service rsync00
{
        flags           = IPv6
        socket_type     = stream
        wait            = no
        user            = root
        server          = /usr/bin/rsync
        server_args     = --daemon --config /etc/rsync00.conf
        log_on_failure  += USERID
}
share|improve this answer
    
This is it, thanks. I also needed to add --port=x to server_args in the new file. It's kind of frustrating that the default config doesn't kick out enough logs to troubleshoot, but I suppose redhat has to sell support somehow. –  Jason Powers Jul 6 '12 at 23:06
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.