# Bulk load to initial multi host cluster

**URL:** <https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593>\
**Category:** Users\
**Created:** [June 10, 2019, 10:18am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593 "2019-06-10T10:18:14Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![explorer](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/explorer/32/1853_2.png) [@explorer](https://discuss.dgraph.io/u/explorer)\
**Post date:** [June 10, 2019, 10:18am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/1 "2019-06-10T10:18:14Z")

</div>

Hi, I load data into a initial cluster(1 zero and 3 alpha in multi host native ) by dgraph bulk ,and then i can find the schema and data from ratel,but the zero node dosen’t rebalance ,all the data is only on the original load node, what should i do in this case?  
zero parameters:  
./dgraph zero --idx 2 --my:IP:PORT --replicas 3 --telemetry  
bulk load parameters:  
–reduce\_shards 1 --map\_shards 3

---

<div class="post-metadata">

**Author:** ![MichelDiz](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/micheldiz/32/11873_2.png) [@MichelDiz](https://discuss.dgraph.io/u/MichelDiz)\
**Post date:** [June 10, 2019, 3:01pm UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/2 "2019-06-10T15:01:39Z")

</div>

Dgraph has its own rules of balancing. It will do it as soon as it is needed. But check in [http://localhost:6080/state](http://localhost:6080/state) which groups are serving the predicates.

---

<div class="post-metadata">

**Author:** ![explorer](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/explorer/32/1853_2.png) [@explorer](https://discuss.dgraph.io/u/explorer)\
**Post date:** [June 11, 2019, 5:21am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/3 "2019-06-11T05:21:45Z")

</div>

Fine, Does it mean if i bulk load data into node with a large disk capacity ,and the dataset is not enough large to trigger the rebalancing rules , all the data will on the original load node no matter what i do?

---

<div class="post-metadata">

**Author:** ![MichelDiz](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/micheldiz/32/11873_2.png) [@MichelDiz](https://discuss.dgraph.io/u/MichelDiz)\
**Post date:** [June 11, 2019, 1:59pm UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/4 "2019-06-11T13:59:30Z")

</div>

Please, check [Get started with Dgraph](https://docs.dgraph.io/deploy/#understanding-dgraph-cluster)  
In the part “Shard rebalancing”.

You can also try to push tablets to other groups

> **[Get started with Dgraph](https://dgraph.io/docs)**
>
> From learning the basics of graph databases to advanced functions and capabilities, Dgraph docs have the information you need.

> - `/moveTablet?tablet=name&group=2` This endpoint can be used to move a tablet to a group. Zero already does shard rebalancing every 8 mins, this endpoint can be used to force move a tablet.

---

<div class="post-metadata">

**Author:** ![explorer](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/explorer/32/1853_2.png) [@explorer](https://discuss.dgraph.io/u/explorer)\
**Post date:** [June 12, 2019, 4:06am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/5 "2019-06-12T04:06:15Z")

</div>

Thanks for your reply.  
Another thing,if i have a massive datasets (may be more than 1TB and about 1 billion edge) which need to bulk load into the cluster, Do I have to load them in one Node? Can I split the datasets to other zero node to bulk load at the same time?  
I only find one blog about the bulk load details : [Loading close to 1M edges/sec into Dgraph](https://blog.dgraph.io/post/bulkloader/) , and official documents [deploy/#bulk-loader](https://docs.dgraph.io/deploy/#bulk-loader) doesn’t mention the multi-zero instance case.  
Could you provide more detail about interaction mechanism between zero instance when bulk load in multi-zero instances case

---

<div class="post-metadata">

**Author:** ![dmai](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/dmai/32/1254_2.png) [@dmai](https://discuss.dgraph.io/u/dmai)\
**Post date:** [June 12, 2019, 6:10am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/6 "2019-06-12T06:10:09Z")

</div>

Currently bulk loader runs only on a single machine. In the soon-to-be-released Dgraph v1.1 we optimized both the live loader and bulk loader—in our own tests we’ve seen bulk loader peak to 4 million edges/sec.

A multi-Zero setup does not make a difference for bulk loading. Bulk loader (must) connect to the **Zero leader** to assign UIDs to the nodes in the cluster. Adding more Zero instances doesn’t make the loading process any faster. Most of the work is done by bulk loader itself, not by Zero.

Bulk loader is highly concurrent, so more CPU cores would definitely help speed up the bulk loading process.

---

<div class="post-metadata">

**Author:** ![explorer](https://yyz1.discourse-cdn.com/flex007/user_avatar/discuss.dgraph.io/explorer/32/1853_2.png) [@explorer](https://discuss.dgraph.io/u/explorer)\
**Post date:** [June 12, 2019, 7:23am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/7 "2019-06-12T07:23:20Z")

</div>

Very useful to solve my problem thanks you !

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex007/uploads/dgraph/original/2X/2/2b38fdece2abe5814f2e51bee69d1e67fc304b0a.png) [@system](https://discuss.dgraph.io/u/system)\
**Post date:** [July 12, 2019, 7:23am UTC](https://discuss.dgraph.io/t/bulk-load-to-initial-multi-host-cluster/4593/8 "2019-07-12T07:23:21Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
