I'm getting quite confused about what files get called at start up. I've done a bit of a web search which revealed that inittab is the place to start. That calls rc.5, which calls, among other things, slim/wait.sh . However I've got programs to run by adding them to slim/nowait.sh which doesn't seem to get called by anything! This is mainly something I'd like to understand, rather than a problem but I would like to know where to start looking for shutdown scripts as I'd like to run a command at shutdown. I've tried adding stuff to rc.6 but that didn't seem to work.