~ubuntu-branches/ubuntu/vivid/slurm-llnl/vivid

« back to all changes in this revision

Viewing changes to debian/slurm-llnl-slurmdbd.init.d

  • Committer: Bazaar Package Importer
  • Author(s): Gennaro Oliva
  • Date: 2009-09-24 23:28:15 UTC
  • mfrom: (1.1.11 upstream) (3.2.4 sid)
  • Revision ID: james.westby@ubuntu.com-20090924232815-enh65jn32q1ebg07
Tags: 2.0.5-1
* New upstream release 
* Changed dependecy from lib-mysqlclient15 to lib-mysqlclient 
* Added Default-Start for runlevel 2 and 4 and $remote_fs requirement in
  init.d scripts (Closes: #541252)
* Postinst checks for wrong runlevels 2 and 4 links
* Upgraded to standard version 3.8.3
* Add lintian overrides for missing slurm-llnl-configurator.html in doc
  base registration
* modified postrm scripts to ignore pkill return value in order to avoid
  postrm failure when no slurm process is running
* Checking for slurmctld.pid before cancelling running and pending
  jobs during package removal 

Show diffs side-by-side

added added

removed removed

Lines of Context:
11
11
#
12
12
### BEGIN INIT INFO
13
13
# Provides:          slurmbd
14
 
# Required-Start:    $local_fs $syslog $network $named munge
15
 
# Required-Stop:     $local_fs $syslog $network $named munge
16
 
# Default-Start:     3 5
17
 
# Default-Stop:      0 1 2 6
 
14
# Required-Start:    $remote_fs $syslog $network munge
 
15
# Required-Stop:     $remote_fs $syslog $network munge
 
16
# Should-Start:      $named
 
17
# Should-Stop:       $named
 
18
# Default-Start:     2 3 4 5
 
19
# Default-Stop:      0 1 6
18
20
# Short-Description: SLURM database daemon
19
21
# Description:       Start slurm to provide database server for SLURM
20
22
### END INIT INFO
61
63
}
62
64
 
63
65
start() {
 
66
 
 
67
    # Create run-time variable data
 
68
    mkdir -p /var/run/slurm-llnl
 
69
    chown slurm:slurm /var/run/slurm-llnl
 
70
 
64
71
    unset HOME MAIL USER USERNAME 
65
72
    log_daemon_msg "Starting $DESCRIPTION"
66
73
    STARTERRORMSG="$(start-stop-daemon --start --oknodo \
103
110
        if [ "$rpid" != "" -a "$pid" != "" ]; then
104
111
            for i in $pid ; do
105
112
                if [ "$i" = "$rpid" ]; then 
106
 
                    echo $"slurmdbd (pid $pid) is running..."
 
113
                    echo "slurmdbd (pid $pid) is running..."
107
114
                    return 0
108
115
                fi     
109
116
            done
110
117
        elif [ "$rpid" != "" -a "$pid" = "" ]; then
111
 
            echo $"slurmdbd is stopped"
 
118
            echo "slurmdbd is stopped"
112
119
            return 1
113
120
        fi 
114
121
 
115
122
    fi
116
123
     
117
 
    echo $"slurmdbd is stopped"
 
124
    echo "slurmdbd is stopped"
118
125
    
119
126
    return 3
120
127
}