Hello everyone and thanks for reading this problem.
I have a solution in C# using the zkemkeeper dll to get the records from some access control devices. When I "ping" them, there isn't any problem, but when I try to connect to them (Using my solution or the standalone demo to get attendance) I get the "-307" error with the "Unable to connect message". That's not very clear and I would really aprecciate if someone can explain what this error is (please!!!!). I would really like to understand these errors myself, so, where can I find all the definition of these errors?
In short:
1.- What is the problem regarding the "-307" error?
2.- Is there any place where all these errors are documented?
Thanks in advance!!
enter image description here
maybe you should check your device, you can ping them
Attention
The dwErrorCode parameter specifies the error code. The values are described as follows:
During connection, the following error codes may be returned:
0 Connected successfully
-1 Failed to invoke the interface
-2 Failed to initialize
-3 Failed to initialize parameters
-5 Data mode read error
-6 Wrong password
-7 Reply error
-8 Receive timeout
-307 Connection timeout
In invoking other interfaces, the following error codes may be returned:
-201 Device is busy
-199 New Mode
-103 device send back error of face version error
-102 face template version error, like 8.0 face template send to 7.0 device
-101 malloc memory failed
-100 Not supported or the data does not exist
-10 The length of transmitted data is incorrect
-5 Data already exists
-4 Insufficient space
-3 Wrong size
-2 File read/write error
-1 The SDK is not initialized and needs to be reconnected
0 Data not found or duplicate data
1 Correct operation
4 Parameter error
101 Buffer allocation error
102 repeat invoking
Underlying error codes:
-12001 Socket creation timeout (connection timeout)
-12002 Insufficient memory
-12003 Wrong Socket version
-12004 Not TCP protocol
-12005 Waiting timeout
-12006 Data transmission timeout
-12007 Data reading timeout
-12008 Failed to read Socket
-13009 Waiting event error
-13010 Exceeded retry attempts
-13011 Wrong reply ID
-13012 Checksum error
-13013 Waiting event timeout
-13014 DIRTY_DATA
-13015 Buffer size too small
-13016 Wrong data length
-13017 Invalid data read1
-13018 Invalid data read2
-13019 Invalid data read3
-13020 Data loss
-13021 Memory initialization error
-15001 Invoking return value of status key issued by SetShortkey interface repeatedly
-15002 Invoking return value of description issued by SetShortkey interface repeatedly
-15003 The two level menu is not opened in the device, and the data need not be issued
getdevicedata and setdevicedata invocation error codes
-15100 Error occurs in obtaining table structure
-15101 The condition field does not exist in the table structure
-15102 Inconsistency in the total number of fields
-15103 Inconsistency in sorting fields
-15104 Memory allocation error
-15105 Data parsing error
-15106 Data overflow as the transmitted data exceeds 4M
-15108 Invalid options
-15113 Data parsing error: table ID not found
-15114 A data exception is returned as the number of fields is smaller than or equal to 0
-15115 A data exception is returned as the total number of table fields is inconsistent with the
total number of fields of the data
Firmware error codes:
2000 Return OK to execute
-2001 Return Fail to execute command
-2002 Return Data
-2003 Regstered event occorred
-2004 Return REPEAT Command
-2005 Return UNAUTH Command
0xffff Return Unknown Command
-4999 Device parameter read error
-4998 Device parameter write error
-4997 The length of the data sent by the software to the device is incorrect
228
229
-4996 A parameter error exists in the data sent by the software to the device
-4995 Failed to add data to the database
-4994 Failed to update the database
-4993 Failed to read data from the database
-4992 Failed to delete data in the database
-4991 Data not found in the database
-4990 The data amount in the database reaches the limit
-4989 Failed to allocate memory to a session
-4988 Insufficient space in the memory allocated to a session
-4987 The memory allocated to a session overflows
-4986 File does not exist
-4985 File read failure
-4984 File write failure
-4983 Failed to calculate the hash value
-4982 Failed to allocate memory
Note
This interface is applicable to the new architecture firmware.
Below is the connection parameters in the python program to connect to ActiveMQ
broker_url = config_params.items('BROKERS')
conn = stomp.Connection12(broker_url,
reconnect_sleep_initial=20.0,
reconnect_sleep_increase=2.0,
reconnect_attempts_max=10,
heartbeats=(60000,60000)
)
So the ReadCheckInterval and WriteCheckInterval are set to 1 minute for the connection. It looks like the heartbeats are being missed. I am just trying to figure out if the heart beats are missing from the client or the ActiveMQ server end. Can someone help me?
Below are the logs from the Python program:
2020-02-25 12:27:16,141 - INFO - Attempting connection to host
2020-02-25 12:27:16,142 - INFO - Established connection to host
2020-02-25 12:27:16,142 - INFO - Starting receiver loop
2020-02-25 12:27:16,143 - DEBUG - Sending frame: ['STOMP', '\n', 'accept-version:1.2\n', 'client-id, 'heart-beat:60000,60000\n',]
2020-02-25 12:27:16,143 - DEBUG - Received frame: 'CONNECTED', headers={'server': 'ActiveMQ/5.15.2', 'heart-beat': '60000,60000']body=''
2020-02-25 12:27:16,143 - DEBUG - Sending frame: ['SUBSCRIBE', '\n', 'ack:auto\n', 'activemq.subscriptionName:subscriber\n']
2020-02-25 12:30:16,144 - DEBUG - Received frame: 'heartbeat', headers={}, body=None
2020-02-25 12:30:16,145 - ERROR - disconnected from broker, will attempt to reconnect...
2020-02-25 12:30:16,145 - INFO - Receiver loop ended
2020-02-25 12:30:16,320 - INFO - Attempting connection to host
2020-02-25 12:30:16,321 - INFO - Established connection to host
2020-02-25 12:30:16,321 - INFO - Starting receiver loop
2020-02-25 12:30:16,321 - DEBUG - Sending frame: ['STOMP', '\n', 'accept-version:1.2\n', 'client-id:\n', 'heart-beat:60000,60000\n']
2020-02-25 12:30:16,322 - DEBUG - Received frame: 'CONNECTED', headers={'server': 'ActiveMQ/5.15.2', 'heart-beat': '60000,60000']body=''
2020-02-25 12:30:16,322 - DEBUG - Sending frame: ['SUBSCRIBE', '\n', 'ack:auto\n', 'activemq.subscriptionName:subscriber]
I see client and the server both missing sending heart beats to each other. Below is a log where the client has missed sending the heartbeat. The connection gets established at 12:03:32. The client sends the first heart beat at 12:03:32 and then subscribes to the ActiveMQ destination. It keeps getting messages, so there is activity, until 12:12:08. Then a period of inactivity until 12:13:32 (>60 seconds) and the connection gets terminated. Is this a problem of the ActiveMQ server being too less tolerant to missed heart beats from the client. Would increasing the heartbeat interval from the client to 120 seconds help in this case?
2020-02-26 12:03:32,498 - INFO - Established connection to host, port 61613
2020-02-26 12:03:32,499 - INFO - Sending frame: 'STOMP', headers={'heart-beat': '60000,60000'}
2020-02-26 12:03:32,512 - INFO - Received frame: 'CONNECTED', headers={'heart-beat': '60000,60000'}
2020-02-26 12:03:32,513 - INFO - Sending frame: 'SUBSCRIBE'
2020-02-26 12:04:27,924 - INFO - Received frame: 'MESSAGE'
.
.
2020-02-26 12:12:08,475 - INFO - Received frame: 'MESSAGE'
2020-02-26 12:13:32,519 - INFO - Received frame: 'heartbeat'
2020-02-26 12:13:32,548 - ERROR - disconnected from broker
I also see problems os the server missing to send the heartbeat and the client getting a heartbeat timeout error. I am thinking of disabling heartbeats from the server by setting the heartbeat configuration to (120000,0). Any suggestions?
After some testing it turned out that even a few milliseconds delay in the client heartbeat was causing the connection to be closed by the broker.
For the same reason, from ActiveMQ server version 5.9.0,
transport.hbGracePeriodMultiplier (default=1) was added. This would increase the heartbeat timeout by a factor of the set value. Below is the JIRA link which was used to implement this feature.
https://issues.apache.org/jira/browse/AMQ-4674
I've also removed the broker heartbeat, by setting the heartbeat as (60000,0) as it was redundant.
The first value in the Connect hear-beat header is the 'will send' value for client heart beats to the broker. The client should be attempting to maintain a consistent heart beat at the level indicated which is defined as
smallest number of milliseconds between heart-beats that it can
guarantee
The broker will allow for some grace period based on that value after which if the client has not sent a heart beat or any other frame the connection will be closed. From the trace given the client is not sending any heart beats or other wire level activity so the broker is dropping the connection.
I have a pretty stock installation with authentication. The installation is only used for 1 to many broadcasting. 1 person shares their screen, everyone starts muted & hidden, follows that 1 person.
I have adaptive last n = true, channel last n = 1.
The screenshares begin to fail after a few minutes. The screen goes gray for participants. The broadcasting user has about an upload of 500kbps in the screenshare but everyone has a download of 11kbps or N/A.
I see this in the jvb logs intermittently
JVB 2017-01-24 14:17:56.506 INFO: [278] org.ice4j.ice.ConnectivityCheckClient.log() timeout for pair: 158.69.116.11:10000/udp/host -> 108.208.24.154:58802/udp/prflx (stream.RTP), failing.
JVB 2017-01-24 12:33:51.337 INFO: [77] org.ice4j.ice.harvest.AbstractTcpListener.readFromChannel() Failed to handle TCP socket Socket[addr=/108.208.24.154,port=60215,localport=4443]: End of stream! JVB 2017-01-24 12:33:51.367 INFO: [507] org.ice4j.ice.ConnectivityCheckServer.log() Failed to send BINDING-RESPONSE(0x101)[attrib.count=5 len=96 tranID=0x776264674249706335757139] through [2607:5300:60:850b:0:0:0:0]:10000/udp java.io.IOException: Network is unreachable (sendto failed) at java.net.PlainDatagramSocketImpl.send(Native Method) at java.net.DatagramSocket.send(DatagramSocket.java:693) at org.ice4j.ice.harvest.AbstractUdpListener$MySocket.send(AbstractUdpListener.java:613) at org.ice4j.socket.DelegatingDatagramSocket.send(DelegatingDatagramSocket.java:767) at org.ice4j.socket.DelegatingDatagramSocket.send(DelegatingDatagramSocket.java:767) at org.ice4j.socket.IceUdpSocketWrapper.send(IceUdpSocketWrapper.java:53) at org.ice4j.stack.Connector.sendMessage(Connector.java:327) at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:629) at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:575) at org.ice4j.stack.StunServerTransaction.retransmitResponse(StunServerTransaction.java:201) at org.ice4j.stack.StunServerTransaction.sendResponse(StunServerTransaction.java:178) at org.ice4j.stack.StunStack.sendResponse(StunStack.java:771) at org.ice4j.ice.ConnectivityCheckServer.processRequest(ConnectivityCheckServer.java:210) at org.ice4j.stack.EventDispatcher$RequestListenerMessageEventHandler.handleMessageEvent(EventDispatcher.java:511) at org.ice4j.stack.EventDispatcher.fireMessageEvent(EventDispatcher.java:268) at org.ice4j.stack.StunStack.handleMessageEvent(StunStack.java:987) at org.ice4j.stack.MessageProcessor.run(MessageProcessor.java:171) at java.lang.Thread.run(Thread.java:745) JVB 2017-01-24 12:33:51.367 INFO: [507] org.ice4j.stack.StunStack.handleMessageEvent() Received an invalid request. java.lang.RuntimeException: Failed to send a response at org.ice4j.ice.ConnectivityCheckServer.processRequest(ConnectivityCheckServer.java:222) at org.ice4j.stack.EventDispatcher$RequestListenerMessageEventHandler.handleMessageEvent(EventDispatcher.java:511) at org.ice4j.stack.EventDispatcher.fireMessageEvent(EventDispatcher.java:268) at org.ice4j.stack.StunStack.handleMessageEvent(StunStack.java:987) at org.ice4j.stack.MessageProcessor.run(MessageProcessor.java:171) at java.lang.Thread.run(Thread.java:745) Caused by: java.io.IOException: Network is unreachable (sendto failed) at java.net.PlainDatagramSocketImpl.send(Native Method) at java.net.DatagramSocket.send(DatagramSocket.java:693) at org.ice4j.ice.harvest.AbstractUdpListener$MySocket.send(AbstractUdpListener.java:613) at org.ice4j.socket.DelegatingDatagramSocket.send(DelegatingDatagramSocket.java:767) at org.ice4j.socket.DelegatingDatagramSocket.send(DelegatingDatagramSocket.java:767) at org.ice4j.socket.IceUdpSocketWrapper.send(IceUdpSocketWrapper.java:53) at org.ice4j.stack.Connector.sendMessage(Connector.java:327) at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:629) at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:575) at org.ice4j.stack.StunServerTransaction.retransmitResponse(StunServerTransaction.java:201) at org.ice4j.stack.StunServerTransaction.sendResponse(StunServerTransaction.java:178) at org.ice4j.stack.StunStack.sendResponse(StunStack.java:771) at org.ice4j.ice.ConnectivityCheckServer.processRequest(ConnectivityCheckServer.java:210)
I set org.jitsi.videobridge.ratecontrol.VideoChannelLastNAdaptor.MAX_STAY_AT_ZERO_MS=5000 in videobridge sip-properties to force the retry after 5 seconds.
The console logs from inspecting chrome in the frozen participants shows: Logger.js:125 [JitsiMeetJS.js] <Object.getGlobalOnErrorHandler>: UnhandledError: null Script: null Line: null Column: null StackTrace: Error: Ping timeout at strophe.ping.js:102 at u.TimedHandler.handler (strophe.js:2752) at u.TimedHandler.run (strophe.js:2095) at u.Connection._onIdle (strophe.js:3706) r # Logger.js:125
What is the optimal config for this type of conference (screenshare 1 send to many receive)?
I'm honestly not sure why the video drops for some people and doesn't reconnect. Can anyone lend a helping hand?
How many viewers do you have? Note that adaptive last N is gone (as an option) it just behaves that way all the time now.
You could try to use meet.jit.si and set that everyone starts muted and hidden by the moderator just to check that it's not an infrastructure problem. Alternatively, this scenario is the perfect one for YouTube broadcasting: you can have the broadcaster(s) join the room and stream it to YouTube, where all viewers can watch it live.
You can also set users to be muted (and also prevent audio and video transmission) when a conference gets started (except the moderator who is presenting) by changing the code inside Jicofo.
This is the method name to permanently disable a user from sending video or audio:
public boolean muteParticipant(ColibriConferenceIQ channelsInfo, boolean mute, MediaType mediaType)
I am getting this when uploading to server in this API I am uploading audio file and text data and if I remove audio it is working fine and I am getting this error in iOS 10. In iOS below 10 it's working fine all data is getting uploaded.
Error: The request timed out. 2016-11-11 10:17:26.263019 Smart Child Info[1407:423623] [] __tcp_connection_write_eof_block_invoke Write close callback received error: [89] Operation canceled
Seems that your request timed out, try (assuming you are using NSMutableURLRequest and you want a timeout of 120 seconds):
request.timeoutInterval = 120;
I got the following error while executing a PDI job.
I do have mysql driver in place (libext/JDBC). Can some one say, what would be the reason of failure?
Despite the error while connecting to DB, my DB is up and I can access it by command prompt.
Error occured while trying to connect to the database
Error connecting to database: (using class org.gjt.mm.mysql.Driver)
Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
ERROR 03-08 11:05:10,595 - stepname- Error initializing step [Update]
ERROR 03-08 11:05:10,595 - stepname - Step [Update.0] failed to initialize!
INFO 03-08 11:05:10,595 - stepname - Finished reading query, closing connection.
ERROR 03-08 11:05:10,596 - stepname - Unable to prepare for execution of the transformation
ERROR 03-08 11:05:10,596 - stepname - org.pentaho.di.core.exception.KettleException:
We failed to initialize at least one step. Execution can not begin!
Thanks
Is this a long running query by any chance? Or; in PDI world it can be because your step kicks off at the start of the transform, waits for something to do, and if nothing comes along by the net write timeout then you'll see this error.
If so your problem is caused by a timeout that MySQL uses and frequently needs increasing from the default which is 10 mins.
See here:
http://wiki.pentaho.com/display/EAI/MySQL