proftpd 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. #!/bin/sh
  2. ########################################################################
  3. # Begin /etc/init.d/vsftpd
  4. #
  5. # Description : Start Pro FTP Daemon
  6. #
  7. # Author : Bruce Dubbs - bdubbs@linuxfromscratch.org
  8. #
  9. # Version : LFS 7.2
  10. #
  11. ########################################################################
  12. ### BEGIN INIT INFO
  13. # Provides: ftpd
  14. # Required-Start: $remote_fs
  15. # Should-Start:
  16. # Required-Stop: $remote_fs
  17. # Should-Stop:
  18. # Default-Start: 3 4 5
  19. # Default-Stop: 0 1 2 6
  20. # Short-Description: Starts proftpd server.
  21. # Description: Starts Professional FTP Daemon (proftpd).
  22. # X-LFS-Provided-By: LFS
  23. ### END INIT INFO
  24. . /etc/rc.d/functions
  25. #$LastChangedBy: bdubbs $
  26. #$Date: 2012-04-21 17:07:20 -0500 (Sat, 21 Apr 2012) $
  27. case "$1" in
  28. start)
  29. log_info_msg "Starting FTP Server..."
  30. start_daemon /usr/sbin/proftpd
  31. evaluate_retval
  32. ;;
  33. stop)
  34. log_info_msg "Stopping FTP Server..."
  35. killproc /usr/sbin/proftpd
  36. evaluate_retval
  37. ;;
  38. reload)
  39. log_info_msg "Reloading FTP Server..."
  40. killproc /usr/sbin/proftpd -HUP
  41. evaluate_retval
  42. ;;
  43. restart)
  44. $0 stop
  45. sleep 1
  46. $0 start
  47. ;;
  48. status)
  49. statusproc /usr/sbin/proftpd
  50. ;;
  51. *)
  52. echo "Usage: $0 {start|stop|reload|restart|status}"
  53. exit 1
  54. ;;
  55. esac
  56. # End /etc/init.d/proftpd