<p>At the moment I try out creating my own leveldb I understand.. The <code>chainstate</code> folder itself is the entry point of the database; all the files within it are just the data.</p>

<p>This is what the data looks like after I put some dummy data </p>

<p><a href="https://i.sstatic.net/2XMxD.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/2XMxD.png" alt="enter image description here"></a></p>

CC BY-SA 4.0
2018-10-20T11:18:05.893Z
If you want to add more information, please edit the question rather than posting an answer :)
meshcollider
CC BY-SA 4.0
2018-10-21T08:02:52.547Z
Apologies if this was intended as an answer, it didn't seem to fully address all the points of the question :)
meshcollider
CC BY-SA 4.0
2018-10-21T09:50:04.573Z
@MeshCollider np. :) Actually the 3 questions can be answered by this one. The separation of .ldb files has nothing to do with bitcoin, it's just the way leveldb stores the data. I hope this learning can help save others' time.
lzl124631x
CC BY-SA 4.0
2018-10-20T05:19:37.303Z
2018-10-20T05:19:37.303Z
lzl124631x
<p>Currently I could see <code>1418</code> ldb files on my box, from 210040.ldb to 215423.ldb (some missing).</p>

<ul>
<li>Why are they separated in this way?</li>
<li>I want to read the leveldb using golang, but I don't know which one should I use.</li>
<li>Can I load them altogether?</li>
</ul>

<leveldb>
why is bitcoin leveldb separated in so many small pieces?
lzl124631x
# why is bitcoin leveldb separated in so many small pieces?

(Asked by: username_0 on 2018-10-20)

Currently I could see `1418` ldb files on my box, from 210040.ldb to 215423.ldb (some missing).

* Why are they separated in this way?
* I want to read the leveldb using golang, but I don't know which one should I use.
* Can I load them altogether?

**Tags:** leveldb


---

## 1 answers

### Answer by username_0 on 2018-10-20. Score: 1

At the moment I try out creating my own leveldb I understand.. The `chainstate` folder itself is the entry point of the database; all the files within it are just the data.

This is what the data looks like after I put some dummy data

[![enter image description here](https://i.sstatic.net/2XMxD.png)](https://i.sstatic.net/2XMxD.png)

> **Comments:**
> **username_1**: If you want to add more information, please edit the question rather than posting an answer :)  
> **username_1**: Apologies if this was intended as an answer, it didn't seem to fully address all the points of the question :)  
> **username_0**: @MeshCollider np. :) Actually the 3 questions can be answered by this one. The separation of .ldb files has nothing to do with bitcoin, it's just the way leveldb stores the data. I hope this learning can help save others' time.  

---

