Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[mosquitto-dev] Not receiving large Binary data on websocket (Browser)

I can't receive large binary files in the Browser through websocket.

labtop[192.168.1.158] ==> here I have the browser subscribed to a topic "/VIDEO"

Mosquito Broker[192.168.1.102] 

PC [192.168.1.153] ==> I use this to publish the file

My test was:

1) PUBLISH FILE from PC:  mosquitto_pub -h 192.168.1.102 -p 1883 -t "/VIDEO"    -u test -P '123'  -f video_test.mp4

2) SUBSCRIBE the Browser in my labtop:  _javascript_ subscribe to "/VIDEO"  keep listening for incoming data..

3) TCPDUMP watch something is arrive:    tcpdump  -i wlan0 host 192.168.1.102

    Dump result:

    21:26:24.187916 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 2775710603, win 698, options [nop,nop,TS val 55736832 ecr 497135], length 0
    21:26:24.201860 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], ack 1, win 132, options [nop,nop,TS val 501642 ecr 55725568], length 0
    21:26:31.082283 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 1:1449, ack 1, win 132, options [nop,nop,TS val 502316 ecr 55725568], length 1448
    21:26:31.082310 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 1449, win 720, options [nop,nop,TS val 55738555 ecr 502316], length 0   
    21:26:31.083975 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [P.], seq 1449:3867, ack 1, win 132, options [nop,nop,TS val 502316 ecr 55725568], length 2418
    21:26:31.083990 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 3867, win 758, options [nop,nop,TS val 55738556 ecr 502316], length 0
    21:26:31.084005 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 3867:11107, ack 1, win 132, options [nop,nop,TS val 502317 ecr 55725568], length 7240
    21:26:31.084019 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 11107, win 871, options [nop,nop,TS val 55738556 ecr 502317], length 0
    21:26:31.084972 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 11107:14003, ack 1, win 132, options [nop,nop,TS val 502317 ecr 55725568], length 2896
    21:26:31.084982 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 14003, win 917, options [nop,nop,TS val 55738556 ecr 502317], length 0
    21:26:31.088993 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 14003:15451, ack 1, win 132, options [nop,nop,TS val 502330 ecr 55738556], length 1448
    21:26:31.089014 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 15451, win 939, options [nop,nop,TS val 55738557 ecr 502330], length 0
    21:26:31.092529 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 15451:22691, ack 1, win 132, options [nop,nop,TS val 502330 ecr 55738556], length 7240
    21:26:31.092561 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 22691, win 1052, options [nop,nop,TS val 55738558 ecr 502330], length 0
    21:26:31.094054 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 22691:29931, ack 1, win 132, options [nop,nop,TS val 502330 ecr 55738556], length 7240
    21:26:31.094075 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 29931, win 1166, options [nop,nop,TS val 55738558 ecr 502330], length 0
    21:26:31.099525 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 29931:37171, ack 1, win 132, options [nop,nop,TS val 502331 ecr 55738557], length 7240
    21:26:31.099539 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 37171, win 1279, options [nop,nop,TS val 55738559 ecr 502331], length 0
    21:26:31.099550 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 37171:38619, ack 1, win 132, options [nop,nop,TS val 502331 ecr 55738558], length 1448
    21:26:31.099553 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 38619, win 1301, options [nop,nop,TS val 55738559 ecr 502331], length 0
    21:26:31.101098 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 38619:44411, ack 1, win 132, options [nop,nop,TS val 502331 ecr 55738558], length 5792
    21:26:31.101122 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 44411, win 1392, options [nop,nop,TS val 55738560 ecr 502331], length 0
    21:26:31.102408 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 44411:54547, ack 1, win 132, options [nop,nop,TS val 502331 ecr 55738558], length 10136
    21:26:31.102423 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 54547, win 1550, options [nop,nop,TS val 55738560 ecr 502331], length 0
    21:26:31.104892 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [.], seq 54547:55995, ack 1, win 132, options [nop,nop,TS val 502332 ecr 55738559], length 1448
    21:26:31.104916 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 55995, win 1573, options [nop,nop,TS val 55738561 ecr 502332], length 0
    21:26:31.109065 IP 192.168.1.102.9001 > 192.168.1.158.57044: Flags [P.], seq 55995:57443, ack 1, win 132, options [nop,nop,TS val 502332 ecr 55738559], length 1448
    21:26:31.109086 IP 192.168.1.158.57044 > 192.168.1.102.9001: Flags [.], ack 57443, win 1595, options [nop,nop,TS val 55738562 ecr 502332], length 0   

mosquitto log:

    1496879851: Sending PUBLISH to mqtt_browser (d0, q0, r0, m0, '/VIDEO', ... (38379280 bytes))
    1496879851: Received DISCONNECT from mosq_pub_7260_manuel-l
    1496879851: Client mosq_pub_7260_manuel-l disconnected.   
    1496879869: New connection from 192.168.1.153 on port 1883.
    1496879869: New client connected from 192.168.1.153 as mosq_pub_7268_manuel-l (c1, k60, u'test').
    1496879869: Sending CONNACK to mosq_pub_7268_manuel-l (0, 0)
    1496879876: Received PUBLISH from mosq_pub_7268_manuel-l (d0, q0, r0, m0, '/VIDEO', ... (38379280 bytes))


As you can see the packets arrived to the labtop but not ALL. 


Any Idea where can be the problem?


Thank you.








Back to the top