Tenno
Tenno

Reputation: 11

How to read a ledger file of a local Hyperledger Fabric?

I have already start a local Fabric network 2.2 by following the official guide (fabcar project). This is the output of docker ps -a: docker ps

Now, I have these questions:

  1. Where is the ledger file which stores the transaction history?
  2. How can I see the historical transactions and the created blocks?

I have read the doc in Fabric Website, that doesn't really help.

Upvotes: -1

Views: 675

Answers (1)

kekomal
kekomal

Reputation: 2200

  1. Ledger data is under /var/hyperledger/production/ledgersData inside your peer container. You might have /var/hyperledger/production mapped to a volume to save your peer state. When using CouchDB to store world state, the world state is stored in the CouchDB container (under something like /opt/couchdb/data, which might be mapped to a volume, too).

  2. In my opinion, the easiest way is to deploy Hyperledger Explorer for your network: https://github.com/hyperledger/blockchain-explorer/blob/main/README.md.

Upvotes: 1

Related Questions