tutorial

Monitoring text-generation-webui (oobabooga) with Vigilmon

text-generation-webui is the most popular local LLM interface — but when Gradio freezes, the OpenAI-compatible API goes silent, or a model silently stops generating, you need to know right away. Here's how to monitor oobabooga's web UI, API endpoints, and model loading state with Vigilmon.

text-generation-webui (commonly called oobabooga or Oobabooga WebUI) is the most widely used open-source interface for running local large language models. Built with Python and Gradio, it supports llama.cpp, Transformers, ExLlamaV2, GPTQ, AWQ, and many other backends — and includes an optional OpenAI-compatible API extension that lets you point any API client at your local hardware. But self-hosting a Gradio app with a heavyweight model backend is inherently fragile: Gradio can freeze, the model process can crash, the API extension can fail to start, or a model can load successfully yet stop generating tokens without any error message. Vigilmon gives you uptime monitors for the Gradio web UI and API endpoints, SSL certificate alerts for proxied deployments, and a heartbeat probe that verifies the loaded model is actually generating — not just sitting in a crashed state.

What You'll Set Up

  • HTTP uptime monitor for the Gradio web UI (port 7860)
  • OpenAI-compatible API availability check on port 5000 /v1/models
  • Model management API check on /api/v1/model
  • SSL certificate expiry alerts for HTTPS-proxied deployments
  • Cron heartbeat that probes /api/v1/generate to confirm the model is responding

Prerequisites

  • text-generation-webui running on a server (port 7860 for the UI, port 5000 for the API extension)
  • The --api flag enabled to activate the API extension
  • A free Vigilmon account

Step 1: Monitor the Gradio Web UI

The text-generation-webui Gradio interface listens on port 7860. Add a Vigilmon HTTP monitor to confirm it is reachable:

  1. Log in to vigilmon.online and click Add Monitor.
  2. Set Type to HTTP / HTTPS.
  3. Enter the URL: http://your-server-ip:7860
  4. Set Check interval to 1 minute.
  5. Set Expected HTTP status to 200.
  6. Click Save.

Gradio serves a JavaScript-heavy frontend; a 200 on the root path confirms the Gradio server process is alive. If you proxy through nginx or Caddy on a custom domain, use that URL so SSL is also checked in a later step.


Step 2: Monitor the OpenAI-Compatible API on Port 5000

When text-generation-webui is started with the --api flag, it exposes an OpenAI-compatible REST API on port 5000. The /v1/models endpoint lists available models and requires no authentication, making it a reliable availability probe:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter the URL: http://your-server-ip:5000/v1/models
  3. Set Method to GET.
  4. Set Expected HTTP status to 200.
  5. Under Response body check, enter "data" to confirm the models list is returned.
  6. Set Check interval to 2 minutes.
  7. Click Save.

A failure here means the API extension process is down even if the Gradio UI is still showing (the two processes can fail independently).


Step 3: Monitor the /api/v1/model Endpoint

The /api/v1/model endpoint (distinct from the OpenAI-compatible API) returns the currently loaded model name. Monitoring it confirms that a model is loaded and that the native API is responsive:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter the URL: http://your-server-ip:5000/api/v1/model
  3. Set Method to GET.
  4. Set Expected HTTP status to 200.
  5. Under Response body check, enter "result" to confirm the model field is present.
  6. Set Check interval to 5 minutes.
  7. Click Save.

A {"result": null} response means the API is up but no model is currently loaded — an alert-worthy state if your setup should always have a model loaded.


Step 4: SSL Certificate Alerts for HTTPS Deployments

text-generation-webui does not handle TLS natively; SSL is typically added via an nginx or Caddy reverse proxy. Certificate expiry silently breaks all API clients and browser access.

  1. Open the HTTP monitor created for your proxied domain in Step 1.
  2. Enable Monitor SSL certificate under the SSL section.
  3. Set Alert when certificate expires in less than 21 days.
  4. Click Save.

Verify certbot auto-renewal is active if you use Let's Encrypt:

systemctl status certbot.timer
# or for snap-installed certbot:
snap run certbot renew --dry-run

Step 5: Heartbeat Monitoring for Model Loading and Inference

A model can appear loaded in the UI yet fail to generate tokens — the model process may have crashed internally or the backend may be in an error state with no visible indicator. Use Vigilmon's cron heartbeat with a minimal generation probe to catch this:

  1. In Vigilmon, click Add MonitorCron Heartbeat.
  2. Name it text-generation-webui inference probe.
  3. Set the expected ping interval to 5 minutes.
  4. Copy the heartbeat URL (e.g. https://vigilmon.online/heartbeat/abc123).

Create a probe script that sends a minimal generation request and pings Vigilmon only on success:

#!/bin/bash
# Send a minimal generation request to verify model is responding
RESPONSE=$(curl -s -X POST http://localhost:5000/api/v1/generate \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "1+1=",
    "max_new_tokens": 3,
    "temperature": 0.1
  }')

# Check that the response contains an output field
if echo "$RESPONSE" | grep -q '"results"'; then
  curl -s https://vigilmon.online/heartbeat/abc123
else
  echo "Inference probe failed: $RESPONSE" >&2
fi

Schedule it with cron:

# /etc/cron.d/tgwebui-heartbeat
*/5 * * * * root /usr/local/bin/tgwebui-probe.sh >> /var/log/tgwebui-hb.log 2>&1

If the model process crashes or becomes unresponsive, the probe fails, no ping fires, and Vigilmon alerts after the expected interval.


Step 6: Configure Alert Channels

  1. Go to Alert Channels in Vigilmon and add Slack, email, or a webhook.
  2. Set Consecutive failures before alert to 2 on the Gradio web UI monitor — Gradio can take 20–30 seconds to restart while a large model loads.
  3. Set the API endpoint and inference heartbeat monitors to alert on first failure — those represent genuine functional failures.

Summary

| Monitor | Target | What It Catches | |---|---|---| | Gradio web UI | http://your-server:7860 | Gradio process crash, server down | | OpenAI API | http://your-server:5000/v1/models | API extension process failure | | Model management API | /api/v1/model | No model loaded, native API failure | | SSL certificate | HTTPS reverse proxy domain | Let's Encrypt / Caddy renewal failure | | Cron heartbeat | /api/v1/generate probe | Model crash, inference failure, frozen backend |

text-generation-webui puts the power of local LLMs on your own hardware — but that power comes with the full responsibility of self-hosted uptime. With Vigilmon watching the Gradio UI, both API layers, SSL certificate, and a live inference heartbeat, every failure mode that could leave your LLM silently unusable is covered.

Monitor your app with Vigilmon

Free plan — 5 monitors, no credit card required. Up and running in 60 seconds.

Start free →