Last updated June 23, 2026
Troubleshooting Guide
This guide helps you diagnose and resolve common issues with your self-hosted deployment.
Table of Contents
- Service Won't Start
- Configuration Error on Web Page
- Database Connection Failed
- Can't Connect to Portal
- Port Already in Use
- Container Keeps Restarting
- Invalid Deployment Credentials
- Subscription Issues
- Reset Everything
- Collecting Logs for Support
Related Guides:
Service Won't Start
Symptoms
docker compose upfails- Containers exit immediately after starting
Diagnosis
Check logs:
docker compose -f docker-compose.production.yml logs server
docker compose -f docker-compose.production.yml logs webCommon Causes & Solutions
| Cause | Solution |
|---|---|
Missing credentials in .env | Verify CDX_APP_ID and CDX_APP_SECRET are set |
| Port already in use | Change CDX_PORT in .env or stop conflicting service |
| Insufficient disk space | Free up disk space (need 20GB minimum) |
| Docker not running | Start Docker Desktop or docker daemon |
Commands to Try
# Check detailed logs
docker compose -f docker-compose.production.yml logs
# Verify Docker is running
docker info
# Check available disk space
df -h
# Try recreating containers
docker compose -f docker-compose.production.yml down
docker compose -f docker-compose.production.yml up -dConfiguration Error on Web Page
Symptoms
- Web page shows "Configuration Error"
- API calls fail with network errors
Diagnosis
The web app can't reach the backend server.
# Is server healthy?
docker compose -f docker-compose.production.yml ps server
# Can you reach the backend health endpoint?
curl http://localhost/health
# Can you reach the config endpoint?
curl http://localhost/api/config/publicCommon Causes & Solutions
-
Server container not running
BASHdocker compose -f docker-compose.production.yml restart server -
Proxy not routing correctly
BASHdocker compose -f docker-compose.production.yml restart proxy -
Network issue between containers
BASH# Recreate the network docker compose -f docker-compose.production.yml down docker compose -f docker-compose.production.yml up -d
Database Connection Failed
Symptoms
- Server logs show:
Error: connect ECONNREFUSED - Server fails to start
Diagnosis
# Check postgres container status
docker compose -f docker-compose.production.yml ps postgres
# Check postgres logs
docker compose -f docker-compose.production.yml logs postgresSolutions
-
Restart postgres:
BASHdocker compose -f docker-compose.production.yml restart postgres -
Wait for healthy status, then restart server:
BASH# Wait for postgres to be healthy docker compose -f docker-compose.production.yml ps postgres # Then restart server docker compose -f docker-compose.production.yml restart server -
Verify password matches:
- Check
CDX_DATABASE_PASSWORDin.env - If you changed the password, you may need to recreate the database:
BASH# WARNING: This deletes all data! docker compose -f docker-compose.production.yml down -v docker compose -f docker-compose.production.yml up -d - Check
Can't Connect to Portal
Symptoms
- Server starts but shows degraded status
- Logs show:
Network error: fetch failed - License validation fails
Diagnosis
# Test network connectivity from server container
docker compose -f docker-compose.production.yml exec server \
wget -qO- https://portal.contextdx.com/healthSolutions
-
Check internet connectivity:
BASHping portal.contextdx.com -
Verify HTTPS is not blocked:
BASHcurl -I https://portal.contextdx.com -
Check firewall rules:
- Ensure outbound port 443 (HTTPS) is allowed
- Whitelist
portal.contextdx.comif using a proxy
-
Verify credentials:
- Check
CDX_APP_IDandCDX_APP_SECRETin.env - Ensure deployment is active in Portal dashboard
- Check
Port Already in Use
Symptoms
- Error:
port is already allocated - Container fails to start
Diagnosis
Find what's using port 80:
# Linux/Mac
sudo lsof -i :80
# Windows
netstat -ano | findstr :80Solutions
Option 1: Stop conflicting service
# Example: stop Apache
sudo systemctl stop apache2
# Example: stop nginx
sudo systemctl stop nginxOption 2: Use a different port
# Edit .env
CDX_PORT=8080
# Restart
docker compose -f docker-compose.production.yml down
docker compose -f docker-compose.production.yml up -dContainer Keeps Restarting
Symptoms
- Container status shows "Restarting"
- Health checks failing
Diagnosis
# Check logs for errors
docker compose -f docker-compose.production.yml logs --tail=100 server
# Check container status
docker compose -f docker-compose.production.yml psCommon Causes & Solutions
| Cause | Solution |
|---|---|
| Database not ready | Wait for postgres to be healthy, then restart server |
| Invalid configuration | Check .env file for syntax errors |
| Out of memory | Increase available RAM or reduce other workloads |
| Dependency container unhealthy | Restart all services in order |
Recovery Steps
# Stop everything
docker compose -f docker-compose.production.yml down
# Start in order with health check waiting
docker compose -f docker-compose.production.yml up -d postgres
# Wait for postgres to be healthy
docker compose -f docker-compose.production.yml ps postgres
docker compose -f docker-compose.production.yml up -d server
# Wait for server to be healthy
docker compose -f docker-compose.production.yml ps server
docker compose -f docker-compose.production.yml up -dInvalid Deployment Credentials
Symptoms
- Server fails to start
- Logs show:
Deployment activation failed: invalid_credentials
Solutions
-
Double-check credentials in
.env:BASH# View current values (careful not to expose these!) grep CDX_DEPLOYMENT .env -
Ensure no extra spaces or quotes:
BASH# Correct CDX_APP_ID=dep_abc123xyz # Wrong CDX_APP_ID="dep_abc123xyz" CDX_APP_ID= dep_abc123xyz -
If credentials were regenerated in Portal:
- Get new credentials from Portal dashboard
- Update
.envwith new values - Restart:
docker compose -f docker-compose.production.yml restart server
Subscription Issues
Subscription Inactive
Symptoms:
- Logs show:
Subscription inactive or suspended
Solutions:
- Log in to Portal dashboard
- Check Billing section
- Update payment method if needed
- Once resolved, restart:
docker compose -f docker-compose.production.yml restart server
Seat Limit Reached
Symptoms:
- New users cannot log in
- Error:
403 Forbidden: Seat limit reached
Solutions:
- Wait for inactive sessions to expire (automatic)
- Upgrade to a higher plan in Portal
- Remove inactive users from your organization
Reset Everything
If all else fails, you can reset to a clean state.
This deletes ALL data including the database!
# Stop and remove everything including volumes
docker compose -f docker-compose.production.yml down -v
# Remove any cached images (optional)
docker system prune -a
# Start fresh
docker compose -f docker-compose.production.yml up -dCollecting Logs for Support
When contacting support, include the following information:
Quick Log Collection
# Save all logs to a file
docker compose -f docker-compose.production.yml logs > contextdx-logs.txt 2>&1
# Include service status
docker compose -f docker-compose.production.yml ps >> contextdx-logs.txt
# Include configuration (without secrets!)
grep -v SECRET .env | grep -v PASSWORD >> contextdx-logs.txtDetailed Diagnostics
# Docker version
docker --version >> contextdx-logs.txt
docker compose version >> contextdx-logs.txt
# System info
uname -a >> contextdx-logs.txt
# Disk space
df -h >> contextdx-logs.txt
# Memory
free -h >> contextdx-logs.txtWhat to Include in Support Requests
- contextdx-logs.txt (from commands above)
- Error messages you're seeing
- Steps to reproduce the issue
- When the issue started (after an update, configuration change, etc.)
Support Channels
- Documentation: https://docs.contextdx.com
- Portal Dashboard: https://portal.contextdx.com
- Email Support: support@contextdx.com
Quick Reference Commands
| Issue | Command |
|---|---|
| Check all container status | docker compose -f docker-compose.production.yml ps |
| View server logs | docker compose -f docker-compose.production.yml logs server |
| View all logs | docker compose -f docker-compose.production.yml logs |
| Restart all services | docker compose -f docker-compose.production.yml restart |
| Restart single service | docker compose -f docker-compose.production.yml restart <service> |
| Stop all services | docker compose -f docker-compose.production.yml down |
| Full reset (loses data) | docker compose -f docker-compose.production.yml down -v |
| Shell into container | docker compose -f docker-compose.production.yml exec server sh |
