mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

57 lines
1.7 KiB

  1. #!/bin/bash
  2. #
  3. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  4. #
  5. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  6. # Please add additional copyright information _after_ the line containing
  7. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  8. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  9. #
  10. # ROCK Linux: rock-src/package/rene/coda/coda-server.init
  11. # ROCK Linux is Copyright (C) 1998 - 2005 Clifford Wolf
  12. #
  13. # This program is free software; you can redistribute it and/or modify
  14. # it under the terms of the GNU General Public License as published by
  15. # the Free Software Foundation; either version 2 of the License, or
  16. # (at your option) any later version. A copy of the GNU General Public
  17. # License can be found at Documentation/COPYING.
  18. #
  19. # Many people helped and are helping developing ROCK Linux. Please
  20. # have a look at http://www.rocklinux.org/ and the Documentation/TEAM
  21. # file for details.
  22. #
  23. # --- ROCK-COPYRIGHT-NOTE-END ---
  24. #
  25. # Desc: The CODA filesystem server daemon
  26. # Runlevel: 32 rcX
  27. #
  28. # (C) FEB 2002 by Ren� Rebe <rene.rebe@gmx.net>
  29. #
  30. VICE=/vice
  31. VICESRV=$VICE/srv
  32. PIDFILE=$VICE/srv/pid
  33. main_begin
  34. block_begin(start, `starting CODA server daemon ...')
  35. if [ -f ${VICESRV}/CRASH ]; then
  36. echo "$(date): found CRASH, codasrv not started." \
  37. >> ${VICE}/srv/SrvErr
  38. echo "found CRASH file, codasrv not started."
  39. exit "-1"
  40. fi
  41. check(`/opt/coda/sbin/startserver &')
  42. block_end
  43. block_begin(stop, `stopping CODA server daemon ...')
  44. if [ -f $PIDFILE ]; then
  45. /opt/coda/sbin/volutil shutdown
  46. echo "sleeping 40 secs to let codasrv shutdown ..."
  47. sleep 40
  48. fi
  49. check(`killall -9 codasrv')
  50. block_end
  51. main_end