Some fixes to the startup scripts.