Home Help Center

ICE 3.4.2 on Android over 3G/4G

monemihirmonemihir Member Mihir MoneOrganization: OMC InternationalProject: Communication Module
Hi guys,

I have been developing a middle ware for one of our applications using ICE. The middle ware is basically a proxy which sits as a background service/task on the Android device and other mobile apps connect to our home base server via this middle ware.

Everything works like a charm when I test it over the local network via Wifi. However, the moment I try to connect to our server over 3G, the whole thing breaks down and starts giving me SocketExceptions either 'Connection Refused' or 'Connection Timeout'.

We have tried opening the 4061 port in our firewall and forwarded it to a local ICE server on the internal network to no avail. We even tried other ports including 80, 8080 and 443 in a bid to get it working. I thought that ICE could run on any TCP port provided that there is no other service bound to that port. However, no matter what we do it does not seem to like it.

We have another ICE server running on a different office IP which does the exact same thing and it works like a charm.

Outside world (PC) => IP1:4061 => Internal ICE server....All GOOD.
Outside world (Android) => IP2:4061/IP2:80/IP2:8080/IP2:443 => Internal ICE Server....No JOY

The fact that it works for IP1 means that the ISP has not blocked port 4061.

Can you guys please help investigating this issue.

PS: We have added the INTERNET permission on our Android middle ware.

Cheers,
Mihir

Comments

  • xdmxdm La Coruña, SpainAdministrators, ZeroC Staff Jose Gutierrez de la ConchaOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Hi,

    Can you run the Android application with Ice.Network.Trace=3 enabled and post the output, and the exception

    Does the application works if you just switch from 3G to Wifi, without configuration changes?

    What Android Version / Device / 3G provider are you using to test this?
    The fact that it works for IP1 means that the ISP has not blocked port 4061.

    But it doesn't mean that your 3g provider isn't blocking the outgoing TCP connection.
  • xdmxdm La Coruña, SpainAdministrators, ZeroC Staff Jose Gutierrez de la ConchaOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Hi,

    You can also try to connect to the online Chat Demo to discard any issues with you application setup.

    There is an Android client included in Ice 3.4.2 demos, you can find it in demoj/android/chat (demo packages) or java/demo/android/chat (source distribution).

    In the login dialog use "demo.zeroc.com" as the Chat Server, you must disable SSL in the login dialog (that is because we have updated the SSL certificates used by the server). You can use any username and password combination, then click Login.
Sign In or Register to comment.