File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -209,7 +209,6 @@ sub start {
209
209
my $count = 0;
210
210
my $success = 0;
211
211
my $config = $self -> wreConfig;
212
- $config -> set(" wreMonitor/mysqlAdministrativelyDown" , 0);
213
212
my $host = WRE::Host-> new(wreConfig => $config );
214
213
my $cmd = " mysql.server start --user=" .$config -> get(" user" );
215
214
` $cmd ` ; # catch command line output
@@ -218,6 +217,9 @@ sub start {
218
217
eval {$success = $self -> ping };
219
218
$count ++;
220
219
}
220
+ if ($success ) {
221
+ $config -> set(" wreMonitor/mysqlAdministrativelyDown" , 0);
222
+ }
221
223
return $success ;
222
224
}
223
225
@@ -236,7 +238,6 @@ sub stop {
236
238
my $count = 0;
237
239
my $success = 1;
238
240
my $config = $self -> wreConfig;
239
- $config -> set(" wreMonitor/mysqlAdministrativelyDown" , 1);
240
241
my $host = WRE::Host-> new(wreConfig => $config );
241
242
my $cmd = " mysql.server stop" ;
242
243
` $cmd ` ; # catch command line output
@@ -245,6 +246,9 @@ sub stop {
245
246
eval {$success = $self -> ping };
246
247
$count ++;
247
248
}
249
+ if (!$success ) {
250
+ $config -> set(" wreMonitor/mysqlAdministrativelyDown" , 1);
251
+ }
248
252
return !$success ;
249
253
}
250
254
You can’t perform that action at this time.
0 commit comments