cardano course
  • Welcome!
  • Video lessons
  • Handbook
    • Module 1. Building and running the node
      • Building the node
      • Running the node and connecting to a network
    • Module 2. Basic operations
      • Creating keys and addresses
      • Creating a simple transaction
      • Registering the stake address and delegating
    • Module 3. Protocol parameters and configuration files
      • Protocol parameters
      • Byron genesis file
      • Shelley genesis file
      • Alonzo genesis file
      • Conway genesis file
      • Node configuration file
      • Topology file
    • Module 4. Peer-to-peer (P2P) networking
    • Module 5. Creating a stake pool
      • The setup
      • Generating keys
      • Registering a stake pool
      • Runtime system options
      • Running the nodes
      • Stake snapshots
      • Upgrading cardano-node and cardano-cli
      • Pool operations and maintenance
      • Retiring a stake pool
    • Module 6. Monitoring the nodes
    • Module 7. Cardano governance
      • Update proposals
      • Polls
    • Module 8. Setting up a local cluster
      • Creating a local cluster
      • Spending the genesis UTXO
      • From Byron to Shelley
      • Moving funds to a Shelley address
      • Creating a first stake pool
      • Bringing decentralization parameter down to .80
      • From Shelley to Alonzo
      • Creating a second stake pool before moving to the Babbage era
      • Redelegating genesis keys
      • Vasil hard fork
      • Creating a local cluster with the mkfiles script
    • Module 9. Simple scripts and Plutus scripts
    • Module 10. New tracing system
    • Module 11. Running the SMASH server
    • Module 12. Running the token metadata server
  • Curated playlist
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub
  1. Handbook
  2. Module 3. Protocol parameters and configuration files

Protocol parameters

Protocol parameters on Cardano are the various settings that define the blockchain's behavior.

Let's delve into the protocol parameters using the Cardano CLI. Note that this time, we will be using the mainnet, as testnet environments may have different parameter values. Additionally, it's important to mention that the output is simplified as the cost models are collapsed.

$ cardano-cli query protocol-parameters --mainnet

> {
    "collateralPercentage": 150,
    "costModels": {
        "PlutusScriptV1": {...},
        "PlutusScriptV2": {...}
    },
    "decentralization": null,
    "executionUnitPrices": {
        "priceMemory": 5.77e-2,
        "priceSteps": 7.21e-5
    },
    "extraPraosEntropy": null,
    "maxBlockBodySize": 90112,
    "maxBlockExecutionUnits": {
        "memory": 62000000,
        "steps": 40000000000
    },
    "maxBlockHeaderSize": 1100,
    "maxCollateralInputs": 3,
    "maxTxExecutionUnits": {
        "memory": 14000000,
        "steps": 10000000000
    },
    "maxTxSize": 16384, 
    "maxValueSize": 5000,
    "minPoolCost": 340000000,
    "minUTxOValue": null,
    "monetaryExpansion": 3.0e-3,
    "poolPledgeInfluence": 0.3,
    "poolRetireMaxEpoch": 18,
    "protocolVersion": {
        "major": 7,
        "minor": 0
    },
    "stakeAddressDeposit": 2000000,
    "stakePoolDeposit": 500000000,
    "stakePoolTargetNum": 500,
    "treasuryCut": 0.2,
    "txFeeFixed": 155381,
    "txFeePerByte": 44,
    "utxoCostPerByte": 4310,
    "utxoCostPerWord": null
}

The CLI retrieves the protocol parameters from the ledger state. This implies that these parameters are currently active, along with their corresponding values. Please note that any parameters set to null have been deprecated.

Protocol parameters can be updated via an update proposal.

Alongside protocol parameters, there are global constants. Unlike protocol parameters, global constants can only be updated through a software update, which always involves incrementing the protocol version. An increase in the major version indicates a hard fork, while the minor version represents a soft fork, allowing old software to validate but not produce new blocks.

SlotsPerEpoch
SlotsPerKESPeriod
MaxKESEvolutions
StabilityWindow
RandomnessStabilisationWindow
Quorum
MaxMajorPV
ActiveSlotCoeff
NetworkId
MaxLovelaceSupply
securityParam
slotLength

Below you will find a description of the protocol parameters and global constants:

Description
Value

NetworkId

Determines the expected network (mainnet or testnet)

mainnet

MaxLovelaceSupply

The total number of lovelace in the system

45000000000000000

SlotsPerEpoch

The number of slots in an epoch

432000

k

The security parameter, which defines the number of blocks required for the blockchain to be considered final, preventing any further rollback (ie, the maximum allowable length of any chain fork)

2160

ActiveSlotCoeff

The fraction of slots, denoted as 'f' in the Praos paper, represents the average proportion of slots that a block will contain

0.05

slotLength

The length of each slot (in seconds)

1

txFeeFixed

Base transaction fee (in lovelace)

155381

txFeePerByte

Additional transaction fee per byte of data (in lovelace)

44

maxTxSize

Maximum transaction size in bytes

16384

maxBlockBodySize

Maximum block size in bytes

90112

maxBlockHeaderSize

Maximum block header size in bytes

1100

maxValueSize

The maximum serialized length (in bytes) of a multi-asset value (token bundle) in a transaction output

5000

Quorum

The number of the Genesis delegate keys that must endorse an update proposal

5

protocolVersion major minor

Current protocol version

7.0

MaxMajorPV

If the major component of the protocol version is larger than MaxMajorPV, there is an

ObsoleteNode failure

Halts below 7.0 nodes

StabilityWindow

The number of slots needed for a block to become stable, defined as 3k/f

3k/f

stakeAddressDeposit

Deposit amount in lovelace required to register stake credential

2000000

stakePoolDeposit

Deposit amount in lovelace required to register a stake pool

500000000

stakePoolTargetNum

The optimal number of saturated stake pools. Impacts saturation threshold, encouraging growth in the number of stake pools

500

decentralization

Controls how many slots are governed by the genesis nodes via OBFT and which slots are open to any registered stake pool

Deprecated

Shelley - Alonzo: [0-1]

Babbage: Null

SlotsPerKESPeriod

Defines after how many slots a pool's operational key pair evolves (key evolving signatures)

129600

MaxKESEvolutions

The maximum number of times a KES key pair can evolve before a new KES key pair is generated from the master keys

62

poolRetireMaxEpoch

Maximum number of epochs within which a pool can be announced to retire, starting from the next epoch

18

minPoolCost

Minimum pool cost per epoch (in lovelace), which enables pledge effect

340000000

minUTxOValue

The minimum ada value that a transaction output must hold (during the Shelley era)

Deprecated

utxoCostPerWord

During the Mary, Allegra, and Alonzo eras, this parameter determined the minimum ada value required for a transaction output to support native assets (in the Mary and Allegra eras) and datum hashes (in the Alonzo era)

Deprecated

utxoCostPerByte

In the Babbage era, transaction outputs are required to contain at least

(160 +

serialized_output

treasuryCut

Proportion of the reward pot that will move to the treasury at each rewards distribution

0.2

monetaryExpansion

Every epoch, the total amount of ada in circulation is increased by monetaryExpanision % of the ada reserves and is moved to the rewards pot

3.0e-3 (.003)

poolPledgeInfluence

Determines stake pool owner-stake influence on pool rewards

0.3

costModels PlutusV1 PlutusV2

Every phase-2 scripting language converts the calculated execution cost into a number of

ExUnits using a cost model, which depends on the language

PV1 PV2

executionUnitPrices priceMemory priceSteps

Prices consist of two rational numbers that correspond to the components

of ExUnits: the price per unit of memory and price per reduction step

priceMemory: 5.77e-2

(.0577) priceSteps: 7.21e-5 (.0000721)

maxBlockExecutionUnits memory steps

Maximum ExUnits allowed in a block

memory: 62000000 steps: 40000000000

collateralPercentage

The percentage of the total transaction fee,

its collateral must (at minimum) cover

150

maxCollateralInputs

Limits the total number of collateral inputs, and thus the total number of additional

signatures that must be checked during validation

3

extraPraosEntropy

This provides additional certainty that the blockchain has not been compromised by the seed key holders. Redundant once the system is sufficiently decentralized

Depracated

Resources

PreviousModule 3. Protocol parameters and configuration filesNextByron genesis file

Last updated 1 year ago

Was this helpful?

See

repository contains the formal specifications, executable models, and implementations of the Cardano ledger.

Original implementation, Cardano-SL

Cardano ledger
Cardano improvement proposal 9
Cardano improvement proposal 28
Cardano improvement proposal 55
https://github.com/serokell/cardano-sl/blob/master/docs/configuration.md
https://iohk.io/en/blog/posts/2021/03/29/the-secure-transition-to-decentralization/
Page cover image