# Status and troubleshooting

> Check that an installation is ready, read its logs, and what to do when an installation, an update, sign-in, indexing or search goes wrong.

Source: https://docs.corfedo.ai/operate/single-host/troubleshooting/

Start with `status`. It names the service or check that is not ready. Then read that service's logs.

## Check the installation

```sh
sh ~/corfedo/install.sh status
```

The report reads from top to bottom:

| Part | What it tells you |
| --- | --- |
| `Release`, `Address`, `Data generation` | The active release, the workspace address and the data generation, which goes up by one with each restore |
| `Unfinished update` | Present only after an interrupted update, with the command that continues it. See [Update](https://docs.corfedo.ai/operate/single-host/update/). |
| `Workload … certificate` | Days left on Corfedo's internal certificates, see [Certificates and trust](https://docs.corfedo.ai/operate/single-host/certificates-and-trust/) |
| Services | Each container and its health from Docker Compose |
| `Engine indexer`, `Engine search` | Whether each engine node is ready |
| `Artifact storage` | The storage budget, what the indexes use, free space and warnings |

**Check:** the last line is `Ready.` and the command exits 0.

Ready means Corfedo, the search engine and the workspace address all answer. With your own reverse proxy, `status` does not check the proxy.

## Read the logs

`compose` runs Docker Compose for the installation:

```sh
sh ~/corfedo/install.sh compose ps
sh ~/corfedo/install.sh compose logs --since 30m platform
sh ~/corfedo/install.sh compose logs -f indexer search
```

The services are `platform`, `indexer`, `search`, `postgres`, and `caddy` and `keycloak` (the bundled account service) when the installation uses them.

## When it is not ready

| What you see | What to do |
| --- | --- |
| `platform is unhealthy` or `starting` | Read `compose logs platform`. A service gets a few minutes to start after a restart. |
| `The workspace address answered 000` | Caddy is not reachable on the address and port. Check `compose ps caddy` and that nothing else uses the port. |
| `Issuer discovery of the account service answered …` | Keycloak is not ready. Read `compose logs keycloak`. |
| An internal certificate shows `expired` | Run `renew-certificates` |
| `Artifact storage` warns of low space | Free disk, or lower `CORFEDO_STORAGE_BUDGET_GIB` in [installation settings](https://docs.corfedo.ai/operate/settings/) so the budget fits the disk |

## Install and update

| What you see | Why | What to do |
| --- | --- | --- |
| `Docker is not running or this user cannot use it` | The Docker daemon is stopped, or the user is not in the `docker` group | Start Docker, or add the user to the group and sign in again |
| `… GiB are free under …` with `at least 10 GiB are needed` | Not enough disk in the installation directory | Free disk or choose another `--dir` |
| `Docker did not report its memory` | Docker gives no memory figure, so the search node cannot be sized | Check `docker info`, then run the installer again |
| `No free network in 172.31.200.0-172.31.250.0` | Other Docker networks use every address range the installer tries | Remove unused Docker networks |
| `Corfedo did not become ready` | A service did not start in time | Run `status`, then read the logs of the service it names |
| An install stopped part way | The terminal closed or a step failed | Run the same command again. It continues where it stopped. |
| `The update of Corfedo … did not finish` | An earlier update was interrupted | Run `update --version` with the release it names. See [Update](https://docs.corfedo.ai/operate/single-host/update/). |

## Sign-in and the browser

| What you see | Why | What to do |
| --- | --- | --- |
| The browser warns that the connection is not private | The browser does not trust the local certificate authority | Trust `generated/caddy-root.crt`. See [Certificates and trust](https://docs.corfedo.ai/operate/single-host/certificates-and-trust/). |
| A coding agent or the CLI cannot connect, with a certificate error | The client's runtime does not trust the certificate | Set the client's trust as [Certificates and trust](https://docs.corfedo.ai/operate/single-host/certificates-and-trust/#trust-in-clients) shows |
| Sign-in with your own identity provider fails after the provider's page | The platform cannot reach the provider's issuer address, or does not trust its certificate | Check that the platform container reaches the issuer. Add a private CA to `generated/tls/ca.crt` and [run `update` for the installed release](https://docs.corfedo.ai/operate/single-host/update/#apply-changed-settings), see [Trust private CAs](https://docs.corfedo.ai/operate/single-host/certificates-and-trust/#trust-private-cas). |
| Browser sign-in for the CLI or an MCP client fails before the sign-in page | The platform cannot fetch the client's identity from `clients.corfedo.ai` or the client's own host | Allow outbound HTTPS from the host |
| Every administrator is locked out by a network list | **Network access** in Settings no longer admits their address | Clear the list on the host as [Security](https://docs.corfedo.ai/operate/security/#clear-a-network-list) shows |

## Indexing and search

| What you see | Why | What to do |
| --- | --- | --- |
| Repositories stay **Indexing** for a long time | The indexer is busy or not ready, or the artifact storage budget is used up, so builds wait | Check `Engine indexer` and `Artifact storage` in `status` and `compose logs indexer`. Raise `CORFEDO_STORAGE_BUDGET_GIB` in [installation settings](https://docs.corfedo.ai/operate/settings/) when the disk has room. |
| **Unavailable** on indexed repositories | The search node is not ready, or cannot hold every index | Check `Engine search` in `status`. Give Docker more memory. To make the search node use it, run `renew-certificates`, which also rewrites the search node's memory limit and restarts it. |
| **The index could not be stored** on a build | Writing the index to artifact storage failed, usually because the disk is full | Free disk, then reindex |
| **The repository exceeds the indexer’s limits** | The repository's index is larger than this installation's build limit | Raise `CORFEDO_MAXIMUM_BUILD_BYTES` in [installation settings](https://docs.corfedo.ai/operate/settings/), or leave the repository out with a [discovery rule](https://docs.corfedo.ai/workspace/sources/discovery-rules/) |

## Certificates

| What you see | Why | What to do |
| --- | --- | --- |
| `certificate_expiry` warnings in the logs | A workload certificate expires within 30 days | Run `renew-certificates` |
| `status` shows a workload certificate as `expired` and services are not ready | The certificate expired | Run `renew-certificates`. It needs no network access. |

## When a part stops

| Part down | What people see |
| --- | --- |
| Search node | Repositories it serves show **Unavailable**, and search leaves them out |
| Indexer | New commits wait. Search keeps the indexes it has. |
| AI provider | Answers fail and say so. **Retry** asks again. Search and code reading keep working. |
| Identity provider | Nobody can sign in. Existing sessions keep working until they expire. |
| PostgreSQL | Corfedo stops working until the database is back |

## Related

- [Requirements](https://docs.corfedo.ai/operate/single-host/#requirements) lists what the host needs.
- [Installer](https://docs.corfedo.ai/reference/installer/) lists every command.
