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-938 - fixed server-id setup on combo systems
This commit is contained in:
@ -30,7 +30,7 @@ set COMMAND "rsync -vopgr -e ssh --exclude=mysql/ --exclude=test/ --exclude=infi
|
||||
#
|
||||
# run command
|
||||
#
|
||||
set timeout 60
|
||||
set timeout 20
|
||||
send "$COMMAND\n"
|
||||
expect {
|
||||
-re "Host key verification failed" { send_user "FAILED: Host key verification failed\n" ; exit -1}
|
||||
@ -57,12 +57,14 @@ expect {
|
||||
|
||||
set HOME "$env(HOME)"
|
||||
|
||||
if {[file exist $HOME/.my.cnf]} {
|
||||
|
||||
set COMMAND "rsync -vopgr -e ssh $HOME/.my.cnf $USERNAME@$SERVER:$HOME/"
|
||||
|
||||
#
|
||||
# run command
|
||||
#
|
||||
set timeout 20
|
||||
set timeout 10
|
||||
send "$COMMAND\n"
|
||||
expect {
|
||||
-re "word: " { send "$PASSWORD\n" }
|
||||
@ -76,6 +78,6 @@ expect {
|
||||
-re "failed" { exit 0 }
|
||||
timeout { exit 0 }
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
exit 0
|
||||
|
@ -459,7 +459,9 @@ int sendReplicationRequest(int IserverTypeInstall, std::string password, std::st
|
||||
{ // set for slave repl request
|
||||
// don't do PMs unless PMwithUM flag is set
|
||||
string moduleType = (*pt).DeviceName.substr(0,MAX_MODULE_TYPE_SIZE);
|
||||
if ( moduleType == "pm" && !pmwithum ) {
|
||||
|
||||
if ( ( moduleType == "pm" && !pmwithum ) &&
|
||||
( IserverTypeInstall != oam::INSTALL_COMBINE_DM_UM_PM ) ) {
|
||||
pt++;
|
||||
continue;
|
||||
}
|
||||
@ -678,15 +680,19 @@ void checkMysqlPort( std::string& mysqlPort, Config* sysConfig )
|
||||
if ( size != 0 ) {
|
||||
if ( noPrompting ) {
|
||||
cout << endl << "The MariaDB ColumnStore port of '" + mysqlPort + "' is already in-use" << endl;
|
||||
cout << "For No-prompt install, use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "Either use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "or stop the process that is using port '" + mysqlPort + "'" << endl;
|
||||
cout << "For No-prompt install, exiting" << endl;
|
||||
exit(1);
|
||||
}
|
||||
|
||||
cout << "The MariaDB ColumnStore port of '" + mysqlPort + "' is already in-use on local server" << endl;
|
||||
cout << "Either enter a different port to use" << endl;
|
||||
cout << "or stop the process that is using port '" + mysqlPort + "' and enter '" + mysqlPort + "' to continue" << endl;
|
||||
|
||||
while(true)
|
||||
{
|
||||
prompt = "Enter a different port number > ";
|
||||
prompt = "Enter port number > ";
|
||||
pcommand = callReadline(prompt.c_str());
|
||||
if (pcommand)
|
||||
{
|
||||
@ -756,7 +762,9 @@ void checkSystemMySQLPort(std::string& mysqlPort, Config* sysConfig, std::string
|
||||
if ( size != 0 ) {
|
||||
if ( noPrompting ) {
|
||||
cout << endl << "The MariaDB ColumnStore port of '" + mysqlPort + "' is already in-use" << endl;
|
||||
cout << "For No-prompt install, use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "Either use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "or stop the process that is using port '" + mysqlPort + "'" << endl;
|
||||
cout << "For No-prompt install, exiting" << endl;
|
||||
exit(1);
|
||||
}
|
||||
else
|
||||
@ -787,7 +795,9 @@ void checkSystemMySQLPort(std::string& mysqlPort, Config* sysConfig, std::string
|
||||
if (WEXITSTATUS(rtnCode) == 0) {
|
||||
if ( noPrompting ) {
|
||||
cout << endl << "The MariaDB ColumnStore port of '" + mysqlPort + "' is already in-use on " << remoteModuleName << endl;
|
||||
cout << "For No-prompt install, use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "Either use the command line argument of 'port' to enter a different number" << endl;
|
||||
cout << "or stop the process that is using port '" + mysqlPort + "'" << endl;
|
||||
cout << "For No-prompt install, exiting" << endl;
|
||||
cout << "exiting..." << endl;
|
||||
exit(1);
|
||||
}
|
||||
@ -805,10 +815,12 @@ void checkSystemMySQLPort(std::string& mysqlPort, Config* sysConfig, std::string
|
||||
if ( inUse )
|
||||
{
|
||||
cout << endl << "The MariaDB ColumnStore port of '" + mysqlPort + "' is already in-use on " << inUseServer << endl;
|
||||
cout << "Either enter a different port to use" << endl;
|
||||
cout << "or stop the process that is using port '" + mysqlPort + "' and enter '" + mysqlPort + "' to continue" << endl;
|
||||
|
||||
while(true)
|
||||
{
|
||||
prompt = "Enter a different port number > ";
|
||||
prompt = "Enter a port number > ";
|
||||
pcommand = callReadline(prompt.c_str());
|
||||
if (pcommand)
|
||||
{
|
||||
|
@ -5440,12 +5440,11 @@ int ProcessManager::addModule(oam::DeviceNetworkList devicenetworklist, std::str
|
||||
}
|
||||
|
||||
//delay to give time for ProcMon to start after the config is sent and procmon restarts
|
||||
log.writeLog(__LINE__, "addModule - sleep 10 - give ProcMon time to CONFIGURE and restart", LOG_TYPE_DEBUG);
|
||||
sleep(10);
|
||||
log.writeLog(__LINE__, "addModule - sleep 30 - give ProcMon time to CONFIGURE and restart", LOG_TYPE_DEBUG);
|
||||
sleep(30);
|
||||
|
||||
// sleep(5);
|
||||
// log.writeLog(__LINE__, "Setup MySQL Replication for new Modules being Added", LOG_TYPE_DEBUG);
|
||||
// processManager.setMySQLReplication(devicenetworklist, oam::UnassignedName, false, true, password );
|
||||
log.writeLog(__LINE__, "Setup MySQL Replication for new Modules being Added", LOG_TYPE_DEBUG);
|
||||
processManager.setMySQLReplication(devicenetworklist, oam::UnassignedName, false, true, password );
|
||||
|
||||
return API_SUCCESS;
|
||||
}
|
||||
|
@ -1791,7 +1791,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO
|
||||
string masterLogFile = oam::UnassignedName;
|
||||
string masterLogPos = oam::UnassignedName;
|
||||
|
||||
if ( (PMwithUM == "n") && (config.moduleType() == "pm") && ( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
if ( ( (PMwithUM == "n") && (config.moduleType() == "pm") ) &&
|
||||
( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
{
|
||||
ackMsg << (ByteStream::byte) ACK;
|
||||
ackMsg << (ByteStream::byte) MASTERREP;
|
||||
@ -1864,7 +1865,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO
|
||||
string port;
|
||||
msg >> port;
|
||||
|
||||
if ( (PMwithUM == "n") && (config.moduleType() == "pm") && ( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
if ( ( (PMwithUM == "n") && (config.moduleType() == "pm") ) &&
|
||||
( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
{
|
||||
ackMsg << (ByteStream::byte) ACK;
|
||||
ackMsg << (ByteStream::byte) SLAVEREP;
|
||||
@ -1911,7 +1913,8 @@ void ProcessMonitor::processMessage(messageqcpp::ByteStream msg, messageqcpp::IO
|
||||
string module;
|
||||
msg >> module;
|
||||
|
||||
if ( (PMwithUM == "n") && (config.moduleType() == "pm") && ( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
if ( ( (PMwithUM == "n") && (config.moduleType() == "pm") ) &&
|
||||
( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
{
|
||||
ackMsg << (ByteStream::byte) ACK;
|
||||
ackMsg << (ByteStream::byte) MASTERDIST;
|
||||
@ -5008,7 +5011,8 @@ int ProcessMonitor::runMasterRep(std::string& masterLogFile, std::string& master
|
||||
|
||||
string moduleType = systemModuleTypeConfig.moduletypeconfig[i].ModuleType;
|
||||
|
||||
if ( (PMwithUM == "n") && (moduleType == "pm") && ( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
if ( ( (PMwithUM == "n") && (config.moduleType() == "pm") ) &&
|
||||
( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
continue;
|
||||
|
||||
HostConfigList::iterator pt1 = (*pt).hostConfigList.begin();
|
||||
@ -5304,7 +5308,8 @@ int ProcessMonitor::runMasterDist(std::string& password, std::string& slaveModul
|
||||
|
||||
string moduleType = systemModuleTypeConfig.moduletypeconfig[i].ModuleType;
|
||||
|
||||
if ( (PMwithUM == "n") && (moduleType == "pm") && ( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
if ( ( (PMwithUM == "n") && (config.moduleType() == "pm") ) &&
|
||||
( config.ServerInstallType() != oam::INSTALL_COMBINE_DM_UM_PM) )
|
||||
continue;
|
||||
|
||||
DeviceNetworkList::iterator pt = systemModuleTypeConfig.moduletypeconfig[i].ModuleNetworkList.begin();
|
||||
|
Reference in New Issue
Block a user