Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove now redundant rockstor-fstrim service and timer #2442

Closed
phillxnet opened this issue Dec 12, 2022 · 3 comments
Closed

Remove now redundant rockstor-fstrim service and timer #2442

phillxnet opened this issue Dec 12, 2022 · 3 comments
Assignees

Comments

@phillxnet
Copy link
Member

phillxnet commented Dec 12, 2022

Our current os base in v4 releases are "Built on openSUSE" and as such now have what we previously supplemented in our older CentOS base: a built-in fstrim configuration:

Dec 12 12:43:38 rleap15-4 fstrim[27461]: /boot/efi: 30 MiB (31453184 bytes) trimmed on /dev/sda2
Dec 12 12:43:38 rleap15-4 fstrim[27461]: /: 20.6 GiB (22067851264 bytes) trimmed on /dev/sda3
Dec 12 12:43:38 rleap15-4 systemd[1]: fstrim.service: Deactivated successfully.
Dec 12 12:43:38 rleap15-4 systemd[1]: Finished Discard unused blocks on filesystems from /etc/fstab.

It is proposed that we no longer attempt to enable our own variant of this via our initrock.py (rockstor-pre.service) in-turn calling:

scripts/flash-optimise.py

Which established the following systemd service and timer:

rockstor-fstrim.service
rockstor-fstrim.timer
@phillxnet
Copy link
Member Author

As we are about to start publishing a new rpm run, "Built on openSUSE" 15.4, I'll see to this issue now to avoid any instances of this now legacy service & time set cropping up that we then have to tidy up there after on our new OS version.

@phillxnet phillxnet self-assigned this Jan 9, 2023
@phillxnet
Copy link
Member Author

Before the proposed changes we have:

rleap15-4:/opt/rockstor # /root/.local/bin/poetry run flash-optimize
2023-01-09 15:56:17,844: TRIM not supported on /dev/sda
2023-01-09 15:56:17,852: usb flash drive validation from udevadm: False
2023-01-09 15:56:17,852: flashiness of the drive(sda): False

After the proposed change (to be submitted shortly via pull request) we have:

rleap15-4:/opt/rockstor # /root/.local/bin/poetry run flash-optimize
2023-01-09 15:57:25,249: usb flash drive validation from udevadm: False
2023-01-09 15:57:25,249: flashiness of the drive(sda): False

phillxnet added a commit to phillxnet/rockstor-core that referenced this issue Jan 9, 2023
Remove all code associated with rockstor-fstrim.service and
rockstor-fstrim.timer from flash_optimize.py.

## Includes:
- minor varialble name clarification.
- fresh black re-formatting.
phillxnet added a commit that referenced this issue Jan 10, 2023
…kstor-fstrim_service_and_timer

Remove now redundant rockstor-fstrim service and timer #2442
@phillxnet
Copy link
Member Author

Closing as:
Fixed by #2461

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant