blob: 67ba05ae94543a0bf5bfd5e8131284b314d9b8ed [file] [log] [blame]
Alpana Kumarib48e6ff2022-04-24 23:42:28 -05001#!/bin/sh
2retries=100
Priyanga Ramasamy29fbea92023-10-04 01:28:10 -05003echo "Checking every 2s for active VPD parsers...."
jinuthomas45d54972023-07-03 04:36:29 -05004while [ "$retries" -ne 0 ]
Alpana Kumarib48e6ff2022-04-24 23:42:28 -05005do
6 sleep 2
7 systemctl -q is-active ibm-vpd-parser@*.service
8 active=$?
9 if [ $active -ne 0 ]
10 then
11 echo "Done wait for active VPD parsers. Exit success"
12 exit 0
13 fi
jinuthomas45d54972023-07-03 04:36:29 -050014 retries="$((retries - 1))"
Alpana Kumarib48e6ff2022-04-24 23:42:28 -050015 echo "VPD parsers still running. Retries remaining: $retries"
16done
17echo "Exit wait for VPD services to finish with timeout"
18exit 1