shutdown script refacotred to use init.d