Understanding your configuration files and how to use them 構成ファイルとその使用方法について(編集中)

徒然草2.0

構成ファイルとその使用方法について

The topology.json file
topology.jsonファイル
Tells your node to which nodes in the network it should talk to. A minimal version of this file looks like this:
ネットワーク内のどのノードと通信するかをノードに伝えます。このファイルの最小バージョンは次のようになります。

{
  "Producers": [
    {
      "addr": "x.x.x.x",
      "port": 3001,
      "valency": 1
    }
  ]
}

This means that your node will contact node at ip x.x.x.x on port 3001.
これは、ノードがポート3001のip x.x.x.xでノードに接続することを意味します。

valency tells the node how many connections your node should have. It only has an effect for dns addresses. If a dns address is given, valency governs to how many resolved ip addresses should we maintain active (hot) connection; for ip addresses, valency is used as a boolean value, where 0 means to ignore the address.
valencyは、ノードに必要な接続数をノードに通知します。 DNSアドレスに対してのみ効果があります。 DNSアドレスが指定されている場合、価数は、アクティブ(ホット)接続を維持する必要がある解決済みIPアドレスの数に影響します。 IPアドレスの場合、valencyはブール値として使用されます。0はアドレスを無視することを意味します。

Your block-producing node must ONLY talk to your relay nodes, and the relay node should talk to other relay nodes in the network. Go to our telegram channel to find out IP addresses and ports of peers.
ブロック生成ノードはリレーノードとのみ通信し、リレーノードはネットワーク内の他のリレーノードと通信する必要があります。テレグラムチャネルにアクセスして、ピアのIPアドレスとポートを確認します。

The genesis.json file
Genesis.jsonファイル

The genesis file is generated with the cardano-cli by reading a genesis.spec.json file, which is out of scope for this document. But it is important because it is used to set:
Genesisファイルは、このドキュメントの範囲外であるgenesis.spec.jsonファイルを読み取ることにより、cardano-cliで生成されます。ただし、次の設定に使用されるため、重要です。

genDelegs, a mapping from genesis keys to genesis delegates.
genDelegs、ジェネシスキーからジェネシスデリゲートへのマッピング。
initialFunds, a mapping from the initial addresses to the initial values at those address.
initialFunds、初期アドレスからそれらのアドレスの初期値へのマッピング。
MaxLovelaceSupply, the total amount of lovelaces in the blockchain.
MaxLovelaceSupply、ブロックチェーン内のラブレースの合計量。
startTime, the time of slot zero.
startTime、スロット0の時間。

The genesis.json file looks like the one below.
Genesis.jsonファイルは、次のようになります。

{ “activeSlotsCoeff”: 0.05, “protocolParams”: { “protocolVersion”: { “minor”: 0, “major”: 2 }, “decentralisationParam”: 1, “eMax”: 18, “extraEntropy”: { “tag”: “NeutralNonce” }, “maxTxSize”: 16384, “maxBlockBodySize”: 65536, “maxBlockHeaderSize”: 1100, “minFeeA”: 44, “minFeeB”: 155381, “minUTxOValue”: 1000000, “poolDeposit”: 500000000, “minPoolCost”: 340000000, “keyDeposit”: 2000000, “nOpt”: 150, “rho”: 0.003, “tau”: 0.20, “a0”: 0.3 }, “genDelegs”: { “ad5463153dc3d24b9ff133e46136028bdc1edbb897f5a7cf1b37950c”: { “delegate”: “d9e5c76ad5ee778960804094a389f0b546b5c2b140a62f8ec43ea54d”, “vrf”: “64fa87e8b29a5b7bfbd6795677e3e878c505bc4a3649485d366b50abadec92d7” }, “b9547b8a57656539a8d9bc42c008e38d9c8bd9c8adbb1e73ad529497”: { “delegate”: “855d6fc1e54274e331e34478eeac8d060b0b90c1f9e8a2b01167c048”, “vrf”: “66d5167a1f426bd1adcc8bbf4b88c280d38c148d135cb41e3f5a39f948ad7fcc” }, “60baee25cbc90047e83fd01e1e57dc0b06d3d0cb150d0ab40bbfead1”: { “delegate”: “7f72a1826ae3b279782ab2bc582d0d2958de65bd86b2c4f82d8ba956”, “vrf”: “c0546d9aa5740afd569d3c2d9c412595cd60822bb6d9a4e8ce6c43d12bd0f674” }, “f7b341c14cd58fca4195a9b278cce1ef402dc0e06deb77e543cd1757”: { “delegate”: “69ae12f9e45c0c9122356c8e624b1fbbed6c22a2e3b4358cf0cb5011”, “vrf”: “6394a632af51a32768a6f12dac3485d9c0712d0b54e3f389f355385762a478f2” }, “162f94554ac8c225383a2248c245659eda870eaa82d0ef25fc7dcd82”: { “delegate”: “4485708022839a7b9b8b639a939c85ec0ed6999b5b6dc651b03c43f6”, “vrf”: “aba81e764b71006c515986bf7b37a72fbb5554f78e6775f08e384dbd572a4b32” }, “2075a095b3c844a29c24317a94a643ab8e22d54a3a3a72a420260af6”: { “delegate”: “6535db26347283990a252313a7903a45e3526ec25ddba381c071b25b”, “vrf”: “fcaca997b8105bd860876348fc2c6e68b13607f9bbd23515cd2193b555d267af” }, “268cfc0b89e910ead22e0ade91493d8212f53f3e2164b2e4bef0819b”: { “delegate”: “1d4f2e1fda43070d71bb22a5522f86943c7c18aeb4fa47a362c27e23”, “vrf”: “63ef48bc5355f3e7973100c371d6a095251c80ceb40559f4750aa7014a6fb6db” } }, “updateQuorum”: 5, “networkId”: “Mainnet”, “initialFunds”: {}, “maxLovelaceSupply”: 45000000000000000, “networkMagic”: 764824073, “epochLength”: 432000, “systemStart”: “2017-09-23T21:44:51Z”, “slotsPerKESPeriod”: 129600, “slotLength”: 1, “maxKESEvolutions”: 62, “securityParam”: 2160 }

Here is a brief description of each parameter. You can learn more in the spec
以下は、各パラメーターの簡単な説明です。あなたはスペックでもっと学ぶことができます。

The config.json file
config.jsonファイル
The default config.json file that we downloaded is shown below.
ダウンロードしたデフォルトのconfig.jsonファイルを以下に示します。

This file has 4 sections that allow you to have full control on what your node does and how the informtion is presented.
このファイルには4つのセクションがあり、ノードの動作と情報の表示方法を完全に制御できます。

NOTE Due to how the config.json file is generated, fields on the real file are shown in a different (less coherent) order. Here we present them in a more structured way
注config.jsonファイルの生成方法により、実際のファイルのフィールドは、異なる(一貫性の低い)順序で表示されます。ここでは、それらをより構造化された方法で提示します

Basic Node Configuration. 基本的なノード構成。
First section relates the basic node configuration parameters. Make sure you have to TPraosas the protocol, the correct path to the mainnet-shelley-genesis.json file, RequiresMagicfor its use in a testnet. Note that in this example we are using the SimpleView. This will send the output to stdout. Other option is LiveView which uses a terminal multiplexer to generate a fancy view. We will cover this topic later.
最初のセクションは、基本的なノード構成パラメーターに関連しています。プロトコルをTPraosasする必要があることを確認してください。mainnet-shelley-genesis.jsonファイルへの正しいパス、テストネットでの使用には、RequiresMagicが必要です。この例ではSimpleViewを使用していることに注意してください。これにより、出力がstdoutに送信されます。その他のオプションは、ターミナルマルチプレクサを使用してファンシービューを生成するLiveViewです。このトピックについては後で説明します。

{
  "Protocol": "TPraos",
  "GenesisFile": "mainnet-shelley-genesis.json",
  "RequiresNetworkMagic": "RequiresMagic",

Update parameteres
パラメータを更新する
This protocol version number gets used by block producing nodes as part of the system for agreeing on and synchronising protocol updates.You just need to be aware of the latest version supported by the network. You dont need to change anything here.
このプロトコルのバージョン番号は、プロトコルの更新に同意して同期するためのシステムの一部として、ブロックを生成するノードによって使用されます。ネットワークでサポートされている最新バージョンに注意する必要があります。ここでは何も変更する必要はありません。

  "ApplicationName": "cardano-sl",
  "ApplicationVersion": 0,
  "LastKnownBlockVersion-Alt": 0,
  "LastKnownBlockVersion-Major": 0,
  "LastKnownBlockVersion-Minor": 0,

Tracing
Tracers tell your node what information you are interested in when logging. Like switches that you can turn ON or OFF according the type and quantity of information that you are interesetd in. This provides fairly coarse grained control, but it is relatively efficient at filtering out unwanted trace output.
トレース
トレーサーは、ロギング時にどの情報に関心があるかをノードに伝えます。関心のある情報の種類と量に応じてオンまたはオフにできるスイッチと同様に、これはかなり粗い制御を提供しますが、不要なトレース出力を比較的効率的に除外します。

The node can run in either the SimpleView or LiveView. The SimpleView just uses standard output, optionally with log output. The LiveView is a text console with a live view of various node metrics.
ノードはSimpleViewまたはLiveViewで実行できます。 SimpleViewは標準出力を使用し、オプションでログ出力を使用します。 LiveViewは、さまざまなノードメトリックのライブビューを備えたテキストコンソールです。

TurnOnLogging: Enbles or disables logging overall.
TurnOnLogging:ロギング全体を有効または無効にします。

TurnOnLogMetrics: Enable the collection of various OS metrics such as memory and CPU use. These metrics can be directed to the logs or monitoring backends.
TurnOnLogMetrics:メモリやCPUの使用など、さまざまなOSメトリックの収集を有効にします。これらの指標は、ログまたは監視バックエンドに送信できます。

setupBackends, defaultBackends, hasEKGand hasPrometheus: The system supports a number of backends for logging and monitoring. This settings list the the backends available to use in the configuration. The logging backend is called Katip. Also enable the EKG backend if you want to use the EKG or Prometheus monitoring interfaces.
setupBackends、defaultBackends、hasEKGand hasPrometheus:システムは、ロギングとモニタリングのためにいくつかのバックエンドをサポートしています。この設定には、構成で使用できるバックエンドが一覧表示されます。ロギングバックエンドはKatipと呼ばれます。 EKGまたはPrometheusモニタリングインターフェイスを使用する場合は、EKGバックエンドも有効にします。

setupScribes and defaultScribes: For the Katip logging backend we must set up outputs (called scribes) The available types of scribe are:
setupScribesとdefaultScribes:Katipロギングバックエンドの場合、出力を設定する必要があります(スクライブと呼ばれます)。使用可能なスクライブのタイプは次のとおりです。

FileSK: for files
FileSK:ファイル用

StdoutSK/StderrSK: for stdout/stderr
StdoutSK/StderrSK:stdout/stderrの場合

JournalSK: for systemd’s journal system
JournalSK:systemdのジャーナルシステム用

DevNullSK
DevNullSK

The scribe output format can be ScText or ScJson.
スクライブ出力形式は、ScTextまたはScJsonです。

rotation The default file rotation settings for katip scribes, unless overridden in the setupScribes above for specific scribes.
rotation特定のスクライブについて上記のsetupScribesでオーバーライドされない限り、katipスクライブのデフォルトのファイルローテーション設定。

  "TurnOnLogging": true,
  "TurnOnLogMetrics": true,
  "ViewMode": "SimpleView",
  "TracingVerbosity": "NormalVerbosity",
  "minSeverity": "Debug",
  "TraceBlockFetchClient": false,
  "TraceBlockFetchDecisions": false,
  "TraceBlockFetchProtocol": false,
  "TraceBlockFetchProtocolSerialised": false,
  "TraceBlockFetchServer": false,
  "TraceChainDb": true,
  "TraceChainSyncBlockServer": false,
  "TraceChainSyncClient": false,
  "TraceChainSyncHeaderServer": false,
  "TraceChainSyncProtocol": false,
  "TraceDNSResolver": true,
  "TraceDNSSubscription": true,
  "TraceErrorPolicy": true,
  "TraceForge": true,
  "TraceHandshake": false,
  "TraceIpSubscription": true,
  "TraceLocalChainSyncProtocol": false,
  "TraceLocalErrorPolicy": true,
  "TraceLocalHandshake": false,
  "TraceLocalTxSubmissionProtocol": false,
  "TraceLocalTxSubmissionServer": false,
  "TraceMempool": true,
  "TraceMux": false,
  "TraceTxInbound": false,
  "TraceTxOutbound": false,
  "TraceTxSubmissionProtocol": false,
  "setupBackends": [
    "KatipBK"
  ],
  "defaultBackends": [
    "KatipBK"
  ],
  "hasEKG": 12788,
  "hasPrometheus": [
    "127.0.0.1",
    12798
  ],
  "setupScribes": [
    {
      "scFormat": "ScText",
      "scKind": "StdoutSK",
      "scName": "stdout",
      "scRotation": null
    }
  ],
  "defaultScribes": [
    [
      "StdoutSK",
      "stdout"
    ]
  ],
  "rotation": {
    "rpKeepFilesNum": 10,
    "rpLogLimitBytes": 5000000,
    "rpMaxAgeHours": 24
    },
徒然草2.0
スポンサーリンク
シェアする
gomiryoをフォローする
ごみぶろぐ

コメント

タイトルとURLをコピーしました