User Tools

Site Tools


Setup Guide - Esxi 6.5 + Nested FreeNAS + Docker Containers

Created: 03/23/2017

Last Tested 03/23/2017

<color #ff7f27>Notice:</color> I am going to assume that you have ESXI and a FreeNAS vm installed at base stock settings. This guide will show you the settings needed to make FreeNAS *vms* and *docker containers* receive a network connection from your DHCP server.

Setting the FreeNAS vm to have Hardware virtualization support form the ESXI host cpu.

For this part please open your esxi host in the web configurator https://IPOFSERVER/ui/.

  1. Power Down your FreeNAS vm and click edit on the vm.
  2. Expand the CPU section
  3. Place a Tick next to: <color #ffc90e>Hardware virtualization</color>, <color #ffc90e>Performance counters</color>
  4. Save and close the vm settings page.

Setting up Vswitch network used for FreeNAS

In this section we will edit the Vswitch that will provide FreeNAS vms and docker containers a network connection. For this I use the VSphere client to make the edits. My FreeNAS vm and its nested vms are using the same network interface witch is located on the Vswitch 0 in ESXI.

  1. Find the vSwitch that corresponds to your FreeNAS install to where the vms and docker containers are running.
  2. Select Properties
  3. Click on EDIT for the Virtual Machine Port Group
  4. Select the Security tab

Although it might not be needed for each I did it anyways.

CHECK, ALLOW - Promiscuous Mode
CHECK, ALLOW - MAC Address Changes
CHECK, ALLOW - Forged Transmits

Booting up FreeNAS and Setting up Networking

Here we will boot FreeNAS and setup networking. My steps below assume that you are logged into FreeNAS under the root user and have no current vms or docker containers loaded.

  1. Set static ipv4 to the FreeNAS server
  2. (Network - vmx0)
  3. Uncheck DHCP
  4. Type in the static ipv4 that you are wanting Example: and Subnet
  5. Save the settings

<color #22b14c»»»> </color>

  1. Check and make sure that the Gateway is setup properly
  2. (Network - Settings)
  3. Verify ipv4 under (Gateway Settings)
  4. if it is wrong and needs to be changes untick (Assign Gateway) and manually enter the proper one.

FreeNAS Setting up Docker Host

I like to setup a storage location and decide where my vms will be stored. I have 2 SSD's of equal size in raid-0 config.

  1. Head over to (Docker + Docker Host) Press the (+) button to add a new Host.
  2. Add a name to the Docker Host
  3. CPU Cores - Add the quantity that you feel is necessary *Make sure you have the numbers of cores assigned to the FreeNAS vm in esxi.
  4. Memory - I set 3GB for Plex. *Make sure you leave some for the FreeNAS os and you have enough provisioned to the FreeNAS vm in esxi.
  5. Datastore - This is where on what array you want to store the docker vm files. I use SSD storage locations.
  6. Click on SAVE

FreeNAS Setting up Plex container

This is the last and final step! WOO! So here I currently have a plex server setup as you can see form my screen shot below. Altho Im going to run through this as if I didn't so lets begin.

  1. Head over to (Docker + Containers) Press the (+) button to add a new Container.
  2. Scroll through the list to find the plex image and then click it.
  3. Give your plex docker container a name.
  4. Docker host: Select the one that you made above or just leave as default for auto select.
  5. Expose ports: ticked
  6. Ports: These are pre configured and don't need to be changed.
  7. Volumes: If you intend to use media stored on your FreeNAS box press the ( + ) button here. You will then want to set the following.
    Type: host
    Path: ''set this to your directory for your plex data''
    Container Path: /media  ''this is a good location and isn't used by default''
  8. Environment variables: These are pre configured and don't need to be changed.
  9. Networking Settings: -
    • Primary Network: Set this to Bridged
    • DHCP: If you want DHCP then tick if not then input a ipv4 address that you want to use below.
    • Mac Address: press {Generate}
    • Networks: leave this blank
  10. Advanced: -
    • Hostname: If you wish to set a hostname do it here.
    • Memory Limit: Set one if you wish.
    • Interactive: unticked
    • Privileged: unticked
    • Autostart: ticked
    • Command: leave this blank
  11. Press SAVE
  12. Now press Web UI at the top and plex should open.

Any questions please let me know:

sesipod/linux/esxi/free10.txt · Last modified: 2022/07/02 05:57 (external edit)