Troubleshooting Agents
Resolve agent connection loss, protect buffered data with MQTT QoS settings, and fix user registration conflicts.
Last updated
Was this helpful?
Resolve agent connection loss, protect buffered data with MQTT QoS settings, and fix user registration conflicts.
When the MQTT connection between an agent and central Connectware is lost, Connectware marks the affected resources as deviated. The agent keeps its machine subscription active during the outage, so data capture from the machine continues while the broker is unreachable.
Whether buffered data reaches Connectware once the connection is restored depends on the MQTT Quality of Service (QoS) level set on each involved Endpoint:
qos: 0 (default) — In-flight messages during the outage are lost.
qos: 1 or qos: 2 — Incoming machine data is buffered locally on the agent and delivered once the broker is reachable again.
QoS is set per endpoint and applies separately to publishing and subscribing. To protect data flow from an agent to central Connectware, set the qos property of each involved endpoint to 1.
QoS level 2 is most likely not useful in the industry context and is not recommended here.
Distributed systems must tolerate network partitions and other unexpected infrastructure failures. When clients reconnect after such a disruption, they may push their buffered messages in a short burst. To handle this reliably, configure MAX_ONLINE_MESSAGES to a value close to your expected per-client MQTT traffic so this burst is not truncated.
If you need help setting up a distributed data collection system that can tolerate longer network fragmentation, contact Cybus support at support@cybus.io.
If the user registration as described above is not accepted by Connectware but lets the agent print a log message 409 Conflict, most likely there is already an existing user with the given agent name in Connectware, but with a different password. The easiest solution is to go to the “User Management” page in the Admin-UI and delete that particular user, see Deleting Users.
The full message at the agent’s log in such cases is the following:
Last updated
Was this helpful?
Was this helpful?
{
'level': 30,
'time': 1590665714502,
'msg': 'Failed to register agent. Response: 409 Conflict. A conflicting registration might be pending, or a user with the same username myAgent is already existing (which you must delete first).',
}
