[Csync2] ERROR from peer http0: Identification failed!
Alex Cartwright
alexc223 at googlemail.com
Sat Feb 5 12:38:58 CET 2011
> Both then do a forward lookup of that hostname, and if that does not
> resolve to the respective remote ip address, that is rejected.
>
> We do that to avoid accidentally syncing with the wrong peer
> and causing, ahum, major inconvenience.
>
> Depending on your setup, forward lookup usually involves looking
> at /etc/hosts, so that's why this influences csync2 "authentication".
I'm still a little confused as to just what exactly it is checking. I'm trying
it on a smaller scale here using just 1 peer and lots of debug to see what is
going on, but none of it makes sense.
This is the output from "example.net":
$ hostname; hostname -f
example
example.net
$ grep -E "example|nas0" hosts
77.xx.xx.xx example.net example
192.168.0.3 nas0.cluster nas0
$ dig +noall +answer example nas0
example. 0 IN A 77.xx.xx.xx
nas0. 0 IN A 192.168.0.3
$ less csync2.cfg
# please see the REAMDE file how to configure csync2
nossl * *;
group standard {
# Standard group that syncs up common configuration
# that generally all our servers will be using.
key /etc/csync2.key;
auto none;
host rrltd;
host nas0;
include /etc/csync2.cfg;
include /etc/vim/vimrc;
}
And from "nas0.cluster"
$ hostname; hostname -f
nas0
nas0.cluster
$ grep -E "example|nas0" hosts
192.168.0.3 nas0.cluster nas0
77.xx.xx.xx example.net example
$ dig +noall +answer example nas0
example. 0 IN A 77.xx.xx.xx
nas0. 0 IN A 192.168.0.3
$ less csync2.cfg
# please see the REAMDE file how to configure csync2
nossl * *;
group standard {
# Standard group that syncs up common configuration
# that generally all our servers will be using.
key /etc/csync2.key;
auto none;
host rrltd;
host nas0;
include /etc/csync2.cfg;
include /etc/vim/vimrc;
}
So why on Earth does the following fail?
$ sudo csync2 -x -P nas0 -vvv /etc/vim/vimrc
My hostname is example.
Database-File: /var/lib/csync2/example.db
Config-File: /etc/csync2.cfg
Match (+): /etc/vim/vimrc on /etc/vim/vimrc
Running check for /etc/vim/vimrc ...
SQL: SELECT filename from file where filename = '/etc/vim/vimrc' ORDER BY
filename
SQL Query finished.
Match (+): /etc/vim/vimrc on /etc/vim/vimrc
Checking /etc/vim/vimrc.
SQL: SELECT checktxt FROM file WHERE filename = '/etc/vim/vimrc'
SQL Query finished.
SQL: SELECT peername FROM dirty GROUP BY peername ORDER BY random()
SQL Query finished.
SQL: SELECT filename, myname, force FROM dirty WHERE peername = 'nas0' ORDER
by filename ASC
SQL Query finished.
Connecting to host nas0 (PLAIN) ...
Local> CONFIG \n
Peer> OK (cmd_finished).\n
Local> HELLO example\n
Peer> Identification failed!\n
While syncing file /etc/vim/vimrc:
ERROR from peer nas0: Identification failed!
Local> BYE\n
Peer> OK (cu_later).\n
SQL: SELECT command, logfile FROM action GROUP BY command, logfile
SQL Query finished.
Finished with 1 errors.
It makes 100% no sense to me, everything matches up ... or at least I think it
does. Any help?
Regards
More information about the Csync2
mailing list