You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ch...@apache.org on 2013/03/04 15:44:41 UTC
git commit: refs/heads/4.1 - CLOUDSTACK-1262: update default built-in
systemvm.iso search patch to be consistent with RPM location
Updated Branches:
refs/heads/4.1 349799af4 -> 99284e7c9
CLOUDSTACK-1262: update default built-in systemvm.iso search patch to be consistent with RPM location
Signed-off-by: Kelven Yang <ke...@gmail.com>
Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/99284e7c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/99284e7c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/99284e7c
Branch: refs/heads/4.1
Commit: 99284e7c954b6771dd5101abe5352d4d43a4105c
Parents: 349799a
Author: Pradeep <pr...@citrix.com>
Authored: Mon Mar 4 13:29:32 2013 +0530
Committer: Chip Childers <ch...@gmail.com>
Committed: Mon Mar 4 09:44:24 2013 -0500
----------------------------------------------------------------------
.../vmware/manager/VmwareManagerImpl.java | 33 ++++++++------
1 files changed, 19 insertions(+), 14 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/99284e7c/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
----------------------------------------------------------------------
diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
index 0b020bb..7fc32ad 100755
--- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
+++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
@@ -604,14 +604,17 @@ public class VmwareManagerImpl extends ManagerBase implements VmwareManager, Vmw
if (url != null) {
isoFile = new File(url.getPath());
}
- if (isoFile == null || !isoFile.exists()) {
- isoFile = new File("/usr/lib64/cloud/common/" + "/vms/systemvm.iso");
- if (!isoFile.exists()) {
- isoFile = new File("/usr/lib/cloud/common/" + "/vms/systemvm.iso");
- }
+
+ if(isoFile == null || !isoFile.exists()) {
+ isoFile = new File("/usr/share/cloudstack-common/vms/systemvm.iso");
}
- return isoFile;
- }
+
+ assert(isoFile != null);
+ if(!isoFile.exists()) {
+ s_logger.error("Unable to locate systemvm.iso in your setup at " + isoFile.toString());
+ }
+ return isoFile;
+ }
@Override
public File getSystemVMKeyFile() {
@@ -620,14 +623,16 @@ public class VmwareManagerImpl extends ManagerBase implements VmwareManager, Vmw
if ( url != null ){
keyFile = new File(url.getPath());
}
+
if (keyFile == null || !keyFile.exists()) {
- keyFile = new File("/usr/lib64/cloud/common" + "/scripts/vm/systemvm/id_rsa.cloud");
- if (!keyFile.exists()) {
- keyFile = new File("/usr/lib/cloud/common" + "/scripts/vm/systemvm/id_rsa.cloud");
- }
- }
- return keyFile;
- }
+ keyFile = new File("/usr/share/cloudstack-common/scripts/vm/systemvm/id_rsa.cloud");
+ }
+ assert(keyFile != null);
+ if(!keyFile.exists()) {
+ s_logger.error("Unable to locate id_rsa.cloud in your setup at " + keyFile.toString());
+ }
+ return keyFile;
+ }
private Runnable getHostScanTask() {
return new Runnable() {