Commit Graph

538 Commits

Author SHA1 Message Date
Marcus Sorensen eed4d2d92e CLOUDSTACK-1846, CLOUDSTACK-1845 - KVM Storage, sometimes KVMHA will remount
deleted NFS pools, causing failures when defining new storage pools. Sometimes
a storage pool has never been used on a host, and getStoragePool fails when
copying templates or in storage migration. deleteStoragePool(pool) often fails
silently, leaving no pool defined in libvirt, but a mountpoint left behind.
This patch handles some of these exceptions and brings forward any issues via
logging.

Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1364603486 -0600
2013-04-01 20:48:51 +01:00
Funs Kessen 8a358980b7 Removing baremetal related references
Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-03-27 15:43:11 +05:30
Vijayendra Bhamidipati c25d60f175 CLOUDSTACK-1773:Temporarily disabling baremetal functionality in CS 4.1
Signed-off-by: Min Chen <min.chen@citrix.com>
2013-03-25 11:34:53 -07:00
Wei Zhou f4f78311b3 CLOUDSTACK-1666: Fix NetworkUsage for VPC on KVM
The collection of network usage from VPC virtual router on KVM does not work,
because there is no corresponding procedure to deal with VPC virtual router
(cmd.isForVpc() = true).

Reviewed-by: Kishan Kavala <kishan@apache.org>
Reported-by: Wei Zhou <w.zhou@leaseweb.com>

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-03-22 16:58:40 +00:00
Marcus Sorensen fc121c2b81 CLOUDSTACK-1761 - Available local storage disk capacity incorrectly reported in
KVM to manager. This adds collection of available storage to KVM, not
     just used.

Bugfix-for: 4.0.2, 4.1, master
Submitted-by: Ted Smith <darnoth@gmail.com>
Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1363966235 -0600
2013-03-22 15:35:17 +00:00
Edison Su 78f1ab1af5 CLOUDSTACK-1772: revert bc94948e06, doesn't specify vnc listening port, make live migration work 2013-03-22 12:45:32 +00:00
Vijay venkatachalam 886c3a5696 CLOUDSTACK-1537. Fixing Network Restart case for AutoScale 2013-03-21 16:53:42 +00:00
hongtu_zang c9c50e4efb 4.1 fix bug vmware create volume from snapshot will missing data 2013-03-19 12:50:05 -04:00
Marcus Sorensen 186fb9ff51 Summary: KVM - remove harmless message about domain not found on VM stop
Detail: When we stop a VM, it's definition is no longer valid. Therefore, we
need to catch the exception thrown from libvirt in trying to lookup a
non-existent domain by UUID while trying to check if it's shut down.

BUG-ID:CLOUDSTACK-600
Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1363201066 -0600
2013-03-15 09:56:19 -04:00
Marcus Sorensen 6df107bcf6 Summary: KVM - undefine persistent VMs on stop
Detail: A previous patch fixed an issue where we are defining VMs to persist
locally on KVM hosts, which can cause issues if the agent isn't running and
libvirt decides to start the VM unbeknownst to cloudstack. The previous patch
stopped defining VMs as persistent. This patch adds compatibility for existing
cloudstack environments, removing the persistent definition on stop if needed.

BUG-ID: CLOUDSTACK-600
Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1363194656 -0600
2013-03-15 09:56:04 -04:00
Wido den Hollander cefece7148 agent: Do not define domains persistent in libvirt
We used to define domains persistent in libvirt, which caused XML definitions
to stay there after a reboot of the hypervisor.

We however don't do anything with those already defined domains, actually, we wipe
all defined domains when starting the agent.

Some users however reported that libvirt started these domains after a reboot
before the CloudStack agent was started.

By starting domains from the XML description and not defining them we prevent
them from ever being stored in libvirt.
2013-03-15 09:55:51 -04:00
Wido den Hollander 8d333ec664 CLOUDSTACK-1415: Merge in the Debian/Ubuntu packaging work from master
This patch inclused the packaging work from master tailored for 4.1

Not everything has been tested yet, but it should generate DEB packages.

Signed-off-by: Wido den Hollander <wido@42on.com>
2013-03-14 21:02:30 -04:00
Rohit Yadav 8071bb7fec Spring fails to inject the class itself which is a pluggable service. A
minor issue, but the listApis won't list the "listApis" API itself.
So, we manually addAll getCommands() from the class to the cmdClass (the
list of cmd classes)

Signed-off-by: Chip Childers <chip.childers@gmail.com>
2013-03-14 16:17:14 -04:00
Marcus Sorensen 6928679ba8 CLOUDSTACK-1648 - KVM - make storage pools non-persistent in libvirt. Persisting
cloud-defined resources on the host has caused various problems. As a backward
compatible fix, if an existing pool with a different name collides with a pool
being created (by path), the pool will be redefined with the name cloudstack
knows about. This is actually what brought up the bug, a persisted storage pool
cloudstack wasn't managing.

Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1363210149 -0600
2013-03-14 15:30:42 -04:00
Murali Reddy 84fbc7e9a2 CLOUDSTACK-1427: Failed to delete Guestnetwork which has LB with Netscaler
There is no need for getIpDeployer to depend on the fact a NetScaler
device is allocated (network is implemented state) or not-allocated
(network is in shutdown state)
2013-03-13 11:50:45 -04:00
Dennis Lawler 29ec31c645 CLOUDSTACK-1620: getXenServer602GuestOsType -> getXenServer610GuestOsType Fixing XenServer 6.1 OS types incompatible with XS6.0 2013-03-11 09:54:54 -04:00
Sheng Yang b8a16856ff CLOUDSTACK-1461: Don't set dns server for non-default ipv6 network
The non-default parameter can be used by ipv4 as well in the future.
2013-03-10 21:44:59 -04:00
Kelven Yang 0f000ad4ff CLOUDSTACK-1615: instead of returning empty host firewall ruleset, ESXi 5.0 Update 1 may return null to indicate empty host firewall ruleset, Cloudstack needs to handle this changed behave 2013-03-08 17:40:02 -08:00
Min Chen 0afc2d0033 CLOUDSTACK-1484: provide api.throttling.enabled gloabl configuration settings to enable/disable api throttling feature. 2013-03-05 11:26:20 -05:00
Pradeep 99284e7c95 CLOUDSTACK-1262: update default built-in systemvm.iso search patch to be consistent with RPM location
Signed-off-by: Kelven Yang <kelveny@gmail.com>
2013-03-04 09:44:24 -05:00
frank 38e06631d2 revert 75aad6763b
which was wrongly checked in after 4.1 frozen
2013-03-01 17:50:08 -08:00
Frank Zhang 75aad6763b CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

make kikcstart working with ubuntu
2013-03-01 15:03:33 -08:00
Hugo Trippaers ac720c1cc8 Use proper version parameters for libvirt and jna (as per widos commit is master) 2013-03-01 20:14:26 +01:00
Hugo Trippaers 6709e83ba0 CLOUDSTACK-1469 As jna is a dependency of libvirt the versions matter 2013-03-01 19:10:03 +01:00
frank 2093aefcb8 CloudStack CLOUDSTACK-723
Enhanced baremetal servers support on Cisco UCS

change UcsXxxDao to Spring xml loading
change ListxxxCmd to inherit ListCmd
change API response in line with current API architecture
adding missing db schema  to db upgrade schemaOh
2013-02-28 15:34:57 -08:00
Kelven Yang ccc51147a5 CLOUDSTACK-1252: Fix the issue of locating systemvm patch ISO under VMware environment 2013-02-27 22:05:23 -05:00
Noa Resare 78e8d18428 CLOUDSTACK-1415: Debian & Ubuntu packaging work
Some concepts included:

* the replace.properties location used by maven is parameterized to allow
  for a build that does not modify the currently git tracked files
* package naming is updated along the lines of what was discussed on the
  -dev mailing list and between committers at the Build a Cloud Day in Belgium.
* package version pattern is updated (since we redo all package names,
  we might as well drop the epoch)
2013-02-27 15:38:55 +00:00
Murali Reddy d76211d5d0 CLOUDSTACK-1391: EventBus is not getting injected after javelin merge
added logic to inject event bus using ComponentContext.getComponent
2013-02-27 14:52:11 +05:30
Rohit Yadav 48ce06b9ba rat: Fix license in file headers
Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-27 12:10:57 +05:30
frank 696b4ed8ea CloudStack CLOUDSTACK-723
Enhanced baremetal servers support on Cisco UCS

change API response in line with new API response convention
2013-02-26 16:31:26 -08:00
Prasanna Santhanam 6977e7bd45 spring changes for simulator component
allow spring to do DI for simulator plugin. componentContext.xml will
have simulator components disabled by default.

Signed-off-by: Prasanna Santhanam <tsp@apache.org>

Conflicts:
	client/tomcatconf/componentContext.xml.in

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-02-26 18:54:02 +05:30
Rohit Yadav c7935a9ab6 CLOUDSTACK-416: Add XCP 1.6.x in XcpServerDiscoverer.java processConnect
Thanks to Devdeep for pointing this out.

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-26 15:34:55 +05:30
Rohit Yadav ec0759ae76 CLOUDSTACK-416: Add XCP 1.6.x as supported hypervisor
Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
(cherry picked from commit 43183893bd)

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-26 13:59:08 +05:30
Sheng Yang 0760fdf6d0 CLOUDSTACK-1332: Add IPv6 DNS for Zone 2013-02-25 16:07:14 -08:00
Mice Xia 8a6d0ffda6 add missing license header reported by rat 2013-02-22 13:10:22 +08:00
frank 5f0bb8ab29 CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

pass host id to baremetal discover when mgmt loads existing hosts
2013-02-21 15:39:15 -08:00
frank 2e069ad16b CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

able to start vm
2013-02-21 15:39:15 -08:00
frank 10afc3b571 CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

adding missing scripts back
2013-02-21 15:39:15 -08:00
frank 241d05e685 CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

fixing bugs to align to new code base
2013-02-21 15:39:15 -08:00
Hugo Trippaers aea5b268b4 Prachi's commit 20a747601c introduced a
new call to network.getPhysicalNetworkId() which wasn't mocked yet in
the nvp plugin unittests.
2013-02-21 12:27:53 +01:00
Prachi Damle 20a747601c CLOUDSTACK-1331: Upgrade fails for a 2.2.14 Zone having multiple guest networks using network_tags and Public Vlan
Changes:
-We need to update the physical_network_id for public vlans.
-Physical network ID should be retrieved from the network if present.
2013-02-20 11:25:36 -08:00
Min Chen 2ee16350dd CLOUDSTACK-1253: Remove @author tag. 2013-02-15 10:40:39 -08:00
Marcus Sorensen 86bb0055cd Summary: Adjust systemvm.iso path for KVM, due to packaging changes
Detail: Removing references to /usr/lib/cloud and /usr/lib64/cloud so that old
systemvm.iso files aren't found by accident. systemvm.iso should exist in
/usr/share/cloudstack-common/vms now.

Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1360860243 -0700
2013-02-14 09:44:03 -07:00
Marcus Sorensen 9b9f3e2e03 Summary: KVM - Fix physical net parsing when traffic label points to tagged dev
Detail: If your traffic label points to a bridge that is on a tagged interface
rather than a real physical interface, cloudstack may not parse the physical
interface correctly, bringing up tagged interfaces on the tagged interface.

Signed-off-by: Marcus Sorensen <marcus@betterservers.com> 1360798665 -0700
2013-02-13 16:37:45 -07:00
Rohit Yadav 0f317567d2 CLOUDSTACK-710: CitrixResourceBase, if dest dir is not found, mkdir -m 700 -p
This is a security failsafe, so even if destination does not exist we mkdir the path
with 0700 permission. If path exists mkdir -m 700 -p won't do anything.

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
(cherry picked from commit 3a0c99b0a4)

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-13 22:48:03 +05:30
Rohit Yadav ce46821b4a CLOUDSTACK-1237: Fix an overriding method that would help find template adapter
Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
(cherry picked from commit fcb4b7a6a7)

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-13 15:21:24 +05:30
Rohit Yadav 5eb767f563 CLOUDSTACK-710: mkdir -p destination before scp-ing file in CitrixResourceBase
- Assumption is that mkdir is available on xen host
- We don't know what kind of file we're copying, dirs would have 0777 permission
  by default

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-11 16:42:49 +05:30
frank c811a025f2 CloudStack CLOUDSTACK-774
Supporting kickstart in CloudStack baremetal

add api annotation to baremetal related api
2013-02-08 14:18:05 -08:00
Min Chen ee90b4cad3 CLOUDSTACK-1190: make APIChecker throw one sensible exception. 2013-02-08 11:05:11 -08:00
Rohit Yadav 5d1769335c CLOUDSTACK-1210: Fix pluggable service, apiserver, mgmt server impl, api-discovery
- Mgmt server impl is a pluggable service, fix it's method
- Fix getCommands() to return all cmd api classes supported by this mgmt server
- For api-discovery, get commands from pluggable services only, don't use reflections
- Don't use reflections in ApiServer, iterate pluggableservices
- Fix api discovery unit test
- The fix was done automatically using following python program along with
  following step:

1. Get all apis provided by default mgmt server, all of them are in cloud-api now
   cd api/src/org/apache/cloudstack/api/command
   find . >> apis
2. For all apis, generate java code that adds the class to the cmdList arraylist:
   f = open('apis', 'r')
   data = f.read()
   f.close()
   output = ""
   for a in data.split('\n'):
     output += "cmdList.add(%s);" % a.split('/')[-1].replace('.java', '.class')
   # wrote output to a file, copied content to mgmt server impl's getCommands()
   # similarly, fixed import statements using same code, splitting on /

Testing:
Ran apiserver, put breakpoints in ApiServer's init() where classes are processed
Total cmd classes found by reflections (ReflectUtil) = 354
Total cmd classes found by getCommands for all pluggable services = 354

Next, copied the comma separated values for each set to a string in ipython, a & b
set(a).difference(set(b)) returned null.

The above test implies both set of cmd classes found by both methods, i.e. using
reflections and using getCommands() had same set of apis and all were unique.

Conclusion:
The changes are idempotent and don't break api server's cmd class api discovery
processing.

BUG-ID: CLOUDSTACK-1210

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
2013-02-08 16:52:04 +05:30