328 Commits

Author SHA1 Message Date
Edison Su
d233f39c82 disable parallel for xenserver. Also for vmware, if full.clone is enabled and migratecommand will have the behavor of start/stop command 2014-10-09 17:14:57 -07:00
Santhosh Edukulla
31a42d2b7a Fixed few coverity patches
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
2014-10-09 11:45:26 +05:30
Anthony Xu
847e1e47ae when system VM ping times out, stop system VM 2014-09-30 12:35:44 -07:00
Hugo Trippaers
1c94017ff6 CID-1241966 Fix potential null deref 2014-09-30 11:27:51 +02:00
Devdeep Singh
55b4ead495 CLOUDSTACK-7598: When a vm deployed by cloudstack is stopped on the hypervisor
(outside cloudstack), the state of the vm is not updated in cloudstack db. The
ping task was not checking for resource (host) status by default. The power
state of the vms is returned as part of the resource status. Fixed the issue by
making sure ping task atleast tries once to get the resource status.
2014-09-25 13:13:56 +05:30
Jayapal
8c8c54f9f5 CLOUDSTACK-7622: Fixed deleting network when provider is disable 2014-09-25 10:31:51 +05:30
Harikrishna Patnala
c55bc0b2d1 CLOUDSTACK-7534: ResetVM for VM with attached datadisk fails when enable.ha.storage.migration is false
Separate global config to enable/disable Storage Migration during normal deployment
Introduced a configuration parameter named enable.storage.migration
2014-09-24 16:35:23 +05:30
Hugo Trippaers
8a13f44b44 Remove duplicate field in constructor 2014-09-18 16:02:26 +02:00
Daan Hoogland
7f440854f7 CLOUDSTACK-7184 retry-wait loop config to deal with network glitches
(cherry picked from commit a29f954a269c992307f0410df88ca4ac7a0b82a0)

Conflicts:
	engine/orchestration/src/com/cloud/agent/manager/DirectAgentAttache.java
2014-09-18 12:55:05 +02:00
Rohit Yadav
2cd99e3e72 CID-1116245: Lock for getting answers from SynchronousListener
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-18 11:56:29 +02:00
Rohit Yadav
3640c61207 CID-1116248: Synchornize method in SynchronousListener
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-09-18 11:54:31 +02:00
Anthony Xu
e5a91e40dd in tagCommand, AsyncJobExecutionContext doesn't need to be created if it doesn't exist 2014-09-17 18:15:41 -07:00
Min Chen
1b15efb5f0 CLOUDSTACK-7563: ClassCastException in VirtualMachineManagerImpl in
handling various Agent command answer.
2014-09-16 12:12:17 -07:00
Min Chen
d5a8f1d875 CLOUDSTACK-7553: Clean up cached agentMap and pingMap in case of agents
connecting back to a different MS.
2014-09-15 17:37:51 -07:00
Nitin Mehta
0a4ab3251a CLOUDSTACK-7513: listServiceOfferings API when called with VM's id also returns offerings to which it cant be upgraded. Adding the logic that when vmid is passed it looks for compatible offerngs using the storage type (local/shares), storage tags and also compute (cpu,speed, memory) in case the vm is running.
Also changed the scaleVm API to upgrade only when the destination offering has storage tags as a subset of current offering tags.
2014-09-15 11:02:34 -07:00
Bharat Kumar
2b7b837b28 CLOUDSTACK-6099 live migration is failing for vm deployed using dynaic compute offerings with NPE 2014-09-10 13:26:24 +02:00
Kishan Kavala
6f7c4863a2 CLOUDSTACK-7473: Vm migration is not supported for LXC. When host is put in maintenance mode, stop the Vms instead of migrating 2014-09-04 20:59:19 +05:30
Likitha Shetty
8ce6eba549 CLOUDSTACK-7415. Host remains in Alert after vCenter restart.
Management server PingTask should update PingMap entry for an agent only if it is already present in the Management Server's PingMap.
2014-08-25 13:24:28 +05:30
Santhosh Edukulla
19ffc93e2e Fixed few coverity reported issues:Aug22 2014 2014-08-21 17:09:27 +05:30
Likitha Shetty
7dbff9b42c CLOUDSTACK-7371. [VMware] Enabling primary storage maintenance fails when storages are across cluster.
1. While destroying a ROOT volume do the lookup of the associated VM under the DC and not just cluster.
2. In case of VMware, during VM start if a volume is being recreated no need to detach the old volume because
we now expunge it immediately and don't wait for the storage cleanup task to run.
2014-08-20 10:51:18 +05:30
Olivier Lemasle
de424061b2 CLOUDSTACK-7006: Restore template ID in ROOT volume usages
Signed-off-by: Sebastien Goasguen <runseb@gmail.com>
2014-08-18 10:14:26 -04:00
Koushik Das
8bc7ae695d CLOUDSTACK-7182: NPE while trying to deploy VMs in parallel in isolated network
- Check to see if network is implemented changed from 'state == Implementing||Implemented' to 'state == Implemented'.
The earlier check was a hack to prevent the issue described below.
- At the time of implementing network (using implementNetwork() method), if the VR needs to be deployed then it follows
the same path of regular VM deployment. This leads to a nested call to implementNetwork() while preparing VR nics. This
flow creates issues in dealing with network state transitions. The original call puts network in "Implementing" state
and then the nested call again tries to put it into same state resulting in issues. In order to avoid it, implementNetwork()
call for VR is replaced with below code.
2014-08-18 10:43:04 +05:30
Min Chen
fee2bfce49 CLOUDSTACK-7344:VOLUME.DELETE usage event missing for VM's in ERROR
state.
2014-08-13 22:15:47 -07:00
Santhosh Edukulla
e4d6cd8e6a Fixed coverity reported concurrency issues
Signed-off-by: Santhosh Edukulla <santhosh.edukulla@gmail.com>
2014-08-05 12:16:08 +05:30
Santhosh Edukulla
b7d3f1bd30 Fixed few coverity issues for resource synchronization 2014-08-04 16:09:26 +05:30
Alena Prokharchyk
ffeca8bbd2 CLOUDSTACK-7209: handle the case when network fails to implement NoTransitionException, and null is returned to the caller stack. All caller methods should verify if the return value is null before processing it further. 2014-08-01 09:47:28 -07:00
Saksham Srivastava
3d6c64d262 CLOUDSTACK-7206: Update vm_network_map table correctly 2014-08-01 13:58:06 +05:30
Santhosh Edukulla
bd3d8286d3 Fixed a simple coverity issue 2014-07-31 16:00:42 +05:30
Sheng Yang
f47cfc6eb1 CLOUDSTACK-7186: Revert "CLOUDSTACK-7182: NPE while trying to deploy VMs in parallel in isolated network"
This reverts commit 47d6a64b319ab064c4b855346f2bfdb250fb9ad8, which broke VPC
completely.
2014-07-28 16:02:21 -07:00
Anthony Xu
330c4ba578 completed the new vmsync TODOs in the code.
removed old vmsync logic
2014-07-28 12:51:37 -07:00
Murali Reddy
67876b215e CLOUDSTACK-7191:On restartNetwork destroy the VR immediatley, instead of
cleanup the rules then destroy

fix adds a provision to specify if cleanup is needed on network on
shutdown. VR is marked as to not to require network rules clean up on
network shutdown as the VR is destroyed and recreated.

ran the simulator tests that test network life cycle
2014-07-28 17:09:42 +05:30
Koushik Das
47d6a64b31 CLOUDSTACK-7182: NPE while trying to deploy VMs in parallel in isolated network
The following changes are made:
- Check to see if network is implemented changed from 'state == Implementing||Implemented' to 'state == Implemented'.
The earlier check was a hack to prevent the issue described below.
- At the time of implementing network (using implementNetwork() method), if the VR needs to be deployed then
it follows the same path of regular VM deployment. This leads to a nested call to implementNetwork() while
preparing VR nics. This flow creates issues in dealing with network state transitions. The original call
puts network in "Implementing" state and then the nested call again tries to put it into same state resulting
in issues. In order to avoid it, implementNetwork() call for VR is replaced with below code.
2014-07-25 15:17:35 +05:30
Hugo Trippaers
676b2d1569 Fix overflow before widening issues reported by Coverity 2014-07-24 13:22:14 +02:00
Hugo Trippaers
e78bb1d225 Switch the catch to Throwable. Uncaught exceptions in a scheduled
threadpool executor will not report or log uncaught exceptions but will
kill the thread causing unexplained timeouts in CS.
2014-07-16 16:24:55 +02:00
Koushik Das
aacf8ef77b Findbugs fixes in cloud-utils project and a few other places 2014-07-15 14:23:17 +05:30
Santhosh Edukulla
97d296bfbd Fixed Coverity reported performance issues like inefficient string concatenations, wrong boxing or unboxing types, inefficent map element retrievals
Signed-off-by: Daan Hoogland <daan@onecht.net>
2014-07-01 22:06:25 +02:00
Hugo Trippaers
ab0dca0385 Catch possible exceptions in finally so they won't shadow the original exception. 2014-06-25 15:51:29 +02:00
Hugo Trippaers
cd0ef09344 Fix typo and add the right exception to the error map. 2014-06-25 15:51:28 +02:00
Kelven Yang
f756d4aa33 Make job info universally available across management server and resource agents 2014-06-24 16:28:22 -07:00
Mike Tutkowski
3d9eaf0753 Fixed some spacing issues from 4d6c682f18d9bca50c145b55d8fa61ea1ab71755 2014-06-24 15:27:06 -06:00
punith-cloudbyte
4d6c682f18 supporting nfs protocol and resize feature for managed storage for xenserver
resize feature refactored

Signed-off-by: Mike Tutkowski <mike.tutkowski@solidfire.com>
2014-06-24 15:16:45 -06:00
Anshul Gangwar
450d890942 CLOUDSTACK-6830: Fixed during VM migration, volumes on zone wide primary store
requires storage migration resulting in failure of VM migration. This also improves
the hostsformigration api. Firstly we were trying to list all hosts and then
finding suitable storage pools for all volumes and then we were checking whether
vm migration requires storage migration to that host. Now the process is updated.
We are checking for only those volumes which are not in zone wide primary store.
We are verifying by comparing volumes->poolid->clusterid to host clusterid. If it
uses local or clusterids are different then verifying whether host has suitable
storage pools for the volume of the vm to be migrated too.
2014-06-20 16:32:19 +05:30
Alena Prokharchyk
3312394154 CLOUDSTACK-6934: don't try to detach volume from host when volume was never allocated to a primary storage 2014-06-18 12:39:36 -07:00
Kelven Yang
f529823566 Add ReflectionUse annotation for marking up *un-used* methods 2014-06-17 17:31:29 -07:00
Anshul Gangwar
aa21cdcd49 CLOUDSTACK-6897: when we try to attach the uploaded/allocated volume to a VM on zwps, then we were passing the podId of VM instead of storage pool to storage allocator. This resulting in use of Clusterscope storage allocator, allocating a storage pool for VM on zwps beacuse of pod id not null. This was resulting in scope conflict later 2014-06-13 14:47:00 +05:30
Anshul Gangwar
66d1eb92f0 CLOUDSTACK-6865 , CLOUDSTACK-6868: [hyperv] while attaching the volume we were changing the volume's Image format to hypervisor's default Image format, hence it was failing to find the volume with vhdx format. Now changed the behavior to set Image Format for volume only when it is not set 2014-06-13 13:26:02 +05:30
Rajani Karuturi
b666a1f3a5 Fixed issues reported by coverity NPEs, unwritten field access and self assignment
Signed-off-by: Koushik Das <koushik@apache.org>
2014-06-10 14:34:47 +05:30
Prachi Damle
3b3f4577b0 CLOUDSTACK-6476: Basic Zone with Multiple Pods Setup: DHCP server doesnt get deployed in the pod where the VM gets deployed
Changes:
PodId in which the router should get started was not being saved to the DB due to the VO's setter method not following the setXXX format. So when planner loaded the router from DB, it always got podId as null and that would allow planner to deploy the router in any pod. If the router happens to start in a different pod than the user VM, the Vm fails to start since the Dhcp service check fails.

Fixed the VO's setPodId method, that was causing the DB save operation fail.
2014-06-06 16:15:31 -07:00
Marcus Sorensen
7ce3034299 CLOUDSTACK-6790: Disable PXE ROM for system vm nics 2014-05-27 16:52:26 -06:00
Koushik Das
d5754d9101 CLOUDSTACK-6740: Direct agent command throttling improvements
List of changes:
1. Created a separate thread pool for handling cron and ping tasks. The size of the pool is based on direct.agent.pool.size. The existing direct agent pool will run all commands other than cron and ping.
2. For normal tasks (generated as part of user/admin API calls), if throttle limit is reached then tasks get queued up for subsequent execution once threads are available.
3. For cron and ping tasks (internally generated by MS like ping, VM sync etc.), if throttle limit is reached then these gets rejected. Since these are internally generated these can be rejected without any issues.
2014-05-22 14:15:42 +05:30