safihre wrote: ↑July 24th, 2024, 5:31 pm
Noted! If it's requested a lot, we can reconsider.
Please do consider this request. It would be greatly welcomed. I believe you may not receive many public request do to the lack of technical knowledge and thus user acceptance that you have to live with it functioning as is.
The basis for the additional functionality is due too how data is treat when crossing file system boundaries; irrelevant of what OS and file system(s) are used.
The boundary here is that each hard drive has its own independent tracking table; be it a MFT, or inode.
A request to "move" a file across boundaries (from one disk to another) requires the destination file system to create a brand new entry in its own metadata table, read every bit from the source and writes it to the new physical sectors on the destination. Followed by registering this new physical locations it was stored on in the destination's metadata table. Finally, it goes back to the source metadata table and deletes the original entry, marking that old space as "free". Where clearly a request to "move" a file in the same boundary is simply updating the existing metadata table and is practically instant.
We'll throw in hardlink since we are discussing file system metadata tables. When a hardlink is applied a new name entry is created that points to an existing metadata record. Clearly why a hardlink has the very same boundary limitations. Only symlink can span multiple drive/network locations, but out of scope here.
So lets move to some examples with this understanding.
If we take any OS and and make three additional physical hard drives available to it, format the HDs with any file system the OS supports.
Can we configure Sabnzbd with three categories each category with its own path? YES we can; as you do not have to use relative folders based on "Default Base Folder" nor the "Completed" folder.
e.g.
Disk1:OS\sab\
\incomplete
\completed
\...
Disk2: media\tv
Disk3: media\movies
Disk4: media\music
Can a "completed download" of any category be moved instantaneously to one of the three HDs? NO it cannot, we are crossing boundaries.
If we move the sabnzbd "download" directories to any one of the data drives above a "completed download" move request to either of the two drives the category does not reside on is still a NO, we are crossing boundaries..
If we had an option to specify individual download directories (Temporary & Completed Download) per Category, could moves not cross boundaries? YES.
Bonus, would hardlink work for each respective categories data , YES.
e.g. (any of these combinations would work for not crossing boundaries)
Disk2:
media\tv
media\incomplete (for tv)
media\completed (for tv)
Disk3:
media\incomplete (for movies)
media\completed (for movies)
media\completed\movies
Disk4:
media\sab\incomplete (for music)
media\sab\completed (for music)
media\sab\music
Only way to accomplish this today, is with multiple sabnzbd installation, each for servicing one category. But this creates an issue with too many calls for searches.
Now let's use another example, using an OS like Unraid. This OS utilizes a custom process called
shfs (consider it a custom volume manager) this is built on the native Linux FUSE framework. You will notice some refer to it as FUSE while others shfs. It is this process which runs in the userspace that determines based on the configuration set what mount point to utilize for the system call that was made. ( e.g., write(), open(), mkdir(),rename() ).
e.g.#1 make a call to copy to a
disk, that will be a native linux call of "
cp /mnt/diskX/" whatever your copying.
e.g.#2 make a call to copy to a
share, the kernel sees that request is a path that belongs to a FUSE (shfs) mount, and redirect it to shfs to process. shfs will make the determination based on the configuration of the share what to actually do. If share was configure to use cache and cache has not run out of space, then it would call "
cp /mnt/cache/share". If the share is not configure to use a cache drive/pool or out of space then it would call "
cp /mnt/share/"
This is where the confusion comes into play, as well as some legitimate requests that should work, but don't because shfs is masking what it transpiring under the hood.
By introducing the ability for Sabnzbd to enable individual incomplete and complete base folders to reside with the categories their data is destined for alleviates various pain points whereby file system boundaries are crossed. A dedicated share can contain books, another for IT apps, another for a specific media type. Each processing that category optimally, which only works today when everything is all under one boundary.
Supporting these feature would allow addition shares for which we could apply different access permissions and should allow "Minimum Free Space for Completed Download Folder" to be calculated per category since each could have their own (secondary sub feature).
Thanks for the consideration.