Cant connect Server to Server : DNS Problem

Hello,

I want to connect s2s, but it doesn’‘t work. I’‘m not really sure what I did wrong. But one Server doesn’‘t resolve the real name from the other machine. It’'s a little bit weird, I look at the logs and the server wants to connect with the domain “de” and not “xyz.de”.

Here are the logs for the first Server:

org.jivesoftware.wildfire.session.OutgoingServerSession.createOutgoingSession(Ou tgoingServerSession.java:258) Error trying to connect to remote server: abc.xyz.de(DNS lookup: abc.xyz.de:5269)

java.net.NoRouteToHostException: No route to host

at java.net.PlainSocketImpl.socketConnect(Native Method)

at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)

at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)

at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)

at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)

at java.net.Socket.connect(Socket.java:519)

at org.jivesoftware.wildfire.session.OutgoingServerSession.createOutgoingSession(O utgoingServerSession.java:253)

at org.jivesoftware.wildfire.session.OutgoingServerSession.authenticateDomain(Outg oingServerSession.java:142)

at org.jivesoftware.wildfire.server.OutgoingSessionPromise$PacketsProcessor.sendPa cket(OutgoingSessionPromise.java:199)

at org.jivesoftware.wildfire.server.OutgoingSessionPromise$PacketsProcessor.run(Ou tgoingSessionPromise.java:184)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java: 650)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)

at java.lang.Thread.run(Thread.java:595)

Here are the logs for the second Server:

at java.lang.Thread.run(Unknown Source)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)

at org.jivesoftware.openfire.server.OutgoingSessionPromise$PacketsProcessor.run(Ou tgoingSessionPromise.java:184)

at org.jivesoftware.openfire.server.OutgoingSessionPromise$PacketsProcessor.sendPa cket(OutgoingSessionPromise.java:199)

at org.jivesoftware.openfire.session.OutgoingServerSession.authenticateDomain(Outg oingServerSession.java:184)

at org.jivesoftware.openfire.session.OutgoingServerSession.createOutgoingSession(O utgoingServerSession.java:253)

at java.net.Socket.connect(Unknown Source)

at java.net.SocksSocketImpl.connect(Unknown Source)

at java.net.PlainSocketImpl.connect(Unknown Source)

java.net.UnknownHostException: de

] Error trying to connect to remote server: de(DNS lookup: de:5269)

System Suse Linux 10.1

Wildfire 3.2.4

Domain: xyz.de

Bind-DNS - I did fake DNS for both servers : 192.168.xxx.9 <-> xyz.de; 192.168.xxx.3 <-> abc.xyz.de

System Windows Server 2003

Openfire 3.3.2

Domain: abc.xyz.de

1.DNS are 192.168.xxx.9

DNS-Resolves are okay on both sides

nslookup works fine with xyz.de and abc.yxz.de!!

But i don’'t know why the Server with Openfire wants to connect only with “de”.

Any Solutions?

Regards

T. Lai

Message was edited by: euroweb

The first log claims that it cannot route the packet to the host. Can you tracert between the boxes? Could this be related to a network routing issue on your network?

Thanks for your answer DeeJay,

this is strange, ja i saw that routing problem in that log. I can trace and ping on both sides

/var/lib/named/etc # traceroute abc.xyz.de

traceroute to abc.xyz.de (192.168.xxx.3), 30 hops max, 40 byte packets

1 192.168.xxx.254 (192.168.xxx.254) 0.405 ms 0.264 ms 0.409 ms

2 abc.xyz.de (192.168.xxx.3) 30.269 ms 30.530 ms 29.252 ms

C:\Documents and Settings\administrator>tracert xyz.de

Tracing route to xyz.de

over a maximum of 30 hops:

1 <1 ms <1 ms <1 ms 192.168.xxx.254

2 29 ms 29 ms 29 ms xyz

Trace complete.

I think i have two problems right?

  1. Server xyz.de cant route to abc.xyz.de, but on the commandline it shows me results

  2. Server abc.xyz.de resolve the wrong domain “de” and not xyz.de

Both servers uses the DNS - Service on the Linux machine with the fake entries (see above)

Any solutions for that?

The manual says:

public class NoRouteToHostException

extends SocketException

Signals that an error occurred while attempting to connect a socket to a remote address and port. Typically, the remote host cannot be reached because of an intervening firewall, or if an intermediate router is down.

Have you proved you can connect? i.e. telnetted from both ends to the correct port on the other end.

You should at least get the TCP session established.

D

Okay I proved both sides. I knew the ports was open, but i checked again. Both sides can connect trough port 5269.

telnet> open abc.xyz.de 5269

Trying 192.168.xxx.3…

Connected to abc.xyz.de.

Escape character is ‘’^]’’.

?

</stream:stream>Connection closed by foreign host.

Details for our network:

2 Offices with 2 Class C Net, connected with a VPN no firerules set between the network.

We have no routing and DNS problems between our 2 offices

OK, and both sides are configured to access server to server connections from the other?

The only thing I can think of is DNS errors. Can you post the results of the following:

nslookup

set type=SRV

xmpp-server._tcp.domain1.com

xmpp-server._tcp.domain2.com

D