node connectivity problem

bokner boris.okner@REDACTED
Sun Sep 12 06:24:58 CEST 2010


Hello everyone,

Struggling with connecting 2 nodes running on separate boxes. Tried to
make sure that there is no usual problems with cookie synchronization,
DNS or firewall.

First, I run epmd in debug mode as recommended by Erlang docs:

epmd -d -d

Then on box #1:
 erl -name xmpp1@`hostname` -kernel inet_dist_listen_min 6000
inet_dist_listen_max 6050 -setcookie testcookie

and on box #2:
 erl -name xmpp2@`hostname` -kernel inet_dist_listen_min 6000
inet_dist_listen_max 6050 -setcookie testcookie

For example, on box #2:
Erlang (BEAM) emulator version 5.6.4 [source] [64-bit] [smp:4] [async-
threads:0] [kernel-poll:false]
Eshell V5.6.4  (abort with ^G)
(xmpp2@REDACTED)1> net_adm:ping('xmpp1@REDACTED').
pang


epmd on server1.net shows following:

epmd: Sun Sep 12 01:40:32 2010: opening connection on file descriptor
6
epmd: Sun Sep 12 01:40:32 2010: got 8 bytes
***** 00000000  00 06 7a 78 6d 70 70 31
|..zxmpp1|
epmd: Sun Sep 12 01:40:32 2010: ** got PORT2_REQ
epmd: Sun Sep 12 01:40:32 2010: got 18 bytes
***** 00000000  77 00 17 70 4d 00 00 05  00 05 00 05 78 6d 70 70  |
w..pM.......xmpp|
***** 00000010  31 00                                             |1.|
epmd: Sun Sep 12 01:40:32 2010: ** sent PORT2_RESP (ok) for "xmpp1"
epmd: Sun Sep 12 01:40:32 2010: closing connection on file descriptor
6

i.e., appears to receive ping request from second node and respond
with ok.

Tshark listening on epmd port (TCP 4369) gives following (I replaced
real IPs with server names):

  1   0.000000 server2.net -> server1.net TCP 43809 > epmd [SYN] Seq=0
Win=5840 Len=0 MSS=1460 SACK_PERM=1 TSV=776213773 TSER=0 WS=5
  2   0.000433 server1.net -> server2.net TCP epmd > 43809 [SYN, ACK]
Seq=0 Ack=1 Win=5792 Len=0 MSS=1460 SACK_PERM=1 TSV=1595930818
TSER=776213773 WS=6
  3   0.000483 server2.net -> server1.net TCP 43809 > epmd [ACK] Seq=1
Ack=1 Win=5856 Len=0 TSV=776213773 TSER=1595930818
  4   0.000545 server2.net -> server1.net EPMD 43809 > epmd [PSH, ACK]
Seq=1 Ack=1 Win=5856 Len=8 TSV=776213773 TSER=1595930818
  5   0.001445 server1.net -> server2.net TCP epmd > 43809 [ACK] Seq=1
Ack=9 Win=5824 Len=0 TSV=1595930818 TSER=776213773
  6   0.001466 server1.net -> server2.net EPMD epmd > 43809 [PSH, ACK]
Seq=1 Ack=9 Win=5824 Len=18 TSV=1595930818 TSER=776213773
  7   0.001474 server2.net -> server1.net TCP 43809 > epmd [ACK] Seq=9
Ack=19 Win=5856 Len=0 TSV=776213773 TSER=1595930818
  8   0.001481 server1.net -> server2.net TCP epmd > 43809 [FIN, ACK]
Seq=19 Ack=9 Win=5824 Len=0 TSV=1595930818 TSER=776213773
  9   0.001623 server2.net -> server1.net TCP 43809 > epmd [FIN, ACK]
Seq=9 Ack=20 Win=5856 Len=0 TSV=776213773 TSER=1595930818
 10   0.001990 server1.net -> server2.net TCP epmd > 43809 [ACK]
Seq=20 Ack=10 Win=5824 Len=0 TSV=1595930818 TSER=776213773


So it looks to me that there is no firewall issues, as epmd instances
talk to each other. What am I missing?

Your advise is very much appreciated!

Best regards,
Boris


More information about the erlang-questions mailing list