> For the complete documentation index, see [llms.txt](https://surftest.gitbook.io/axelar-wiki/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://surftest.gitbook.io/axelar-wiki/english/disk-usage-optimisation.md).

# Disk usage optimisation

This guide is suitable for all Cosmos network validators.

The blockchain grows in size over time. The filling rate of an SSD depends on the block production rate, the number of transactions in each block, the blockchain log settings, etc.&#x20;

Below are practical tips that will help you slow down the growth of the blockchain on servers 10 times.

{% hint style="warning" %}
This section is written for **TESTNET**. The section for MAINNET will be on the site later (after my installation of the node in the mainnet)
{% endhint %}

## Editing config.toml

Let's start the setup by adjusting parameters of the file `~/.axelar_testnet/.core/config/config.toml`

### Indexing <a href="#indexing" id="indexing"></a>

The "Indexing" function is only needed by those who need to request transactions from a specific node. Most of the time this setting can be changed.

&#x20;Open file editing by nano:

```
sudo nano ~/.axelar_testnet/.core/config/config.toml
```

Finding a string `indexer = "info"` and change the parameter to "null":

```
indexer = "null"
```

Indexing files are stored in the `~/.axelar_testnet/.core/data/tx_index.db/` directory. If you changed this parameter on a synchronized node that has already collected this information, then delete it with the command below:

```
sudo rm ~/.axelar_testnet/.core/data/tx_index.db/*
```

### Logging <a href="#logging" id="logging"></a>

By default, the node state logging level is set to `info`, i.e. full display of all node information.

Это полезно при запуске ноды, чтобы убедиться что нода правильно работает.&#x20;

This is useful when starting a node for the first time to make sure the node is working properly.

But after you understand that the node is working correctly and synchronizing, you can lower the log display level to `warn` (or even to `error` ).

**This parameter can be in one of two places:**

1\. In the config file `~/.axelar_testnet/.core/config/config.toml`

{% hint style="warning" %}
Before editing config.toml, make sure that there is no flag with logs in the axelar.service file ( just delete flag --`log_level`). Line example:\
`ExecStart=$HOME/go/bin/axelar start --log_level=info`
{% endhint %}

2\. In the service file `/etc/systemd/system/axelar.service`.&#x20;

{% hint style="warning" %}
In this case, check that in the file `config.toml` log line will be commented out:\
`# log_level = "info"`
{% endhint %}

It is important to understand:

{% hint style="info" %}
It doesn't matter where you change this parameter (in axelar.service or in config.toml), the main thing is that it should be in one place.
{% endhint %}

So, set the log parameter like this:

```
log_level = "warn"
```

Save and exit.

## Editing app.toml

The `app.toml` file is located at `~/.axelar_testnet/.core/config/app.toml` .&#x20;

### State-sync snapshots <a href="#state-sync-snapshots" id="state-sync-snapshots"></a>

If we are not going to use the server for snapshots, then we need to set this parameter to zero.

```
sudo nano ~/.axelar_testnet/.core/config/app.toml
```

We go down to the end of the file and turn off snapshot intervals (change the value to 0). But in Axelar this parameter is already set to 0. Let's check:

```
snapshot-interval = 0
```

### Configure pruning <a href="#configure-pruning" id="configure-pruning"></a>

If you closed the app.toml file, then open it with the nano editor:

```
sudo nano ~/.axelar_testnet/.core/config/app.toml
```

And we should bring the lines with pruning to this form:

```
pruning = "custom"
pruning-keep-recent = "100"
pruning-keep-every = "0"
pruning-interval = "10"
```

## Restart Axelar

We have changed the Axelar config. Then for the changes to take effect, we need to restart the container.

After restart everything is ready. Now the disk space will last 10 times longer.<br>
