Hi all, is possible to know what version is executed on one server? Tnx -- Ciao Pirla Per rispondere in E-mail the (punto) pirla (chiocciola) flashnet.it *** un bacio ai pupi *** ---> Linux user since yesterday <--- ---> Linux User #389536 <---
Alexandros Papadopoulos
2006-May-03 12:48 UTC
How to know the remote version of rsync daemon?
On Wednesday 03 May 2006 13:13, Pirla wrote:> Hi all, > > is possible to know what version is executed on one server?You can get the protocol version with a simple netcat to the server: $ nc -n -v 172.16.23.5 873 (UNKNOWN) [172.16.23.5] 873 (rsync) open @RSYNCD: 29 Hence, protocol version 29. Not sure about the program version. -A
On Wed, May 03, 2006 at 12:13:49PM +0200, Pirla wrote:> is possible to know what version is executed on one server?There is no direct way to get this info via the rsync daemon protocol. You can sometimes try to narrow it down by using some of the newer options and seeing if they work or not. For instance, try this rsync command using at least rsync 2.6.7 on the local machine (choose any local file and a remote module on the host you want to figure out): rsync -vvvv --dirs --delete --dry-run some-file host::module The -vvvv will show you the protocol number: (Client) Protocol versions: remote=29, negotiated=29 Refer to the OLDNEWS file to see what rsync releases had what remote protocol version. In this case, a remote=29 means that the remote rsync is at least 2.6.4. If you get back this error: rsync: on remote machine: --no-r: unknown option then the rsync is older than 2.6.7 (you can get rid of the -vvvv if you're having a hard time finding the error among the other messages). If you see an error like one of these: ERROR: module is read only or rsync: The server is configured to refuse --delete or no error at all, then the remote machine is 2.6.7 or 2.6.8. If you want to distinguish 2.6.4 from 2.6.5/2.6.6, try this command: rsync --only-write-batch=batch_name some-file host::module If you see this error: rsync: on remote machine: --only-write-batch=X: unknown option then the remote system is running 2.6.4. There might be similar tricks to figure out older rsyncs (those with an older remote protocol version), but I'll leave it at that for now. ..wayne..