# ブロック調査

これを確認したところで、ブロック生成ができるわけではないです。\
こちらの記事はあくまでメモ書きで（2021/5/29時点）、下記ソースの補足です。\
<https://github.com/AndrewWestberg/cncli/blob/develop/USAGE.md>

### cncli

リーダーになったブロックを生成できたか、ステータスを確認するコマンドの例

```
$ cncli validate --hash d5c6abb96b335e9f09f824e2c2fadab5bafcdcfb6f3a3822d138780bbead43c5
{
 "status": "ok",
 "block_number": "5781050",
 "slot_number": "30717956",
 "pool_id": "5c8751066db31d6745bc8a58ba1534de67a95f9962fc309b4673dd8c",
 "hash": "d5c6abb96b335e9f09f824e2c2fadab5bafcdcfb6f3a3822d138780bbead43c5",
 "prev_hash": "dd71b100eeb6647bc4fa8f720ee515dcf4f70dcfd625df4810dcce516bc7ddcb",
 "leader_vrf": "00013fa053635b868266ff41d3dcff149ec4d1a0673db13bf6ba51f84d9205efe33b29a397ee2c97102ca93c796192b0ce5d0ec3cf44358d236ee5ff72659a34"
}
```

pool\_id: 調べたいプールのid (自身のプールのid)\
status: okであることを確認します。

\
ここで、current （現在のエポック）でリーダになったスロットの１つを例に、インプットであるhashの探し方（一例）を記載します。

```
$ cncli leaderlog --byron-genesis ${NODE_HOME}/mainnet-byron-genesis.json --pool-id $(cat ${NODE_HOME}/stakepoolid.txt) --pool-vrf-skey ${NODE_HOME}/vrf.skey --shelley-genesis ${NODE_HOME}/mainnet-shelley-genesis.json --ledger-set current --tz Asia/Tokyo
...
    {
      "no": 8,
      "slot": 30717956,
      "slotInEpoch": 305156,
      "at": "2021-05-29T19:30:47+09:00"
    },
...

```

ステータスを確認したいslot番号を[エクスプローラ](https://explorer.cardano.org/ja)やPoolToolで検索（コマンドでは未確認）します。\
下記IDをhashの引数として使用します。

![](/files/-Mas61cAE7VH3b9Nx47N)

### PoolToolからみてorphanになった時

![](/files/-MbR57DtLbZonIaE8mDU)

プール情報のORPHANSタブから「Explore」を押すと詳細が表示されます。Block Numberを確認すると、同じ番号で生成を成功したプールが確認できます。

![](/files/-MbR5TZzFp2e6tyF4phh)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://sugar-stake-pool.gitbook.io/cardano-kb/cardano-node-operation/cncli.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
