source:
npl/commonservers/mysql51/start
@
f49e71c
| Last change on this file since f49e71c was c5c522c, checked in by , 9 years ago | |
|---|---|
|
|
| File size: 402 bytes | |
| Line | |
|---|---|
| 1 | #!/bin/bash |
| 2 | TRY=50 |
| 3 | svc -u /service/mysql |
| 4 | while ! mysqladmin status --password=`cat /etc/my.passwd` &>/dev/null; do |
| 5 | echo "Waiting for mysql to start.. ($TRY)" |
| 6 | sleep 1 |
| 7 | (( TRY-- )) |
| 8 | if [ $TRY -eq 0 ]; then |
| 9 | syn3-state mysql CAUTION "Startup error" |
| 10 | svc -d /service/mysql |
| 11 | exit 1 |
| 12 | fi |
| 13 | done |
| 14 | #race condition |
| 15 | sleep 1 |
| 16 | syn3-state mysql OK "Started" |
Note: See TracBrowser
for help on using the repository browser.
