I am trying to create a daemon that is started automatically during the boot-up. It depends on the network, local fs and remote fs services. I believe I have done everything to indicate these dependencies and I expect the daemon to be started after the network daemons are up and running. But when I look into my logs I see that my daemon S1 is consistently starting before the network daemon is available.

The following is the init information in my S1.sh script located in /etc/init.d:
Qt Code:
  1. #!/bin/sh
  3. # Provides: My S1 Service
  4. # Required-Start: $local_fs $network $remote_fs
  5. # Required-Stop: $local_fs $network $remote_fs
  6. # Default-Start: 2 3 4 5
  7. # Default-Stop: 0 1 6
  8. # Short-Description: start S1 Service
  9. # Description: S1 Service
  10. ### END INIT INFO
To copy to clipboard, switch view to plain text mode 

And the following are my entries in the rc directories:

Qt Code:
  1. rc0.d:
  2. K20S1_Service.sh -> ../init.d/S1.sh
  4. rc1.d:
  5. K20S1_Service.sh -> ../init.d/S1.sh
  7. rc2.d:
  8. S98S1_Service.sh -> ../init.d/S1.sh
  10. rc3.d:
  11. S98S1_Service.sh -> ../init.d/S1.sh
  13. rc4.d:
  14. S98S1_Service.sh -> ../init.d/S1.sh
  16. rc5.d:
  17. S98S1_Service.sh -> ../init.d/S1.sh
  19. rc6.d:
  20. K20S1_Service.sh -> ../init.d/S1.sh
To copy to clipboard, switch view to plain text mode 

Is there anything more I have to do or am I doing anything wrong to make sure that my service/daemon is started after the network services/daemons are available?

I am reading up on upstart but I really like to know whats wrong with my current scipts and daemon startup.