> For the complete documentation index, see [llms.txt](https://service.block-pro.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://service.block-pro.net/mainnet/lava/upgrade.md).

# Upgrade

Upgrade Lava safely and confirm the node resumes syncing.

**Mainnet · `lava-mainnet-1`**

This procedure uses the direct `lavad.service` created by our installation guide. If your service uses Cosmovisor, stage the binary under the exact on-chain upgrade plan name instead of replacing its symlink.

{% hint style="warning" %}
For a scheduled chain upgrade, prepare the binary in advance and switch only at the announced height. For a compatible patch, follow the project’s release instructions. Do not skip database migrations or start an old binary against upgraded state.
{% endhint %}

### Check the service

Confirm its executable and home before changing anything.

```bash
systemctl cat lavad
```

### Check the upgrade plan

Read any scheduled on-chain upgrade.

```bash
lavad query upgrade plan -o json
```

### Prepare the new binary

Use the binary download/build steps in [Installation](/mainnet/lava/installation.md), but stage the result as `$HOME/lavad.next` and do not install it over the running executable yet. Select the release announced for `lava-mainnet-1`.

### Select the approved target

v6.2.5 is the reviewed stable reference; change it only to the release authorized for your network.

```bash
LAVA_VERSION=v6.2.5
```

### Download to a staging path

This leaves the current service binary intact.

```bash
curl -fL "https://github.com/lavanet/lava/releases/download/$LAVA_VERSION/lavad-$LAVA_VERSION-linux-amd64" -o "$HOME/lavad.next"
```

### Verify v6.2.5

Use the checksum belonging to the chosen release.

```bash
printf "%s  %s\n" e500f73102264a48818ab5ecc1350bf54d663d6d3a4bfb45d9a85833d2b1fded "$HOME/lavad.next" | sha256sum -c -
```

### Make executable

Allow checking the staged binary.

```bash
chmod 0755 "$HOME/lavad.next"
```

### Check the staged version

Resolve missing libraries or a wrong release before downtime.

```bash
"$HOME/lavad.next" version --long
```

### Stop at the correct time

Stop the one active signer before switching binaries.

```bash
sudo systemctl stop lavad
```

### Back up configuration and signing state

Keep the signing state from this stopped node. Store a full stopped database backup as well if the release requires one.

```bash
tar -czf "$HOME/lava-mainnet-upgrade-$(date +%Y%m%d-%H%M%S).tar.gz" -C "$HOME/.lava" config data/priv_validator_state.json
```

### Keep the previous binary

Retain a copy for diagnostics; database migrations may prevent a simple binary rollback.

```bash
cp /usr/local/bin/lavad "$HOME/lavad.previous"
```

### Replace the binary

Install the staged executable.

```bash
sudo install -m 0755 "$HOME/lavad.next" /usr/local/bin/lavad
```

### Start

Start the node with the upgraded binary.

```bash
sudo systemctl start lavad
```

### Inspect logs

Check for migration errors and advancing heights.

```bash
sudo journalctl -u lavad -n 100 -f -o cat
```

### Confirm sync

Check height and catching\_up after the node recovers.

```bash
curl -fsS http://127.0.0.1:26657/status | jq '.result.sync_info'
```

[Release history](https://github.com/lavanet/lava/releases).
