Fix various errors for boot