Project

General

Profile

Feature #23393

Avatar?id=14398&size=50x50

Add ability to configure NFS passthrough into a Docker VM

Added by Kris Moore over 3 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Expected
Assignee:
Marcelo Araujo
Category:
Middleware
Target version:
Estimated time:
Severity:
Medium
Reason for Closing:
Not Applicable
Reason for Blocked:
Needs QA:
Yes
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:

Description

As part of our "Docker" strategy we've decided to embrace rancher / rancheros. We need a framework to do the following:

1) Deploy a pre-build rancherOS VM image

2) Configure NFS passthrough into the VM

3) Launch the rancher UI for docker management

More on this as we go.


Related issues

Related to FreeNAS - Bug #23357: Add ability to create Docker container in VM using RancherOSResolved2017-04-13

History

#1 Updated by Marcelo Araujo over 3 years ago

  • Status changed from Unscreened to Screened

#2 Avatar?id=14398&size=24x24 Updated by Kris Moore over 3 years ago

  • Target version changed from 9.10.4 to 11.1

#3 Updated by Marcelo Araujo over 3 years ago

  • Status changed from Screened to Fix In Progress

I'm working on that for a couple days already.

#4 Updated by Doug Dimick over 3 years ago

11124

This needs a closer look. Rancher is an inadequate replacement for Corral's Docker integration and is better suited for a devops environment than a user who just wants to get Crashplan working. Aside from concerns about running applications that use sqlite over NFS, and aside from the lack key features like being able to assign a dedicated IP address to a container from within the GUI, a standard installation, including Rancher-NFS, consists of 11 containers that consume over 1GB of RAM. And that's before the user creates any of their own containers.

[docker@rancher ~]$ cat /proc/meminfo
MemTotal:        4048464 kB
MemFree:         2091664 kB
MemAvailable:    2709072 kB
Buffers:           49760 kB
Cached:          1048772 kB
SwapCached:            0 kB
Active:          1147560 kB
Inactive:         698252 kB
Active(anon):     892088 kB
Inactive(anon):   149444 kB
Active(file):     255472 kB
Inactive(file):   548808 kB
Unevictable:           0 kB
Mlocked:               0 kB
SwapTotal:             0 kB
SwapFree:              0 kB
Dirty:                48 kB
Writeback:             0 kB
AnonPages:        739632 kB
Mapped:           213176 kB
Shmem:            294248 kB
Slab:              73368 kB
SReclaimable:      36600 kB
SUnreclaim:        36768 kB
KernelStack:        8864 kB
PageTables:         6184 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:     2024232 kB
Committed_AS:    3693972 kB
VmallocTotal:   34359738367 kB
VmallocUsed:           0 kB
VmallocChunk:          0 kB
HardwareCorrupted:     0 kB
AnonHugePages:    378880 kB
ShmemHugePages:        0 kB
ShmemPmdMapped:        0 kB
CmaTotal:              0 kB
CmaFree:               0 kB
HugePages_Total:       0
HugePages_Free:        0
HugePages_Rsvd:        0
HugePages_Surp:        0
Hugepagesize:       2048 kB
DirectMap4k:       57280 kB
DirectMap2M:     4136960 kB
[docker@rancher ~]$

#5 Updated by disk diddler over 3 years ago

Doug Dimick wrote:

This needs a closer look. Rancher is an inadequate replacement for Corral's Docker integration and is better suited for a devops environment than a user who just wants to get Crashplan working. Aside from concerns about running applications that use sqlite over NFS, and aside from the lack key features like being able to assign a dedicated IP address to a container from within the GUI, a standard installation, including Rancher-NFS, consists of 11 containers that consume over 1GB of RAM. And that's before the user creates any of their own containers.

[...]

I have no idea how to code, nor do I know a lot about docker but if Doug is right, well, I'm with Doug.
I'm not a fan of Corral but the concept of 'doing docker right' I like. Crashplan is frankly, a joke under FreeNAS 9 and not worth wasting time on. Is the intention to eventually replace plugins with Dockers, like Corral?
(Even if they work side by side, I'd really like full docker functionality, seeing as it's fairly easy to get working and the library of software is vast)

Finally, any particular reason we can't 'steal' the existing dockerVM from FreeNAS10? Presumably it ran thin and light and did the job?

Thanks all.

#6 Updated by Marcelo Araujo over 3 years ago

Doug Dimick wrote:

This needs a closer look. Rancher is an inadequate replacement for Corral's Docker integration and is better suited for a devops environment than a user who just wants to get Crashplan working. Aside from concerns about running applications that use sqlite over NFS, and aside from the lack key features like being able to assign a dedicated IP address to a container from within the GUI, a standard installation, including Rancher-NFS, consists of 11 containers that consume over 1GB of RAM. And that's before the user creates any of their own containers.

[...]

We are aware of that and we will provide a thin/light container option too.

Best,

#7 Updated by Educated Warrior over 3 years ago

From what I'm reading rancheros is like boot2docker but better. Both have a "minimal linux-based operating system for running Docker containers".. Thank you for doing good research on this. I jut wanted to express some issues I had in Corral; hopefully they will be non-issues your new implementation.

I've had issues in the past with these "minimal linux based" os. You cannot install pkgs on them because they don't have persistent storage. I may want to install additional packages to my docker server like git, puppet, docker-compose, wireshark etc. Will this be possible? Definitely need docker-compose installed?

Using boot2docker in Corral, I created a bug because the boot2docker image was tripping a snort rule on my router saying it was trojan horse infected. I was unable to install any pkgs on the vm to troubleshoot the issue. For production maintenance and troubleshooting, this is not good.

It would be nice to have an option to choose a standard linux vm image for the docker machine,

Another thing, corral had the functionality to use freenas metadata for creating freenas docker containers. Is this all going to the wayside and we will not have the ability to use all of the freenas docker images that were created for Corral?

#8 Updated by Educated Warrior over 3 years ago

Doug Dimick wrote:

This needs a closer look. Rancher is an inadequate replacement for Corral's Docker integration and is better suited for a devops environment than a user who just wants to get Crashplan working. Aside from concerns about running applications that use sqlite over NFS, and aside from the lack key features like being able to assign a dedicated IP address to a container from within the GUI, a standard installation, including Rancher-NFS, consists of 11 containers that consume over 1GB of RAM. And that's before the user creates any of their own containers.

[...]

Boot2docker has a smaller footprint than Rancher, but you couldn't install any packages on either of them because no package manager. It is confirmed rancheros doesn't have a package manager. This sucks. https://groups.google.com/forum/#!topic/rancherio/suoWW4n8Lms

#9 Updated by Alexandru Mirica over 3 years ago

Educated Warrior wrote:

Doug Dimick wrote:

This needs a closer look. Rancher is an inadequate replacement for Corral's Docker integration and is better suited for a devops environment than a user who just wants to get Crashplan working. Aside from concerns about running applications that use sqlite over NFS, and aside from the lack key features like being able to assign a dedicated IP address to a container from within the GUI, a standard installation, including Rancher-NFS, consists of 11 containers that consume over 1GB of RAM. And that's before the user creates any of their own containers.

[...]

Boot2docker has a smaller footprint than Rancher, but you couldn't install any packages on either of them because no package manager. It is confirmed rancheros doesn't have a package manager. This sucks. https://groups.google.com/forum/#!topic/rancherio/suoWW4n8Lms

boot2docker actually has a package manager. It's based on Tiny Core Linux, so it uses tce-load.
Also, it comes without persistent storage BY DEFAULT, but that can easily be changed. In recent versions, just having a hdd present in the VM during the boot2docker install will partition that hdd for persistent storage.

EDIT:
Regarding what Doug Dimick about assigning ip's to containers directly from the interface:
The Corral boot2docker VM had a buit-lin macvlan network which would attach directly to the network Corral was running on (it was called bridge in the Corral interface, which was a bit confusing since bridge networking in Docker is actually a completely different network than the one the host is on).

So, using the Docker command line or portainer we could create this macvlan network manually and assign said ip's, however I agree that having it built directly into the FN11 VM template would be ideal.

#10 Updated by Educated Warrior over 3 years ago

Marcelo, you are correct boot2docker has a package manager... I think I communicated incorrectly. I've tried using the package manager in the past but for some reason I'm not able to install some typical Linux packages on boot2docker and get them to work (due to kernel incompatibility as I recall)... and when I did get the install to work, I had to reinstall it everytime after reboot. If you can get persistent storage to work on boot2docker, that would be great.

#11 Updated by Dru Lavigne over 3 years ago

  • Status changed from Fix In Progress to 46

Kris: is this feature still slated for 11.1?

#12 Updated by Dru Lavigne over 3 years ago

  • Assignee changed from Marcelo Araujo to Kris Moore

#13 Avatar?id=14398&size=24x24 Updated by Kris Moore over 3 years ago

  • Status changed from 46 to Screened
  • Assignee changed from Kris Moore to Marcelo Araujo
  • Target version changed from 11.1 to 11.2-BETA1

With the updated timetable for 11.1 this will need to be pushed back to 11.1. Marcelo is still working on much of the bhyve backend which needs much love.

#14 Updated by Marcelo Araujo about 3 years ago

  • Status changed from Screened to Ready For Release

Hi All,

After months of tests and talks, we have decided to use RancherOS as the main system for our docker container.

Rancher brings a lot of advantages for containers, it has a nice UI called RancherUI and you can make an orchestration with lots of other containers just installing a simple agent.

Also soon Rancher 2.0 will bring great user experience with Kubernetes whether managing it using Rancher or existing Kubernetes clusters.

The feature was committed at: https://github.com/freenas/freenas/commit/829484373de48c310e544a72a5a67d4f52963ea0

#15 Updated by Tobias Müllauer about 3 years ago

wee. get so happy for this. i think you make a good decision for the future of freenas.

now when you have decided what to use. how long culd it take to implement this?
i am only curious =D

#16 Updated by Marcelo Araujo about 3 years ago

Tobias Müllauer wrote:

wee. get so happy for this. i think you make a good decision for the future of freenas.

now when you have decided what to use. how long culd it take to implement this?
i am only curious =D

Well, take the decision took more time, but to implement took something like 3 weeks.

#17 Avatar?id=13649&size=24x24 Updated by Ben Gadd almost 3 years ago

  • Status changed from Ready For Release to Done

#18 Updated by Dru Lavigne almost 3 years ago

  • Status changed from Done to Closed
  • Target version changed from 11.2-BETA1 to N/A
  • Severity set to Medium
  • Reason for Closing set to Duplicate

#19 Updated by Dru Lavigne almost 3 years ago

  • Is duplicate of Bug #23357: Add ability to create Docker container in VM using RancherOS added

#20 Updated by Dru Lavigne almost 3 years ago

  • Is duplicate of Bug #26773: [NEW UI/VM] Add Docker VM in the new UI. added

#21 Updated by Dru Lavigne almost 3 years ago

  • Is duplicate of deleted (Bug #23357: Add ability to create Docker container in VM using RancherOS)

#22 Updated by Dru Lavigne almost 3 years ago

  • Related to Bug #23357: Add ability to create Docker container in VM using RancherOS added

#23 Updated by Dru Lavigne almost 3 years ago

  • Is duplicate of deleted (Bug #26773: [NEW UI/VM] Add Docker VM in the new UI.)

#24 Updated by Dru Lavigne almost 3 years ago

  • Related to Bug #26773: [NEW UI/VM] Add Docker VM in the new UI. added

#25 Updated by Dru Lavigne almost 3 years ago

  • Subject changed from Docker Container Framework to Add ability to configure NFS passthrough into a Docker VM
  • Status changed from Closed to In Progress
  • Target version changed from N/A to 11.2-RC2

Renaming to catch the NFS pass-through piece.

#26 Updated by Marcelo Araujo almost 3 years ago

Dru Lavigne wrote:

Renaming to catch the NFS pass-through piece.

I think we can close this ticket, nothing stops users to setup the NFS with RancherOS.

#27 Updated by Dru Lavigne almost 3 years ago

  • Status changed from In Progress to Closed
  • Target version changed from 11.2-RC2 to N/A
  • Reason for Closing changed from Duplicate to Not Applicable

#28 Avatar?id=13649&size=24x24 Updated by Ben Gadd over 2 years ago

  • Related to deleted (Bug #26773: [NEW UI/VM] Add Docker VM in the new UI.)

Also available in: Atom PDF