Error: Failed to connect to Webtomcat on HTTP Response code 400 - DX NetOps Spectrum
search cancel

Error: Failed to connect to Webtomcat on HTTP Response code 400 - DX NetOps Spectrum

book

Article ID: 442911

calendar_today

Updated On:

Products

Network Observability Spectrum

Issue/Introduction

The DX NetOps Spectrum OneClick catalina.out log file shows the following errors recurring every minute:

[Thread-####] WARN com.aprisma.errorlog - WebTomcatHealthWatcher encountered IOException: Connection refused

Failed to connect to Webtomcat on HTTP. Response code: 400

[https-jsse-nio-8443-exec-####] INFO com.aprisma.debuglog - IOException while connecting to webapp, URL : https://<hostname>:9446/spectrum ,Msg : Certificate Not 


Cause

The WebTomcatHealthWatcher class monitors the health of WebTomcat by attempting connections in a specific order:

HTTP first, then HTTPS. The process requires an HTTP 200 response to validate a protocol.

In this scenario, the HTTP attempt returns a 400 error.

The subsequent HTTPS attempt fails because the SSL certificate in the keystore has expired or is invalid (Msg : Certificate Not Valid).

Because neither protocol returns a success code, the health check loop restarts every minute, resulting in continuous log noise.

Resolution

Renew the expired certificate and update the keystore.

  • Stop the Tomcat and WebTomcat services.
  • Navigate to the following directory: $SPECROOT/custom/keystore.
  • Create a backup of the current truststore file: rename cacerts cacerts.backup
  • Replace the cacerts file with a renewed version containing the valid certificate.
  • Start the Tomcat and WebTomcat services.
  • Verify access to OneClick and the Webapp.
  • Review the catalina.out log to confirm the errors have ceased.