jaegertracing/jaeger · error
abnormal value of http status code: %v
Error message
abnormal value of http status code: %v
What it means
The `jaeger status` (doStatus) command issues an HTTP GET to the running Jaeger instance's admin endpoint and prints the response body. If the server responds with any status other than 200 OK, the command fails with this error carrying the received status code, signaling that the service is not healthy/ready.
Source
Thrown at cmd/internal/status/command.go:42
func Command(v *viper.Viper, adminPort int) *cobra.Command {
c := &cobra.Command{
Use: "status",
Short: "Print the status.",
Long: `Print Jaeger component status information, exit non-zero on any error.`,
RunE: func(_ *cobra.Command, _ /* args */ []string) error {
url := convert(v.GetString(statusHTTPHostPort))
ctx, cx := context.WithTimeout(context.Background(), time.Second)
defer cx()
req, _ := http.NewRequestWithContext(ctx, http.MethodGet, url, http.NoBody)
resp, err := http.DefaultClient.Do(req)
if err != nil {
return err
}
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
if resp.StatusCode != http.StatusOK {
return fmt.Errorf("abnormal value of http status code: %v", resp.StatusCode)
}
return nil
},
}
c.Flags().AddGoFlagSet(flags(&flag.FlagSet{}, adminPort))
v.BindPFlags(c.Flags())
return c
}
func flags(flagSet *flag.FlagSet, adminPort int) *flag.FlagSet {
adminPortStr := ports.PortToHostPort(adminPort)
flagSet.String(statusHTTPHostPort, adminPortStr, fmt.Sprintf(
"The host:port (e.g. 127.0.0.1%s or %s) for the health check", adminPortStr, adminPortStr,
))
return flagSet
}
func convert(httpHostPort string) string {View on GitHub (pinned to 806f444784)
Solutions
- Wait until the Jaeger service reports Ready (health check flips after RunAndThen sets it) and retry `jaeger status`
- Verify the status command's admin port/URL matches jaeger.admin.http.host-port of the running instance (default :14269)
- Check the printed response body — it shows what the endpoint actually returned (e.g. 503 with health details)
- Confirm you are querying the right process: `curl http://localhost:14269/` to inspect the admin server directly
Example fix
// before
# jaeger status -> 503
cmd.Flags().String("status-http-host-port", ":8080", "...") // wrong port
// after
# point at the admin port actually configured
jaeger status --admin-http-port 14269 Defensive patterns
Strategy: try-catch
Validate before calling
// Before trusting `jaeger status`, probe the admin endpoint yourself
resp, err := http.Get(fmt.Sprintf("http://%s/", adminAddr))
if err != nil {
return fmt.Errorf("admin endpoint unreachable at %s: %w", adminAddr, err)
}
if resp.StatusCode != http.StatusOK {
return fmt.Errorf("service not healthy yet, status %d", resp.StatusCode)
} Try / catch
if err := statusCmd.RunE(cmd, args); err != nil {
if strings.HasPrefix(err.Error(), "abnormal value of http status code") {
// service not ready or wrong admin port; retry with backoff
time.Sleep(2 * time.Second)
return retry()
}
return err
} Prevention
- Retry the status command with backoff right after service start (health flips to Ready only after initialization)
- Point the status command at the real jaeger.admin.http.host-port (default :14269)
- Read the response body the command prints — it explains the non-200
- Verify no proxy intercepts the admin endpoint
When it happens
Trigger: Running `jaeger status` against an instance whose admin health endpoint returns non-200 — service still starting (503 not ready), shutting down, or the request hit the wrong URL/port that returns e.g. 404.
Common situations: Executing the status command before Jaeger finished initialization; pointing the status command at the wrong admin port (default 14269); a reverse proxy intercepting the request; the Jaeger process crashed but something else answers on that port.
Related errors
- jaeger exporter is no longer supported, please use otlp
- access denied
- no http.RoundTripper provided
- bad request
- failed to initialize config: %w
AI-assisted analysis of jaegertracing/jaeger@806f444784 (2026-09-01).
Data as JSON: /api/errors/8e649ebcc5e695e4.
Report an issue: GitHub.