[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Freeipmi-users] How to detect broken LAN session

From: Klemen Vodopivec
Subject: [Freeipmi-users] How to detect broken LAN session
Date: Mon, 8 Apr 2019 17:45:21 -0400


I'm working on an IPMI bridge to EPICS control system where the daemon-like
process is intended to have  IPMI session established always established.
So I'm looking for best practices how to keep the connection open.

If I'm not mistaken, the session won't automatically reconnect, at least it
doesn't for me. So I'm trying to detect dropped connection and reconnect
but I'm having trouble getting meaningful error code that would uniquely
tell me when to reconnect. In my case ipmi_cmd() function returns errno 24
(bad completion code) but it's really just masking the error as there is no
comp_code in the response message in the first place. Debugging through
the  stack I see ipmi_cmd_send_message() properly identifies error as
IPMI_ERR_SESSION_TIMEOUT in ipmi-lan-session-common.c:_ipmi_cmd_send_ipmb()
but then invokes API_BAD_RESPONSE_TO_API_ERRNUM which results in errnum=24.

Writing all these function calls may already be too much details and
hopefully I'm just missing some high-level function I can call.

Thanks, Klemen

reply via email to

[Prev in Thread] Current Thread [Next in Thread]