Refactored bitcoinutil and db initialization