> 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/nolus/useful-commands.md). Agents can also search and read this documentation through its [MCP server](https://service.block-pro.net/~gitbook/mcp).

# Useful Commands

Everyday Nolus service, wallet and validator commands.

**Mainnet · `pirin-1`**

Commands use the `wallet` key name. Transaction examples ask for confirmation. Replace quoted address placeholders and review amounts before signing. `1 NLS = 1,000,000 unls`.

Fee examples use `0.025unls` per gas, following the [official Nolus validator guide](https://docs.nolus.io/network/validators). The gas limit and gas price are separate: increasing the price alone does not fix `out of gas`.

## Service operations

### Status

Check the systemd unit.

```bash
sudo systemctl status nolusd --no-pager
```

### Logs

Follow recent logs.

```bash
sudo journalctl -u nolusd -f -o cat
```

### Restart

Restart the node process.

```bash
sudo systemctl restart nolusd
```

### Stop

Stop the node.

```bash
sudo systemctl stop nolusd
```

### Start

Start the node.

```bash
sudo systemctl start nolusd
```

### Sync status

Check height and catching\_up.

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

### Version

Show the installed binary version.

```bash
nolusd version --long
```

### Running service version

Check the executable running under `nolusd.service`. After applying the upgrade at **29,561,450**, expect `0.9.0`.

```bash
systemctl is-active --quiet nolusd.service &&
sudo "/proc/$(systemctl show nolusd.service -p MainPID --value)/exe" version --long
```

### Mainnet upgrade

Proposal [#385](https://lens.nolus.io/proposal/385) passed with plan `v0.9.0` at height **29,561,450**. Follow [Upgrade](https://service.block-pro.net/mainnet/nolus/upgrade.md) to replace the service binary.

Read the on-chain proposal.

```bash
nolusd query gov proposal 385 -o json
```

Check which height applied the upgrade. Expect `29561450`.

```bash
curl -fsS "https://lcd.nolus.network/cosmos/upgrade/v1beta1/applied_plan/v0.9.0" | jq -r '.height'
```

## Key management

### Create

Create a wallet and securely store its recovery phrase.

```bash
nolusd keys add wallet
```

### Recover

Import a wallet interactively.

```bash
nolusd keys add wallet --recover
```

### List

List local keys.

```bash
nolusd keys list
```

### Address

Show the account address.

```bash
nolusd keys show wallet -a
```

### Balance

Query token balances.

```bash
nolusd query bank balances "$(nolusd keys show wallet -a)"
```

## Tokens

### Send

Send 1 token to the chosen recipient.

```bash
nolusd tx bank send wallet "RECIPIENT_ADDRESS" 1000000unls --chain-id pirin-1 --gas auto --gas-adjustment 1.5 --gas-prices 0.025unls
```

### Delegate

Delegate 1 token to a validator.

```bash
nolusd tx staking delegate "VALIDATOR_ADDRESS" 1000000unls --from wallet --chain-id pirin-1 --gas auto --gas-adjustment 1.5 --gas-prices 0.025unls
```

### Withdraw rewards

Withdraw delegation rewards.

```bash
nolusd tx distribution withdraw-all-rewards --from wallet --chain-id pirin-1 --gas auto --gas-adjustment 1.5 --gas-prices 0.025unls
```

## Validator operations

### Details

Query your validator record.

```bash
nolusd query staking validator "$(nolusd keys show wallet --bech val -a)"
```

### Commission and rewards

Withdraw rewards and validator commission.

```bash
nolusd tx distribution withdraw-rewards "$(nolusd keys show wallet --bech val -a)" --commission --from wallet --chain-id pirin-1 --gas auto --gas-adjustment 1.5 --gas-prices 0.025unls
```

### Unjail

Use only after correcting the cause of jailing and meeting unjail conditions.

```bash
nolusd tx slashing unjail --from wallet --chain-id pirin-1 --gas auto --gas-adjustment 1.5 --gas-prices 0.025unls
```

## Governance

### Proposals

List governance proposals.

```bash
nolusd query gov proposals
```

### Proposal details

Replace 123 with the proposal you want to review. Confirm it is still in its voting period.

```bash
nolusd query gov proposal 123
```

### Vote

Replace 123 with your reviewed proposal ID and choose your vote option. This single-vote example uses an explicit gas limit of `200000` to avoid the observed automatic-estimation failure. Review the transaction before confirming.

```bash
nolusd tx gov vote 123 yes --from wallet --chain-id pirin-1 --gas 200000 --gas-prices 0.025unls
```

The fee is **5000 unls = 0.005 NLS**. An explicit limit does not need `--gas auto` or `--gas-adjustment`. This is a practical limit for this vote example, not a universal setting for every transaction.

### Confirm your vote

A broadcast response with `code: 0` and `height: 0` only confirms initial acceptance. Wait a few blocks, then query your recorded vote using the same proposal ID.

```bash
nolusd query gov vote 123 "$(nolusd keys show wallet -a)"
```

For the YES example, look for your address, the correct proposal ID and `option: 1` or `VOTE_OPTION_YES` (depending on the output format). `weight: "1.000000000000000000"` assigns 100% of this vote to YES. A matching record confirms that the vote is stored on-chain. If a recent vote is not found, check the transaction before treating the vote as confirmed.

### Transaction result

Replace the placeholder with the hash returned by the new attempt. On a node with transaction indexing enabled, a successful included transaction has `code: 0` and a block height greater than zero.

```bash
nolusd query tx "TRANSACTION_HASH"
```

<details>

<summary>Fix: out of gas in WritePerByte</summary>

The reported vote used `--gas auto --gas-adjustment 1.5`, but its gas limit was `76363`. Execution had already consumed `80457` when it stopped with `code: 11`. That value is the consumption at failure, not the complete gas requirement.

Retry the reviewed vote with the explicit `--gas 200000` example above, then confirm the recorded vote. Raising `--gas-prices` alone does not increase the gas limit. A transaction hash by itself does not prove success.

If another transaction still runs out of gas, size its limit for that operation and review the resulting fee. Keep automatic estimation for the other transaction examples unless their own results indicate a problem.

[Gas and transaction lifecycle](https://docs.cosmos.network/sdk/v0.50/learn/beginner/tx-lifecycle) · [Governance query reference](https://docs.cosmos.network/sdk/v0.50/build/modules/gov/README#vote)

</details>
