Project

General

Profile

Bug #41324

If Jail exists with preferred jailname of a plugin, plugin script DESTROYS jail.

Added by Disk Didler about 2 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
No priority
Assignee:
Lola Yang
Category:
GUI (new)
Target version:
Seen in:
Severity:
Med High
Reason for Closing:
Duplicate Issue
Reason for Blocked:
Needs QA:
Yes
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

Oh dear.

I just attempted to install the qbittorrent plugin, while already having a jail called 'qbittorrent' manually created by myself a few weeks ago.
This failed, I logged this job https://redmine.ixsystems.com/issues/41320 (perhaps this can now be closed?)

I just noticed, my jail is now destroyed and missing entirely. The plugin script trashed a jail it didn't 'own' because it had the jailname the system wanted to work with...
This very much shouldn't happen.

I now, very very much recommend my notes from issue 41320, please consider a unique jailnaming convention, the _1, _2, _3 is totally acceptable and alleviates this issue AND it sticks with existing conventions from the Warden system, people are accustomed to.

Fortunately I can figure out how to fix this, probably but it may frustrate other users.

Medium to high priority, user data being accidentally deleted via script.


Related issues

Has duplicate FreeNAS - Bug #41212: Installing the same plugin more than once, results in the deletion of the first plugin, jail, and all related snapshotsClosed
Is duplicate of FreeNAS - Bug #39682: Fix issues associated with a failed or interrupted plugin install in the new UIDone
Blocked by FreeNAS - Feature #41694: Improve validation for jail creationDone

History

#1 Updated by Disk Didler about 2 years ago

Oh boy,....

Since the plugin script destroyed the full jail path, entirely.
ARRAY/iocage/jails/qbittorrent

I no longer have snapshots listed for this path at all. (This may be a FreeBSD limitation?)
Therefore, I have to re-create this jail entirely from scratch.

I'm glad that I've learnt a lot in the past month or two, or I'd be significantly frustrated.
This definitely needs to be fixed for end users

#2 Updated by William Grzybowski about 2 years ago

  • Category changed from OS to Middleware
  • Assignee changed from Release Council to Brandon Schneider
  • Target version changed from Backlog to 11.2-BETA3
  • Severity changed from New to Med High

#3 Updated by Dru Lavigne about 2 years ago

  • Has duplicate Bug #41212: Installing the same plugin more than once, results in the deletion of the first plugin, jail, and all related snapshots added

#4 Updated by Brandon Schneider about 2 years ago

  • Status changed from Unscreened to In Progress

The naming convention is a band aid to the problem, if the jail already existed it shouldn't have nuked it. Just a flaw in the logic :)

Thanks for the report, sorry to hear about the sacrificial jail.

#5 Updated by Brandon Schneider about 2 years ago

  • Category changed from Middleware to GUI (new)
  • Status changed from In Progress to Unscreened
  • Assignee changed from Brandon Schneider to Erin Clark

Erin: While waqar was working on a different ticket, he stumbled on this bug and has a screenshot showing the UI is calling the deletion.

#6 Updated by Waqar Ahmed about 2 years ago

24384

So the new UI is calling jail.delete on it's own in case a validation error is raised from the Middlewared's end. Imho this case should be handled in middlewared that it deletes any resources it allocates.

#7 Updated by Erin Clark about 2 years ago

  • Assignee changed from Erin Clark to Lola Yang

#8 Updated by Lola Yang about 2 years ago

  • Blocked by Feature #41694: Improve validation for jail creation added

#9 Updated by Erin Clark about 2 years ago

  • Related to Bug #39682: Fix issues associated with a failed or interrupted plugin install in the new UI added

#10 Updated by Lola Yang about 2 years ago

  • Status changed from Unscreened to Blocked

#11 Updated by Dru Lavigne about 2 years ago

  • Status changed from Blocked to Not Started

#12 Updated by Lola Yang about 2 years ago

  • Status changed from Not Started to In Progress

#13 Updated by Dru Lavigne about 2 years ago

  • Related to deleted (Bug #39682: Fix issues associated with a failed or interrupted plugin install in the new UI)

#14 Updated by Dru Lavigne about 2 years ago

  • Is duplicate of Bug #39682: Fix issues associated with a failed or interrupted plugin install in the new UI added

#15 Updated by Dru Lavigne about 2 years ago

  • Status changed from In Progress to Closed
  • Target version changed from 11.2-BETA3 to N/A
  • Reason for Closing set to Duplicate Issue

This should be fixed by the related tickets.

#16 Updated by Erin Clark about 2 years ago

  • Status changed from Closed to Ready for Testing

The UI was still deleting the jail, the PR for this ticket removed that behavior so that the middleware can handle it

#17 Updated by Dru Lavigne about 2 years ago

  • Status changed from Ready for Testing to Closed

Also available in: Atom PDF