TCPSocketLayer: Connection error

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 07 Sep 2010, 17:16

When you start the server, you will see the addresses that were really bound . I am no EC2 guru but I didn't have any problems binding the private address and it worked out of the box.

FYI: I can't see any image.
My question is... is there another network service that you can actually reach from outside? For instance, can you login via SSH?
If so, please double check your firewall settings for that service and make sure to apply them for SFS too, using the right port number.
Lapo
--
gotoAndPlay()
...addicted to flash games
kosirm
Posts: 11
Joined: 01 Mar 2006, 22:08

Postby kosirm » 08 Sep 2010, 13:40

Thanks again for reply!
Images are in public folder so anyone can see them (http://picasaweb.google.com/kosir.milan/Smartfox#)

I didn't have any problems binding the private address and it worked out of the box.

On EC2?
So what am I doing wrong?
My question is... is there another network service that you can actually reach from outside?

I'm accessing webserver (jetty and IIS) without problem.
For instance, can you login via SSH?

To Smartfox server? No, I can't even telnet...
To EC2? Sure, I can use EC2 command line tools with no problem to configure instance.
If so, please double check your firewall settings for that service and make sure to apply them for SFS too, using the right port number.

Problem is, that there are NO special firewall settings for any of those services. I've made inbound rule for smartfox to be sure it is in "allowed zone".

I can acces smartfox server, config manager, even game if I log on machine with remote desktop, otherwise no.

I've updated page with images, where is documented all what I've done.
Thanks in advance for any hint,
Milan
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 08 Sep 2010, 15:33

I can reach your SmartFox from here :)

Code: Select all

Lapo$ telnet 79.125.117.165 9933
Trying 79.125.117.165...
Connected to ec2-79-125-117-165.eu-west-1.compute.amazonaws.com.
Escape character is '^]'.

This means that the server is up and running and reachable, yay! :D

Btw, I also tested with the SFS2X-Connector example app which confirmed the healthy status:

--> SmartFox API: 0.8.6
--> Click the CONNECT button to start...
--> Config load success!
--> Server settings: 79.125.117.165:9933
--> Connection Success!
Lapo

--

gotoAndPlay()

...addicted to flash games
stevets
Posts: 60
Joined: 11 Jul 2010, 12:22
Location: USA

Postby stevets » 08 Sep 2010, 21:57

Hi Milan,

On photo 9 ( Lobby Example), how was your config-sys.xml configured.
I think the IP may need to be changed from the default settings in that case?

Steve
kosirm
Posts: 11
Joined: 01 Mar 2006, 22:08

Postby kosirm » 09 Sep 2010, 09:48

Lapo, thanks A LOT!
I can reach your SmartFox from here

Code: Select all

Lapo$ telnet 79.125.117.165 9933
Trying 79.125.117.165...
Connected to ec2-79-125-117-165.eu-west-1.compute.amazonaws.com.
Escape character is '^]'.

This means that the server is up and running and reachable, yay!


That's wonderful news :D , so server is reachable, but I still can't connect :?. I tried with putty, windows telnet client, same result. Our developer in Italy tried from his machine, same result. Maybe is reason that we are all using windows? Any thoughts?

Milan

edit: in fact, there is telnet session created on server (http://picasaweb.google.com/kosir.milan/Smartfox#5514861586470770338), but I don't get any response on client, and after some time, session is closed by itself.
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 09 Sep 2010, 15:09

If I test under Windows 7, I get the same successful result.

Of course, if you have installed a local firewall or configured the native Windows firewall to be restrictive you might have problems.

I don't see any problems with your server. It's definitely reachable and working
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Postby Lapo » 09 Sep 2010, 15:11

edit: in fact, there is telnet session created on server (http://picasaweb.google.com/kosir.milan ... 6470770338), but I don't get any response on client, and after some time, session is closed by itself.

This is perfectly normal. SFS2X won't respond to telnet, but the connection means that you can actually reach the server.
So if you run an SFS2X example it will work.
Lapo

--

gotoAndPlay()

...addicted to flash games
ThomasLund
Posts: 1297
Joined: 14 Mar 2008, 07:52
Location: Sweden

Postby ThomasLund » 09 Sep 2010, 16:05

It looks like you are running one of the Unity examples from your log dump. Are you sure you are setting the IP to connect to in the Unity inspector and not in the script for a public variable?

If there is a public variable exposed to Unity, the inspector value will always override the script value. So you could actually be trying to connect to your localhost and not the server.

Just some input

/T
kosirm
Posts: 11
Joined: 01 Mar 2006, 22:08

Postby kosirm » 10 Sep 2010, 07:22

People, thank you all for your help!!!
Thank you Lapo for all your time you've spend on this!
Thomas, you are the men who has the answer :D
The answer is sometimes elsewhere...
I' won't forget this lesson.
(http://picasaweb.google.com/kosir.milan/Smartfox#5515186678204733106)
Thanks you again,
Best regards,
Milan

ps: good news for all interested in testing games and stuff on ec2, yesterday I've got mail from amazon : New offer is micro On-Demand instances.
Micro instance pricing for On-Demand instances starts at $0.02 per hour for Linux and $0.03 per hour for Windows (before $0.12 per hour for Windows).
ThomasLund
Posts: 1297
Joined: 14 Mar 2008, 07:52
Location: Sweden

Postby ThomasLund » 10 Sep 2010, 08:26

Great - happy it was as simple as that (once you know what it is) :-D

Return to “SFS2X Questions”

Who is online

Users browsing this forum: Stevenor and 119 guests