Register for the iXsystems Community to get an ad-free experience and exclusive discounts in our eBay Store.

No network in jail after upgrade to FreeNAS 11

fillg1

Member
Joined
Dec 14, 2014
Messages
28
Hi folks
I just upgraded to from 9.10 to FreeNAS 11 and noticed that my old portjail has no working network anymore.

ifconfig shows

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
inet 127.0.0.1 netmask 0xff000000
nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
epair0b: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=8<VLAN_MTU>
ether 02:4b:da:00:09:0b
inet6 fe80::4b:daff:fe00:90b%epair0b prefixlen 64 scopeid 0x2
inet6 2a02:908:1d0:ab00:4b:daff:fe00:90b prefixlen 64 autoconf
nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active


A new created jail seems to work (all defaults and DHCP)

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
inet 127.0.0.1 netmask 0xff000000
nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
groups: lo
epair1b: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=8<VLAN_MTU>
ether 92:94:80:0d:00:6d
inet 192.168.42.41 netmask 0xffffff00 broadcast 192.168.42.255
inet6 2a02:908:e348:7d00::1 prefixlen 64 tentative
nd6 options=9<PERFORMNUD,IFDISABLED>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair


Any hints?
 
D

dlavigne

Guest
Do you get any errors if you dhclient epair0b? (Note that you may have to killall dhclient first).
 

fillg1

Member
Joined
Dec 14, 2014
Messages
28
strange
Code:
root@port:/ # dhclient epair0b
ifconfig: ioctl (SIOCAIFADDR): Invalid argument
epair0b: not found
exiting.
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,352
strange
Code:
root@port:/ # dhclient epair0b
ifconfig: ioctl (SIOCAIFADDR): Invalid argument
epair0b: not found
exiting.
This could be a major abi change going from freebsd 10 to 11. We should test this to know for sure but you should consider rebuilding your jails. New jails is a better solution.

Sent from my Nexus 5X using Tapatalk
 

gleggate

Newbie
Joined
Jun 15, 2017
Messages
1
Stumbled across this issue as I'm having the same issue with 3 out of 4 jails. I tried switching the interface from static IP to DHCP but I'm getting the same result as fillg1.
 

Erich

Junior Member
Joined
Jan 10, 2014
Messages
14
I can report exactly the same behaviour (3 out of 6 jails), FreeNAS box went from 10.3 to 11.0-U2.

Also tried DHCP manually and via jail restart but no success.

The jails which stay offline are the same ones each time. They are of mixed types, portjails and Standard, which doesn't matter in their ability to get network.
 

albrandwood

Neophyte
Joined
Jun 15, 2014
Messages
4
I don't know if this will help ... but it worked for me ...

SSH to freenas (or use the java terminal) and sudo to root. Navigate to the Jails dataset (in my case /mnt/Data/Jails). There you will find the .<jailname>.meta folder ... in there is a file called "vnet". Removing this file, appears to have resolved my jail network issues. then just restart the jail. It should start working again. (And no, I don't know what the vnet file does, as my jails were created 3 years ago!)

Code:
freenas$ sudo su -
Password:
ssh user@freenas
user@freenas's password:
Welcome to FreeNAS
freenas$ cd /mnt/Data/Jails/
freenas$ ls -al
total 15
drwxr-xr-x  16 root  wheel  17 Aug 30 22:33 .
drwxr-xr-x  16 root  wheel  17 Aug 30 20:45 ..
drwxr-xr-x   2 root  wheel  18 Aug 30 20:46 .DB.meta
drwxr-xr-x  19 root  wheel  21 Jun 15  2014 DB
freenas$ sudo su rm -f /mnt/Data/Jails/.DB.meta/vnet
Password:


If not, the quick hack solution ... This will get your jail back online, albeit not on startup.

Code:
IFACE=`ifconfig | egrep ^epair[0-9]b | cut -d: -f1`
ifconfig $IFACE 192.168.xxx.yyy
route add default 192.168.xxx.1 -interface $IFACE


@
 
Last edited:

IceBoosteR

Senior Member
Joined
Sep 27, 2016
Messages
503

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,352
I don't know if this will help ... but it worked for me ...

SSH to freenas (or use the java terminal) and sudo to root. Navigate to the Jails dataset (in my case /mnt/Data/Jails). There you will find the .<jailname>.meta folder ... in there is a file called "vnet". Removing this file, appears to have resolved my jail network issues. then just restart the jail. It should start working again. (And no, I don't know what the vnet file does, as my jails were created 3 years ago!)

Code:
freenas$ sudo su -
Password:
ssh user@freenas
user@freenas's password:
Welcome to FreeNAS
freenas$ cd /mnt/Data/Jails/
freenas$ ls -al
total 15
drwxr-xr-x  16 root  wheel  17 Aug 30 22:33 .
drwxr-xr-x  16 root  wheel  17 Aug 30 20:45 ..
drwxr-xr-x   2 root  wheel  18 Aug 30 20:46 .DB.meta
drwxr-xr-x  19 root  wheel  21 Jun 15  2014 DB
freenas$ sudo su rm -f /mnt/Data/Jails/.DB.meta/vnet
Password:


If not, the quick hack solution ... This will get your jail back online, albeit not on startup.

Code:
IFACE=`ifconfig | egrep ^epair[0-9]b | cut -d: -f1`
ifconfig $IFACE 192.168.xxx.yyy
route add default 192.168.xxx.1 -interface $IFACE


@
Do not just delete files that you don't understand. Someone way smarter than you decided it needed it be there.

If you want to disable vimage you turn that off in the gui, you can do the same for vnat.
 

bed

Member
Joined
Jun 17, 2011
Messages
38
I think I may be victim to the same issue. I am getting ready to buy new hardware and do a fresh build as its been ages since I upgraded my freenas.
So far I have built a development freenas in a vmware VM with a fresh install of of freenas 11U4 and created 2 jails. Both have static IP's. The jails can ping each other but only one of them can ping the host and neither of them can ping the gateway.
After 2 days of researching I finally ended up here. I hope someone can help shed some light on this for me.
Thanks/
 

IceBoosteR

Senior Member
Joined
Sep 27, 2016
Messages
503
I think I may be victim to the same issue. I am getting ready to buy new hardware and do a fresh build as its been ages since I upgraded my freenas.
So far I have built a development freenas in a vmware VM with a fresh install of of freenas 11U4 and created 2 jails. Both have static IP's. The jails can ping each other but only one of them can ping the host and neither of them can ping the gateway.
After 2 days of researching I finally ended up here. I hope someone can help shed some light on this for me.
Thanks/
Please open a bug ticket, set the target version to 11.1 and with high prio, as this is essential for freenas and should work. Hopefully this can get figured out and get fixed.
 

bed

Member
Joined
Jun 17, 2011
Messages
38
Just thought I would post an update regarding the bug I submitted.
If you are running in a virtual environment, enabling promiscuous mode on your virtual network will allow your jail networks to function properly. At least in my case.

I don't know if this is considered a permanent fix especially regarding any security issues this might present to some users. Since I am only using the virtual environment for testing before deploying on bare metal this is much less of a concern to me.
 

xxsj

Member
Joined
Aug 2, 2014
Messages
26
Had same problem as OP and tried the steps provided originally, and got the same error:

ifconfig: ioctl (SIOCAIFADDR): Invalid argument

This is breaking 7 out of 9 of my jails currently. (The oldest 7... hmm)

Static IP doesn't help, started after upgrading from 9.1x train to 11.1 train.

VIMAGE cannot be unchecked, it simply wont let me in advanced mode even though I can see the checkbox and uncheck the box above it (autostart)
 

xxsj

Member
Joined
Aug 2, 2014
Messages
26
I was able to get static networking working in my jails, when I cleared every field under advanced mode excluding the mac address, the textbox at the bottom, the ipv4 address and netmask, unchecked vimage, and rebooted the jail. Hope this helps someone else!
 

vzmr82

Newbie
Joined
Oct 15, 2014
Messages
1
I was able to get static networking working in my jails, when I cleared every field under advanced mode excluding the mac address, the textbox at the bottom, the ipv4 address and netmask, unchecked vimage, and rebooted the jail. Hope this helps someone else!
Just upgraded from 9.3.1 to 11.1-U2 and had this same problem. Unchecking vimage solved the problem. Thanks.

UPDATE===

No, it did not. Even thought I have a static IP address, my Plex Media Server just stopped working. As per this post https://forums.plex.tv/discussion/2...ng-posters-with-vimage-not-enabled-on-freenas, I have other network problems.

So I still need to solve the problem by not unchecking VIMAGE...
 
Last edited:

jg3

Junior Member
Joined
May 17, 2017
Messages
19
tough to believe this is still open.
I updated from 11.1-U4 (which was working fine, oddly enough) to -U7 and now none of my jails seem to have any kind of network access. Poked around a bunch with the notes in this thread, finally decided to destroy and re-create the jail.

Created a new jail via CLI:
root@fn:~ # iocage create -n "plex" -p /tmp/pkg.json -r 11.1-RELEASE vnet="on" allow_raw_sockets="1" bpf=yes dhcp=on boot="on"
plex successfully created!
Testing SRV response to FreeBSD
Error: error sending query: General LDNS error
{repo} could not be reached, please check your DNS


Creating it from the WebUI also fails because this bug still exists where ticking the box for BPF when creating a jail causes creation to fail:
*** true is not a valid value for bpf. Value must be no or yes ***

Such a bummer. I again created a jail via CLI and the WebUI with a static IP and it still doesn't get network.
So here I am ... unable to ping my gateway or the freenas host, and no idea what to do to make it work. Help?!


Code:
root@plex:~ # ifconfig
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
        options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
        inet6 ::1 prefixlen 128
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
        inet 127.0.0.1 netmask 0xff000000
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
        groups: lo
epair0b: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=8<VLAN_MTU>
        ether 02:ff:60:14:fa:0a
        hwaddr 02:2d:a0:00:0a:0b
        inet 10.39.6.88 netmask 0xffffff00 broadcast 10.39.6.255
        nd6 options=9<PERFORMNUD,IFDISABLED>
        media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
        status: active
        groups: epair
root@plex:~ # netstat -rnf inet
netstat: kvm not available: /dev/mem: No such file or directory
Routing tables

Internet:
Destination        Gateway            Flags     Netif Expire
default            10.39.6.254        UGS     epair0b
10.39.6.0/24       link#2             U       epair0b
10.39.6.88         link#2             UHS         lo0
127.0.0.1          link#1             UH          lo0
root@plex:~ # ping 10.39.6.254
PING 10.39.6.254 (10.39.6.254): 56 data bytes
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down
ping: sendto: Host is down
^C
--- 10.39.6.254 ping statistics ---
9 packets transmitted, 0 packets received, 100.0% packet loss
root@plex:~ # ping 10.39.6.99
PING 10.39.6.99 (10.39.6.99): 56 data bytes
ping: sendto: Host is down
ping: sendto: Host is down
^C
--- 10.39.6.99 ping statistics ---
7 packets transmitted, 0 packets received, 100.0% packet loss
 

jg3

Junior Member
Joined
May 17, 2017
Messages
19
Nope! I threw in the towel. I blew away all the jails, created a VM and an 11.2-U2.1 FreeNAS system on another machine, verified that creating jails worked there, rsync'd the data ... then upgraded the original system. So far that's worked.

With the stuff I read about the upgrade to 11.2 I wanted to wait, but from what I've seen so far, the 11.2-U2.1 jail admin stuff works a treat.
 
Top