[Libwebsockets] Unable to establish test-client and test-server connection.

"Andy Green (林安廸)" andy at warmcat.com
Tue Oct 15 09:35:56 CEST 2013


On 15/10/13 15:29, the mail apparently from Hemant Kumar included:
> Hi Andy
>
> I am running server on x86 and when I run browser client accessing 127.0.0.1:7681,it works fine as expected which tells me that server is behaving correctly.
>
> The second instance ,is when I am running client on remote netscaler XLR platform.Thats when ,the failure happens and there is no connection establishment.

I think this probably reflects correct behaviour then.  Since the last 
couple of weeks I added proper blocking and timeout semantics for 
connection attempts.

It sounds like it really can't establish the connection and hits the 
five second timeout and shuts it down, like it is supposed to.

Try coming with telnet 10.x.x.x 7681 if things are workable you should 
get a connection and be able to type things.  If a firewall is blocking 
it even that won't work.

-Andy

> Both client and server side programs have been compiled without OpenSSL support in this case.
>
> -Hemant
>
>> On Oct 14, 2013, at 11:42 PM, "Andy Green" <andy at warmcat.com> wrote:
>>
>> Hemant Kumar <hkumar at arubanetworks.com> wrote:
>>> I am trying out test-client and test-server program. I was able to
>>> start test-server well and following appears when I run the server and
>>> access 127.0.0.1:7681<http://127.0.0.1:7681/>
>>
>> Are you sure about that last part?  You seem yo be trying to connect to a completely different address  ----->
>>
>>
>>> bash-4.1$ ./webserver
>>> lwsts[4279]: libwebsockets test server - (C) Copyright 2010-2013 Andy
>>> Green <andy at warmcat.com<mailto:andy at warmcat.com>> - licensed under
>>> LGPL2.1
>>> lwsts[4279]: Initial logging level 7
>>> lwsts[4279]: Initial logging level 7
>>> lwsts[4279]: Library version: 1.3 5dc62ea
>>> lwsts[4279]:  Started with daemon pid 0
>>> lwsts[4279]:  static allocation: 4472 + (16 x 1024 fds) = 20856 bytes
>>> lwsts[4279]:  canonical_hostname = hkumar-linux
>>> lwsts[4279]:  Compiled without SSL support
>>> lwsts[4279]:  per-conn mem: 160 + 1360 headers + protocol rx buf
>>> lwsts[4279]:  Listening on port 7681
>>>    GET URI = /
>>>    Host = 127.0.0.1:7681<http://127.0.0.1:7681/>
>>>    Connection = keep-alive, Upgrade
>>>    Protocol = dumb-increment-protocol
>>>    Upgrade = websocket
>>>    Origin = http://127.0.0.1:7681<http://127.0.0.1:7681/>
>>>    Key = UMmyHgvmaU3hAIB2QgSKiQ==
>>>    Version = 13
>>>
>>>
>>> The test-client thought exits with following error is unable to
>>> connect.I can ping the server machine from client platform though.
>>>
>>> /# ./testclient 10.5.165.61 --port=7681
>>
>>    <-------
>>
>>> libwebsockets test client
>>> (C) Copyright 2010-2013 Andy Green
>>> <andy at warmcat.com<mailto:andy at warmcat.com>> licensed under LGPL2.1
>>> [1381854505:5044] NOTICE: Initial logging level 7
>>> [1381854505:5045] NOTICE: Initial logging level 7
>>> [1381854505:5046] NOTICE: Library version: 1.3 5dc62ea
>>> [1381854505:5050] NOTICE:  Started with daemon pid 0
>>> [1381854505:5051] NOTICE:  static allocation: 4436 + (12 x 1024 fds) =
>>> 16724 bytes
>>> [1381854505:5052] NOTICE:  canonical_hostname = Aruba-controller
>>> Waiting for connect...
>>> LWS_CALLBACK_CLIENT_CONNECTION_ERROR
>>> Exiting
>>> LWS_CALLBACK_CLIENT_CONNECTION_ERROR
>>> #
>>>
>>> Am I missing something? Please suggest.
>>> Sorry for being a newbie here.
>>>
>>>
>>> Thanks
>>> Hemant
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>> _______________________________________________
>>> Libwebsockets mailing list
>>> Libwebsockets at ml.libwebsockets.org
>>> http://ml.libwebsockets.org/mailman/listinfo/libwebsockets
>>
>>




More information about the Libwebsockets mailing list