Read the Man Pages


This morning I realized that I needed some sort of synchronization between my primary and secondary web servers for when I make updates to my website. When I was just running the website on one web server, there was only a need for synchronization between my desktop machine and the server. So my plan is to use openrsync to sync files between my desktop and the primary web server. Then I can either have a periodic cron job running on the primary server or I could just do another sync from my desktop to the secondary server.

Openrsync is a really great program, but up until today, I thought that it still required rsync on a remote end because I got an error every time I tried to use it. The error was something about rsync not being found or installed; something along those lines so I just installed rsync. I know that OpenBSD developers generally do not do pointless things as the idea behind openrsync was so that OpenBSD could do RPKI updates. The original rsync program is a GPLv4 licensed tool so the OpenBSD project cannot use it in the default build. Thus, write an rsync compatible tool called openrsync. Reading the man page I learned that I needed to specify an option. So, when I want to sync I just do openrsync -arv --rsync-path=openrsync -e "ssh: /dir/to/sync me@example.com:/dir/to/sync. Voila! It works! I can pkg_delete rsync and stick with the truly open one.

I think the reason the devs left openrsync default to regular rsync so as to be compatible with the rest of the world. It’s trivial to use it between OpenBSD machines if you add the --rsynch-path= switch. Simply for reading the man page a little more closely, I discovered that installing rsync from packages was superfluous and redundant. I am laughing about it now.


See also