Project

General

Profile

Bug #27362

Do not show Wipe button for disks that are in use

Added by Bonnie Follweiler over 1 year ago. Updated 12 months ago.

Status:
Done
Priority:
Nice to have
Assignee:
William Grzybowski
Category:
Middleware
Target version:
Seen in:
Severity:
New
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

This is in FreeNAS-11.1-RELEASE: In the previous versions (tested on several versions) the boot drive didn't show up in the list of disks. When upgraded or fresh install it is an option. (screenshot provided) It also can be selected and the Edit and wipe buttons are active.
If I click to do a quick wipe I get the following Traceback error:
Request Method: POST
Request URL: http://10.231.1.145/storage/disks/wipe/ada0/
Software Version: FreeNAS-11.1-RELEASE (dc7d195f4)
Exception Type: MiddlewareError
Exception Value:

[MiddlewareError: Failed to wipe ada0p2: dd: /dev/ada0p2: Operation not permitted
]

Exception Location: ./freenasUI/middleware/notifier.py in _do_disk_wipe_quick, line 3584
Server time: Thu, 21 Dec 2017 07:06:03 -0800

Traceback
Environment:

Software Version: FreeNAS-11.1-RELEASE (dc7d195f4)
Request Method: POST
Request URL: http://10.231.1.145/storage/disks/wipe/ada0/

Traceback:
File "/usr/local/lib/python3.6/site-packages/django/core/handlers/exception.py" in inner
42. response = get_response(request)
File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py" in _legacy_get_response
249. response = self._get_response(request)
File "/usr/local/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response
178. response = middleware_method(request, callback, callback_args, callback_kwargs)
File "./freenasUI/freeadmin/middleware.py" in process_view
162. return login_required(view_func)(request, *view_args, **view_kwargs)
File "/usr/local/lib/python3.6/site-packages/django/contrib/auth/decorators.py" in _wrapped_view
23. return view_func(request, *args, **kwargs)
File "./freenasUI/storage/views.py" in disk_wipe
850. notifier().disk_wipe(devname, form.cleaned_data['method'])
File "./freenasUI/middleware/notifier.py" in disk_wipe
3607. self._do_disk_wipe_quick(part)
File "./freenasUI/middleware/notifier.py" in _do_disk_wipe_quick
3584. "Failed to wipe %s: %s" % (devname, err)

Exception Type: MiddlewareError at /storage/disks/wipe/ada0/
Exception Value: [MiddlewareError: Failed to wipe ada0p2: dd: /dev/ada0p2: Operation not permitted
]

Request information
GET

No GET data
POST
Variable Value
all ''
method 'quick'
__form_id 'form_DiskWipeForm'
FILES

No FILES data
COOKIES
Variable Value
csrftoken 'AyflCf276Ji3xCE5YrxoYq8mMGDh3mo1JdEno1Y4ONTo1o3KqtXDGQ6hhfsft9uK'
sessionid 'hfqpdw1z45r32l2v0nm6os011k5hr7r2'
fntreeSaveStateCookie 'root'
META
Variable Value

Screen Shot 2017-12-21 at 10.03.54 AM.png (219 KB) Screen Shot 2017-12-21 at 10.03.54 AM.png Wipe Screen Bonnie Follweiler, 12/21/2017 07:09 AM
Screen Shot 2017-12-21 at 10.06.05 AM.png (206 KB) Screen Shot 2017-12-21 at 10.06.05 AM.png Traceback error Bonnie Follweiler, 12/21/2017 07:09 AM
Screen Shot 2017-12-21 at 10.12.20 AM.png (37.8 KB) Screen Shot 2017-12-21 at 10.12.20 AM.png Edit screen Bonnie Follweiler, 12/21/2017 07:13 AM
Screen Shot 2018-05-03 at 2.28.36 PM.png (60.6 KB) Screen Shot 2018-05-03 at 2.28.36 PM.png Bonnie Follweiler, 05/03/2018 11:28 AM
13530
13531
13532
17184

Related issues

Related to FreeNAS - Bug #29809: Do not show "Wipe" option for disks in use.Done2018-03-13

Associated revisions

Revision e17fbda5 (diff)
Added by William Grzybowski over 1 year ago

fix(gui): do not show Wipe button for used disks

Ticket: #27362

Revision 946c7fa7 (diff)
Added by William Grzybowski over 1 year ago

fix(gui): do not show Wipe button for used disks

Ticket: #27362

History

#1 Updated by Bonnie Follweiler over 1 year ago

  • Subject changed from The option to wipe the boot drive exists in the View Disks area of Storage to The option to wipe the boot drive exists and gives a traceback error after confirmation (in the View Disks area of Storage)

#2 Updated by William Grzybowski over 1 year ago

  • Status changed from Unscreened to 15
  • Target version changed from 11.1-U1 to 11.2-BETA1

Is the disk in use by something? e.g. volume

#3 Updated by Bonnie Follweiler over 1 year ago

That is the boot volume in the VM. The other two drives are for storage to use but I haven't created any volume/tanks so they don't have data on them either

#4 Updated by William Grzybowski over 1 year ago

So what is the issue here exactly? Allowing to try to wipe a disk in use by the system?

EDIT: Yes, sorry, I missed the first line of the issue describing that.

#5 Updated by William Grzybowski over 1 year ago

  • Status changed from 15 to Screened
  • Priority changed from No priority to Nice to have

#6 Updated by William Grzybowski over 1 year ago

  • Status changed from Screened to Ready For Release

#7 Updated by Dru Lavigne about 1 year ago

  • Subject changed from The option to wipe the boot drive exists and gives a traceback error after confirmation (in the View Disks area of Storage) to Do not show Wipe button for disks that are in use
  • Status changed from Ready For Release to Done
  • Needs Merging changed from Yes to No

#8 Updated by Dru Lavigne about 1 year ago

  • Seen in changed from TrueNAS 11.1-U1 to 11.1

#9 Updated by Timothy Moore II about 1 year ago

  • Related to Bug #29809: Do not show "Wipe" option for disks in use. added

#10 Updated by Dru Lavigne 12 months ago

  • Status changed from Done to Ready for Testing

#12 Updated by Bonnie Follweiler 12 months ago

17184

Test Passed in FreeNAS-11-MASTER-201805030407

#13 Updated by Dru Lavigne 12 months ago

  • Status changed from Passed Testing to Done
  • Needs Doc changed from Yes to No

Also available in: Atom PDF