Connect Spark to Openfire

I have Openfire installed and have access to the admin console, using which I created a user john with password john to see spark working with OF. I tried to connect using Spark using these credentials (spark and OF both on this same computer), but none of ‘localhost’, ‘john-pc’ (the server name), or 192.168.99.106 (ip behind firewall) work as the server field.

When I try to log in using this or using ‘admin’ and the admin password I get the same error message as when I use the normal credentials (invalid username and password), despite the admin one working to access the admin controls. When I try to connect to a random server url it says it cannot connect, which implies a problem with my OF installation or settings. However, I am at a loss. The OF log when I start the server reads as follows (my firewall is turned off):

Error creating server listener on port 5269: Unrecognized Windows Sockets error: 0: JVM_Bind

Openfire 3.7.0 Beta [Dec 14, 2010 3:14:40 PM]

Admin console listening at:

http://127.0.0.1:9090

https://127.0.0.1:9091

Error starting server listener on port 5269: null

Error starting XMPP listener on port 5222: Address already in use: bind

Error starting SSL XMPP listener on port 5223: Address already in use: bind

Error creating server listener on port 5269: Unrecognized Windows Sockets error: 0: JVM_Bind

Openfire 3.7.0 Beta [Dec 14, 2010 3:14:40 PM]

Admin console listening at:

http://127.0.0.1:9090

https://127.0.0.1:9091

Error starting server listener on port 5269: null

Error starting XMPP listener on port 5222: Address already in use: bind

Error starting SSL XMPP listener on port 5223: Address already in use: bind

Something isa already using your ports 5222 and 5223 which are the port used to connect with spark.

Go in the command prompt and do a netstat and check the ports used and try to figure out what is using it.

Running it after rebooting (so nothing else is running) I get the same error. Netstat returns (showing only entries with the relevant ports):

Proto Local Address Foreign Address State

TCP 0.0.0.0:5222 0.0.0.0:0 LISTENING

TCP 0.0.0.0:5223 0.0.0.0:0 LISTENING

TCP 0.0.0.0:5269 0.0.0.0:0 LISTENING

TCP 0.0.0.0:5222 0.0.0.0:0 LISTENING

TCP 0.0.0.0:5223 0.0.0.0:0 LISTENING

TCP 0.0.0.0:5269 0.0.0.0:0 LISTENING

TCP 127.0.0.1:9090 127.0.0.1:1260 ESTABLISHED

9090 is the admin console, which I can access. But 5222, 5223, and 5269 all show the 0.0.0.0 IP, which is unexpected. Nothing else is running on the computer.

I’m more familiar with unix… But I’ll try.

Is openfire running as a service or do you start it manually?

The server seems up as shown above, do you have windows firewall enabled?

What happens if you telnet your port: telnet localhost 5222

best would be to do the telnet from another machine with your openfire server IP instead of localhost.

I am running it manually, as an administrator (if not as admin., it errored out since it could not r/w some files), and my firewall is disabled.

When I telnet 5222 I get no output.I have opened, closed, and restarted Openfire while watching 5222. When I type in the field it loses the connection, citing ‘invalid xml recieved’. I also telnet’ed into 5223, 5269, and 9090; they all had the same black screen, but did not close when I typed something.

After getting frustrated at the circular solutions I was trying, I created an XP VM and installed Openfire, where it ran perfectly the first time. I’m still not sure why it was failing for me in my normal environment, but thank you for trying to help.