Project

General

Profile

Bug #11029

Actually prune old boot environments when space is running low and need to create new one

Added by Sean Fagan about 5 years ago. Updated almost 4 years ago.

Status:
Closed: Not To Be Fixed
Priority:
Important
Assignee:
William Grzybowski
Category:
OS
Target version:
Severity:
New
Reason for Closing:
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

This is blocked by #10794.

be-usage.png (246 KB) be-usage.png Joe Maloney, 09/19/2016 10:25 AM
7135

Related issues

Has duplicate FreeNAS - Bug #8910: freenas update process should do a better job of reporting the out-of-space conditionClosed: Duplicate2015-03-27
Blocked by FreeNAS - Bug #10794: Add UI to System -> Boot which allows the user to tag a Boot Environment as "Keep"Resolved2016-05-16
Copied from FreeNAS - Bug #10795: Need to prune old boot environments when space is running low and need to create new oneClosed: Not To Be Fixed2016-05-11

History

#1 Updated by Sean Fagan about 5 years ago

  • Copied from Bug #10795: Need to prune old boot environments when space is running low and need to create new one added

#2 Updated by Sean Fagan about 5 years ago

  • Blocked by Bug #10794: Add UI to System -> Boot which allows the user to tag a Boot Environment as "Keep" added

#3 Updated by Sean Fagan about 5 years ago

When #10794 is done, this will be where I add the call to prune in the update code.

#4 Updated by Jordan Hubbard about 5 years ago

  • Status changed from Unscreened to Investigation

#5 Updated by Jordan Hubbard over 4 years ago

  • Has duplicate Bug #8910: freenas update process should do a better job of reporting the out-of-space condition added

#6 Updated by Jordan Hubbard over 4 years ago

  • Assignee changed from Sean Fagan to Anonymous

Let's see if the Calsoft team can get to this one - it's almost a year old, and we now have the "keep" flag for boot environments so the code to go automatically delete old boot envs can check this flag and skip over them.

#7 Updated by Anonymous over 4 years ago

  • Status changed from Investigation to Fix In Progress

#8 Updated by Anonymous about 4 years ago

  • Status changed from Fix In Progress to 19
  • % Done changed from 0 to 100

#9 Updated by Dru Lavigne about 4 years ago

Is this slated for -U1?

#10 Avatar?id=14398&size=24x24 Updated by Kris Moore about 4 years ago

  • Target version changed from Unspecified to 9.10.1-U1

Assuming its fixed here, then yes:

#10795

#11 Updated by Vaibhav Chauhan about 4 years ago

where is the pull request for this ticket ?

#12 Updated by Anonymous about 4 years ago

Still working on 10795, Prioritising the ticket, will make the required changes and update with the same.

#13 Avatar?id=14398&size=24x24 Updated by Kris Moore about 4 years ago

  • Due date set to 09/19/2016

#14 Updated by Vaibhav Chauhan about 4 years ago

BRB: we need this fix to go in before the due date.

#15 Updated by Vaibhav Chauhan about 4 years ago

calsoft, any updates ?

#16 Updated by Anonymous about 4 years ago

I have created pull requests for bug #10795 which is a fix for this ticket also and waiting to get it reviewed:
https://github.com/freenas/freenas-pkgtools/pull/2
https://github.com/freenas/freenas/pull/189

#17 Avatar?id=14398&size=24x24 Updated by Kris Moore about 4 years ago

  • Assignee changed from Anonymous to Joe Maloney

Joe, is this still showing broken in the automated QA tests?

#18 Updated by Vaibhav Chauhan about 4 years ago

if the QA tests still fails we need to punt this ticket to 9.10.1-U2

#19 Updated by Joe Maloney about 4 years ago

7135

Tested with FreeNAS-9.10-MASTER-201609162356 (8d98b55)

I do not think this is working. To test this I created 7 BE's on an 8GB disk. For each BE I created a 1GB file inside each BE as shown below.

  1. create new BE test1, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test1.img bs=1G count=1
  2. create new BE test2, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test2.img bs=1G count=1
  3. create new BE test3, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test3.img bs=1G count=1
  4. create new BE test4, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test4.img bs=1G count=1
  5. create new BE test5, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test5.img bs=1G count=1
  6. create new BE test6, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test6.img bs=1G count=1
  7. create new BE test7, activated BE, and rebooted
    cd /data/
    dd if=/dev/urandom of=test7.img bs=1G count=1

I started out with default, and Initial-Install. Attached is a screenshot showing where I was able to create an 8th BE when the disk was 96 percent full. Nothing was pruned.

#20 Avatar?id=14398&size=24x24 Updated by Kris Moore about 4 years ago

  • Assignee changed from Joe Maloney to Anonymous
  • Target version changed from 9.10.1-U1 to 9.10.1-U2

Punting to -U2 since clearly it needs some further investigation / work.

#21 Updated by Anonymous about 4 years ago

@Joe: I talked to William about this situation, He asked me not to call PruneClones() while creating a new BE on ticket #10795 as:
"Correction, there is another issue here.

If you go to the GUI and try to create a boot environment it will fail with the error about deleting BE, so here is what needs to be done, in that order:

#1 - install 9.10, try to create a BE - verify the error and try to fix it before anything (because the logic in PruneClones is failing)
#2 - call PruneClones() while upgrading but not during creation of a new BE from GUI/API
#3 - make sure "keep" is never True by default in any of these cases"

@William: Please suggest your views on this. Should I delete old BEs while creating new ones if storage space is more than 80% used?

#22 Updated by Vaibhav Chauhan about 4 years ago

  • Target version changed from 9.10.1-U2 to 9.10.1-U3

#23 Updated by Vaibhav Chauhan about 4 years ago

  • Target version changed from 9.10.1-U3 to 9.10.1-U2

#24 Updated by William Grzybowski about 4 years ago

Correct.

I do not believe/agree BE should be deleted by the simple fact of creating a new one from the UI, since the user has control over what he is doing.
In my opinion BE should only be deleted in case of upgrades.

#25 Avatar?id=14398&size=24x24 Updated by Kris Moore about 4 years ago

  • Target version changed from 9.10.1-U2 to 9.10.1-U3

#26 Updated by Vaibhav Chauhan almost 4 years ago

  • Assignee changed from Anonymous to William Grzybowski

william, can you please take a look at this item ?

#27 Updated by William Grzybowski almost 4 years ago

  • Status changed from 19 to Closed: Not To Be Fixed

I dont think a PR was ever accepted for this. This ticket has been superseded by pkgtools changes AFAIK.

Also available in: Atom PDF