Unable to Stop or Start Plugin Jails - Permission Denied

permaN00b

Cadet
Joined
Nov 27, 2020
Messages
2
Hi All,

First post - I have gotten myself in a bind and need some guidance on what to troubleshoot.

Running TrueNAS-12.0-RELEASE (FreeNAS/TrueNAS Core).

I have had multiple Plugins and Jails running smoothly since the upgrade from FreeNAS to TrueNAS, which I did as a clean install. Today I wanted to add another mount point to my Plex, so attempted to stop the jail to add the mount. The jail would not stop from the plugin or jail interface on the GUI. I went to the CLI and forced a stop with iocage stop --force Plex. Plex stopped after that and I was able to add the new mount points. However, I could not restart Plex when finished.

I restarted TrueNAS and saw that all of my manually created jails started normally on boot, but none of the plugins started. I was unable to start any of the plugin-built jailes, either through the GUI or CLI. Besides Plex, I also have ClamAV and TauTulli as plugins.

I've been tweaking my system for about a week since my last configuration back-up. If I changed something recently that caused this, I can't think of what it may have been. I tried loading a configuration file from several weeks ago, but that did not correct whatever error is now occurring. Everything had been working just fine until I attempted to stop Plex.

After troubling shooting as much as I could think of, to include removing the mounts added to Plex, I decided to do a manual jail creation for ClamAV. I deleted the plugin and was able to manually create the jail, but it would not start. The error returned was the same as I was getting when trying to start the other plugins via CLI.

root@truenas[~]# iocage start ClamAV
No default gateway found for ipv6.
* Starting ClamAV
+ Started OK
+ Using devfs_ruleset: 1005 (iocage generated default)
+ Configuring VNET OK
+ Using IP options: vnet
+ Starting services FAILED
ERROR:
[b'jexec: execvp: /bin/sh: Permission denied\n', b'', b'']

Refusing to start ClamAV: exec_start failed

I don't understand how permission is being denied when I am logged in as root. The one other thing I noticed was Using devfs_ruleset: 1005 - which I thought was supposed to be 4, not 1005. When I go into the GUI editor for each jail/plugin, they are set to 4 - even the ones not starting.

Have I bumped a switch somewhere accidentally? Did I do something that caused root to lose permissions? What might be wrong and where should I look?
 

permaN00b

Cadet
Joined
Nov 27, 2020
Messages
2
I made another attempt to create a jail and was rewarded with a more detailed error message. Is there something wrong with my python module?

Error: Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_start.py", line 833, in __start_jail__
output = iocage_lib.ioc_exec.SilentExec(
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_exec.py", line 268, in __init__
self.output = list(silent)
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_exec.py", line 259, in exec_jail
raise iocage_lib.ioc_exceptions.CommandFailed(
iocage_lib.ioc_exceptions.CommandFailed: [b'jexec: execvp: /bin/sh: Permission denied\n', b'']

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/middlewared/job.py", line 361, in run
await self.future
File "/usr/local/lib/python3.8/site-packages/middlewared/job.py", line 399, in __run_body
rv = await self.middleware.run_in_thread(self.method, *([self] + args))
File "/usr/local/lib/python3.8/site-packages/middlewared/utils/run_in_thread.py", line 10, in run_in_thread
return await self.loop.run_in_executor(self.run_in_thread_executor, functools.partial(method, *args, **kwargs))
File "/usr/local/lib/python3.8/site-packages/middlewared/utils/io_thread_pool_executor.py", line 25, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.8/site-packages/middlewared/schema.py", line 977, in nf
return f(*args, **kwargs)
File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/jail_freebsd.py", line 876, in do_create
err, msg = iocage.create(
File "/usr/local/lib/python3.8/site-packages/iocage_lib/iocage.py", line 603, in create
ioc_create.IOCCreate(
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_create.py", line 100, in create_jail
return self._create_jail(jail_uuid, location)
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_create.py", line 688, in _create_jail
iocage_lib.ioc_start.IOCStart(jail_uuid, location,
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_start.py", line 87, in __init__
raise e
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_start.py", line 84, in __init__
self.__start_jail__()
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_start.py", line 858, in __start_jail__
iocage_lib.ioc_common.logit({
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_common.py", line 107, in logit
callback(content, exception)
File "/usr/local/lib/python3.8/site-packages/iocage_lib/ioc_common.py", line 80, in callback
raise callback_exception(message)
RuntimeError: + Starting services FAILED
ERROR:
[b'jexec: execvp: /bin/sh: Permission denied\n', b'']

Refusing to start ClamAV: exec_start failed
 
Top