# Basic guidelines for using dremio docker

**URL:** <https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935>\
**Category:** Uncategorized\
**Created:** [September 26, 2018, 10:35pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935 "2018-09-26T22:35:16Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dave\_Campbell](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/dave_campbell/32/39_2.png) [@Dave\_Campbell](https://community.dremio.com/u/Dave_Campbell)\
**Post date:** [September 26, 2018, 10:35pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/1 "2018-09-26T22:35:16Z")

</div>

are there any basic guidelines for using the dremio docker image?

even like how to make configuration and user data persist from one run to the next?

i suppose it is a docker volume configuration, but not sure what the dremio path should be, etc.

---

<div class="post-metadata">

**Author:** ![nsen](https://avatars.discourse-cdn.com/v4/letter/n/c68b51/32.png) [@nsen](https://community.dremio.com/u/nsen)\
**Post date:** [September 27, 2018, 3:14am UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/2 "2018-09-27T03:14:39Z")

</div>

You will find some information in [https://github.com/dremio/containers](https://github.com/dremio/containers)

For a Dremio cluster in a single container, yes you can use docker volume configuration to persist the data locally. E.g.

`docker run --rm -v /tmp/dremio:/opt/dremio/data dremio/dremio-oss`

to have the local /tmp/dremio persist the data from dremio container.

Now, for a clustered deployment, the recommendation would be to look at the [helm chart](https://github.com/dremio/containers/tree/master/charts/dremio) to deploy Dremio a kubernetes managed environment. These are examples that you can take and adjust for your environment. For example, the memory and cpu in values.yaml should be adjusted to account for the resource availability in your kubernetes environment. And set path.dist to point to a distributed file store (note that requires [additional configuration](https://docs.dremio.com/deployment/distributed-storage.html) in Dremio).

---

<div class="post-metadata">

**Author:** ![Dave\_Campbell](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/dave_campbell/32/39_2.png) [@Dave\_Campbell](https://community.dremio.com/u/Dave_Campbell)\
**Post date:** [September 27, 2018, 2:57pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/3 "2018-09-27T14:57:57Z")

</div>

hmm…that didn’t seem to work.

i used the options you suggested (-v /tmp/dremio:/opt/dremio/data), making sure /tmp/dremio existed locally.

- brought up home page in browser

- registered an admin account

- logged in as that account

- logged out of that account

- stopped container

- nothing written to /tmp/dremio

- restarted container

- forced to create an admin account again

again, how do i persist the configuration and the user accounts?

---

<div class="post-metadata">

**Author:** ![nsen](https://avatars.discourse-cdn.com/v4/letter/n/c68b51/32.png) [@nsen](https://community.dremio.com/u/nsen)\
**Post date:** [September 27, 2018, 4:21pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/4 "2018-09-27T16:21:18Z")

</div>

hmm…just to make sure things haven’t changed, I tried it out and it worked. After the container is started and when stopped, the local /tmp/dremio should be like:

```auto
$ ls -l /tmp/dremio
total 0
drwxr-xr-x 5 nirmalyasen wheel 160 Sep 27 09:09 db
drwxr-xr-x 7 nirmalyasen wheel 224 Sep 27 09:04 pdfs
drwxr-xr-x 3 nirmalyasen wheel 96 Sep 27 09:09 zk

```

What is your OS? What is your Docker version? What is the image used by your container? Do you mind sharing your full docker run command?

---

<div class="post-metadata">

**Author:** ![Dave\_Campbell](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/dave_campbell/32/39_2.png) [@Dave\_Campbell](https://community.dremio.com/u/Dave_Campbell)\
**Post date:** [September 27, 2018, 8:51pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/5 "2018-09-27T20:51:50Z")

</div>

argh - i had a typo…"/opt/ **f** remio/data".  
fixed that and it works as you specified. sorry for that oversight.

thanks - this approach will really help me take some baby steps in looking at a dremio-class tool for experimentation and discovery.

---

<div class="post-metadata">

**Author:** ![mathew.lee](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/mathew.lee/32/1022_2.png) [@mathew.lee](https://community.dremio.com/u/mathew.lee)\
**Post date:** [November 19, 2018, 12:13am UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/6 "2018-11-19T00:13:25Z")

</div>

Hi @nsen,

Do you know if persistence is possible for Windows 7?

I’ve tried following the previous posts and end up with a:

Dremio is exiting. Failure while starting services.  
org.rocksdb.RocksDBException: While fsync: a directory: Invalid argument

docker@default:/dremio$ ls -l  
total 0  
drwxrwxrwx 1 docker staff 0 Nov 18 23:59 db  
drwxrwxrwx 1 docker staff 0 Nov 18 23:58 zk

OS: Windows 7  
Docker Version: Docker version 18.03.0-ce, build 0520e24302  
Image: dremio/dremio-oss  
run command: docker run --name dremio2 -p 9047:9047 -p 31010:31010 -p 45678:45678 -v /dremio:/opt/dremio/data dremio/dremio-oss

The folders zk and db make it to the folder on my laptops C:User/… drive but don’t make it to pdfs.

Any insight is greatly appreciated!

Thanks,  
Mathew

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [November 19, 2018, 2:08am UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/7 "2018-11-19T02:08:05Z")

</div>

Hi @mathew.lee

What type of mount are you writing your rocksDB to? The local or db parameter in your dremio.conf?

Thanks  
@balaji.ramaswamy

---

<div class="post-metadata">

**Author:** ![mathew.lee](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/mathew.lee/32/1022_2.png) [@mathew.lee](https://community.dremio.com/u/mathew.lee)\
**Post date:** [November 19, 2018, 4:59am UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/8 "2018-11-19T04:59:59Z")

</div>

Hi @balaji.ramaswamy,

How would I check on docker which type of mount I’m writing to? I apologize as I’m very new to docker and containers!

In addition, let me know if I should start another thread or post regarding this as well!

Thanks,  
Mathew

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [November 19, 2018, 4:54pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/9 "2018-11-19T16:54:36Z")

</div>

HI @mathew.lee

Look at your /etc/fstab or /etc/mtab and the options that go with it

Thanks  
@balaji.ramaswamy

---

<div class="post-metadata">

**Author:** ![mathew.lee](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/mathew.lee/32/1022_2.png) [@mathew.lee](https://community.dremio.com/u/mathew.lee)\
**Post date:** [November 20, 2018, 8:45pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/10 "2018-11-20T20:45:32Z")

</div>

@balaji.ramaswamy,

Hmm when I use:

docker exec -it -u root dremio1 bash

and try to cd into /etc/fstab or /etc/mtab, neither can be found.

Thanks for all the help!  
Mathew

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [January 17, 2019, 9:35pm UTC](https://community.dremio.com/t/basic-guidelines-for-using-dremio-docker/1935/11 "2019-01-17T21:35:52Z")

</div>

Sorry to ask again @mathew.lee, can you please provide the complete docker command you are using to start the Dremio container?
