From FreeNAS 11.3 to TrueNAS Core 12 - Upgrade Stories

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,176
 

airflow

Contributor
Joined
May 29, 2014
Messages
102
After I learned that TrueNAS Core 12 went STABLE recently (I missed any official announcment regarding this here), I upgraded my FreeNAS-system running 11.3-U5 yesterday.

My system runs several jails with various functionality. I don't use plugins but build all my jails myself with scripts using the ports (BubbleUPnP, plex, dnsmasq, MinimServer, unison, transmission, nextcloud).

I can report that everything so far works fine without any action required from my side. All the jails still work and do their job, although they are still 11.3 based. I am wondering why this works, as others report that their jails stopped working. The only - expected - sideeffect is that the jails cannot be updated any more (make: "/usr/ports/Mk/bsd.port.mk" line 1204: UNAME_r (12.2-RC3) and OSVERSION (1103000) do not agree on major version number.)

As I have scripted the creation and building of all these jails, there is an easy fix: I will just rebuild the jails one by one (I did this already in the past on main version upgrades). I saw that TrueNAS Core 12 offers two release-versions for creating new jails, 11.4 and 12.1.

When I type "uname" on the shell of the new TrueNAS-system, I see that it uses 12.2-RC3 as its OS. Why is then possible to chose between 11.4 and 12.1? Shouldn't it be just 12.2? I thought jails base on the same kernel and have to share the version number? I guess the best way to go forward now is to chose 12.1 as the base for the jails, although the host uses 12.2, right?

Kind Regards,
airflow
 

adrianwi

Guru
Joined
Oct 15, 2013
Messages
1,231
I
After I learned that TrueNAS Core 12 went STABLE recently (I missed any official announcment regarding this here), I upgraded my FreeNAS-system running 11.3-U5 yesterday.

My system runs several jails with various functionality. I don't use plugins but build all my jails myself with scripts using the ports (BubbleUPnP, plex, dnsmasq, MinimServer, unison, transmission, nextcloud).

I can report that everything so far works fine without any action required from my side. All the jails still work and do their job, although they are still 11.3 based. I am wondering why this works, as others report that their jails stopped working. The only - expected - sideeffect is that the jails cannot be updated any more (make: "/usr/ports/Mk/bsd.port.mk" line 1204: UNAME_r (12.2-RC3) and OSVERSION (1103000) do not agree on major version number.)

As I have scripted the creation and building of all these jails, there is an easy fix: I will just rebuild the jails one by one (I did this already in the past on main version upgrades). I saw that TrueNAS Core 12 offers two release-versions for creating new jails, 11.4 and 12.1.

When I type "uname" on the shell of the new TrueNAS-system, I see that it uses 12.2-RC3 as its OS. Why is then possible to chose between 11.4 and 12.1? Shouldn't it be just 12.2? I thought jails base on the same kernel and have to share the version number? I guess the best way to go forward now is to chose 12.1 as the base for the jails, although the host uses 12.2, right?

Kind Regards,
airflow

I'd like to think you can upgrade the version of FreeBSD running in the jail to the latest supported in TrueNAS (12.1?) and then the packages should update?

Upgrading Jails
Upgrades are handled with the freebsd-update(8) utility. By default, the user must supply the new RELEASE for the jail’s upgrade. For example:

# iocage upgrade examplejail -r 11.0-RELEASE

Tells jail examplejail to upgrade its RELEASE to 11.0-RELEASE.

Note
It is recommended to keep the iocage host and jails RELEASE synchronized.
To upgrade a jail to the host’s RELEASE, run:

iocage upgrade -r [11.1-RELEASE] [UUID | NAME]

This upgrades the jail to the same RELEASE as the host. This method also applies to basejails.
 

macmuchmore

Explorer
Joined
Feb 4, 2020
Messages
58
Edit each Jail, go to "Jail Properties" and change "devfs_ruleset" value to "4". Save and start Jail UP, it should work :cool:
Thank you so much! That did the trick. One was set to 5, the other 6. If you could elaborate, why did these need to be changed/why were they set incorrectly when I upgraded to TNC 12? I’ll see if I can figure it out/find it in the documentation.
 

airflow

Contributor
Joined
May 29, 2014
Messages
102
I'd like to think you can upgrade the version of FreeBSD running in the jail to the latest supported in TrueNAS (12.1?) and then the packages should update?
Yes thanks for pointing it out. I deliberately choose to rebuild them at this occasion, because I want to be sure that the build scripts still work and all the configurations in my repository is up-to-date and correct and restores correctly after the changes in the software.
 

stillka

Explorer
Joined
Nov 15, 2014
Messages
55
Actually, after fixing some minor problems with NFS, SAMBA and Jails only 1 message is not fixed for me:

Oct 24 15:19:15 freenas 1 2020-10-24T15:19:15.074269+02:00 freenas.local mountd 1638 - - can't open /etc/zfs/exports

I can temporary fix it by making symlink bellow but after reboot its gone and I have to re-create link again....
ln -s /etc/exports /etc/zfs/exports

Any idea how to fix it permanently?
 

TallCoolOne

Cadet
Joined
Oct 31, 2017
Messages
8
Actually, after fixing some minor problems with NFS, SAMBA and Jails only 1 message is not fixed for me:

Oct 24 15:19:15 freenas 1 2020-10-24T15:19:15.074269+02:00 freenas.local mountd 1638 - - can't open /etc/zfs/exports

I can temporary fix it by making symlink bellow but after reboot its gone and I have to re-create link again....
ln -s /etc/exports /etc/zfs/exports

Any idea how to fix it permanently?

I had the same issue also, I think it was related to NFS service, I just turned it off as I don't use it anyway.

Reverted back to 11.3-U5 for now as the slow read speeds from shares was a deal breaker.
 

AirborneTrooper

Contributor
Joined
Jun 20, 2014
Messages
148
Upgraded from 11.3 to 12 yesterday. Spent some of last night and all of today upgrading my jails to 12.1. Some I just recreated from scratch but others did the
Code:
iocage upgrade -r 12.1-RELEASE jailname
which takes FOOOOREVER followed by
Code:
pkg-static install -f pkg 
and
Code:
pkg upgrade -y 
. I'd say easily an hour per jail doing this method or close to it. Can someone tell me in noob terms, why this process takes so long compared to just creating a new icoage jail?
 

colmconn

Contributor
Joined
Jul 28, 2015
Messages
174
Upgraded from 11.3 to 12 yesterday. Spent some of last night and all of today upgrading my jails to 12.1. Some I just recreated from scratch but others did the
Code:
iocage upgrade -r 12.1-RELEASE jailname
which takes FOOOOREVER followed by
This is probably because your jail(s) have src/src (the freebsd source code) installed and /etc/freebsd-update.conf is configured to keep the src up to date. I found this out the hard way yesterday when I upgraded my jails. I have 13 and it took about 14 hours to update all of them (about 2 hours per jail). Worse, it's interactive and will stop periodically to ask if the changes it want's to make are OK. On the third from last jail I finally googled why it took so long and discovered the issue with source. For the last 2 jails I deleted /usr/src in the jail and edited /etc/freebsd-update.conf (in each jail) to change line 15 from "Components src world" to "Components world" The last two jails took about 15 mins each to upgrade to 12.1 including a complete pkg upgrade.
 
Last edited:

AirborneTrooper

Contributor
Joined
Jun 20, 2014
Messages
148
For the last 2 jails I deleted /usr/src in the jail and edited /etc/freebsd-update.conf (in each jail) to change line 15 from "Components src world" to "Components world" The last two jails took about 15 mins each to upgrade to 12.1 including a complete pkg upgrade.

Wish I knew this last night or even this morning. I'll update my post on another thread here with these steps.
 

Kam

Dabbler
Joined
Mar 28, 2016
Messages
39
I'm upgrading my jails to 12.1-RELEASE, but before that want to take snapshot.
Taking snapshot works, but then snaplist is getting Traceback:
iocage snapshot jailname
iocage snaplist jailname
Traceback (most recent call last):
File "/usr/local/bin/iocage", line 10, in <module>
......
Does "iocage snaplist" work for anybody after upgrade to 12-RELEASE ?
In my case it works only when there are no snapshots.
If I remove manually snapshots with "zfs destroy", snaplist works again, till new snapshot is created.
Thanks.
 

Alecmascot

Guru
Joined
Mar 18, 2014
Messages
1,175
NAS-107916
Claimed to be fixed in the RELEASE but I have raised it again.
 

TAC

Contributor
Joined
Feb 16, 2014
Messages
152
Here is a pretty good video on updating FreeNAS to TrueNAS by Tom Lawrence. Not too much info on updating individual jails (expect SyncThing), but some pretty good info anyway.

https://www.youtube.com/watch?v=z0O6WHJz8I4
 

yannickg

Dabbler
Joined
Mar 20, 2017
Messages
13
I just upgraded to TN12. Everything works fine but all my jails cannot connect to the network. Anyone has an idea?

Thanks
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,740
iocage get all <one of your jails>
ifconfig -a

please.
 

yannickg

Dabbler
Joined
Mar 20, 2017
Messages
13
just found out that I had a bridge0 interface but it was not showing up in the GUI so I deleted it through command line and then recreated it in the GUI and all jails are up and running!
 

InQuize

Explorer
Joined
May 9, 2015
Messages
81
Updated from 11.3-U5 and also getting a bunch of these on boot.

Code:
mountd 1545 - - can't open /etc/zfs/exports

Currently LEMP over NFS seems to work, so not sure if there is a need to take any action or just wait leave it until point release.

I can temporary fix it by making symlink bellow but after reboot its gone and I have to re-create link again....
ln -s /etc/exports /etc/zfs/exports

Any idea how to fix it permanently?
Init script
 

Kelly Hays

Dabbler
Joined
Apr 25, 2017
Messages
16
Updated from 11.3-U5 and also getting a bunch of these on boot.

Code:
mountd 1545 - - can't open /etc/zfs/exports

Currently LEMP over NFS seems to work, so not sure if there is a need to take any action or just wait leave it until point release.

This has been reported here: NAS-107421
There are some workarounds in the comments.
 
Top