TrueNAS Stable Version Documentation
This content follows TrueNAS 25.04 (Fangtooth) releases.
Use the Product and Version selectors above to view content specific to a different software release.
Accessing NAS from VMs and Containers
6 minute read.
If you want to access your TrueNAS directories from within a virtual machine or container hosted on the system, you have multiple options:
Allow TrueNAS to create an automatic bridge (default)
If you have only one physical interface, you can manually create a bridge interface.
If you have more than one physical interface, you can assign a NIC other than the primary one your TrueNAS server uses. This method makes communication more flexible but does not offer the potential speed benefits of a bridge.
Containers allow you to configure a MACVLAN NIC, which creates a virtual interface based on an existing physical one. The assigned unique MAC address allows the instance to appear as a separate device on the network.
A MACVLAN NIC on the same physical interface as the TrueNAS host cannot directly communicate with the host. MACVLAN sends traffic directly to the external network without passing through the host network stack. The host does not recognize MACVLAN packets as local, so any traffic between them must be routed through an external switch, use a separate NIC, or use a network bridge.
Leave Use default network settings selected while creating a new instance to allow TrueNAS to automatically assign the default network bridge. This is the simplest way to allow communication between containers and the TrueNAS host.
If your system only has a single physical interface, and you prefer to manually configure a network bridge, complete these steps.
Before making network interface changes:
- Stop running apps.
- Power off running virtual machines (VMs) and containers.
- Remove active NIC devices for VMs and containers.
Sharing services such as SMB that use the IP address(s) assigned to the primary interface might cause issues with testing network changes. To resolve issues, stop sharing services such as SMB, change the interface, and test the connection. Restart the service when complete.
To set up a bridge interface:
Go to Network > Interfaces and find the active interface you want to use as the bridge parent interface. Note the interface IP Address and subnet mask. Click the interface to open the Edit Interface screen.
Clear the DHCP checkbox, if enabled. Note the IP address and mask under Aliases. Click the X next to the listed alias to remove the IP address and mask. The Aliases field now reads No items have been added yet. Click Save.
The Interfaces widget displays the edited interface without IP information.
Click Add to open the Add Interface screen. Select Bridge from the Type dropdown list. You cannot change the Type field value after clicking Save!
Enter a name for the interface. Use the correct format based on the interface type:
bondX* for a LAGG interface vlanX for a VLAN interface brx for a bridge interface
Where X is a number representing a non-parent interface. Assign the first bridge interface br0.
You cannot change the Name of the interface after clicking Save.
(Optional but recommended) Enter any notes or reminders about this particular bridge in Description.
Select the interfaces on the Bridge Members dropdown list.
Click Add to the right of Aliases to show the IP address fields, and enter the IP address for this bridge interface. Click Add again to show additional IP address fields for each additional IP address you want to add.
Click Save when finished. The created bridge shows in Interfaces with its associated IP address information.
Click Test Changes to determine if network changes are successful. See Testing Network Interface Changes
After TrueNAS finishes testing the interface, click Save Changes to keep the changes. Click Revert Changes to discard the changes and return to the previous configuration.
- To assign the bridge to a VM or container, go to Instances, select the instance you want to use to access TrueNAS storage, and locate the NIC widget. Click Add and select the new bridge interface from the dropdown list.
You can now access your TrueNAS storage from the container. You might have to set up shares or users with home directories to access certain files.
If you have more than one NIC on your system, you can assign container traffic to a secondary NIC. Configure the secondary interface as described in Managing Interfaces before attaching it to an instance.
If you are creating a new instance, use the Network settings to disable Use default network Settings and select the secondary NIC from Macvlan NICs.
To edit the NIC attached to an existing VM:
Go to Instances, select the instance you want to use to access TrueNAS storage, and locate the NIC widget.
Click Add and select the secondary interface from the MAC VLAN dropdown list.
















