better handling of init.d stuff