Skip to main content

check-ibstat

Overview

Verifies InfiniBand link operational status using ibstat command. Checks physical link state (LinkUp) or operational state (Active) with filtering options for InfiniBand links versus all adapter ports.

Requirements

  • InfiniBand Drivers: Mellanox/NVIDIA OFED or inbox drivers
  • ibstat: Part of infiniband-diags package

Package Installation

# RHEL/CentOS
yum install infiniband-diags iproute

# Ubuntu/Debian
apt-get install infiniband-diags iproute2

Command-Line Options

OptionTypeDefaultDescription
--physical-stateFlagTrueCheck 'Physical state: LinkUp'
--stateFlag-Check 'State: Active' (alternative to physical-state)
--iblinks-onlyFlagTrueFilter only InfiniBand links
--all-linksFlag-Check all adapter links (alternative to iblinks-only)
--timeoutInteger300Command execution timeout in seconds
--sinkStringdo_nothingTelemetry sink destination
--sink-optsMultiple-Sink-specific configuration
--verbose-outFlagFalseDisplay detailed output
--log-levelChoiceINFODEBUG, INFO, WARNING, ERROR, CRITICAL
--log-folderString/var/log/fb-monitoringLog directory
--heterogeneous-cluster-v1FlagFalseEnable heterogeneous cluster support

Exit Conditions

Exit CodeCondition
OK (0)Feature flag disabled (killswitch active)
OK (0)All links report expected state
WARN (1)Command execution failed
WARN (1)Exception during execution
CRITICAL (2)Physical state not LinkUp
CRITICAL (2)State not Active

Usage Examples

check-ibstat - Basic Physical State Check

health_checks check-ib check-ibstat \
--sink otel \
--sink-opts "log_resource_attributes={'attr_1': 'value1'}" \
[CLUSTER] \
app

check-ibstat - Operational State Check

health_checks check-ib check-ibstat \
--state \
--iblinks-only \
--sink stdout \
[CLUSTER] \
app

check-ibstat - All Ports Physical State

health_checks check-ib check-ibstat \
--physical-state \
--all-links \
--timeout 30 \
--sink file --sink-opts filepath=/var/log/ibstat_check.json \
[CLUSTER] \
app

check-ibstat - Debug Mode

health_checks check-ib check-ibstat \
--physical-state \
--iblinks-only \
--log-level DEBUG \
--verbose-out \
--sink stdout \
[CLUSTER] \
app