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
FS#2043 - mdadm files/mdadm.config should ship with an empty config array #6919
Comments
josephtingiris: As seen, here: https://github.com/openwrt/openwrt/blob/openwrt-18.06/package/utils/mdadm/files/mdadm.config If a new /dev/md0 is created then the first boot fails with the package as-is. Little documentation exists to point a user in the right direction to correct the issue. The mdadm.config that's shipped in 18.06.01 (and current snapshot) gets installed as /etc/config/mdadm with a defunct /dev/md0 uuid. Newly created devices named /dev/md0 will not have that uuid and extra steps are required to achieve a functional boot. One could either update via uci set or remove it and add the correct uuid of the linux_raid_members. |
jow-: Did you test whether simply commenting out the uuid works? |
josephtingiris: Additionally, an /etc/mdadm/config as follows fails to start the 'correct' uuid if both arrays use the same device. In my case, the second uuid is valid but the first is not.
config mdadm
option email 'root'
I've written a workaround init script, that runs prior to the existing /etc/init.d/mdadm, that works for me. It corrects the config prior to mdadm starting. Attached for your consideration to include in future packages, or integrate similar logic in /etc/init.d/mdadm. |
josephtingiris: @Jo-Philipp Wich; yes and no. Replacing the uuid with the correct one works as expected. However, commenting out the uuid triggers another warning and the device still fails to mount. The correct uuid must be known. |
jow-: Uhm, so the config needs editing either way. I can simply comment out the array settings by default but that wouldn't really solve the issue you raised here, /etc/config/mdadm would still need editing and not work ootb. |
josephtingiris: I've created a PR on github that addresses both issues (for me).
|
jow-: I will comment out the config by default but auto-setup is out of the scope of the package. |
josephtingiris:
Supply the following if possible:
specifically tested & confirmed on x86-64 and ipq806x
18.06.1 and snapshot
opkg install mdadm
The text was updated successfully, but these errors were encountered: