1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-06-09 06:41:19 +03:00

tweaked to correct a failing attach at startup

This commit is contained in:
david hill 2017-07-25 15:25:05 -05:00
parent 6a276600f7
commit 3825ea9681

View File

@ -7871,11 +7871,23 @@ namespace oam
****************************************************************************/ ****************************************************************************/
std::string Oam::getEC2VolumeStatus(std::string volumeName) std::string Oam::getEC2VolumeStatus(std::string volumeName)
{
bool pass = true;
for ( int retry = 0 ; retry < 5 ; retry++ )
{ {
// run script to get Volume Status // run script to get Volume Status
string cmd = InstallDir + "/bin/MCSVolumeCmds.sh describe " + volumeName + " > /tmp/getVolumeStatus_" + volumeName; string cmd = InstallDir + "/bin/MCSVolumeCmds.sh describe " + volumeName + " > /tmp/getVolumeStatus_" + volumeName;
int ret = system(cmd.c_str()); int ret = system(cmd.c_str());
if (WEXITSTATUS(ret) != 0 ) if (WEXITSTATUS(ret) == 0 )
break;
else
{
sleep(1);
pass = false;
}
}
if (!pass)
return "failed"; return "failed";
// get status // get status