Improves the SBD config writer and fixes some two-line warning messages

* Patches from @lhwang flattened and slightly modified based on feedback
* Contract some two-line error messages to make them easier to read