You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-01 06:46:55 +03:00
MCOL-520 amazon changes
This commit is contained in:
@ -805,12 +805,16 @@ int main(int argc, char* argv[])
|
|||||||
{
|
{
|
||||||
cout << "===== Quick Install Multi-Server Configuration =====" << endl << endl;
|
cout << "===== Quick Install Multi-Server Configuration =====" << endl << endl;
|
||||||
|
|
||||||
|
cout << "Multi-Server install defaulting to using local storage" << endl;
|
||||||
|
|
||||||
singleServerInstall = "2";
|
singleServerInstall = "2";
|
||||||
}
|
}
|
||||||
else if (amazon_quick_install)
|
else if (amazon_quick_install)
|
||||||
{
|
{
|
||||||
cout << "===== Quick Install Amazon Configuration =====" << endl << endl;
|
cout << "===== Quick Install Amazon Configuration =====" << endl << endl;
|
||||||
|
|
||||||
|
cout << "Amazon AMI EC2 install defaulting to using local storage" << endl;
|
||||||
|
|
||||||
singleServerInstall = "2";
|
singleServerInstall = "2";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -856,95 +860,14 @@ int main(int argc, char* argv[])
|
|||||||
|
|
||||||
if (temp == "1")
|
if (temp == "1")
|
||||||
{
|
{
|
||||||
singleServerInstall = temp;
|
singleServerInstall = "1";
|
||||||
cout << endl << "Performing the Single Server Install." << endl << endl;
|
break;
|
||||||
|
|
||||||
if ( reuseConfig == "n" )
|
|
||||||
{
|
|
||||||
//setup to Columnstore.xml file for single server
|
|
||||||
singleServerConfigSetup(sysConfig);
|
|
||||||
}
|
|
||||||
|
|
||||||
//module ProcessConfig.xml to setup all apps on the pm
|
|
||||||
if ( !updateProcessConfig() )
|
|
||||||
cout << "Update ProcessConfig.xml error" << endl;
|
|
||||||
|
|
||||||
try
|
|
||||||
{
|
|
||||||
sysConfig->setConfig(InstallSection, "SingleServerInstall", "y");
|
|
||||||
sysConfig->setConfig(InstallSection, "ServerTypeInstall", "2");
|
|
||||||
}
|
|
||||||
catch (...)
|
|
||||||
{
|
|
||||||
cout << "ERROR: Problem setting SingleServerInstall from the MariaDB ColumnStore System Configuration file" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
if ( !writeConfig(sysConfig) )
|
|
||||||
{
|
|
||||||
cout << "ERROR: Failed trying to update MariaDB ColumnStore System Configuration file" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
setSystemName();
|
|
||||||
cout << endl;
|
|
||||||
|
|
||||||
system(cmd.c_str());
|
|
||||||
|
|
||||||
// setup storage
|
|
||||||
if (!storageSetup(false))
|
|
||||||
{
|
|
||||||
cout << "ERROR: Problem setting up storage" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (hdfs || !rootUser)
|
|
||||||
if ( !updateBash() )
|
|
||||||
cout << "updateBash error" << endl;
|
|
||||||
|
|
||||||
// setup storage
|
|
||||||
if (!singleServerDBrootSetup())
|
|
||||||
{
|
|
||||||
cout << "ERROR: Problem setting up DBRoot IDs" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
//set system DBRoot count and check 'files per parition' with number of dbroots
|
|
||||||
try
|
|
||||||
{
|
|
||||||
sysConfig->setConfig(SystemSection, "DBRootCount", oam.itoa(DBRootCount));
|
|
||||||
}
|
|
||||||
catch (...)
|
|
||||||
{
|
|
||||||
cout << "ERROR: Problem setting DBRoot Count in the MariaDB ColumnStore System Configuration file" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
//check if dbrm data resides in older directory path and inform user if it does
|
|
||||||
dbrmDirCheck();
|
|
||||||
|
|
||||||
if (startOfflinePrompt)
|
|
||||||
offLineAppCheck();
|
|
||||||
|
|
||||||
checkMysqlPort(mysqlPort, sysConfig);
|
|
||||||
|
|
||||||
if ( !writeConfig(sysConfig) )
|
|
||||||
{
|
|
||||||
cout << "ERROR: Failed trying to update MariaDB ColumnStore System Configuration file" << endl;
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
cout << endl << "===== Performing Configuration Setup and MariaDB ColumnStore Startup =====" << endl;
|
|
||||||
|
|
||||||
cmd = installDir + "/bin/installer dummy.rpm dummy.rpm dummy.rpm dummy.rpm dummy.rpm initial dummy " + reuseConfig + " --nodeps ' ' 1 " + installDir;
|
|
||||||
system(cmd.c_str());
|
|
||||||
exit(0);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (temp == "2")
|
if (temp == "2")
|
||||||
{
|
{
|
||||||
singleServerInstall = temp;
|
singleServerInstall = "2";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -953,14 +876,99 @@ int main(int argc, char* argv[])
|
|||||||
|
|
||||||
if ( noPrompting )
|
if ( noPrompting )
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
||||||
continue;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// perform single server install
|
||||||
|
if (singleServerInstall == "1")
|
||||||
|
{
|
||||||
|
cout << endl << "Performing the Single Server Install." << endl << endl;
|
||||||
|
|
||||||
|
if ( reuseConfig == "n" )
|
||||||
|
{
|
||||||
|
//setup to Columnstore.xml file for single server
|
||||||
|
singleServerConfigSetup(sysConfig);
|
||||||
|
}
|
||||||
|
|
||||||
|
//module ProcessConfig.xml to setup all apps on the pm
|
||||||
|
if ( !updateProcessConfig() )
|
||||||
|
cout << "Update ProcessConfig.xml error" << endl;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
sysConfig->setConfig(InstallSection, "SingleServerInstall", "y");
|
||||||
|
sysConfig->setConfig(InstallSection, "ServerTypeInstall", "2");
|
||||||
|
}
|
||||||
|
catch (...)
|
||||||
|
{
|
||||||
|
cout << "ERROR: Problem setting SingleServerInstall from the MariaDB ColumnStore System Configuration file" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ( !writeConfig(sysConfig) )
|
||||||
|
{
|
||||||
|
cout << "ERROR: Failed trying to update MariaDB ColumnStore System Configuration file" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
setSystemName();
|
||||||
|
cout << endl;
|
||||||
|
|
||||||
|
system(cmd.c_str());
|
||||||
|
|
||||||
|
// setup storage
|
||||||
|
if (!storageSetup(false))
|
||||||
|
{
|
||||||
|
cout << "ERROR: Problem setting up storage" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hdfs || !rootUser)
|
||||||
|
if ( !updateBash() )
|
||||||
|
cout << "updateBash error" << endl;
|
||||||
|
|
||||||
|
// setup storage
|
||||||
|
if (!singleServerDBrootSetup())
|
||||||
|
{
|
||||||
|
cout << "ERROR: Problem setting up DBRoot IDs" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
//set system DBRoot count and check 'files per parition' with number of dbroots
|
||||||
|
try
|
||||||
|
{
|
||||||
|
sysConfig->setConfig(SystemSection, "DBRootCount", oam.itoa(DBRootCount));
|
||||||
|
}
|
||||||
|
catch (...)
|
||||||
|
{
|
||||||
|
cout << "ERROR: Problem setting DBRoot Count in the MariaDB ColumnStore System Configuration file" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
//check if dbrm data resides in older directory path and inform user if it does
|
||||||
|
dbrmDirCheck();
|
||||||
|
|
||||||
|
if (startOfflinePrompt)
|
||||||
|
offLineAppCheck();
|
||||||
|
|
||||||
|
checkMysqlPort(mysqlPort, sysConfig);
|
||||||
|
|
||||||
|
if ( !writeConfig(sysConfig) )
|
||||||
|
{
|
||||||
|
cout << "ERROR: Failed trying to update MariaDB ColumnStore System Configuration file" << endl;
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
cout << endl << "===== Performing Configuration Setup and MariaDB ColumnStore Startup =====" << endl;
|
||||||
|
|
||||||
|
cmd = installDir + "/bin/installer dummy.rpm dummy.rpm dummy.rpm dummy.rpm dummy.rpm initial dummy " + reuseConfig + " --nodeps ' ' 1 " + installDir;
|
||||||
|
system(cmd.c_str());
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
// perform multi-node install
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
sysConfig->setConfig(InstallSection, "SingleServerInstall", "n");
|
sysConfig->setConfig(InstallSection, "SingleServerInstall", "n");
|
||||||
|
@ -55,6 +55,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $HOME = "/root" ]]; then
|
if [[ $HOME = "/root" ]]; then
|
||||||
|
echo ""
|
||||||
echo "${bold}Run post-install script${normal}"
|
echo "${bold}Run post-install script${normal}"
|
||||||
echo ""
|
echo ""
|
||||||
/usr/local/mariadb/columnstore/bin/post-install
|
/usr/local/mariadb/columnstore/bin/post-install
|
||||||
@ -70,13 +71,14 @@ else
|
|||||||
echo ""
|
echo ""
|
||||||
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
||||||
|
|
||||||
tmpDir=`$HOME/mariadb/columnstore/bin/getConfig SystemConfig SystemTempFileDir`
|
export COLUMNSTORE_INSTALL_DIR=$HOME/mariadb/columnstore
|
||||||
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/mariadb/columnstore/lib:$HOME/mariadb/columnstore/mysql/lib
|
||||||
|
|
||||||
echo "${bold}Run postConfigure script${normal}"
|
echo "${bold}Run postConfigure script${normal}"
|
||||||
echo ""
|
echo ""
|
||||||
if [[ $umCount = "" ]]; then
|
if [[ $umCount = "" ]]; then
|
||||||
. $tmpDir;$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qa -pm-count $pmCount $systemName -d
|
$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qa -pm-count $pmCount $systemName -d
|
||||||
else
|
else
|
||||||
. $tmpDir;$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qa -pm-count $pmCount -um-count $umCount $systemName -d
|
$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qa -pm-count $pmCount -um-count $umCount $systemName -d
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@ -61,6 +61,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $HOME = "/root" ]]; then
|
if [[ $HOME = "/root" ]]; then
|
||||||
|
echo ""
|
||||||
echo "${bold}Run post-install script${normal}"
|
echo "${bold}Run post-install script${normal}"
|
||||||
echo ""
|
echo ""
|
||||||
/usr/local/mariadb/columnstore/bin/post-install
|
/usr/local/mariadb/columnstore/bin/post-install
|
||||||
@ -72,17 +73,19 @@ if [[ $HOME = "/root" ]]; then
|
|||||||
/usr/local/mariadb/columnstore/bin/postConfigure -qm -pm-ip-addrs $pmIpAddrs -um-ip-addrs $umIpAddrs $nonDistrubutedInstall $systemName
|
/usr/local/mariadb/columnstore/bin/postConfigure -qm -pm-ip-addrs $pmIpAddrs -um-ip-addrs $umIpAddrs $nonDistrubutedInstall $systemName
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
|
echo ""
|
||||||
echo "${bold}Run post-install script${normal}"
|
echo "${bold}Run post-install script${normal}"
|
||||||
echo ""
|
echo ""
|
||||||
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
||||||
|
|
||||||
tmpDir=`$HOME/mariadb/columnstore/bin/getConfig SystemConfig SystemTempFileDir`
|
export COLUMNSTORE_INSTALL_DIR=$HOME/mariadb/columnstore
|
||||||
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/mariadb/columnstore/lib:$HOME/mariadb/columnstore/mysql/lib
|
||||||
|
|
||||||
echo "${bold}Run postConfigure script${normal}"
|
echo "${bold}Run postConfigure script${normal}"
|
||||||
echo ""
|
echo ""
|
||||||
if [[ $umIpAddrs = "" ]]; then
|
if [[ $umIpAddrs = "" ]]; then
|
||||||
. $tmpDir;$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qm -pm-ip-addrs $pmIpAddrs $nonDistrubutedInstall $systemName
|
$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qm -pm-ip-addrs $pmIpAddrs $nonDistrubutedInstall $systemName
|
||||||
else
|
else
|
||||||
. $tmpDir;$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qm -pm-ip-addrs $pmIpAddrs -um-ip-addrs $umIpAddrs $nonDistrubutedInstall $systemName
|
$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qm -pm-ip-addrs $pmIpAddrs -um-ip-addrs $umIpAddrs $nonDistrubutedInstall $systemName
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@ -18,6 +18,7 @@ done
|
|||||||
|
|
||||||
|
|
||||||
if [ $HOME == "/root" ]; then
|
if [ $HOME == "/root" ]; then
|
||||||
|
echo ""
|
||||||
echo "Run post-install script"
|
echo "Run post-install script"
|
||||||
echo ""
|
echo ""
|
||||||
/usr/local/mariadb/columnstore/bin/post-install
|
/usr/local/mariadb/columnstore/bin/post-install
|
||||||
@ -29,9 +30,10 @@ else
|
|||||||
echo ""
|
echo ""
|
||||||
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
$HOME/mariadb/columnstore/bin/post-install --installdir=$HOME/mariadb/columnstore
|
||||||
|
|
||||||
tmpDir=`$HOME/mariadb/columnstore/bin/getConfig SystemConfig SystemTempFileDir`
|
export COLUMNSTORE_INSTALL_DIR=$HOME/mariadb/columnstore
|
||||||
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/mariadb/columnstore/lib:$HOME/mariadb/columnstore/mysql/lib
|
||||||
|
|
||||||
echo "Run postConfigure script"
|
echo "Run postConfigure script"
|
||||||
echo ""
|
echo ""
|
||||||
. $tmpDir; $HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qs
|
$HOME/mariadb/columnstore/bin/postConfigure -i $HOME/mariadb/columnstore -qs
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user