From 8a946e7c737404a7917910767c2fb5a1bbea8070 Mon Sep 17 00:00:00 2001 From: david hill Date: Mon, 22 Feb 2016 11:42:40 -0600 Subject: [PATCH] change to new mariadb rpms --- oam/install_scripts/performance_installer.sh | 114 ++-------------- oam/install_scripts/user_installer.sh | 112 ++------------- oamapps/postConfigure/postConfigure.cpp | 25 ++-- procmgr/processmanager.cpp | 3 +- procmon/processmonitor.cpp | 26 +--- tools/configMgt/autoInstaller.cpp | 135 +++++-------------- 6 files changed, 73 insertions(+), 342 deletions(-) diff --git a/oam/install_scripts/performance_installer.sh b/oam/install_scripts/performance_installer.sh index 329a1c6bb..2efa68ed5 100644 --- a/oam/install_scripts/performance_installer.sh +++ b/oam/install_scripts/performance_installer.sh @@ -43,12 +43,15 @@ log_user $DEBUG spawn -noecho /bin/bash # if { $PKGTYPE == "rpm" } { - set PKGERASE "rpm -e --nodeps --allmatches " + set PKGERASE "rpm -e --nodeps $(rpm -qa | grep '^infinidb')" + set PKGERASE1 "rpm -e --nodeps " + set PKGINSTALL "rpm -ivh $NODEPS " set PKGUPGRADE "rpm -Uvh --noscripts " } else { if { $PKGTYPE == "deb" } { - set PKGERASE "dpkg -P " + set PKGERASE "dpkg -P $(dpkg --get-selections | grep '^infinidb')" + set PKGERASE1 "dpkg -P " set PKGINSTALL "dpkg -i --force-confnew" set PKGUPGRADE "dpkg -i --force-confnew" } else { @@ -96,7 +99,7 @@ if { $INSTALLTYPE == "initial" || $INSTALLTYPE == "uninstall" } { # erase package # send_user "Erase InfiniDB Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGERASE calpont >/dev/null 2>&1; $PKGERASE infinidb-enterprise >/dev/null 2>&1; $PKGERASE infinidb-libs infinidb-platform;$PKGERASE dummy'\n" + send "ssh $USERNAME@$SERVER '$PKGERASE ;$PKGERASE1 dummy'\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -143,7 +146,7 @@ expect { -re {[$#] } { } } -send "scp $CALPONTRPM1 $CALPONTRPM2 $CALPONTMYSQLRPM $CALPONTMYSQLDRPM $USERNAME@$SERVER:.;$PKGERASE dummy\n" +send "scp $CALPONTRPM1 $USERNAME@$SERVER:.;$PKGERASE dummy\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -151,7 +154,7 @@ if { $PASSWORD != "ssh" } { "passphrase" { send "$PASSWORD\n" } } } -set timeout 120 +set timeout 180 expect { "package dummy" { send_user "DONE" } "directory" { send_user "ERROR\n" ; @@ -161,30 +164,6 @@ expect { } send_user "\n" -#sleep to make sure it's finished -sleep 5 -if { $CALPONTRPM3 != "dummy.rpm" } { - expect -re {[$#] } - send_user "Copy new InfiniDB Enterprise Packages to Module " - send "scp $CALPONTRPM3 $USERNAME@$SERVER:.\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 120 - expect { - "100%" { send_user "DONE" } - "directory" { send_user "ERROR\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - send_user "\n" -} - #sleep to make sure it's finished sleep 5 @@ -195,7 +174,7 @@ if { $INSTALLTYPE == "initial"} { # send_user "Install InfiniDB Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGINSTALL $CALPONTRPM1 $CALPONTRPM2;$PKGERASE dummy'\n" + send "ssh $USERNAME@$SERVER '$PKGINSTALL $CALPONTRPM1 ;$PKGERASE dummy'\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -215,81 +194,6 @@ if { $INSTALLTYPE == "initial"} { "conflicts" { send_user "ERROR: File Conflict issue\n" ; exit 1 } } - if { $CALPONTRPM3 != "dummy.rpm" } { - expect -re {[$#] } - send_user "\n" - send_user "Install InfiniDB Enterprise Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGINSTALL $CALPONTRPM3'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 60 - expect { - "completed" { send_user "DONE" } - "Setting up" { send_user "DONE" } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Permission denied, please try again" { send_user "ERROR: Invalid password\n" ; exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - "conflicts" { send_user "ERROR: File Conflict issue\n" ; exit 1 } - } - } - -} else { - # - # upgrade package - # - send_user "Upgrade InfiniDB Packages on Module " - - send "ssh $USERNAME@$SERVER '$PKGUPGRADE $CALPONTRPM1 $CALPONTRPM2;$PKGERASE dummy'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 60 - expect { - "package dummy" { send_user "DONE" } - "already installed" { send_user "INFO: Already Installed\n" ; exit 1 } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Permission denied, please try again" { send_user "ERROR: Invalid password\n" ; exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - - if { $CALPONTRPM3 != "dummy.rpm" } { - send_user "\n" - send_user "Upgrade InfiniDB Enterprise Packages on Module " - - send "ssh $USERNAME@$SERVER '$PKGUPGRADE $CALPONTRPM3'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 60 - expect { - "completed" { send_user "DONE" } - "Setting up" { send_user "DONE" } - "already installed" { send_user "INFO: Already Installed\n" ; exit 1 } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Permission denied, please try again" { send_user "ERROR: Invalid password\n" ; exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - } - } send_user "\n" #sleep to make sure it's finished diff --git a/oam/install_scripts/user_installer.sh b/oam/install_scripts/user_installer.sh index 267f9d7ae..d7f042a6f 100644 --- a/oam/install_scripts/user_installer.sh +++ b/oam/install_scripts/user_installer.sh @@ -49,12 +49,15 @@ log_user $DEBUG spawn -noecho /bin/bash # if { $PKGTYPE == "rpm" } { - set PKGERASE "rpm -e --nodeps --allmatches " + set PKGERASE "rpm -e --nodeps $(rpm -qa | grep '^infinidb')" + set PKGERASE1 "rpm -e --nodeps " + set PKGINSTALL "rpm -ivh $NODEPS " set PKGUPGRADE "rpm -Uvh --noscripts " } else { if { $PKGTYPE == "deb" } { - set PKGERASE "dpkg -P " + set PKGERASE "dpkg -P $(dpkg --get-selections | grep '^infinidb')" + set PKGERASE1 "dpkg -P " set PKGINSTALL "dpkg -i --force-confnew" set PKGUPGRADE "dpkg -i --force-confnew" } else { @@ -99,7 +102,7 @@ if { $INSTALLTYPE == "initial" || $INSTALLTYPE == "uninstall" } { # erase InfiniDB packages # send_user "Erase InfiniDB Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGERASE calpont >/dev/null 2>&1; $PKGERASE calpont-mysql >/dev/null 2>&1; $PKGERASE calpont-mysqld >/dev/null 2>&1; $PKGERASE infinidb-enterprise >/dev/null 2>&1; $PKGERASE infinidb-libs infinidb-platform;$PKGERASE infinidb-storage-engine infinidb-mysql;$PKGERASE dummy'\n" + send "ssh $USERNAME@$SERVER '$PKGERASE ;$PKGERASE1 dummy'\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -145,7 +148,7 @@ expect { -re {[$#] } { } } -send "scp $CALPONTRPM1 $CALPONTRPM2 $CALPONTMYSQLRPM $CALPONTMYSQLDRPM $USERNAME@$SERVER:.;$PKGERASE dummy\n" +send "scp $CALPONTRPM1 $USERNAME@$SERVER:.;$PKGERASE dummy\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -163,30 +166,6 @@ expect { } send_user "\n" -#sleep to make sure it's finished -sleep 5 -if { $CALPONTRPM3 != "dummy.rpm" } { - expect -re {[$#] } - send_user "Copy new InfiniDB Enterprise Packages to Module " - send "scp $CALPONTRPM3 $USERNAME@$SERVER:.\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 120 - expect { - "100%" { send_user "DONE" } - "directory" { send_user "ERROR\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - send_user "\n" -} - #sleep to make sure it's finished sleep 5 # @@ -197,7 +176,7 @@ if { $INSTALLTYPE == "initial"} { # install package # send_user "Install InfinIDB Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGINSTALL $CALPONTRPM1 $CALPONTRPM2 $CALPONTMYSQLDRPM $CALPONTMYSQLRPM;$PKGERASE dummy'\n" + send "ssh $USERNAME@$SERVER '$PKGINSTALL ;$PKGERASE dummy'\n" if { $PASSWORD != "ssh" } { set timeout 30 expect { @@ -217,82 +196,7 @@ if { $INSTALLTYPE == "initial"} { } send_user "\n" - if { $CALPONTRPM3 != "dummy.rpm" } { - expect -re {[$#] } - send_user "Install InfinIDB Enterprise Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGINSTALL $CALPONTRPM3'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 60 - expect { - "completed" { send_user "DONE" } - "Setting up" { send_user "DONE" } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - send_user "\n" - } - set timeout 30 - #expect -re {[$#] } -} else { - # - # upgrade package - # - #expect -re {[$#] } - send_user "Upgrade InfinIDB Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGUPGRADE $CALPONTRPM1 $CALPONTRPM2 $CALPONTRPM3 $CALPONTMYSQLDRPM $CALPONTMYSQLRPM;$PKGERASE dummy'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 120 - expect { - "package dummy" { send_user "DONE" } - "already installed" { send_user "INFO: Already Installed\n" ; exit 1 } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - send_user "\n" - - if { $CALPONTRPM3 != "dummy.rpm" } { - expect -re {[$#] } - send_user "Upgrade InfinIDB Enterprise Packages on Module " - send "ssh $USERNAME@$SERVER '$PKGUPGRADE $CALPONTRPM3'\n" - if { $PASSWORD != "ssh" } { - set timeout 30 - expect { - "word: " { send "$PASSWORD\n" } - "passphrase" { send "$PASSWORD\n" } - } - } - set timeout 30 - expect { - "completed" { send_user "DONE" } - "Setting up" { send_user "DONE" } - "already installed" { send_user "INFO: Already Installed\n" ; exit 1 } - "error: Failed dependencies" { send_user "ERROR: Failed dependencies\n" ; - send_user "\n*** Installation ERROR\n" ; - exit 1 } - "Connection closed" { send_user "ERROR: Connection closed\n" ; exit 1 } - } - send_user "\n" - } - - set timeout 30 - expect -re {[$#] } } #sleep to make sure it's finished sleep 5 diff --git a/oamapps/postConfigure/postConfigure.cpp b/oamapps/postConfigure/postConfigure.cpp index e9a575d68..684600d70 100644 --- a/oamapps/postConfigure/postConfigure.cpp +++ b/oamapps/postConfigure/postConfigure.cpp @@ -2925,7 +2925,8 @@ int main(int argc, char *argv[]) string separator = "-"; if ( EEPackageType == "deb" ) separator = "_"; - calpontPackage1 = "infinidb-libs" + separator + systemsoftware.Version + "-" + systemsoftware.Release; + //mariadb + calpontPackage1 = "infinidb-*" + separator + systemsoftware.Version + "-" + systemsoftware.Release; calpontPackage2 = "infinidb-platform" + separator + systemsoftware.Version + "-" + systemsoftware.Release; calpontPackage3 = "infinidb-enterprise" + separator + systemsoftware.Version + "-" + systemsoftware.Release; mysqlPackage = "infinidb-storage-engine" + separator + systemsoftware.Version + "-" + systemsoftware.Release; @@ -2945,6 +2946,7 @@ int main(int argc, char *argv[]) } else { + // binary string fileName = installDir + "/bin/healthcheck"; ifstream file (fileName.c_str()); if (!file) // CE @@ -2972,20 +2974,21 @@ int main(int argc, char *argv[]) globfree(>); } + //mariadb //if PM is running with UM functionality // install UM packages and run mysql setup scripts - if ( pmwithum ) { +// if ( pmwithum ) { //run the mysql / mysqld setup scripts - if ( EEPackageType != "binary") { - cout << endl << "===== Installing InfiniDB UM Packages and Running the InfiniDB MySQL setup scripts =====" << endl << endl; - string cmd = "rpm -Uv --force " + mysqlPackage + " " + mysqldPackage; - if ( EEPackageType == "deb" ) - cmd = "dpkg -i " + mysqlPackage + " " + mysqldPackage; - system(cmd.c_str()); - cout << endl; - } - } +// if ( EEPackageType != "binary") { +// cout << endl << "===== Installing InfiniDB UM Packages and Running the InfiniDB MySQL setup scripts =====" << endl << endl; +// string cmd = "rpm -Uv --force " + mysqlPackage + " " + mysqldPackage; +// if ( EEPackageType == "deb" ) +// cmd = "dpkg -i " + mysqlPackage + " " + mysqldPackage; +// system(cmd.c_str()); +// cout << endl; +// } +// } cout << endl; cout << "Next step is to enter the password to access the other Servers." << endl; diff --git a/procmgr/processmanager.cpp b/procmgr/processmanager.cpp index 2c48f2ff0..4a770fd02 100644 --- a/procmgr/processmanager.cpp +++ b/procmgr/processmanager.cpp @@ -4435,7 +4435,8 @@ int ProcessManager::addModule(oam::DeviceNetworkList devicenetworklist, std::str string separator = "-"; if ( packageType == "deb" ) separator = "_"; - calpontPackage = homedir + "/infinidb-platform" + separator + systemsoftware.Version + "-" + systemsoftware.Release + "*." + packageType; + //mariadb + calpontPackage = homedir + "/infinidb-*" + separator + systemsoftware.Version + "-" + systemsoftware.Release + "*." + packageType; mysqlPackage = homedir + "/infinidb-storage-engine" + separator + systemsoftware.Version + "-" + systemsoftware.Release + "*." + packageType; mysqldPackage = homedir + "/infinidb-mysql" + separator + systemsoftware.Version + "-" + systemsoftware.Release + "*." + packageType; calpontPackage1 = homedir + "/infinidb-libs" + separator + systemsoftware.Version + "-" + systemsoftware.Release + "*." + packageType; diff --git a/procmon/processmonitor.cpp b/procmon/processmonitor.cpp index 471e5d258..f60436538 100644 --- a/procmon/processmonitor.cpp +++ b/procmon/processmonitor.cpp @@ -915,8 +915,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO if ( actIndicator == oam::REMOVE ) { log.writeLog(__LINE__, "STOPALL: uninstall Calpont RPMs", LOG_TYPE_DEBUG); if ( config.moduleType() == "um" ) { - system("rpm -e infinidb-libs infinidb-platform infinidb-enterprise infinidb-storage-engine infinidb-mysql --nodeps"); - system("dpkg -P infinidb-libs infinidb-platform infinidb-enterprise infinidb-storage-engine infinidb-mysql"); + system("rpm -e --nodeps $(rpm -qa | grep '^infinidb')"); + system("dpkg -P $(dpkg --get-selections | grep '^infinidb')"); } else // pm { @@ -930,8 +930,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO system(cmd.c_str()); sleep(1); - system("rpm -e infinidb-libs infinidb-platform infinidb-enterprise infinidb-storage-engine infinidb-mysql --nodeps"); - system("dpkg -P infinidb-libs infinidb-platform infinidb-enterprise infinidb-storage-engine infinidb-mysql"); + system("rpm -e --nodeps $(rpm -qa | grep '^infinidb')"); + system("dpkg -P $(dpkg --get-selections | grep '^infinidb')"); } // should get here is packages get removed correctly string cmd = startup::StartUp::installDir() + "/bin/infinidb stop > /dev/null 2>&1"; @@ -1380,24 +1380,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO } } - // remove mysql rpms if being reconfigured as a pm - if ( reconfigureModuleName.find("pm") != string::npos && - config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM ) { - try { - oam.actionMysqlCalpont(MYSQL_STOP); - } - catch(...) - {} - system("rpm -e infinidb-storage-engine infinidb-mysql"); - system("dpkg -P infinidb-storage-engine infinidb-mysql"); - log.writeLog(__LINE__, "RECONFIGURE: removed mysql rpms"); - } - // install mysql rpms if being reconfigured as a um if ( reconfigureModuleName.find("um") != string::npos ) { - system("rpm -ivh /root/infinidb-storage-engine-*rpm /root/infinidb-mysql-*rpm > /tmp/rpminstall"); - system("dpgk -i /root/infinidb-storage-engine-*deb /root/infinidb-mysql-*deb >> /tmp/rpminstall"); - string cmd = startup::StartUp::installDir() + "/bin/post-mysqld-install >> /tmp/rpminstall"; system(cmd.c_str()); cmd = startup::StartUp::installDir() + "/bin/post-mysql-install >> /tmp/rpminstall"; @@ -1429,7 +1413,7 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO log.writeLog(__LINE__, "RECONFIGURE: mysqld failed to start", LOG_TYPE_ERROR); } else - log.writeLog(__LINE__, "RECONFIGURE: install mysql rpms and started mysqld"); + log.writeLog(__LINE__, "RECONFIGURE: install started mysqld"); } } diff --git a/tools/configMgt/autoInstaller.cpp b/tools/configMgt/autoInstaller.cpp index 06f352b49..b7c2324ef 100644 --- a/tools/configMgt/autoInstaller.cpp +++ b/tools/configMgt/autoInstaller.cpp @@ -351,25 +351,9 @@ int main(int argc, char *argv[]) idbver = 4; globfree(>); } - //v4 really means 4+, it'll get fixed later... - currentPrefix = oam.itoa(idbver); - if (idbver >= 4) - { - calpontPackagename = "infinidb"; - mysqlRPMname = calpontPackagename + "-storage-engine"; - } - else - { - if (CE == "1") - { - cout << endl << "FAILED: Community-Edition install valid for 4.x builds and above" << endl; - cerr << endl << "FAILED: Community-Edition install valid for 4.x builds and above" << endl; - exit(1); - } - calpontPackagename = "calpont"; - mysqlRPMname = calpontPackagename + "-mysql"; - } + calpontPackagename = "infinidb"; + mysqlRPMname = calpontPackagename + "-storage-engine"; //check if package is there cmd = "ls " + systemDir + mysqlRPMname + "* > /tmp/package.txt 2>&1"; @@ -393,21 +377,10 @@ int main(int argc, char *argv[]) buf = line; string::size_type pos; - if (idbver >= 4) - { - pos = buf.find("infinidb-storage-engine-",0); - if (pos != string::npos) { - currentPrefix = buf.substr(pos+24,1); - break; - } - } - else - { - pos = buf.find("calpont-mysql-",0); - if (pos != string::npos) { - currentPrefix = buf.substr(pos+14,1); - break; - } + pos = buf.find("infinidb-storage-engine-",0); + if (pos != string::npos) { + currentPrefix = buf.substr(pos+24,1); + break; } } file.close(); @@ -438,20 +411,11 @@ int main(int argc, char *argv[]) idbver = 4; globfree(>); } - //v4 really means 4+, it'll get fixed later... currentPrefix = oam.itoa(idbver); - if (idbver >= 4) - { - calpontPackagename = "infinidb"; - mysqlRPMname = calpontPackagename + "-storage-engine"; - calpontPackage = "infinidb-ent-" + systemPackage; - } - else - { - calpontPackagename = "calpont"; - mysqlRPMname = calpontPackagename + "-mysql"; - calpontPackage = calpontPackagename + "-infinidb-ent-" + systemPackage; - } + + calpontPackagename = "infinidb"; + mysqlRPMname = calpontPackagename + "-storage-engine"; + calpontPackage = "infinidb-ent-" + systemPackage; //check if package is there cmd = "ls " + systemDir + calpontPackage + " > /tmp/package.txt 2>&1"; @@ -475,21 +439,10 @@ int main(int argc, char *argv[]) buf = line; string::size_type pos; - if (idbver >= 4) - { - pos = buf.find("infinidb-ent-",0); - if (pos != string::npos) { - currentPrefix = buf.substr(pos+13,1); - break; - } - } - else - { - pos = buf.find("calpont-infinidb-ent-",0); - if (pos != string::npos) { - currentPrefix = buf.substr(pos+21,1); - break; - } + pos = buf.find("infinidb-ent-",0); + if (pos != string::npos) { + currentPrefix = buf.substr(pos+13,1); + break; } } file.close(); @@ -499,10 +452,8 @@ int main(int argc, char *argv[]) } mysqlRPM = mysqlRPMname + "-" + systemPackage; - if (idbver >= 4) - mysqldRPM = calpontPackagename + "-mysql-" + systemPackage; - else - mysqldRPM = calpontPackagename + "-mysqld-" + systemPackage; + + mysqldRPM = calpontPackagename + "-mysql-" + systemPackage; //TODO: we go to all the effort of downloading the packages above only to delete them here... cmd = "rm -f " + systemDir + systemPackage + " > /dev/null 2>&1"; @@ -802,10 +753,7 @@ CONFIGDONE: string installer; if ( systemPackage != "*.x86_64.rpm" ) { //do binary install - if (idbver >= 4) - installer = "parent_binary_installer.sh"; - else - installer = "parent_binary_installer_v3.sh"; + installer = "parent_binary_installer.sh"; cmd = "cd " + systemDir + ";../../" + installer + " " + installParentModuleIPAddr + " " + password + " " + systemPackage + " " + release + " " + configFile + " " + systemUser + " " + installDir + " " + debug_flag; @@ -814,19 +762,13 @@ CONFIGDONE: { if ( serverTypeInstall == oam::INSTALL_COMBINE_DM_UM_PM ) { - if (idbver >= 4) - installer = "dm_parent_installer.sh"; - else - installer = "dm_parent_installer_v3.sh"; + installer = "dm_parent_installer.sh"; cmd = "cd " + systemDir + ";../../" + installer + " " + installParentModuleIPAddr + " " + password + " " + systemPackage + " " + release + " " + configFile + " " + systemUser + " " + CE + " " + debug_flag; } else { - if (idbver >= 4) - installer = "pm_parent_installer.sh"; - else - installer = "pm_parent_installer_v3.sh"; + installer = "pm_parent_installer.sh"; cmd = "cd " + systemDir + ";../../" + installer + " " + installParentModuleIPAddr + " " + password + " " + systemPackage + " " + release + " " + configFile + " " + currentPrefix + " " + systemUser + " " + debug_flag; @@ -844,34 +786,27 @@ CONFIGDONE: // Perform System Installing and launch // cout << "Install System " << flush; - if (idbver < 3) + if (HDFS) { - cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + " " + password + " '/usr/local/Calpont/bin/installer /root/" + calpontPackage + " /root/" + mysqlRPM + " /root/" + mysqldRPM + " initial " + password + " " + XMpassword + " --nodeps 1' 'InfiniDB Install Successfully Completed' ERROR 1200 " + debug_flag; - } - else - { - if (HDFS) + if ( MySQLport == oam::UnassignedName ) { - if ( MySQLport == oam::UnassignedName ) - { - cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '. " + installDir + "/Calpont/bin/" + DataFileEnvFile + ";" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + "' 'System is Active' Error 1200 " + debug_flag; - } - else - { - cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '. " + installDir + "/Calpont/bin/" + DataFileEnvFile + ";" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + " -port " + MySQLport + "' 'System is Active' Error 1200 " + debug_flag; - } + cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '. " + installDir + "/Calpont/bin/" + DataFileEnvFile + ";" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + "' 'System is Active' Error 1200 " + debug_flag; } else { - if ( MySQLport == oam::UnassignedName ) - { - cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + "' 'System is Active' Error 1200 " + debug_flag; - } - else - { - cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + " -port " + MySQLport + "' 'System is Active' Error 1200 " + debug_flag; - string DataFileEnvFile = "setenv-hdfs-20"; - } + cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '. " + installDir + "/Calpont/bin/" + DataFileEnvFile + ";" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + " -port " + MySQLport + "' 'System is Active' Error 1200 " + debug_flag; + } + } + else + { + if ( MySQLport == oam::UnassignedName ) + { + cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + "' 'System is Active' Error 1200 " + debug_flag; + } + else + { + cmd = "./remote_command.sh " + installParentModuleIPAddr + " " + systemUser + " " + password + " '" + installDir + "/Calpont/bin/postConfigure -i " + installDir + "/Calpont -n -p " + password + " -port " + MySQLport + "' 'System is Active' Error 1200 " + debug_flag; + string DataFileEnvFile = "setenv-hdfs-20"; } }