I can not create a new jail any more?

TrueNAS-13.0-U6.3 Core

I try to create a jail and it errors.

RELEASE: 13.4-RELEASE not found!

Im not trying to install a plugin, just create a jail.

jack@truenas ~ $ sudo iocage fetch release=13.3-RELEASE
[0] 13.3-RELEASE
[1] 13.4-RELEASE
[2] 14.0-RELEASE
[3] 14.1-RELEASE

Type the number of the desired RELEASE
Press [Enter] to fetch the default selection: (13.1-RELEASE)
Type EXIT to quit: 0
Fetching: 13.3-RELEASE

Extracting: base.txz... 
Traceback (most recent call last):
  File "/usr/local/bin/iocage", line 10, in <module>
    sys.exit(cli())
  File "/usr/local/lib/python3.9/site-packages/click/core.py", line 1128, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.9/site-packages/click/core.py", line 1053, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python3.9/site-packages/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.9/site-packages/click/core.py", line 1395, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.9/site-packages/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/usr/local/lib/python3.9/site-packages/iocage_cli/fetch.py", line 181, in cli
    ioc.IOCage().fetch(**kwargs)
  File "/usr/local/lib/python3.9/site-packages/iocage_lib/iocage.py", line 1105, in fetch
    ioc_fetch.IOCFetch(
  File "/usr/local/lib/python3.9/site-packages/iocage_lib/ioc_fetch.py", line 215, in fetch_release
    rel = self.fetch_http_release(eol, _list=_list)
  File "/usr/local/lib/python3.9/site-packages/iocage_lib/ioc_fetch.py", line 446, in fetch_http_release
    missing_files = self.__fetch_check__(self.files)
  File "/usr/local/lib/python3.9/site-packages/iocage_lib/ioc_fetch.py", line 644, in __fetch_check__
    self.fetch_extract(f)
  File "/usr/local/lib/python3.9/site-packages/iocage_lib/ioc_fetch.py", line 821, in fetch_extract
    f.extractall(dest, members=member, filter='tar')
TypeError: extractall() got an unexpected keyword argument 'filter'

You need to upgrade your TrueNAS to 13.3 first.

1 Like

Ok, cheers, i shall give it a go. Hope everything just works after update. Fingers crossed (Updating CORE | TrueNAS Documentation Hub)

Im dreading the day people say ā€œO you have to drop core and use scale!ā€

I can only just about figure enough to be happy with core and that took a year or so.

EDIT:

Ok i got it to update to 13.3, but it says there is another update but looking at the update page its not on any ā€œtrainā€ now, its blank.

I don’t know if it is supposed to be on any of the scale trains i would highly doubt it but then should it be left blank?

Should i do this update on the blank train or just leave the update alone (not do it)?

Read the release notes on the update and decide if you want to do it. 13.3 isn’t on a train and was done just for those that HAD to stay on Core and needed to update Jails and their packages inside.

Announcement of the update and links to release notes, etc.

1 Like

It’s also for those who want to be absolutely sure, every day, that their boot-pool is not corrupted. :muscle:

This is a silly problem. The URL changed. This should fix your original problem on 13.0u6.x or 13.3.x

iocage fetch --root-dir /pub/FreeBSD-Archive/old-releases/amd64/ --server ftp-archive.freebsd.org

Read more:

1 Like

Ok , well thx all. I am at Version: TrueNAS-13.3-U1 now. I have not yet tried making a jail but i assume it will be ok. I shall take a look later today.

So it was nothing to do with me needing to update, I did do the updates but it still had the same error.

I followed @NickF1227’s post and it was the resolution. This was all I needed to do.

Thank you @NickF1227 :slightly_smiling_face:

1 Like

The solution proposed to me did not solve the problem, but I solved it by modifying the file ioc_fetch.py in the folder usr/local/lib/python3.9/site-packages/iocage_lib/, all from shell from the web interface of truenas core.

Analyzing the error, the python compiler finds a problem when it says to launch the function f.extractall(..) on line 821.

Then I went to edit the file, I looked for the line 821 in question, and I modified from like this:

f.extractall(dest, members=member, filter='tar')

to like this

f.extractall(dest, members=member)

So, simply by removing the third argument in calling the function, the call works.
In fact, going to the github repository of truenas/iocage branch 13.0-u6.3-stable,
the wrong call appears, but in the master branch, this error is correct
(I was unable to insert links or images from the github repository because I was blocked by the post button)

Since I am inexperienced with python and the truenas project, could it be a python version issue? or tarfile library version?

3 Likes

I spent several hours and tried several things in effort to figure out why I was getting this extraction error and this quick edit did the trick. THANK YOU for posting.

The other solution mentioned did nothing to solve the issue, but this worked like a charm. Thank you

Hey there, I’ve just upgraded to TrueNAS 13.0-U6.4 and am experiencing the same issue, with the exact same problem (line 821, filter argument). This might sound like a silly question, but - how exactly did you go about editing that ioc_fetch.py? I’m still very new to not using the GUI but it seems that the usr directory doesn’t exist, if the ā€˜ls’ command is to be believed…?

I’m sure I’m doing something wrong, and it’s likely dead simple, but I can’t figure it out just now. Any help would be appreciated!

did you figure it out?

The file referenced is there on Core for me

jack@TruenasCore ~ $ sudo cat /usr/local/lib/python3.9/site-packages/iocage_lib/ioc_fetch.py | grep f.ext
            f.extractall(dest, members=member, filter='tar')
jack@TruenasCore ~ $ 

P.S. I assumed you were wanting to use the GUI built-in shell, but after a frustrating hour of memory searching (I have a terrible memory but I was damn sure there is a GUI shell on Core). Turns out its been removed, wtf !

The web UI Shell is removed in CORE 13.3. Users can continue to access the shell using SSH or a physical system connection with serial cable or other direct method.

ā€œA security feature? Ehh, but Scale still has one. I haven’t used the built-in shell for ever but looks like you will need to setup ssh or use keyboard on the metal that the OS is installed onā€

I did figure it out - but, speaking of memory, I can’t quite remember how I did it now! =)

Ah, yeah - I just had to put a ā€˜/’ in front of the cd request. As in - I used to type ā€˜cd usr’ but I had to type ā€˜cd /usr/blah/blah/’ instead. Once I figured that out, I was off to the races.

That said - I was sure I was on 13.3 but I guess I’m on 13.0-U6.4. Cuz I most definitely have a web GUI Shell option - but I tend to just SSH into my boxes using a Windows command prompt anyway.

But thanks for checking! I managed to edit that irksome line 821 and installed Release 13.3, and so am now able to create jails.

Which have a high probability not to work unless you also upgrade your TrueNAS. Just saying :wink:

Yes, I know. :slight_smile: and although it’ll likely be little consolation, I’ll have you know that, until this Christmas, my main FreeNAS box was on…

…

  1. :)))).

One of the boot flash drives crapped the bed, and that started me on this whole path to upgrade both the main and replication boxes, which I now have done. But I went straight to the TrueNAS website and downloaded what I thought was the latest CORE version…I guess it wasn’t…?

In any case, I suppose I should wait for the merged version now…?

In other news - jail actually seems to work fine from what I can see. Haven’t yet built my Kodi database on it though, to so I very well could be surprised yet!

Actually the very problem is that ā€œfilterā€ option for function tarfile.extractall() was added from python version 3.12 so you either update python before that, or edit that line and remove filter option at all as was suggested earlier.