客户端连接超时

时间:2017-06-27 08:47:11

标签: erlang mqtt messagebroker

我的服务器因超时而崩溃

我在服务器上面临负载,并且由于硬件上的1024 ulimit而崩溃了。在增加ulimit后重新启动服务器后,服务器再次开始崩溃。 在日志中退出noproc也是一个问题。

以下是相同的日志:

07:49:48.998 [error] Supervisor 'esockd_connection_sup - <0.1366.0>' had child connection started with emqttd_client:start_link([{max_clientid_len,1024},{max_packet_size,65536},{client_idle_timeout,60}]) at <0.21065.0> exit with reason {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"5950f8ac38271f9915770bb9/1498478765842">>,undefined},<0.21065.0>},120000]}} in context connection_crashed

07:49:52.105 [error] gen_server <0.21075.0> terminated with reason: {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"5951d2826279a0096bccbfbe/1498534531992">>,undefined},<0.21075.0>},120000]}} in gen_server2:call/3 line 340

07:49:52.105 [error] CRASH REPORT Process <0.21075.0> with 0 neighbours exited with reason: {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"5951d2826279a0096bccbfbe/1498534531992">>,undefined},<0.21075.0>},120000]}} in gen_server:terminate/7 line 826


07:49:55.727 [error] Supervisor 'esockd_connection_sup - <0.1366.0>' had child connection started with emqttd_client:start_link([{max_clientid_len,1024},{max_packet_size,65536},{client_idle_timeout,60}]) at <0.21089.0> exit with reason {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"59515348e504c95206eab08a/1498501962038">>,undefined},<0.21089.0>},120000]}} in context connection_crashed



07:49:56.186 [warning] Session(59511a5c38271f991578914e/1498487408182): 
 Client <0.16035.0> EXIT for noproc Expires = 31536000 


07:49:56.186 [warning] Session(59511a2638271f9915789107/1498487338761): 
 resumed by <0.16042.0> 


07:49:56.186 [warning] Session(59511a2638271f9915789107/1498487338761): 
 Checking ===> New = <0.16042.0> and Old =  undefined 

07:49:56.186 [warning] Session(59511a2638271f9915789107/1498487338761): 
 Client <0.16042.0> EXIT for noproc Expires = 31536000 


07:49:57.759 [warning] Client(undefined@10.0.51.48:57232): 
 Process Connect Packet {mqtt_packet,{mqtt_packet_header,1,false,0,false},{mqtt_packet_connect,<<"595109d638271f991577cd65/1498483170166">>,3,<<"MQIsdp">>,true,1,true,false,20,<<"presence/595109d638271f991577cd65">>,<<"{\"category\":0,\"data\":{\"presence\":\"last seen at 1:17p.m.\"},\"lat\":0.0,\"lon\":0.0,\"senderId\":\"595109d638271f991577cd65\",\"v\":0}">>,undefined,undefined},undefined} 


07:49:59.371 [error] gen_server <0.21096.0> terminated with reason: {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"5950fbc338271f9915772177/1498479558019">>,undefined},<0.21096.0>},120000]}} in gen_server2:call/3 line 340


07:49:59.371 [error] CRASH REPORT Process <0.21096.0> with 0 neighbours exited with reason: {timeout,{gen_server2,call,[<0.1287.0>,{start_session,false,{<<"5950fbc338271f9915772177/1498479558019">>,undefined},<0.21096.0>},120000]}} in gen_server:terminate/7 line 826

07:49:59.640 [warning] Client(undefined@10.0.44.224:33608): 
 Process Connect Packet {mqtt_packet,{mqtt_packet_header,1,false,0,false},{mqtt_packet_connect,<<"5951ea496279a0096bcd75d0/1498540622037">>,4,<<"MQTT">>,true,1,true,false,20,<<"presence/5951ea496279a0096bcd75d0">>,<<"{\"category\":0,\"data\":{\"presence\":\"last seen at 1:19pm\"},\"lat\":0.0,\"lon\":0.0,\"senderId\":\"5951ea496279a0096bcd75d0\",\"v\":0}">>,undefined,undefined},undefined} 

07:50:02.702 [warning] Client(undefined@10.0.51.48:57268): 
 Process Connect Packet {mqtt_packet,{mqtt_packet_header,1,false,0,false},{mqtt_packet_connect,<<"595148ece504c95206ea0a1f/1498499309936">>,4,<<"MQTT">>,true,1,true,false,20,<<"presence/595148ece504c95206ea0a1f">>,<<"{\"category\":0,\"data\":{\"presence\":\"last seen at 0:56p.m.\"},\"lat\":0.0,\"lon\":0.0,\"senderId\":\"595148ece504c95206ea0a1f\",\"v\":0}">>,undefined,undefined},undefined} 

07:50:03.188 [warning] Session(59510c1d38271f991577e30d/1498483758044): 
 Client <0.16051.0> EXIT for noproc Expires = 31536000 

07:50:03.188 [warning] Session(595125ae38271f9915792642/1498490288948): 
 resumed by <0.16058.0> 

0 个答案:

没有答案