I've goot a multiboot system on my laptop, which is booted via GRUB (version 1.99-21ubuntu3.17). My main system is Ubuntu Linux, but I also have a custom record for booting NetBSD that I made manually. My problem is, when Ubuntu does an update involving a kernel change, boot.cfg gets automatically re-written. And while it does provide entries for all OSes presented on my HD (also Windows and Hackintosh), the NetBSD entry gets skipped, so I need to write it in each time manually. How can I work it around, to let GRUB remember all previous records, not only the ones it feels like?

The above was written without having tried it. In the meantime, found what a Ubuntu user had to say about it. Same thing, but explained at least. That method loads the netbsd kernel directly. Read further down about chainloading the partition so that your BSD bootloader and its settings are used for loading.

Tried the direct kernel method using /etc/grub.d/40_custom, and it works here on this Slackish for NetBSD 7.0 BETA. No doubt chainloading would work the same way.

Side issues:
grub-probe can find the BSD's. grub-mount can mount at least the ones using "ufs2" read-write, though I won't vouch for the safety of that. The holdup to auto-detection by grub-mkconfig is that the grub maintainers haven't published their own scripts for OS detection, but for the present rely on os-prober, which obviously can't handle the job. The Gnu folks list this in grub-mkconfig's "Bugs" section.

Last edited by roarde; 4th April 2015 at 01:39 AM.
Reason: clarification

Thank you Roarde! I'm ashamed to admit having read that Ubuntu help page when I was searching for instructions on how to boot NetBSD from GRUB, but the "/etc/grub.d/40_custom" thing somehow escaped my mind. You never stop learning...

BSD_keith, I appreciate your point, I thought of using the NetBSD bootloader too, but for a number of reasons I'd like to keep GRUB. Would love to play with the NetBSD loader too though..