Commit Graph

25192 Commits

Author SHA1 Message Date
Rohit Yadav 68b5440d44 fix NPE cases, throw exceptions early on
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 17:44:32 +05:30
Gaurav Aradhye 9658569f5a CLOUDSTACK-8124: Skipping snapshot tests on Hyper-V
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2015-02-05 17:36:11 +05:30
Gaurav Aradhye 762727439b CLOUDSTACK-8124: Skipping snapshot tests on hyperv hypervisor
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2015-02-05 17:35:36 +05:30
Rohit Yadav 78b9be07d5 Merge remote-tracking branch 'terbolous/saml2-certvalidity' into 4.5
This closes #71

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 17:20:35 +05:30
Rohit Yadav 1cf165f86d ApiResponseHelper: fix NPE when parent of snapshot is null 2015-02-05 17:10:56 +05:30
Kishan Kavala ca0a77088c Close transaction while fetching recent events
(cherry picked from commit 438f90a262)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:56:20 +05:30
Rohit Yadav fb1069ace9 agent: don't investigate if host is null, send alert instead
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:42:56 +05:30
Rohit Yadav 419508b016 orchestration: allow storage migration
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit a2547ed827)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:39:17 +05:30
Kishan Kavala 7a397cd4ef For volumes created from template, do not log offering ID in VOLUME.CREATE in usage_event. Moved offering type to DiskOffering interface
(cherry picked from commit 9eb8d538dd)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:37:59 +05:30
Rohit Yadav e40b06e9ca AgentAttache: allow checkonhost command in maintenance, cancel if only allowed
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:29:44 +05:30
Rohit Yadav 46cd98b163 jobs: fix corner cases, add NPE checks
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:20:47 +05:30
Hugo Trippaers 744c20bd7c CID-1249801 This should be a string comparison, not an object comparison
(cherry picked from commit ab980cd3b7)

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 16:02:24 +05:30
Erik Weber 03e07c41b5 CLOUDSTACK-8215: Change Date calculation to Joda DateTime 2015-02-05 11:31:42 +01:00
Santhosh Edukulla c25263ba81 Fixed Coverity Issues 2015-02-05 15:59:29 +05:30
Rohit Yadav b442d77dc9 Publish secstorage failure, removed by a12ab8a2b3
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 15:54:27 +05:30
Rohit Yadav 125abe8234 improve protocol enabling based on socket object type
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit d62d511f47)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 15:49:01 +05:30
Hugo Trippaers 6fc97f9181 CID-1116546 Fix resource leak
(cherry picked from commit fe0168f6d2)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 15:32:08 +05:30
Likitha Shetty 7de7885a54 CLOUDSTACK-8125. VM fails to start on the first attempt after a cold migration.
Update volume chain_info to NULL during cold migration.
Otherwise during VM start, CCP will configure and try to power-on the VM with wrong disk information.

(cherry picked from commit 7b32b8a268)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 15:30:49 +05:30
Rohit Yadav 6ddaef7a48 CloudStackPrimaryDataStoreLifeCycleImpl: decode path as UTF8 or fallback
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 15:27:45 +05:30
Damodar 01cc1b816d CLOUDSTACK-7792: Usage Events to be captured based on Volume State Machine
(cherry picked from commit 781648fb10)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

Conflicts:
	engine/orchestration/src/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java
	engine/storage/volume/src/org/apache/cloudstack/storage/volume/VolumeServiceImpl.java
2015-02-05 15:22:21 +05:30
Erik Weber b84c8889a3 SAML changing date calculation
Signed-off-by: Erik Weber <terbolous@gmail.com>
2015-02-05 10:29:27 +01:00
Damodar 8ec6d0471c CLOUDSTACK-7648: There are new VM State Machine changes introduced which were missed to capture the usage events
(cherry picked from commit 50185b7c3a)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

Conflicts:
	plugins/hypervisors/baremetal/src/com/cloud/baremetal/manager/BaremetalManagerImpl.java
	server/src/com/cloud/capacity/CapacityManagerImpl.java
	server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java
2015-02-05 14:56:52 +05:30
Kishan Kavala 6541354a59 Trigger user stats aggregation job at midnight in usage aggregation timezone
(cherry picked from commit 4ac96d637c)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

Conflicts:
	server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java
2015-02-05 14:33:27 +05:30
Rajesh Battala 782adc106e CLOUDSTACK-7313 Fixed issues in provisioning vpx in SDX from CS
(cherry picked from commit 0f528df228)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 13:50:29 +05:30
Santhosh Edukulla bd190192b9 Fixed Resource Leaks
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
(cherry picked from commit 350ac4c4b0)

Conflicts:
	engine/schema/src/com/cloud/upgrade/dao/Upgrade441to450.java
2015-02-05 13:47:22 +05:30
Anthony Xu 98b416b7f0 fixed NPE
(cherry picked from commit c78f14cbc2)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-05 12:10:09 +05:30
Rohit Yadav bf17f640c6 CLOUDSTACK-8198: Use random local storage UUID
Earlier host addition of multiple hosts with local storage failed due to
same local storage UUID being used where the storage path is same.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-03 22:26:51 +05:30
Rohit Yadav 1172867df0 CLOUDSTACK-8195: Don't break IdP, return metadata XML
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-03 16:59:09 +05:30
Rohit Yadav 5159cbec9f appliance: get scripts only from 4.5 and not master
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-03 16:50:37 +05:30
Rohit Yadav 876c78fe1b CLOUDSTACK-8191: SAML users should have their own accounts
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 19:56:25 +05:30
Rohit Yadav 48ec9ac11b CLOUDSTACK-8190: Fix xenserver traffic label for backward compatiblity
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 16:09:56 +05:30
Anthony Xu 64e938b701 fixed NPE on calculating vm snasphot volume size
(cherry picked from commit 95c7ffbd46)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 15:03:43 +05:30
Anthony Xu 86fe713ab9 don't need to check if pv driver is updated, old pv driver should work
(cherry picked from commit 45611a0f83)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 15:02:31 +05:30
Likitha Shetty bf7013f0ea CLOUDSTACK-8111. NFS secondary storage repetitively mounted on CS server with ESXi hypervisors.
Fix cleanup of NFS mounts on management server during server starup by correcting how mount points are listed for a management server.

(cherry picked from commit 647532376f)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 14:51:53 +05:30
Likitha Shetty d466ecaf7a CLOUDSTACK-5485. Cannot process more than 5 concurrent snapshots.
Number of threads on SSVM agent for connection with MS (Agent->NioClient) should be configurable using global config 'workers'.

(cherry picked from commit bc235ed5eb)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 14:46:58 +05:30
Devdeep Singh 0e4d91aa91 CLOUDSTACK-6924. To attach a volume if a volume needs to be moved to another storage
pool, the source and destination pools cannot be local and cluster/zone and vice versa.
Cloudstack detects it and throws a exception. However, the end user only sees an
unexpected exception and not the reason for failure. Fixed it by making sure the
reason for the failure is correctly captured and shown to the end user.

(cherry picked from commit cffae8eef0)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

Conflicts:
	server/src/com/cloud/storage/VolumeApiServiceImpl.java
2015-02-02 14:36:07 +05:30
Likitha Shetty f00140243c CLOUDSTACK-8112. CS allows creation of VM's with the same Display name when vm.instancename.flag is set to true.
During VM creation, if vm.instancename.flag is set to true and hypervisor type is VMware, check if VM with the same hostname already exists in the zone.

(cherry picked from commit 5f9e4fddf3)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 14:30:18 +05:30
Kishan Kavala 0c1172ffe9 Network offering usage event should be logged for UserVms only
(cherry picked from commit 42cecbb000)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 14:27:24 +05:30
Likitha Shetty 294f5bf331 CLOUDSTACK-8114. Ensure VM stop and then start updates the volume path correctly in the DB.
(cherry picked from commit 521258bafb)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 14:27:04 +05:30
Likitha Shetty 272f282a05 CLOUDSTACK-8119. Propagate error message to UI for attach/detach volume failure operations.
For AttachVolume/DetachVolume API command, improve user error message in case of RuntimeException by throwing the exception instead of 'Unexpected Exception'.

(cherry picked from commit 4d7ede535d)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

Conflicts:
	server/src/com/cloud/storage/VolumeApiServiceImpl.java
2015-02-02 13:57:38 +05:30
Likitha Shetty b9932a0129 CLOUDSTACK-8122. Handle NPE thrown during migration failures.
When migration fails instead of returning NULL, throw the exception.

(cherry picked from commit a5a65c7b55)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:56:43 +05:30
Likitha Shetty bcbfe3bdee CLOUDSTACK-8129. Cold migration of VM across VMware DCs leaves the VM behind in the source host.
If VM has been cold migrated across different VMware DCs, then unregister the VM from source host.

(cherry picked from commit 15b348632d)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:47 +05:30
Likitha Shetty 12cbebc544 CLOUDSTACK-8126. Cold Migration of VM is not working as expected. In case a VM is cold migrated across clusters then VM fails to start.
1. If a VM by the same name exists on a different cluster in the VMware DC, unregister the existing VM and continue with the VM start.
2. If VM start succeeds, delete VM files associated with the unregistered VM.
3. If VM start fails, re-register the unregistered VM.

(cherry picked from commit 974b0180dd)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:42 +05:30
Likitha Shetty a1eca8bd16 CLOUDSTACK-8118. Root volume migration fails with 'No such disk device' in case of vCenter 5.5 setup.
If an exact match is being done while locating disk chain by name, don't trim snapshot postfix appended to the disk name.

(cherry picked from commit ddcae8a930)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:36 +05:30
Likitha Shetty ad92b85076 CLOUDSTACK-8113. VM migration fails with "Message: No such disk device: " error.
Consolidate VM disks once VM/volumes are migrated.

(cherry picked from commit cb211f18d1)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:29 +05:30
Likitha Shetty 45d32234a6 CLOUDSTACK-8112. CS allows creation of VM's with the same Display name when vm.instancename.flag is set to true.
Before registering a VM check if a different CS VM with same name exists in vCenter.

(cherry picked from commit 33179cce56)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:22 +05:30
Likitha Shetty b2fa91629e CLOUDSTACK-8110. VM name in vCenter should be VM's DisplayName if global config 'vm.instancename.flag' is set.
(cherry picked from commit 51ee90074d)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:16 +05:30
Sateesh Chodapuneedi ba00a1a081 CLOUDSTACK-7803 Storage live migration of instance may not happen if instance has ISO attached.
BUG-ID:CLOUDSTACK-7803
Summary:Ensure secondary storage is mounted on target host.
Reviewed-By:Rajesh

Signed-off-by: Sateesh Chodapuneedi <sateesh@apache.org>
(cherry picked from commit bca015306e)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:10 +05:30
Likitha Shetty c8a437b782 BUG-ID: CLOUDSTACK-7102. Volume migration fails with 'VM i-2-3-VM does not exist in VMware datacenter' expection.
Look for a VM in vCenter based on both the vCenter name and CS internal name (required in case 'vm.instancename.flag' is enabled).
During Attach Volume and Volume Migration, for lookup and other operations use VM's name as obtained from vCenter instead of using the name set in the agent command.

(cherry picked from commit b8fdda0a34)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:51:04 +05:30
Likitha Shetty 8f4aa23ae0 CLOUDSTACK-8127. VM name not displayed after attaching data disk to a VM.
If user hasn't supplied a display name for a VM, default it to VM name in listVolume response.
This behaviour is identical to listVirtualMachine response.

(cherry picked from commit ff7997a2b1)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-02-02 13:01:33 +05:30