* Add CLI flags to config LevelDB table/total sizes
I wired up CLI flags to allow configuring LevelDB table and total sizes:
- `--leveldb.compaction.table.size`, LevelDB SSTable file size factor in MiB (default: 2)
- `--leveldb.compaction.table.multiplier`, multiplier on LevelDB SSTable file size (default: 1)
- `--leveldb.compaction.total.size`, total size factor in MiB of LevelDB levels (default: 10)
- `--leveldb.compaction.total.multiplier`, multiplier on LevelDB total level size (default: 10)
N.B. that the default values for these configs are exactly the same as
before this changset and so Bor behavior should not change unless these
flags are deliberately overridden. Bor/Geth inherited the default values
from [the `goleveldb`
defaults](
|
||
|---|---|---|
| .. | ||
| audits | ||
| cli | ||
| postmortems | ||
| README.md | ||
Documentation
The new command line interface (CLI) in this version of Bor aims to give users more control over the codebase when interacting with and starting a node. We have made every effort to keep most of the flags similar to the old CLI, except for a few notable changes. One major change is the use of the --config flag, which previously represented fields without available flags. It now represents all flags available to the user, and will overwrite any other flags if provided. As a node operator, you still have the flexibility to modify flags as needed. Please note that this change does not affect the internal functionality of the node, and it remains compatible with Geth and the Ethereum Virtual Machine (EVM).
Additional notes
-
The new entrypoint to run the Bor client is
server.$ bor server <flags>See here for more flag details.
-
The
bor dumpconfigsub-command prints the default configurations, in the TOML format, on the terminal. One canpipe (>)this to a file (sayconfig.toml) and use it to start bor. -
A toml file now can be used instead of flags and can contain all configuration for the node to run. To simply run bor with a configuration file, the following command can be used.
$ bor server --config <path_to_config.toml> -
You can find an example config file here to know more about what each flag is used for, what are the defaults and recommended values for different networks.
-
Toml files used earlier (with
--configflag) to configure additional fields (like static and trusted nodes) are being deprecated and have been converted to flags.