Service startup script - bugfixes.