mirror of https://github.com/apache/cloudstack.git
Summary: fix cloud-agent KVM calls to cloudstack-agent for centos6.3
BUG-ID: CLOUDSTACK-1234 Bugfix-for: 4.1, master Reported-by: Rayees Namathponnan Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1360736064 -0700
This commit is contained in:
parent
15e466c56d
commit
ae2b673e03
|
|
@ -19,12 +19,12 @@
|
|||
|
||||
|
||||
|
||||
# Did cloud-agent installed
|
||||
# Did cloudstack-agent installed
|
||||
#set -x
|
||||
install_cloud_agent() {
|
||||
local dev=$1
|
||||
local retry=10
|
||||
which cloud-setup-agent
|
||||
which cloudstack-setup-agent
|
||||
if [ $? -gt 0 ]
|
||||
then
|
||||
# download the repo
|
||||
|
|
@ -51,7 +51,7 @@ install_cloud_agent() {
|
|||
while [ "$retry" -gt "0" ]
|
||||
do
|
||||
yum clean all
|
||||
yum install cloud-agent -y
|
||||
yum install cloudstack-agent -y
|
||||
if [ $? -gt 0 ]
|
||||
then
|
||||
let retry=retry-1
|
||||
|
|
@ -64,7 +64,7 @@ install_cloud_agent() {
|
|||
while [ "$retry" -gt "0" ]
|
||||
do
|
||||
yum clean all
|
||||
yum update cloud-agent -y
|
||||
yum update cloudstack-agent -y
|
||||
if [ $? -gt 0 ]
|
||||
then
|
||||
let retry=retry-1
|
||||
|
|
@ -155,7 +155,7 @@ cloud_agent_setup() {
|
|||
sed -i 's/\(SELINUX\)\(.*\)/\1=permissive/' /etc/selinux/config
|
||||
setenforce 0
|
||||
fi
|
||||
cloud-setup-agent --host=$host --zone=$zone --pod=$pod --cluster=$cluster --guid=$guid -a > /dev/null
|
||||
cloudstack-setup-agent --host=$host --zone=$zone --pod=$pod --cluster=$cluster --guid=$guid -a > /dev/null
|
||||
}
|
||||
|
||||
cloud_consoleP_setup() {
|
||||
|
|
@ -224,5 +224,5 @@ then
|
|||
setenforce 0
|
||||
fi
|
||||
|
||||
cloud-setup-agent --host=$host --zone=$zone --pod=$pod --cluster=$cluster --guid=$guid $paramters -a > /dev/null
|
||||
cloudstack-setup-agent --host=$host --zone=$zone --pod=$pod --cluster=$cluster --guid=$guid $paramters -a > /dev/null
|
||||
#cloud_consoleP_setup $host $zone $pod
|
||||
|
|
|
|||
|
|
@ -212,7 +212,7 @@ Listener, ResourceStateAdapter {
|
|||
parameters += " --prvNic=" + kvmPrivateNic;
|
||||
parameters += " --guestNic=" + kvmGuestNic;
|
||||
|
||||
SSHCmdHelper.sshExecuteCmd(sshConnection, "cloud-setup-agent " + parameters, 3);
|
||||
SSHCmdHelper.sshExecuteCmd(sshConnection, "cloudstack-setup-agent " + parameters, 3);
|
||||
|
||||
KvmDummyResourceBase kvmResource = new KvmDummyResourceBase();
|
||||
Map<String, Object> params = new HashMap<String, Object>();
|
||||
|
|
|
|||
|
|
@ -2361,7 +2361,7 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager,
|
|||
ResourceState.Event.AdminCancelMaintenance, _nodeId);
|
||||
_agentMgr.pullAgentOutMaintenance(hostId);
|
||||
|
||||
// for kvm, need to log into kvm host, restart cloud-agent
|
||||
// for kvm, need to log into kvm host, restart cloudstack-agent
|
||||
if (host.getHypervisorType() == HypervisorType.KVM) {
|
||||
_hostDao.loadDetails(host);
|
||||
String password = host.getDetail("password");
|
||||
|
|
@ -2382,7 +2382,7 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager,
|
|||
|
||||
try {
|
||||
SSHCmdHelper.sshExecuteCmdOneShot(connection,
|
||||
"service cloud-agent restart");
|
||||
"service cloudstack-agent restart");
|
||||
} catch (sshException e) {
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue