···11++++
22+title = "Operating leveva"
33+template = "page.html"
44+weight = 5
55++++
66+77+Day-to-day operation of a running leveva server.
88+99+## Reloading config with `REHASH`
1010+1111+leveva remembers the path it was started with, so an operator can reload the
1212+config without restarting:
1313+1414+```
1515+/REHASH
1616+```
1717+1818+Most of the config hot-reloads: operators, connection classes, `allow` blocks,
1919+the MOTD, the admin block, `connect` blocks, listeners, default user/channel
2020+modes, bans, auto-connect, flood and knock tunables, and connection-accept
2121+thresholds. Validate a config edit before reloading with `leveva --config
2222+ircd.kdl --check`.
2323+2424+## TLS certificate reload
2525+2626+TLS certificate and key files are watched on disk. When they change — for example
2727+after a Let's Encrypt renewal — leveva reloads them live, with no restart and no
2828+dropped connections. Sending `SIGHUP` also triggers a reload. This pairs well
2929+with an ACME client that rewrites the cert in place.
3030+3131+## Operators
3232+3333+An operator authenticates with:
3434+3535+```
3636+/OPER <name> <password>
3737+```
3838+3939+`<name>` is the `operator "<name>"` block in the config. Generate a SHA-512
4040+password hash for that block with the `MKPASSWD` command (the `$6$…` output is
4141+stored as the block's `password (hash)"…"`). Each operator is granted exactly the
4242+`privileges` listed in their block — `kill`, `squit`, `connect`, `rehash`,
4343+`kline`, `trace`, and so on. Operators with `+s` receive server notices about
4444+network events (kills, rehashes, link changes).
4545+4646+## Bans
4747+4848+Config `ban` blocks are enforced at registration and reload with `REHASH`.
4949+Operators with the right privileges can also set runtime bans:
5050+5151+- `KLINE` / `UNKLINE` — ban by `user@host`.
5252+- `DLINE` / `UNDLINE` — ban by IP address or CIDR range.
5353+- `RESV` — reserve nicknames and channels.
5454+5555+`STATS` reports the active ban lists (for example `STATS k` and `STATS d`).
5656+5757+## Logging
5858+5959+leveva logs through `tracing`. Pick a verbosity at startup with `--log-level`
6060+(`error`/`warn`/`info`/`debug`/`trace`) or with a full `RUST_LOG`-style filter
6161+string. The `RUST_LOG` environment variable, when set, takes precedence over the
6262+flag:
6363+6464+```sh
6565+RUST_LOG=leveva=debug,leveva_iauth=info ./target/release/leveva --config ircd.kdl
6666+```
6767+6868+## Metrics
6969+7070+When a metrics listener is configured, leveva exposes Prometheus-format counters
7171+(client and server counts, link traffic, and more) over HTTP. The same counters
7272+back the `STATS m` and `STATS z` reports, so you can read them either from a
7373+Prometheus scrape or interactively as an operator.
7474+7575+## Server links
7676+7777+Operators bring links up and down by hand with `CONNECT` and `SQUIT`, and leveva
7878+will dial configured `connect` blocks automatically when `autoconnect #true` and
7979+`auto-connect` is enabled in `options`. See the
8080+[`connect` block](@/configuration.md) for how link passwords and roles are
8181+configured.