IMVEEDev Portal

Troubleshooting

Solutions for common issues with the Satellite Agent — enrollment, connectivity, data collection and updates. Always start with agent-doctor.sh when troubleshooting.

:::info [First stop] Always start with agent-doctor.sh — the script checks all relevant areas automatically and outputs a colour-coded PASS/WARN/FAIL overview. :::

agent-doctor.sh

The repository contains an integrated diagnostics script (scripts/agent-doctor.sh). It automatically checks all relevant aspects and outputs a colour-coded PASS / WARN / FAIL / INFO summary.

# If the repo is available locally:
sudo bash /path/to/repo/scripts/agent-doctor.sh

# On an installed system (macOS):
sudo bash /usr/local/imvee-satellite/scripts/agent-doctor.sh

Checks performed:

AreaWhat is checked
BaseInstallation directory, binary, wrapper script
Environmentagent.env present, IMVEE_INDEX set, legacy variables
Servicesystemd/launchd registered, service state
Queuequeue.jsonl present, size (warning above 5 MB)
ProcessAgent process running
ConnectivityOpenSearch URL resolvable, HTTP status, latency
Cluster HealthOpenSearch /_cluster/health (if credentials present)

Exit codes: 0 = OK · 1 = Warnings · 2 = Errors


Log Paths & Service Names

PlatformService NameLog access
Linux (systemd)imvee-satellitesudo journalctl -u imvee-satellite -f
macOS (launchd)com.imvee.satellitesudo tail -f /var/log/imvee-satellite.log

Linux:

# Live logs
sudo journalctl -u imvee-satellite -f

# Last 100 lines
sudo journalctl -u imvee-satellite -n 100 --no-pager

macOS:

# Stdout log
sudo tail -f /var/log/imvee-satellite.log

# Stderr log
sudo tail -f /var/log/imvee-satellite-error.log

Installation paths:

PathContent
/usr/local/imvee-satellite/Installation directory (binary, config, scripts)
/usr/local/imvee-satellite/satellite.envConfiguration file (0600)
/usr/local/imvee-satellite/queue/Queue directory (Linux install.sh)
/usr/local/var/imvee-satellite/queue.jsonlShell commands queue (macOS)
/usr/local/var/imvee-satellite/agent.idAgent ID (macOS)
/var/log/imvee-satellite.logstdout log (macOS)
/var/log/imvee-satellite-error.logstderr log (macOS)

Common Issues

Agent does not register

Symptom: Agent does not appear in SOCSuite, no agent.id file present.

Possible causes & solutions:

CauseSolution
Enrollment token invalid or expiredCreate a new token in SOCSuite under Orbit → Agents → New Agent
Backend unreachableCheck firewall rules (socsuite.dev.imvee.de:443)
Wrong API_URL valueCheck environment variable API_URL
TLS errorCheck certificate on the backend; in development set IMVEE_OPENSEARCH_INSECURE_SKIP_VERIFY=true
# Connectivity test
curl -v https://socsuite.dev.imvee.de/api/v1/health

Heartbeat failures

Symptom: Agent does not report regularly, status in SOCSuite switches to offline.

Background: The agent uses a staged backoff (10s → 30s → 1m → 2m → 5m → 10m). After 6 consecutive failures it attempts re-registration.

Diagnostics:

# Service status (Linux)
sudo systemctl status imvee-satellite

# Watch logs
sudo journalctl -u imvee-satellite -f

# macOS service status
sudo launchctl print system/com.imvee.satellite

# Connectivity test
curl -v https://socsuite.dev.imvee.de/api/v1/health

Queue fills up

Symptom: /var/lib/imvee-satellite/queue.jsonl grows uncontrolled, events do not reach OpenSearch.

Possible causes & solutions:

CauseSolution
OpenSearch unreachableCheck OPENSEARCH_URL and firewall (siem.dev.imvee.de:443)
TLS error against OpenSearchCheck certificate; optionally IMVEE_OPENSEARCH_INSECURE_SKIP_VERIFY=true (development only)
Circuit breaker openSee Circuit Breaker section
Disk fullCheck free space on /var/lib/imvee-satellite/
# Check queue size
ls -lh /var/lib/imvee-satellite/queue.jsonl
wc -l /var/lib/imvee-satellite/queue.jsonl

WebSocket connection drops

Symptom: Missions are not received, live commands do not arrive.

Diagnostics:

# Is the WebSocket endpoint reachable?
curl -v --include \
  --no-buffer \
  -H "Connection: Upgrade" \
  -H "Upgrade: websocket" \
  https://socsuite.dev.imvee.de/ws/agents/<AGENT_ID>

Note: The websocketLoop() reconnects automatically on connection drops. Short interruptions are therefore non-critical. For persistent issues check backend reachability and the certificate for socsuite.dev.imvee.de.


Agent lockout (401 — invalid API key)

Symptom: The agent journal shows ERROR: AGENT LOCKOUT - … consecutive credential rejections (401/403), the status server reports auth.status: "locked_out", and the event queue grows. Note: heartbeats may keep running — the WebSocket session established before the key rotation survives (stale auth) and makes the agent look healthy.

Background: The backend rejects the agent's API key — the typical cause is a lost key rotation push (multi-replica, see Self-Update). The agent cannot self-heal: a reissue request with the invalid key fails as well (401).

Recovery (manual, DEV-176 runbook):

  1. Rotation re-run (preferred): Trigger the API key rotation in the backend again and make sure the WS push reaches the agent (API Key rotated successfully in the journal).
  2. Re-enrollment: If no valid key is available anymore: remove agent.id and agent.key from /var/lib/imvee-satellite/, set IMVEE_API_KEY in agent.env and restart the service.

Diagnostics:

# Auth state of the running agent
curl -s http://127.0.0.1:8888/status | jq .auth

# Journal: lockout signature
sudo journalctl -u imvee-satellite | rg "AGENT LOCKOUT|rejected agent credentials"

# Diagnostics bundle (includes status.json with the auth block)
sudo /usr/local/imvee-satellite/imvee-satellite/imvee-satellite diagnostics

Circuit Breaker

The Satellite Agent uses a Circuit Breaker (sony/gobreaker, under internal/breaker/) for outbound connections to OpenSearch and the backend.

States

CLOSED  → Normal operation, requests pass through
   │
   │  (too many failures)
   ▼
OPEN    → Requests rejected immediately (no network overhead)
   │
   │  (after timeout)
   ▼
HALF-OPEN → Test request is sent
   ├── Success → back to CLOSED
   └── Failure → back to OPEN

When does the circuit breaker activate?

The circuit breaker opens when a configured number of consecutive failures occur on OpenSearch or backend calls.

Reset

The circuit breaker closes automatically after the configured timeout (Half-Open state). A manual reset is done by restarting the agent service:

sudo systemctl restart imvee-satellite

Quick Reference: Diagnostic Commands

# === Linux ===
# Service status
sudo systemctl status imvee-satellite

# Live logs
sudo journalctl -u imvee-satellite -f

# Check agent ID
cat /usr/local/var/imvee-satellite/agent.id  # macOS
# or:
cat /usr/local/imvee-satellite/agent.id       # Linux (depending on install)

# Queue status
ls -lh /usr/local/var/imvee-satellite/queue.jsonl
wc -l /usr/local/var/imvee-satellite/queue.jsonl

# === macOS ===
# Service status
sudo launchctl print system/com.imvee.satellite

# Logs
sudo tail -f /var/log/imvee-satellite.log

# === Connectivity (cross-platform) ===
curl -v https://socsuite.dev.imvee.de/api/v1/health
curl -v https://siem.dev.imvee.de

# === Automated health check ===
sudo bash /usr/local/imvee-satellite/scripts/agent-doctor.sh

See Also

On this page