Project

General

Profile

Bug #50519

Do not leave behind a partial jail if plugin installation fails

Added by Disk Didler over 1 year ago. Updated over 1 year ago.

Status:
Done
Priority:
No priority
Assignee:
Waqar Ahmed
Category:
Middleware
Target version:
Seen in:
Severity:
Medium
Reason for Closing:
Reason for Blocked:
Needs QA:
No
Needs Doc:
No
Needs Merging:
No
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

There is currently a big mess going on with sickrage (not your fault, at all).

The repository has been hijacked or something, causing your pull to grab bad files.
However, the install process, within FreeNAS is failing right at the end with a small error near the 90% mark.

Error being
"
Install
[EFAULT] An error occured! Please read above"

I clicked ok on this error twice today, figuring the plugin will be broken until the repository thing is fixed.
However, I've just noticed 2 orphaned jails on my system just sitting there. (The plugin doesn't work for them either, there's no web interface for the plugin at the correct IP / Port)

Perhaps the plugin install code, needs to be /really/ darn sure the plugin installed properly, otherwise nuke the jail (or tell us about it)

Thanks guys - low priority obviously, pretty rare situation.


Related issues

Related to FreeNAS - Feature #44856: Update iocage Plugins for RC1Done

History

#1 Updated by Dru Lavigne over 1 year ago

  • Category changed from OS to GUI (new)
  • Assignee changed from Release Council to Lola Yang
  • Target version changed from Backlog to 11.2-RC2

Lola: wrt a jail being created for a failed plugin install, is that something that is happening on the new UI side or is there a middleware piece missing? Ideally, we would have this fixed for RELEASE or U1.

Disk: thanks for the heads up on why Sickrage is failing. I'll delist it from the INDEX for RC1 until its issues are sorted.

#2 Updated by William Grzybowski over 1 year ago

  • Category changed from GUI (new) to Middleware
  • Assignee changed from Lola Yang to Waqar Ahmed

This is middleware. Waqar can you verify why this isnt happening? Or was the fix made for upcoming RC1?

#3 Updated by Waqar Ahmed over 1 year ago

  • Status changed from Unscreened to In Progress

#4 Updated by Disk Didler over 1 year ago

They've renamed themselves to sick chill now. It's the "real" sick rage.

#5 Updated by Waqar Ahmed over 1 year ago

  • Severity changed from New to Medium

Freenas - iocage master PR - https://github.com/freenas/iocage/pull/62
Iocage/iocage master PR - https://github.com/iocage/iocage/pull/664

#6 Updated by Dru Lavigne over 1 year ago

#7 Updated by Waqar Ahmed over 1 year ago

  • Status changed from In Progress to Ready for Testing

#8 Updated by Dru Lavigne over 1 year ago

  • Status changed from Ready for Testing to In Progress

#10 Updated by Waqar Ahmed over 1 year ago

  • Status changed from In Progress to Ready for Testing
  • Needs Merging changed from Yes to No

#11 Updated by Dru Lavigne over 1 year ago

  • Subject changed from Failed plugin install, is still leaving a partial jail. to Do not leave behind a partial jail if plugin installation fails
  • Needs Doc changed from Yes to No

#12 Updated by Bonnie Follweiler over 1 year ago

  • Status changed from Ready for Testing to Failed Testing

I installed couch potato and, to imitate a install failure, rebooted during the install.
I had 3 jails (2 plugins and a jail) before I tried to install Couch Potato)

I installed click Plugins, which there were two of before, the system gives me "couchpotato is missing it's configuration, please destroy this jail and recreate it."
and the following: Error: concurrent.futures.process._RemoteTraceback:
"""
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_json.py", line 244, in json_load
jail_dataset.properties["org.freebsd.iocage:host_hostuuid"]
File "libzfs.pyx", line 2059, in libzfs.ZFSPropertyDict.__getitem__
KeyError: 'org.freebsd.iocage:host_hostuuid'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/concurrent/futures/process.py", line 175, in _process_worker
r = call_item.fn(*call_item.args, **call_item.kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 122, in main_worker
res = loop.run_until_complete(coro)
File "/usr/local/lib/python3.6/asyncio/base_events.py", line 468, in run_until_complete
return future.result()
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 82, in _run
return await self._call(f'{service_name}.{method}', serviceobj, methodobj, params=args, job=job)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 75, in _call
return methodobj(*params)
File "/usr/local/lib/python3.6/site-packages/middlewared/worker.py", line 75, in _call
return methodobj(*params)
File "/usr/local/lib/python3.6/site-packages/middlewared/schema.py", line 668, in nf
return f(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/plugins/jail.py", line 462, in list_resource
resource_list = iocage.list("all", plugin=True)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/iocage.py", line 1157, in list
quick=quick
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_list.py", line 75, in list_datasets
_all = self.list_all(ds)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_list.py", line 153, in list_all
conf = iocage_lib.ioc_json.IOCJson(mountpoint).json_load()
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_json.py", line 259, in json_load
silent=self.silent)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_common.py", line 81, in logit
_callback(content, exception)
File "/usr/local/lib/python3.6/site-packages/iocage_lib/ioc_common.py", line 64, in callback
raise callback_exception(message)
RuntimeError: couchpotato is missing it's configuration, please destroy this jail and recreate it.
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 161, in call_method
result = await self.middleware.call_method(self, message)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 1043, in call_method
return await self._call(message['method'], serviceobj, methodobj, params, app=app, io_thread=False)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 980, in call
return await self._call_worker(serviceobj, name, *args)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 1007, in _call_worker
job,
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 938, in run_in_proc
return await self.run_in_executor(self.
_procpool, method, *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/middlewared/main.py", line 923, in run_in_executor
return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
RuntimeError: couchpotato is missing it's configuration, please destroy this jail and recreate it.

When I close that dialog box it just gives me the spinner and doesn't show the installed plugins
I go to the Jails area and there are no jails listed (so I can't delete couch potato)

#13 Updated by William Grzybowski over 1 year ago

  • Status changed from Failed Testing to Ready for Testing

Rebooting is not a valid test scenario.

To simulate a failure try pulling out the ethernet cable instead.

#14 Updated by Bonnie Follweiler over 1 year ago

  • Status changed from Ready for Testing to Passed Testing
  • Needs QA changed from Yes to No

Test passed in FreeNAS-11.2-INTERNAL32

#15 Updated by Dru Lavigne over 1 year ago

  • Status changed from Passed Testing to Done

Also available in: Atom PDF