View | Details | Raw Unified | Return to bug 17468
Collapse All | Expand All

(-)a/debian/docs/koha-common.xml (-16 / +2 lines)
Lines 119-134 Link Here
119
    <variablelist>
119
    <variablelist>
120
120
121
      <varlistentry>
121
      <varlistentry>
122
        <term><option>koha-start-zebra</option></term>
122
        <term><option>koha-zebra</option></term>
123
        <listitem>
123
        <listitem>
124
          <para>Start Zebra for named Koha instances.</para>
124
          <para>Handle Zebra for named Koha instances.</para>
125
        </listitem>
126
      </varlistentry>
127
128
      <varlistentry>
129
        <term><option>koha-restart-zebra</option></term>
130
        <listitem>
131
          <para>Restart Zebra for named Koha instances.</para>
132
        </listitem>
125
        </listitem>
133
      </varlistentry>
126
      </varlistentry>
134
127
Lines 140-152 Link Here
140
      </varlistentry>
133
      </varlistentry>
141
134
142
      <varlistentry>
135
      <varlistentry>
143
        <term><option>koha-stop-zebra</option></term>
144
        <listitem>
145
          <para>Stop Zebra for named Koha instances.</para>
146
        </listitem>
147
      </varlistentry>
148
149
      <varlistentry>
150
        <term><option>koha-indexer</option></term>
136
        <term><option>koha-indexer</option></term>
151
        <listitem>
137
        <listitem>
152
          <para>Manage the indexer daemon for named Koha instances.</para>
138
          <para>Manage the indexer daemon for named Koha instances.</para>
(-)a/debian/docs/koha-rebuild-zebra.xml (-3 / +1 lines)
Lines 86-94 Link Here
86
  
86
  
87
  <refsect1><title>See also</title>
87
  <refsect1><title>See also</title>
88
  <simplelist type="inline">
88
  <simplelist type="inline">
89
    <member><command>koha-restart-zebra(8)</command></member>
89
    <member><command>koha-zebra(8)</command></member>
90
    <member><command>koha-start-zebra(8)</command></member>
91
    <member><command>koha-stop-zebra(8)</command></member>
92
  </simplelist>
90
  </simplelist>
93
  </refsect1>
91
  </refsect1>
94
  
92
  
(-)a/debian/docs/koha-restart-zebra.xml (-44 lines)
Lines 1-44 Link Here
1
<article xmlns='http://docbook.org/ns/docbook'>
2
<title>koha-restart-zebra</title>
3
<info>
4
<productname>Koha</productname> is the first free software library automation package.
5
<author>
6
  <orgname>The Koha Community</orgname>
7
  <uri>http://koha-community.org/</uri>
8
</author>
9
</info>
10
11
<refentry xml:id="koha-restart-zebra">
12
13
  <refmeta>
14
    <refentrytitle>koha-restart-zebra</refentrytitle>
15
    <manvolnum>8</manvolnum>
16
  </refmeta>
17
18
  <refnamediv>
19
    <refname>koha-restart-zebra</refname>
20
    <refpurpose>Restart Zebra for named Koha instances.</refpurpose>
21
    <refclass>UNIX/Linux</refclass>
22
  </refnamediv>
23
24
  <refsynopsisdiv>
25
    <cmdsynopsis>
26
      <command>koha-restart-zebra</command> <arg choice="req" rep="repeat"><replaceable>instancename</replaceable></arg>
27
    </cmdsynopsis>
28
  </refsynopsisdiv>
29
30
  <refsect1><title>Description</title>
31
  <para>Restart Zebra for named Koha instances.</para>
32
  </refsect1>
33
  
34
  <refsect1><title>See also</title>
35
  <simplelist type="inline">
36
    <member><command>koha-rebuild-zebra(8)</command></member>
37
    <member><command>koha-start-zebra(8)</command></member>
38
    <member><command>koha-stop-zebra(8)</command></member>
39
  </simplelist>
40
  </refsect1>
41
  
42
</refentry>
43
44
</article>
(-)a/debian/docs/koha-start-zebra.xml (-44 lines)
Lines 1-44 Link Here
1
<article xmlns='http://docbook.org/ns/docbook'>
2
<title>koha-start-zebra</title>
3
<info>
4
<productname>Koha</productname> is the first free software library automation package.
5
<author>
6
  <orgname>The Koha Community</orgname>
7
  <uri>http://koha-community.org/</uri>
8
</author>
9
</info>
10
11
<refentry xml:id="koha-start-zebra">
12
13
  <refmeta>
14
    <refentrytitle>koha-start-zebra</refentrytitle>
15
    <manvolnum>8</manvolnum>
16
  </refmeta>
17
18
  <refnamediv>
19
    <refname>koha-start-zebra</refname>
20
    <refpurpose>Start Zebra for named Koha instances.</refpurpose>
21
    <refclass>UNIX/Linux</refclass>
22
  </refnamediv>
23
24
  <refsynopsisdiv>
25
    <cmdsynopsis>
26
      <command>koha-start-zebra</command> <arg choice="req" rep="repeat"><replaceable>instancename</replaceable></arg>
27
    </cmdsynopsis>
28
  </refsynopsisdiv>
29
30
  <refsect1><title>Description</title>
31
  <para>Start Zebra for named Koha instances.</para>
32
  </refsect1>
33
  
34
  <refsect1><title>See also</title>
35
  <simplelist type="inline">
36
    <member><command>koha-rebuild-zebra(8)</command></member>
37
    <member><command>koha-restart-zebra(8)</command></member>
38
    <member><command>koha-stop-zebra(8)</command></member>
39
  </simplelist>
40
  </refsect1>
41
  
42
</refentry>
43
44
</article>
(-)a/debian/docs/koha-stop-zebra.xml (-44 lines)
Lines 1-44 Link Here
1
<article xmlns='http://docbook.org/ns/docbook'>
2
<title>koha-stop-zebra</title>
3
<info>
4
<productname>Koha</productname> is the first free software library automation package.
5
<author>
6
  <orgname>The Koha Community</orgname>
7
  <uri>http://koha-community.org/</uri>
8
</author>
9
</info>
10
11
<refentry xml:id="koha-stop-zebra">
12
13
  <refmeta>
14
    <refentrytitle>koha-stop-zebra</refentrytitle>
15
    <manvolnum>8</manvolnum>
16
  </refmeta>
17
18
  <refnamediv>
19
    <refname>koha-stop-zebra</refname>
20
    <refpurpose>Stop Zebra for named Koha instances.</refpurpose>
21
    <refclass>UNIX/Linux</refclass>
22
  </refnamediv>
23
24
  <refsynopsisdiv>
25
    <cmdsynopsis>
26
      <command>koha-stop-zebra</command> <arg choice="req" rep="repeat"><replaceable>instancename</replaceable></arg>
27
    </cmdsynopsis>
28
  </refsynopsisdiv>
29
30
  <refsect1><title>Description</title>
31
  <para>Stop Zebra for named Koha instances.</para>
32
  </refsect1>
33
  
34
  <refsect1><title>See also</title>
35
  <simplelist type="inline">
36
    <member><command>koha-rebuild-zebra(8)</command></member>
37
    <member><command>koha-restart-zebra(8)</command></member>
38
    <member><command>koha-start-zebra(8)</command></member>
39
  </simplelist>
40
  </refsect1>
41
  
42
</refentry>
43
44
</article>
(-)a/debian/koha-common.bash-completion (-5 lines)
Lines 130-140 complete -F _koha_disabled_instances koha-enable Link Here
130
# koha-disable autocompletes with enabled instances
130
# koha-disable autocompletes with enabled instances
131
complete -F _koha_enabled_instances koha-disable
131
complete -F _koha_enabled_instances koha-disable
132
132
133
# koha-*-zebra autocomplete with enabled instances
134
complete -F _koha_enabled_instances koha-start-zebra
135
complete -F _koha_enabled_instances koha-restart-zebra
136
complete -F _koha_enabled_instances koha-stop-zebra
137
138
# koha-mysql autocompletes with a single instance name
133
# koha-mysql autocompletes with a single instance name
139
complete -F _koha_single_instance koha-mysql
134
complete -F _koha_single_instance koha-mysql
140
135
(-)a/debian/koha-common.init (-7 / +6 lines)
Lines 5-14 Link Here
5
# Required-Stop:     $remote_fs
5
# Required-Stop:     $remote_fs
6
# Default-Start:     2 3 4 5
6
# Default-Start:     2 3 4 5
7
# Default-Stop:      0 1 6
7
# Default-Stop:      0 1 6
8
# Short-Description: Start Zebra server for each Koha instance
8
# Short-Description: Start required services for each Koha instance
9
# Description:       For each enabled Koha instance on this host,
9
# Description:       For each enabled Koha instance on this host,
10
#                    as listed by "koha-list --enabled", start a Zebra
10
#                    start the required services (Zebra, SIP, Indexer and Plack)
11
#                    server (using koha-start-zebra).
12
### END INIT INFO
11
### END INIT INFO
13
12
14
# Author: Lars Wirzenius <lars@catalyst.net.nz>
13
# Author: Lars Wirzenius <lars@catalyst.net.nz>
Lines 22-28 NAME="koha-common" Link Here
22
SCRIPTNAME=/etc/init.d/$NAME
21
SCRIPTNAME=/etc/init.d/$NAME
23
22
24
# Exit if the package is not installed
23
# Exit if the package is not installed
25
[ -x /usr/sbin/koha-start-zebra ] || exit 0
24
[ -x /usr/sbin/koha-zebra ] || exit 0
26
25
27
# Read configuration variable file if it is present
26
# Read configuration variable file if it is present
28
if [ -r /etc/default/$NAME ]; then
27
if [ -r /etc/default/$NAME ]; then
Lines 55-61 do_start() Link Here
55
{
54
{
56
    # We insure all required directories exist, including disabled ones.
55
    # We insure all required directories exist, including disabled ones.
57
    koha-create-dirs $(koha-list)
56
    koha-create-dirs $(koha-list)
58
    koha-start-zebra $(koha-list --enabled)
57
    koha-zebra --start $(koha-list --enabled)
59
    koha-start-sip $(koha-list --enabled)
58
    koha-start-sip $(koha-list --enabled)
60
    koha-plack --start $(koha-list --enabled --plack)
59
    koha-plack --start $(koha-list --enabled --plack)
61
60
Lines 70-76 do_start() Link Here
70
do_stop()
69
do_stop()
71
{
70
{
72
    # We stop everything, including disabled ones.
71
    # We stop everything, including disabled ones.
73
    koha-stop-zebra $(koha-list) || true
72
    koha-zebra --stop $(koha-list) || true
74
    koha-stop-sip $(koha-list) || true
73
    koha-stop-sip $(koha-list) || true
75
    koha-plack --stop --quiet $(koha-list --enabled --plack)
74
    koha-plack --stop --quiet $(koha-list --enabled --plack)
76
75
Lines 83-89 do_stop() Link Here
83
# Function that sends a SIGHUP to the daemon/service
82
# Function that sends a SIGHUP to the daemon/service
84
#
83
#
85
do_reload() {
84
do_reload() {
86
    koha-restart-zebra $(koha-list --enabled)
85
    koha-zebra --restart $(koha-list --enabled)
87
    koha-stop-sip $(koha-list) || true
86
    koha-stop-sip $(koha-list) || true
88
    koha-start-sip $(koha-list --enabled)
87
    koha-start-sip $(koha-list --enabled)
89
    koha-plack --restart --quiet $(koha-list --enabled --plack)
88
    koha-plack --restart --quiet $(koha-list --enabled --plack)
(-)a/debian/koha-common.install (-3 lines)
Lines 25-37 debian/scripts/koha-plack usr/sbin Link Here
25
debian/scripts/koha-rebuild-zebra           usr/sbin
25
debian/scripts/koha-rebuild-zebra           usr/sbin
26
debian/scripts/koha-remove                  usr/sbin
26
debian/scripts/koha-remove                  usr/sbin
27
debian/scripts/koha-reset-passwd            usr/sbin
27
debian/scripts/koha-reset-passwd            usr/sbin
28
debian/scripts/koha-restart-zebra           usr/sbin
29
debian/scripts/koha-restore                 usr/sbin
28
debian/scripts/koha-restore                 usr/sbin
30
debian/scripts/koha-run-backups             usr/sbin
29
debian/scripts/koha-run-backups             usr/sbin
31
debian/scripts/koha-shell                   usr/sbin
30
debian/scripts/koha-shell                   usr/sbin
32
debian/scripts/koha-sitemap                 usr/sbin
31
debian/scripts/koha-sitemap                 usr/sbin
33
debian/scripts/koha-start-zebra             usr/sbin
34
debian/scripts/koha-stop-zebra              usr/sbin
35
debian/scripts/koha-translate               usr/sbin
32
debian/scripts/koha-translate               usr/sbin
36
debian/scripts/koha-upgrade-schema          usr/sbin
33
debian/scripts/koha-upgrade-schema          usr/sbin
37
debian/scripts/koha-upgrade-to-3.4          usr/sbin
34
debian/scripts/koha-upgrade-to-3.4          usr/sbin
(-)a/debian/koha-common.logrotate (-2 / +2 lines)
Lines 9-20 Link Here
9
    notifempty
9
    notifempty
10
    sharedscripts
10
    sharedscripts
11
    prerotate
11
    prerotate
12
        /usr/sbin/koha-stop-zebra $(koha-list --enabled) > /dev/null
12
        /usr/sbin/koha-zebra --stop $(koha-list --enabled) > /dev/null
13
        /usr/sbin/koha-plack --stop --quiet $(koha-list --enabled --plack) > /dev/null
13
        /usr/sbin/koha-plack --stop --quiet $(koha-list --enabled --plack) > /dev/null
14
    endscript
14
    endscript
15
    postrotate
15
    postrotate
16
        /etc/init.d/apache2 reload > /dev/null
16
        /etc/init.d/apache2 reload > /dev/null
17
        /usr/sbin/koha-plack --start --quiet $(koha-list --enabled --plack) > /dev/null
17
        /usr/sbin/koha-plack --start --quiet $(koha-list --enabled --plack) > /dev/null
18
        /usr/sbin/koha-start-zebra $(koha-list --enabled) > /dev/null
18
        /usr/sbin/koha-zebra --start $(koha-list --enabled) > /dev/null
19
    endscript
19
    endscript
20
}
20
}
(-)a/debian/scripts/koha-create (-1 / +1 lines)
Lines 784-790 then Link Here
784
    service apache2 restart
784
    service apache2 restart
785
785
786
    # Start Zebra.
786
    # Start Zebra.
787
    koha-start-zebra "$name"
787
    koha-zebra --start "$name"
788
788
789
    if [ "$USE_INDEXER_DAEMON" = "yes" ]; then
789
    if [ "$USE_INDEXER_DAEMON" = "yes" ]; then
790
        # Start Indexer daemon
790
        # Start Indexer daemon
(-)a/debian/scripts/koha-disable (-1 / +1 lines)
Lines 67-73 do Link Here
67
                koha-stop-sip $name
67
                koha-stop-sip $name
68
            fi
68
            fi
69
            if is_zebra_running $name; then
69
            if is_zebra_running $name; then
70
                koha-stop-zebra $name
70
                koha-zebra --stop $name
71
            fi
71
            fi
72
            if is_indexer_running $name; then
72
            if is_indexer_running $name; then
73
                koha-indexer --stop $name
73
                koha-indexer --stop $name
(-)a/debian/scripts/koha-remove (-1 / +1 lines)
Lines 77-83 eof Link Here
77
    fi #`
77
    fi #`
78
    
78
    
79
    # If the daemon is not running already, we don't want to fail this loop. So bin the result code if this fails.
79
    # If the daemon is not running already, we don't want to fail this loop. So bin the result code if this fails.
80
    koha-stop-zebra $name || /bin/true
80
    koha-zebra --stop $name || /bin/true
81
81
82
    instancefile=$(get_apache_config_for $name)
82
    instancefile=$(get_apache_config_for $name)
83
    le_opacdomain=$(letsencrypt_get_opacdomain_for $name)
83
    le_opacdomain=$(letsencrypt_get_opacdomain_for $name)
(-)a/debian/scripts/koha-restart-zebra (-116 lines)
Lines 1-116 Link Here
1
#!/bin/sh
2
#
3
# koha-restart-zebra - Restart Zebra for named Koha instances
4
# Copyright 2010  Catalyst IT, Ltd
5
# 
6
# This program is free software: you can redistribute it and/or modify
7
# it under the terms of the GNU General Public License as published by
8
# the Free Software Foundation, either version 3 of the License, or
9
# (at your option) any later version.
10
# 
11
# This program is distributed in the hope that it will be useful,
12
# but WITHOUT ANY WARRANTY; without even the implied warranty of
13
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
# GNU General Public License for more details.
15
# 
16
# You should have received a copy of the GNU General Public License
17
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
19
set -e
20
21
# include helper functions
22
if [ -f "/usr/share/koha/bin/koha-functions.sh" ]; then
23
    . "/usr/share/koha/bin/koha-functions.sh"
24
else
25
    echo "Error: /usr/share/koha/bin/koha-functions.sh not present." 1>&2
26
    exit 1
27
fi
28
29
restart_zebra_instance()
30
{
31
    local instancename=$1
32
33
    if is_zebra_running $instancename; then
34
        echo "Restarting Zebra server for $instancename"
35
        daemon \
36
            --name="$instancename-koha-zebra" \
37
            --pidfiles="/var/run/koha/$instancename/" \
38
            --errlog="/var/log/koha/$instancename/zebra-error.log" \
39
            --stdout="/var/log/koha/$instancename/zebra.log" \
40
            --output="/var/log/koha/$instancename/zebra-output.log" \
41
            --verbose=1 \
42
            --respawn \
43
            --delay=30 \
44
            --user="$instancename-koha.$instancename-koha" \
45
            --restart \
46
            -- \
47
            zebrasrv \
48
            -v none,fatal,warn \
49
            -f "/etc/koha/sites/$instancename/koha-conf.xml" && \
50
        return 0
51
    else
52
        return 1
53
    fi
54
}
55
56
start_zebra_instance()
57
{
58
    local instancename=$1
59
60
    if is_enabled $instancename; then
61
        echo "Starting Zebra server for $instancename"
62
        daemon \
63
            --name="$instancename-koha-zebra" \
64
            --pidfiles="/var/run/koha/$instancename/" \
65
            --errlog="/var/log/koha/$instancename/zebra-error.log" \
66
            --stdout="/var/log/koha/$instancename/zebra.log" \
67
            --output="/var/log/koha/$instancename/zebra-output.log" \
68
            --verbose=1 \
69
            --respawn \
70
            --delay=30 \
71
            --user="$instancename-koha.$instancename-koha" \
72
            -- \
73
            zebrasrv \
74
            -v none,fatal,warn \
75
            -f "/etc/koha/sites/$instancename/koha-conf.xml" && \
76
        return 0
77
    else
78
        return 1
79
    fi
80
}
81
82
usage()
83
{
84
    local scriptname=$0
85
    cat <<EOF
86
Restart Zebra for Koha instances.
87
88
Usage: $scriptname instancename1 instancename2...
89
90
EOF
91
}
92
93
# Parse command line.
94
#[ $# -ge 1 ] || ( usage ; die "Missing instance name..." )
95
96
# Loop through the instance names
97
for name in "$@"
98
do
99
    if is_instance $name ; then
100
        if ! is_zebra_running $name; then
101
            warn "Zebra does not appear to have been running for instance $name."
102
103
            if ! start_zebra_instance $name ; then
104
                warn "Something went wrong starting Zebra for $name."
105
            fi
106
        else
107
            if ! restart_zebra_instance $name; then
108
              warn "Something went wrong restarting Zebra for $name."
109
            fi
110
        fi
111
    else
112
        warn "Unknown instance $name."
113
    fi
114
done
115
116
exit 0
(-)a/debian/scripts/koha-start-zebra (-89 lines)
Lines 1-89 Link Here
1
#!/bin/sh
2
#
3
# koha-start-zebra - Start Zebra for named Koha instances
4
# Copyright 2010  Catalyst IT, Ltd
5
# 
6
# This program is free software: you can redistribute it and/or modify
7
# it under the terms of the GNU General Public License as published by
8
# the Free Software Foundation, either version 3 of the License, or
9
# (at your option) any later version.
10
# 
11
# This program is distributed in the hope that it will be useful,
12
# but WITHOUT ANY WARRANTY; without even the implied warranty of
13
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
# GNU General Public License for more details.
15
# 
16
# You should have received a copy of the GNU General Public License
17
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
19
set -e
20
21
# include helper functions
22
if [ -f "/usr/share/koha/bin/koha-functions.sh" ]; then
23
    . "/usr/share/koha/bin/koha-functions.sh"
24
else
25
    echo "Error: /usr/share/koha/bin/koha-functions.sh not present." 1>&2
26
    exit 1
27
fi
28
29
start_zebra_instance()
30
{
31
    local instancename=$1
32
33
    # get zebra log levels from koha-conf.xml
34
    local loglevels=$(get_loglevels $instancename)
35
36
    echo "Starting Zebra server for $instancename"
37
    touch "/var/log/koha/$instancename/zebra-error.log" \
38
        "/var/log/koha/$instancename/zebra-output.log"
39
    chown "$instancename-koha:$instancename-koha" \
40
        "/var/log/koha/$instancename/zebra-error.log" \
41
        "/var/log/koha/$instancename/zebra-output.log"
42
    daemon \
43
        --name="$instancename-koha-zebra" \
44
        --pidfiles="/var/run/koha/$instancename/" \
45
        --errlog="/var/log/koha/$instancename/zebra-error.log" \
46
        --output="/var/log/koha/$instancename/zebra-output.log" \
47
        --verbose=1 \
48
        --respawn \
49
        --delay=30 \
50
        --user="$instancename-koha.$instancename-koha" \
51
        -- \
52
        zebrasrv \
53
        -v $loglevels \
54
        -f "/etc/koha/sites/$instancename/koha-conf.xml" && \
55
        return 0 || \
56
        return 1
57
}
58
59
usage()
60
{
61
    local scriptname=$0
62
    cat <<EOF
63
Starts Zebra for Koha instances.
64
65
Usage: $scriptname instancename1 instancename2...
66
67
EOF
68
}
69
70
# Parse command line.
71
#[ $# -ge 1 ] || ( usage ; die "Missing instance name..." )
72
73
# Loop through the instance names
74
for name in "$@"
75
do
76
    if is_instance $name ; then
77
        if ! is_zebra_running $name; then
78
            if ! start_zebra_instance $name; then
79
                warn "Something went wrong starting Zebra for $name."
80
            fi
81
        else
82
            warn "Zebra already running for instance $name."
83
        fi
84
    else
85
        warn "Unknown instance $name."
86
    fi
87
done
88
89
exit 0
(-)a/debian/scripts/koha-stop-zebra (-75 lines)
Lines 1-74 Link Here
1
#!/bin/sh
2
#
3
# koha-stop-zebra - Stop Zebra for named Koha instances
4
# Copyright 2010  Catalyst IT, Ltd
5
# 
6
# This program is free software: you can redistribute it and/or modify
7
# it under the terms of the GNU General Public License as published by
8
# the Free Software Foundation, either version 3 of the License, or
9
# (at your option) any later version.
10
# 
11
# This program is distributed in the hope that it will be useful,
12
# but WITHOUT ANY WARRANTY; without even the implied warranty of
13
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
# GNU General Public License for more details.
15
# 
16
# You should have received a copy of the GNU General Public License
17
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
19
set -e
20
21
# include helper functions
22
if [ -f "/usr/share/koha/bin/koha-functions.sh" ]; then
23
    . "/usr/share/koha/bin/koha-functions.sh"
24
else
25
    echo "Error: /usr/share/koha/bin/koha-functions.sh not present." 1>&2
26
    exit 1
27
fi
28
29
stop_zebra_instance()
30
{
31
    local instancename=$1
32
33
    local PIDFILE="/var/run/koha/${instancename}/${instancename}-koha-zebra.pid"
34
    echo "Stopping Zebra server for $instancename"
35
36
    if start-stop-daemon --pidfile ${PIDFILE} --stop --quiet --retry=TERM/30/KILL/5; then
37
        return 0;
38
    else
39
        return 1;
40
    fi
41
42
}
43
44
usage()
45
{
46
    local scriptname=$0
47
    cat <<EOF
48
Stops Zebra for Koha instances.
49
50
Usage: $scriptname instancename1 instancename2...
51
52
EOF
53
}
54
55
# Parse command line.
56
#[ $# -ge 1 ] || ( usage ; die "Missing instance name..." )
57
58
# Loop through the instance names
59
for name in "$@"
60
do
61
    if is_instance $name ; then
62
        if is_zebra_running $name; then
63
            if ! stop_zebra_instance $name; then
64
                warn "Something went wrong stopping Zebra for $name."
65
            fi
66
        else
67
            warn "Zebra already stopped for instance $name."
68
        fi
69
    else
70
        warn "Unknown instance $name."
71
    fi
72
done
73
74
exit 0
75
- 

Return to bug 17468