# Troubleshooting & Error Reference

#### Error Reference Table

<table id="bkmrk-error-message-cause-"><thead><tr><th>Error message</th><th>Cause</th><th>Solution</th></tr></thead><tbody><tr><td>`Not configured`</td><td>No credentials stored</td><td>Run `elestio login --email X --token Y`</td></tr><tr><td>`Authentication failed`</td><td>Wrong credentials or expired token</td><td>Regenerate token at [dash.elest.io/account/security](https://docs.elest.io/dash.elest.io/account/security "dash.elest.io/account/security")</td></tr><tr><td>`Account not approved`</td><td>New account without approval</td><td>Wait for approval or contact support@elest.io</td></tr><tr><td>`Template not found`</td><td>Wrong name or ID</td><td>Run `elestio templates search <name>`</td></tr><tr><td>`Invalid serverType`</td><td>Provider/region/size combo invalid</td><td>Check `elestio sizes --provider X`</td></tr><tr><td>`Service not found`</td><td>Wrong vmID or wrong project</td><td>Run `elestio services --project X`</td></tr><tr><td>`Deployment timeout`</td><td>Deployment is taking too long</td><td>Check dashboard; contact support if &gt; 10 min</td></tr><tr><td>`Project not found`</td><td>Wrong projectId</td><td>Run `elestio projects` to find the correct ID</td></tr></tbody></table>

---

#### Authentication Issues

##### "Authentication failed" repeatedly

```bash
# Step 1: Check current config
elestio config

# Step 2: Re-generate token in the Elestio dashboard
# Go to: https://dash.elest.io/account/security → Manage API Tokens → Create Token

# Step 3: Update credentials
elestio login --email "you@example.com" --token "new_token"

# Step 4: Verify
elestio auth test
```

##### The wrong user is being used

```bash
elestio whoami   # Check which account is active
elestio config   # See stored configuration
```

---

#### Deployment Issues

##### Service stuck in "Deploying" state

1. Normal deployment takes **2–5 minutes**
2. CI/CD target deployment may take up to **10 minutes**
3. If &gt; 10 minutes: check the Elestio dashboard for error messages
4. Contact support@elest.io if still stuck after 15+ minutes

```bash
# Poll until deployed
elestio wait <vmID>

# Check current status
elestio service <vmID>
```

##### "Service not found," but it exists

```bash
# Verify you are using vmID (not serverID)
elestio services --project 112

# Both IDs are shown — ensure you use the correct one:
# vmID  → most commands (firewall, ssl, power, etc.)
# id    → backup endpoints
```

##### "Invalid serverType" when deploying

```bash
# Check valid combinations for your provider
elestio sizes --provider netcup
elestio sizes --provider hetzner
```

---

#### Pipeline Issues

##### Pipeline not building

```bash
# View build logs
elestio cicd pipeline-logs <vmID> <pipelineID>

# Restart the pipeline
elestio cicd pipeline-restart <vmID> <pipelineID>
```

##### App deployed but not reachable in the browser

1. Check that your app is binding to the internal network, not `0.0.0.0`: 
    - Correct: `172.17.0.1:3000`
    - Wrong: `0.0.0.0:3000`
2. SSH in and check containers:

```bash
ssh root@<ipv4>
cd /opt/app/<pipeline-name>
docker-compose ps
docker-compose logs
```

##### Pipeline fails after code push

```bash
# View deployment history
elestio cicd pipeline-history <vmID> <pipelineID>

# Check latest logs
elestio cicd pipeline-logs <vmID> <pipelineID>
```

---

#### Firewall Issues

##### Can't reach the service after enabling the firewall

1. Ensure port 443 (HTTPS) is in the rules
2. Ensure port 22 (SSH) is included if you need SSH access
3. Re-check rules:

```bash
elestio firewall get <vmID>
```

4. Temporarily disable to test:

```bash
elestio firewall disable <vmID>
```

---

#### SSL/Domain Issues

##### SSL certificate not provisioning

1. Ensure your DNS A record points to the service's IPv4 **before** running `ssl add`
2. DNS propagation can take up to 48 hours (typically 5–30 minutes)
3. Check: `elestio ssl list <vmID>`
4. Remove and re-add if stuck: `elestio ssl remove <vmID> <domain>` then re-add

---

#### Resize/Downgrade Issues

##### Service blocked after downgrade attempt

This happens when trying to downgrade on a provider that doesn't support it (Hetzner, GCP).

**Supported for downgrade:** Netcup, AWS, Azure, and Scaleway only.

Resolution: Contact support@elest.io with the vmID. They can restore the service.

---

#### General Debugging Flow

```bash
# 1. Verify authentication
elestio auth test

# 2. Check service status
elestio service <vmID>

# 3. Restart the application stack (fastest recovery)
elestio restart-stack <vmID>

# 4. If pipeline involved, check logs
elestio cicd pipeline-logs <vmID> <pipelineID>

# 5. Full reboot if restart-stack doesn't help
elestio reboot <vmID>
```

---

#### Getting Help

<table id="bkmrk-channel-details-emai"><thead><tr><th>Channel</th><th>Details</th></tr></thead><tbody><tr><td>**Email support**</td><td>support@elest.io</td></tr><tr><td>**Dashboard**</td><td>[https://dash.elest.io](https://dash.elest.io "https://dash.elest.io")</td></tr><tr><td>**API Docs**</td><td>[https://api-doc.elest.io](https://api-doc.elest.io "https://api-doc.elest.io")</td></tr><tr><td>**Templates**</td><td>[https://elest.io/fully-managed-services](https://elest.io/fully-managed-services "https://elest.io/fully-managed-services")</td></tr></tbody></table>