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

Enhancement Request: add option for directly applying u/Alex_of_Chaos patch for making HDD hibernation work when you (only) have NVMe I/O activity #420

Open
TorbenSchreiter opened this issue Jan 3, 2025 · 4 comments
Labels
enhancement New feature or request

Comments

@TorbenSchreiter
Copy link

Referring to this and parts of the related Python script from https://github.com/AlexFromChaos/synology_hibernation_fixer.

While the Synology DSM HDD hibernation fixer script does a number of different things, I would find what Alex labels "applying in-memory patches for DSM binaries which prevent HDD hibernation to function normally when there is an NVMe activity (allows for eg. to setup noisy Docker containers on an NVMe partition and have working HDD hibernation)" as probably very useful in most cases where Synology_HDD_db is applied. He states explicitly that this goes beyond just Docker usage (and I have observed the same on my unit).

My understanding of Alex' original Reddit post is that this strange behavior was probably introduced w/ SSD Cache in mind. As it is the main point of Synology_HDD_db to actually make the M.2 slots work for normal storage purposes, it would make sense to also integrate the hibernation fix directly here as many people will move their frequently accessed files to the M.2 first (I would expect).

Having this available as an (experimental) option directly in Synology_HDD_db (while giving credit to Alex in the Readme) would be a great addition IMHO.

@007revad
Copy link
Owner

007revad commented Jan 3, 2025

If I add hibernation fixer as an option, rather than copying Alex's work I'd probably make syno_hdd_db download hiber_fixer.py and run it when syno_hdd_db has finished.

I've never run hiber_fixer.py so I'll have a play with it.

@007revad 007revad added the enhancement New feature or request label Jan 3, 2025
@007revad
Copy link
Owner

007revad commented Jan 3, 2025

Okay, I just ran hiber_fixer.py

Alex obviously doesn't believe in the standard 80 column shell window. The first 5 lines:

----------------------------------------------------------------------------------------------------
Select desired triggering periods for synocrond tasks. Depending on your NAS usage scenario you
might want to leave some of them enabled (for eg. periodic BTRFS-related maintaining jobs). If you
don't want to specify your setup, you can just press Enter for all tasks to choose the default
recommended values
----------------------------------------------------------------------------------------------------

are a mess for me:
image

I'd probably end up fixing that :o)

The default schedules for most items looked okay to me. They were either daily, weekly or monthly. I'm not worried about my NAS waking up the HDDs once a day (as long those daily schedules aren't spread out too much).

There were 10 crontab schedules, that I didn't bother working out how frequently they were scheduled for.

@TorbenSchreiter
Copy link
Author

Just saw this (from 5 months ago, thus more recently than the latest version on Github):

But don't use it right now - I have updates for the script pending for a long time which I need to clean up and push to github.

Although first I'm going to release another hibernation-related thing once I have some free time - a script to force DSM to boot only from NVMe (DSM system partitions only on NVMe disks). That in-memory patch to separate SATA/NVMe activity for the hibernation timer will be included there too and in general it should make the synology_hibernation_fixer script useless for those who apply the upcoming one.

Regardless of the above: I think hiber_fixer.py does a lot of things unrelated to what Synology_HDD_db is meant for. They will be useful for other scenarios but I would maybe not mix up things too much.

So maybe, if you are thinking about making hiber_fixer.py more controllable via shell, then an option that only does the NVMe patch (but not the other bunch of things largely unrelated to M.2s) makes more sense?

@007revad
Copy link
Owner

007revad commented Jan 3, 2025

It would depending on how Alex intends to force DSM to boot only from NVMe drives. Assuming Alex's method would need to be redone after each DSM update it would need to be done after syno_hdd_db has run.

I'd hope Alex knows some way to add md0 and md1 to the NVMe drives without needing to reformat them.

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

No branches or pull requests

2 participants