sh: refactored sh startup scripts