<div dir="ltr">Hello, <div><br></div><div>i see your point. File corruption should really be taken into account. This is what cannot be solved on HW raid setup. Thus having /boot on md0 is comparable in this context with having /boot on hw raid. That is raid in this case gives protection from disk physical failure excluding corruption. Yet, for some users it might be sufficient.</div><div><br></div><div>Thank You for advices.</div><div> </div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div><div>best regards, <br><br></div>Antanas Masevicius<br></div>TENDO LT<br></div><a href="https://tendo.lt" target="_blank">https://tendo.lt</a><br><br></div></div></div>
<br><div class="gmail_quote">On Tue, Nov 25, 2014 at 9:57 AM, Thomas Neumann <span dir="ltr"><<a href="mailto:blacky+fai@fluffbunny.de" target="_blank">blacky+fai@fluffbunny.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Tuesday 25 November 2014 09:16:28 Antanas Masevicius wrote:<br>
> Yes, thats a solution, but still, it would be better to have some kind of<br>
> automation. One way probably would be to run some kind of configuration<br>
> engine, or write some script fixing md mbr from init.d. How would you do<br>
> that?<br>
<br>
</span>During/after installation of a new machine:<br>
install mbr on second disk and never touch it again<br>
<br>
<br>
_After_ successfully booting the new kernel:<br>
synchronize contents of /boot to second disk<br>
(adjust hd0 / hd1 as necessary)<br>
<br>
Implement this is as a small script but _never_ call this script automatically<br>
_during the installation of a new kernel package_. (This prevents promoting a<br>
logical error to your backup /boot filesystem.)<br>
<br>
If you want to fully automate it then you could add this script to be run from<br>
/etc/rc.local or similar. If you've reached this stage you can be reasonably<br>
sure the kernel has managed to boot and mount all required filesystems.<br>
(However there's no guarantee the network works as expected, so you should<br>
make sure the relevant modules are included in the initrd or have console<br>
access available.)<br>
<br>
<br>
Yes, this is a bit more work then trying to get a software-raid /boot to work.<br>
But it has 2 distinct advantages:<br>
- if something accidentally deletes / corrupts a file in /boot there's<br>
still a reasonable chance for recovery _during system boot_<br>
- it works with all combinations of fat/gpt/md/lvm/crypt/btrfs<br>
<br>
bye<br>
<span class="HOEnZb"><font color="#888888">thomas<br>
</font></span></blockquote></div><br></div></div>