Home Help Center

Login Problem

PAUL12PAUL12 Member paul munteanOrganization: PersonalProject: Android testing
Hy,

I trye to run the android database demo from the Ice3.4.2 demos.
I start the app in the Simulator and it conects to the server running on the same computer.

Now I put the Client app on a Motorola XOOM and trye to connect to the server.
I put in the ip which the server is giving me. After he connects to the database (the server I meean) I get is:

Login failed:Ice.ConnectTimeoutException on a popup window.

This message appears after some 5 sec. In this time I think is doing something.

I have to mention that the application has runned on my PC and smartphone some 2 weeks ago with the glacier started and also without.

What should I do?
Reinstall windows?

Comments

  • xdmxdm La Coruña, SpainAdministrators, ZeroC Staff Jose Gutierrez de la ConchaOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    That could be a problem with the server endpoints configuration, by default server is configured to listen on all addresses.

    The timeout could happen when some of the server addresses are not reachable from the device.

    Try to set the SessionFactory endpoints in config.server to an address that is reachable from the device.
    SessionFactory.Endpoints=tcp -h 192.168.50.2 -p 10000:ssl -h 192.168.50.2 -p 10001
    

    See also Object Adapter Endpoints - Ice 3.4 - ZeroC
  • PAUL12PAUL12 Member paul munteanOrganization: PersonalProject: Android testing
    The problem stil persists.

    I connect fine from the emulator.
    I use ase above indicated.
    SessionFactory.Endpoints=tcp -h 192.168.50.2 -p 10000:ssl -h 192.168.50.2 -p 10001
    
    But when connecting from the Android Phone(Motorola XOOM) I get.
    -- 2/21/12 23:06:11:820 demo.Database.library.Server: ConnectionPool: establishing 5 connections to jdbc:oracle:thin:[email protected]//129.187.64.237:1521/orcl
    !! 2/21/12 23:06:14:512 demo.Database.library.Server: error: main: Ice.SocketException
           error = 0
       	at IceInternal.Network.doBind(Network.java:209)
       	at IceInternal.TcpAcceptor.<init>(TcpAcceptor.java:119)
       	at IceInternal.TcpEndpointI.acceptor(TcpEndpointI.java:403)
       	at IceInternal.IncomingConnectionFactory.<init>(IncomingConnectionFactory.java:367)
       	at Ice.ObjectAdapterI.<init>(ObjectAdapterI.java:1000)
       	at IceInternal.ObjectAdapterFactory.createObjectAdapter(ObjectAdapterFactory.java:130)
       	at Ice.CommunicatorI.createObjectAdapter(CommunicatorI.java:77)
       	at library.Server.run(Server.java:103)
       	at Ice.Application.doMain(Application.java:202)
       	at Ice.Application.main(Application.java:182)
       	at Ice.Application.main(Application.java:118)
       	at library.Server.main(Server.java:139)
       Caused by: java.net.BindException: Cannot assign requested address: bind
       	at sun.nio.ch.Net.bind(Native Method)
       	at sun.nio.ch.ServerSocketChannelImpl.bind(Unknown Source)
       	at sun.nio.ch.ServerSocketAdaptor.bind(Unknown Source)
       	at IceInternal.Network.doBind(Network.java:203)
       	... 11 more
    

    Anibody an Ideea?
  • PAUL12PAUL12 Member paul munteanOrganization: PersonalProject: Android testing
    If I use
    SessionFactory.Endpoints=tcp -p 10000:ssl -p 10001
    
    -- 2/21/12 23:09:16:506 demo.Database.library.Server: ConnectionPool: establishing 5 connections to jdbc:oracle:thin:[email protected]//129.187.64.237:1521/orcl
    -- 2/21/12 23:09:19:217 demo.Database.library.Server: Network: accepting tcp connections at 0.0.0.0:10000
       local interfaces: 192.168.1.7, 129.187.211.250, 127.0.0.1
    -- 2/21/12 23:09:19:279 demo.Database.library.Server: Network: accepting ssl connections at 0.0.0.0:10001
       local interfaces: 192.168.1.7, 129.187.211.250, 127.0.0.1
    -- 2/21/12 23:09:19:382 demo.Database.library.Server: Network: published endpoints for object adapter `SessionFactory':
       tcp -h 192.168.1.7 -p 10000:tcp -h 129.187.211.250 -p 10000:ssl -h 192.168.1.7 -p 10001:ssl -h 129.187.211.250 -p 10001
    


    Then I trye to connect from the Motorola XOOM and I get the Ice.ConnectTimeoutException.
    Any Ideea.

    I am getting to frustration with this!
  • xdmxdm La Coruña, SpainAdministrators, ZeroC Staff Jose Gutierrez de la ConchaOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Hi Paul,
    SessionFactory.Endpoints=tcp -h 192.168.50.2 -p 10000:ssl -h 192.168.50.2 -p 10001
    

    You must replace 192.168.50.2 for you actual ip address.
    Caused by: java.net.BindException: Cannot assign requested address: bind

    The error means the address don't belong to your network interfaces, so cannot assign.
Sign In or Register to comment.