startup script fixes