auanasgheps / snapraid-aio-script

The definitive all-in-one SnapRAID script on Linux. Diff, sync, scrub are things of the past. Manage SnapRAID and much, much more!
GNU General Public License v3.0
231 stars 37 forks source link

snapraid config diff location with OMV 6.2 plugin #54

Closed d4g79 closed 1 year ago

d4g79 commented 1 year ago

Hi,

OMV 6 with Snapraid 6.2 plugin

The old location for the snapraid.conf is @ etc/snapraid.conf

New location is @ etc/snapraid/omv-snapraid-88f2fa6e-f7f8-4258-82f6-be63f6d90259.conf

thats my config, not sure what thenumbers mean. To overcome this i had to rename the above file to snapraid.conf and place it ion the etc folder.

Script then works as normal. This is even the case if i try to run the snapraid sync under cli it searches etc for the config., In the OMV plugin GUI it works as expected.

Thanks

auanasgheps commented 1 year ago

Hi, can you please clarify the issue?

d4g79 commented 1 year ago

With the new OMV6 plugin snapraid 6.2.1 there config location location is @ etc/snapraid but the scirpt is looking for the config at etc.

thats the issue.

auanasgheps commented 1 year ago

I can see this change made to their script, which will either look for the location you mentioned or the original.

Looks like it's a change specific to multiple arrays. Is this your case?

Both in my test and production server, snapraid config is in /etc/snapraid.conf.

auanasgheps commented 1 year ago

Hi @d4g79 since I do not have multiple arrays (please confirm if this is your case) it's not easy for me to replicate this behavior.

Do not rename files generated by OMV, they could go back to the original name at some point in time, e.g. after an update.

The proper way to address this scenario is to change this line to point to your configuration file.

I could build an integrated way to read the config file, but it might not be worth the effort.