Revert "Do not restart local db server too early."

This reverts commit 2ddcd975ed2141ce3731e91a09e5b1d9a9add3b2.
Move DB GRANTS setup for master instance to the correct level.