Can't delete unused tunable
Description
Problem/Justification
None
Impact
None
Activity
Show:

Bug Clerk August 11, 2023 at 12:36 PM

Bug Clerk August 11, 2023 at 12:36 PM
22.12.4 PR: https://github.com/truenas/middleware/pull/11829

Automation for Jira August 11, 2023 at 12:36 PM
This issue has now been closed. Comments made after this point may not be viewed by the TrueNAS Teams. Please open a new issue if you have found a problem or need to re-engage with the TrueNAS Engineering Teams.

Bug Clerk August 7, 2023 at 3:33 PM

Caleb August 7, 2023 at 11:18 AM
seems we need to handle FileNotFoundError on deletion requests and still remove db entries
Complete
Pinned fields
Click on the next to a field label to start pinning.
Details
Details
Assignee

Reporter

Labels
Time remaining
0m
Components
Fix versions
Affects versions
Priority
Katalon Platform
Linked Test Cases, Katalon Defect Results, Katalon Studio Test Results
Katalon Platform
Linked Test Cases, Katalon Defect Results, Katalon Studio Test Results
Created July 25, 2023 at 9:44 PM
Updated August 15, 2023 at 2:16 PM
Resolved August 11, 2023 at 8:11 PM
I go into to look at my tunables and there are some that are deactivated. I tried to use the trashcan to delete them but I get an error on them. The tunables were for a 10gb pci card that used a rj45 port. I've since moved to a 10gb sfp+ port with DAC cable. Here is the error.
Error: Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 204, in call_method
result = await self.middleware._call(message['method'], serviceobj, methodobj, params, app=self)
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1344, in _call
return await methodobj(*prepared_call.args)
File "/usr/lib/python3/dist-packages/middlewared/service.py", line 962, in delete
rv = await self.middleware._call(
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1344, in _call
return await methodobj(*prepared_call.args)
File "/usr/lib/python3/dist-packages/middlewared/schema.py", line 1246, in nf
res = await f(*args, **kwargs)
File "/usr/lib/python3/dist-packages/middlewared/schema.py", line 1378, in nf
return await func(*args, **kwargs)
File "/usr/lib/python3/dist-packages/middlewared/plugins/tunables.py", line 178, in do_delete
await self.middleware.call('tunable.reset_sysctl', entry)
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1395, in call
return await self._call(
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1355, in _call
return await self.run_in_executor(prepared_call.executor, methodobj, *prepared_call.args)
File "/usr/lib/python3/dist-packages/middlewared/main.py", line 1258, in run_in_executor
return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
File "/usr/lib/python3.9/concurrent/futures/thread.py", line 52, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/lib/python3/dist-packages/middlewared/plugins/tunables.py", line 58, in reset_sysctl
self.set_sysctl(tunable['var'], tunable['orig_value'])
File "/usr/lib/python3/dist-packages/middlewared/plugins/tunables.py", line 53, in set_sysctl
with open(f'/proc/sys/{var.replace(".", "/")}', 'w') as f: