cdq 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. #!/bin/sh
  2. #
  3. # cdq This shell script takes care of starting and stopping
  4. # the ipfcst-cdq subsystem (cdq).
  5. #
  6. # chkconfig: 345 64 36
  7. # description: ipfcst-cdq.
  8. # processname: cdq
  9. # Source function library.
  10. #. /etc/rc.d/init.d/functions
  11. # Source networking configuration.
  12. #. /etc/sysconfig/network
  13. # Support for extra options passed to cdq
  14. command=$1 && shift
  15. extra_opts="$@"
  16. start(){
  17. sh /home/syjy/ipfcstV3/bin/start-cdq.sh
  18. }
  19. stop(){
  20. sh /home/syjy/ipfcstV3/bin/stop-cdq.sh
  21. }
  22. restart(){
  23. stop
  24. start
  25. }
  26. status(){
  27. sh /home/syjy/ipfcstV3/bin/status-cdq.sh
  28. }
  29. # See how we were called.
  30. case "$command" in
  31. start)
  32. start
  33. ;;
  34. startup)
  35. start
  36. ;;
  37. stop)
  38. stop
  39. ;;
  40. shutdown)
  41. stop
  42. ;;
  43. status)
  44. status
  45. ;;
  46. state)
  47. status
  48. ;;
  49. restart)
  50. restart
  51. ;;
  52. restartup)
  53. restart
  54. ;;
  55. reload)
  56. exit 3
  57. ;;
  58. force-reload)
  59. restart
  60. ;;
  61. *)
  62. echo $"Usage: $0 {start|startup|stop|shutdown|status|state|restart|restartup|reload|force-reload}"
  63. exit 2
  64. esac
  65. exit $?