Docker support is incredibly confusing

Status
Not open for further replies.

lukyjay

Contributor
Joined
May 13, 2016
Messages
134
The implementation of rancher / docker in FreeNAS 11.1 is not user friendly. The documentation provided is very minimal and gives no information on basic functions such as setting a static IP, accessing your datasets from a container and setting up a new container.

In Corral there was an interface within FreeNAS to manage docker containers. Will we see this return in 11.2?
 
Last edited by a moderator:

Allan Wilmath

Explorer
Joined
Nov 26, 2015
Messages
99
Will be interesting to see the response to this, as when Docker support will be integrated. Doing Docker in Ubuntu is pretty easy however. I used a Samba mount point in Ubuntu to mount my share and just a mapping between the docker container and Ubuntu in the Docker file you use when initializing the Docker container. Has been working pretty well.

I tried Boot2Docker and Rancher and was not impressed, seemed fundamentally broken. Ubuntu enjoys substantial online help and guides, which really can make the difference.

I don't know how hard it is to get Ubuntu running as a VM, shouldn't be that hard. I can post my Docker file and line in stab that I use to run Plex in a Ubuntu Docker container if that would help. I run FreeNAS virtualized on ESXi, with Ubuntu as a peer VM. Shouldn't make much difference if you run Ubuntu in bhyve on FreeNAS when it comes to the file sharing and Docker file required.
 

garm

Wizard
Joined
Aug 19, 2017
Messages
1,556
Running Ubuntu on FreeNAS is easy, but it’s a resource hog and really defeats the purpose unless you have an abundance of dedicated resources. While Ubuntu requires 25 GB system disk and 2 GB RAM a dedicated docker os will use less. For rancher I believe RAM is rated at 512 MB. On top of that you need what ever the containers require. So say you run plex, nextcloud and mysql. For a smal home build that would mean an extra 3-4 GB RAM and 2-3 cores dedicated to the VM. Now you just locked FreeNAS out of most of your CPU and bought yourself a lot of idle RAM.

I much rather buy the 4 gig of RAM and run my services in a jail (if they “have” to be on the NAS)
 

lukyjay

Contributor
Joined
May 13, 2016
Messages
134
I have 32gb of ram so not concerned about resource usage. I miss how easy it was to manage and set up dockers in Corral. Someone who's never used docker before could do it without documentation.

I wonder when docker containers themselves can be set up in the FreeNAS UI without the useless rancher interface?
 
Last edited by a moderator:

KrisBee

Wizard
Joined
Mar 20, 2017
Messages
1,288
I have 32gb of ram so not concerned about resource usage. I miss how easy it was to manage and set up dockers in Coral. Someone who's never used docker before could do it without documentation.

I wonder when docker containers themselves can be set up in the FreeNAS UI without the useless rancher interface?

So far FreeNAS 11.1. has only provided a "user friendly way" to download and start a Docker VM based on rancherOS to acts as a docker host. FreeNAS docs do show you how to get the rancher-server going, but I agree these docs are minimal and there are things you'd probably want to configure on the docker host before pulling and running the rancher-server and these are not covered. The FreeNAS docs may even give the mistaken impression that the use of the rancher-server is obligatory, it is not. You could use portainer for example as a way to manage your docker containers. But you'd still need to do some work at the CLI to set this up.

I think most people would argue that basing a "Docker VM" on rancheros rather than boot2docker, which was used in Corral, is technically superior and is far from useless. But rancheros is kind of "Linux, but not as we know it Jim" , so having to configure the rancheros based Docker host might be a challenge and not everyone will have the inclination to get to grips with the documentation at http://rancher.com/docs/os/v1.1/en/configuration/ etc.

One major piece of the puzzle that the FreeNAS docs gives no hint about is how docker containers running in a Virtual machine may access data in your zpool. If the FreeNAS devs decided to put all their docker eggs in the Rancher basket, you'd think they might have offered some guide/advice here. Obviously it must be done by network shares, but what is the best method? Did they assume you'd use the Rancher-NFS service available if you installed the rancher-server and configured via the RancherUI? There are alternatives.

As mentioned above, those familiar with Linux may have already taken the easy route of using docker-ce and docker-compose in their preferred distro by just using a traditional network mount which then maps to docker volumes as necessary. Their reaction to the new "Docker Vm" function in FreeNAS 11.1 maybe, so what?

For apps that need to access zpool data, jail performance will be better than dockerized apps but then not all apps can run in jails and some are just far easier to use as docker containers. Of course both jails and VMs consume resources, but I don't think it is correct say allocating CPUs to a VM results in "Now you just locked FreeNAS out of most of your CPU". As far as bhyve is concerned my basic understanding is that a virtual "CPU Core" roughly equates to a kernel-thread which then gets schedule across as many real cores as you have on your machine.
 
Last edited by a moderator:

LotLits

Dabbler
Joined
Apr 10, 2015
Messages
30
I was able to get docker setup and running following the FreeNAS 11.1 guide but couldn't get NFS functioning quite right, no matter how I set it up (using rancher-nfs). Part of this is probably how the shares are setup (1 share for each of the container's dataset) but I don't think I have a good grasp on how the services, storage, and such work together using the Rancher GUI. Probably need to read up on it more although it'll be nice once the documentation is updated and more how-tos start showing up.

I wish docker would get full support on FreeBSD though. Would probably make life a bit easier.
 
Last edited by a moderator:

lukyjay

Contributor
Joined
May 13, 2016
Messages
134
Not sure BSD will get proper support any time soon. My understanding is that Linux is better for that kind of thing. I don't know much about BSD though, I just know that ZFS works best on BSD according to this community.

They managed to get it working really well on Corral with a Linux VM, here's to hoping with a bit more time ix can do the same with FreeNAS 11.

I think that and the UI was Corral's biggest selling points and the reason the community grew when Corral came out but shrunk when it went away.
 
Last edited by a moderator:
D

dlavigne

Guest
The support for 11.1 was introductory, it will be more feature complete for 11.2.
 

KrisBee

Wizard
Joined
Mar 20, 2017
Messages
1,288
Last edited by a moderator:

KrisBee

Wizard
Joined
Mar 20, 2017
Messages
1,288

silverback

Contributor
Joined
Jun 26, 2016
Messages
134
I am hoping that a rancher-cifs Storage driver will be forthcoming. It would make persistent storage easier to handle on my system.
 

bodriye

Explorer
Joined
Mar 27, 2016
Messages
82
Yes, same here, not found the answer to getting Rancher-nfs to work with Freenas NFS server. Works fine in an all Linux environment as long as nfs exports have no_root_squash. Need to find time to see if reverting to nfsv3 works to avoid possible idmapping problems.

Others have resorted to using https://hub.docker.com/r/d3fk/nfs-client/ , e.g:

https://bmccarthy.net/2017/10/09/ra...to-stop-worrying-and-love-the-docker-compose/
Any idea how to add no_root_squash to export on FreeNAS?

edit: it seems set Map all users to root is the same as including the no_root_squash option.
 
Last edited by a moderator:

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
it seems set Map all users to root is the same as including the no_root_squash option.
Nope. maproot=root is the equivalent to no_root_squash

Patrick
 
Status
Not open for further replies.
Top