48 Commits

Author SHA1 Message Date
John Bampton
fa39e61a4c
Fix spelling (#6609) 2022-11-01 08:30:01 +01:00
sureshanaparti
eba186aa40
storage: New Dell EMC PowerFlex Plugin (formerly ScaleIO, VxFlexOS) (#4304)
Added support for PowerFlex/ScaleIO (v3.5 onwards) storage pool as a primary storage in CloudStack (for KVM hypervisor) and enabled VM/Volume operations on that pool (using pool tag).
Please find more details in the FS here:
https://cwiki.apache.org/confluence/x/cDl4CQ

Documentation PR: apache/cloudstack-documentation#169

This enables support for PowerFlex/ScaleIO (v3.5 onwards) storage pool as a primary storage in CloudStack

Other improvements addressed in addition to PowerFlex/ScaleIO support:

- Added support for config drives in host cache for KVM
	=> Changed configuration "vm.configdrive.primarypool.enabled" scope from Global to Zone level
	=> Introduced new zone level configuration "vm.configdrive.force.host.cache.use" (default: false) to force host cache for config drives
	=> Introduced new zone level configuration "vm.configdrive.use.host.cache.on.unsupported.pool" (default: true) to use host cache for config drives when storage pool doesn't support config drive
	=> Added new parameter "host.cache.location" (default: /var/cache/cloud) in KVM agent.properties for specifying the host cache path and create config drives on the "/config" directory on the host cache path
	=> Maintain the config drive location and use it when required on any config drive operation (migrate, delete)

- Detect virtual size from the template URL while registering direct download qcow2 (of KVM hypervisor) templates

- Updated full deployment destination for preparing the network(s) on VM start

- Propagate the direct download certificates uploaded to the newly added KVM hosts

- Discover the template size for direct download templates using any available host from the zones specified on template registration
	=> When zones are not specified while registering template, template size discovery is performed using any available host, which is picked up randomly from one of the available zones

- Release the VM resources when VM is sync-ed to Stopped state on PowerReportMissing (after graceful period)

- Retry VM deployment/start when the host cannot grant access to volume/template

- Mark never-used or downloaded templates as Destroyed on deletion, without sending any DeleteCommand
	=> Do not trigger any DeleteCommand for never-used or downloaded templates as these doesn't exist and cannot be deleted from the datastore

- Check the router filesystem is writable or not, before performing health checks
	=> Introduce a new test "filesystem.writable.test" to check the filesystem is writable or not
	=> The router health checks keeps the config info at "/var/cache/cloud" and updates the monitor results at "/root" for health checks, both are different partitions. So, test at both the locations.
	=> Added new script: "filesystem_writable_check.py" at /opt/cloud/bin/ to check the filesystem is writable or not

- Fixed NPE issue, template is null for DATA disks. Copy template to target storage for ROOT disk (with template id), skip DATA disk(s)

* Addressed some issues for few operations on PowerFlex storage pool.

- Updated migration volume operation to sync the status and wait for migration to complete.

- Updated VM Snapshot naming, for uniqueness in ScaleIO volume name when more than one volume exists in the VM.

- Added sync lock while spooling managed storage template before volume creation from the template (non-direct download).

- Updated resize volume error message string.

- Blocked the below operations on PowerFlex storage pool:
  -> Extract Volume
  -> Create Snapshot for VMSnapshot

* Added the PowerFlex/ScaleIO client connection pool to manage the ScaleIO gateway clients, which uses a single gateway client per Powerflex/ScaleIO storage pool and renews it when the session token expires.

- The token is valid for 8 hours from the time it was created, unless there has been no activity for 10 minutes.
  Reference: https://cpsdocs.dellemc.com/bundle/PF_REST_API_RG/page/GUID-92430F19-9F44-42B6-B898-87D5307AE59B.html

Other fixes included:

- Fail the VM deployment when the host specified in the deployVirtualMachine cmd is not in the right state (i.e. either Resource State is not Enabled or Status is not Up)

- Use the physical file size of the template to check the free space availability on the host, while downloading the direct download templates.

- Perform basic tests (for connectivity and file system) on router before updating the health check config data
	=> Validate the basic tests (connectivity and file system check) on router
	=> Cleanup the health check results when router is destroyed

* Updated PowerFlex/ScaleIO storage plugin version to 4.16.0.0

* UI Changes to support storage plugin for PowerFlex/ScaleIO storage pool.
- PowerFlex pool URL generated from the UI inputs(Gateway, Username, Password, Storage Pool) when adding "PowerFlex" Primary Storage
- Updated protocol to "custom" for PowerFlex provider
- Allow VM Snapshot for stopped VM on KVM hypervisor and PowerFlex/ScaleIO storage pool

and Minor improvements in PowerFlex/ScaleIO storage plugin code

* Added support for PowerFlex/ScaleIO volume migration across different PowerFlex storage instances.

- findStoragePoolsForMigration API returns PowerFlex pool(s) of different instance as suitable pool(s), for volume(s) on PowerFlex storage pool.
- Volume(s) with snapshots are not allowed to migrate to different PowerFlex instance.
- Volume(s) of running VM are not allowed to migrate to other PowerFlex storage pools.
- Volume migration from PowerFlex pool to Non-PowerFlex pool, and vice versa are not supported.

* Fixed change service offering smoke tests in test_service_offerings.py, test_vm_snapshots.py

* Added the PowerFlex/ScaleIO volume/snapshot name to the paths of respective CloudStack resources (Templates, Volumes, Snapshots and VM Snapshots)

* Added new response parameter “supportsStorageSnapshot” (true/false) to volume response, and Updated UI to hide the async backup option while taking snapshot for volume(s) with storage snapshot support.

* Fix to remove the duplicate zone wide pools listed while finding storage pools for migration

* Updated PowerFlex/ScaleIO volume migration checks and rollback migration on failure

* Fixed the PowerFlex/ScaleIO volume name inconsistency issue in the volume path after migration, due to rename failure
2021-02-24 14:58:33 +05:30
Rohit Yadav
f5a44b3502 Merge remote-tracking branch 'origin/4.14' into 4.15 2021-02-05 18:28:02 +05:30
Pearl Dsilva
c9c1d4a6e5
marvin: fix test failures when changing service offering of a VM (#4651)
Co-authored-by: Pearl Dsilva <pearl.dsilva@shapeblue.com>
2021-02-05 18:12:12 +05:30
davidjumani
d949302d0f
packaging: Adding Centos8, Ubuntu 20.04, XCPNG8.1 Support (#4068)
* DB : Add support for MySQL 8

- Splits commands to create user and grant access on database, the old
statement is no longer supported by MySQL 8.x
- `NO_AUTO_CREATE_USER` is no longer supported by MySQL 8.x so remove
that from db.properties conn parameters

For mysql-server 8.x setup the following changes were added/tested to
make it work with CloudStack in /etc/mysql/mysql.conf.d/mysqld.cnf and
then restart the mysql-server process:

    server_id = 1
    sql-mode="STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION,ERROR_FOR_DIVISION_BY_ZERO,NO_ZERO_DATE,NO_ZERO_IN_DATE,NO_ENGINE_SUBSTITUTION"
    innodb_rollback_on_timeout=1
    innodb_lock_wait_timeout=600
    max_connections=1000
    log-bin=mysql-bin
    binlog-format = 'ROW'

    default-authentication-plugin=mysql_native_password

Notice the last line above, this is to reset the old password based
authentication used by MySQL 5.x.

Developers can set empty password as follows:

    > sudo mysql -u root
    ALTER USER 'root'@'localhost' IDENTIFIED BY '';

In libvirt repository, there are two related commits

2019-08-23 13:13 Daniel P. Berrangé            ● rpm: don't enable socket activation in upgrade if --listen present
2019-08-22 14:52 Daniel P. Berrangé            ● remote: forbid the --listen arg when systemd socket activation

In libvirt.spec.in

        /bin/systemctl mask libvirtd.socket >/dev/null 2>&1 || :
        /bin/systemctl mask libvirtd-ro.socket >/dev/null 2>&1 || :
        /bin/systemctl mask libvirtd-admin.socket >/dev/null 2>&1 || :
        /bin/systemctl mask libvirtd-tls.socket >/dev/null 2>&1 || :
        /bin/systemctl mask libvirtd-tcp.socket >/dev/null 2>&1 || :

Co-authored-by: Wei Zhou <w.zhou@global.leaseweb.com>
Co-authored-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
Co-authored-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2020-08-17 16:28:30 +05:30
Rohit Yadav
7d144e146a
CLOUDSTACK-10227: Add delay before reverting VM snapshot (#2407)
As discovered and discussed in #2376, adding some delay after stopping
the VM and reverting VM snapshot passes the
`test_change_service_offering_for_vm_with_snapshots` test case. The
suspect here is userVMDao or background vmsync that may not update
the VM state to PowerOff.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2018-01-15 15:57:48 +05:30
Rajani Karuturi
d96b3cd19c Merge release branch 4.9 to master
* 4.9:
  CLOUDSTACK-9876: Removed test test_01_test_vm_volume_snapshot as we no longer have that restriction and now after fix for CLOUDSTACK-8663 we allow VM and volume snapshots to exist together
2017-04-18 15:17:00 +05:30
Anshul Gangwar
e82a6351a1 CLOUDSTACK-9876: Removed test test_01_test_vm_volume_snapshot as we no longer have that restriction and now after fix for CLOUDSTACK-8663 we allow VM and volume snapshots to exist together 2017-04-17 12:44:44 +05:30
nvazquez
3a6d98289c CLOUDSTACK-9539: Support changing Service offering for instance with VM Snapshots 2017-02-16 10:49:09 -03:00
Simon Weller
6f2a5cf04e Fixes for testing VM Snapshots on KVM. Related to PR 977 2017-01-24 21:48:09 +01:00
Wei Zhou
a2428508e2 CLOUDSTACK-8746: vm snapshot implementation for KVM
(1) add support to create/delete/revert vm snapshots on running vms with QCOW2 format
(2) add new API to create volume snapshot from vm snapshot
(3) delete metadata of vm snapshots before stopping/migrating and recover vm snapshots after starting/migrating
(4) enable deleting of VM snapshot on stopped vm or vm snapshot is not listed in qcow2 image.
(5) enable smoke tests for vmsnaphsots on KVM
2017-01-24 21:47:30 +01:00
Boris
b0d527688f CLOUDSTACK-9527: test_01_test_vm_volume_snapshot making test negative again
- test_01_test_vm_volume_snapshot not supported for Xen, tests keep failing

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-10-06 15:38:08 +05:30
Boris
394f2e359f CLOUDSTACK-9527: Skip tests not supported for hypervisor
- test_01_test_vm_volume_snapshot not supported for Xen, tests keep failing
- Skip snapshot tests for centos6/kvm as snapshot is not supported by older
  qemu-img versions

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2016-10-05 15:11:00 +05:30
sanjeev
7147627aa2 Modified test description 2015-09-23 11:52:10 +05:30
sanjeev
fbc2e2e983 CLOUDSTACK-8893: Fixing script as per the latest functionality 2015-09-23 11:52:08 +05:30
sanjeev
18fee95109 Removed medium dictionary from test_data and modified the tests dependent on it
Removed duplicate test data related to vm properties.Modified tests dependent on it

Removed duplicte service offerings from test data and modified tests dependent on it
Bug-Id: CLOUDSTACK-8617
This closes #644
2015-08-06 11:29:13 +05:30
Gaurav Aradhye
bede34d297 CLOUDSTACK-8394: Skip test cases through setUp() instead of setUpClass()
Signed-off-by: Gaurav Aradhye <gaurav.aradhye@clogeny.com>
This closes #203
2015-04-28 12:33:54 +05:30
sanjeev
fd92f9d4d8 Revert "Removed raise for skiptest"
This reverts commit b5a74c34cf352e733040ffd6f2cbe0dd3b105c84.
2015-04-23 10:46:16 +05:30
sanjeev
b5a74c34cf Removed raise for skiptest 2015-04-22 11:49:34 +05:30
Gaurav Aradhye
5cdb25f412 CLOUDSTACK-8311: Adding test case to confirm Volume Snapshot for root disk is
... not allowed when VM snapshot is present for a VM

This closes #107

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-03-12 16:43:48 +05:30
Gaurav Aradhye
fc2c1a09a7 CLOUDSTACK-8098: Fixed VM snapshot issue in smoke/test_vm_snapshots.py
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2014-12-23 14:46:10 +05:30
SrikanteswaraRao Talluri
0d75682a34 Revert "CLOUDSTACK-7762 -[Automation] - Fix test failure for test_02_revert_vm_snapshots in smoke/test_vm_snapshots.py"
This reverts commit f510ef995baaa9addefc22ff0330cd51dee1dd95.
2014-12-23 14:46:10 +05:30
Sangeetha Hariharan
f510ef995b CLOUDSTACK-7762 -[Automation] - Fix test failure for test_02_revert_vm_snapshots in smoke/test_vm_snapshots.py 2014-10-21 18:35:53 -07:00
Alex Brett
20d3cf1acc CLOUDSTACK-7727 Skip various BVT tests on LXC
A number of BVT tests are not valid for LXC (e.g. migrating a VM), so this patch
ensures they skip if LXC is in use.

Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2014-10-16 17:23:04 +05:30
John Dilley
d75961d973 CLOUDSTACK-7192: Skip tests on Hyper-V which don't apply 2014-08-12 16:49:56 +05:30
Girish Shilamkar
06fbaf59cc CLOUDSTACK-6943: Skip VM snapshot tests on KVM 2014-06-20 14:42:06 +05:30
Santhosh Edukulla
7c15f148da CLOUDSTACK-6914: Fixed the mentioned issue
Signed-off-by: Abhinandan Prateek <aprateek@apache.org>
2014-06-17 14:26:44 +05:30
Girish Shilamkar
ef9471692d CLOUDSTACK-5674: Remove assigning accountname which was useless 2014-04-10 17:49:39 +05:30
SrikanteswaraRao Talluri
0e223d6787 Merge branch 'master' into marvin
Conflicts:
	test/integration/component/test_base_image_updation.py
	test/integration/component/test_cpu_domain_limits.py
	test/integration/component/test_cpu_limits.py
	test/integration/component/test_cpu_project_limits.py
	test/integration/component/test_ip_reservation.py
	test/integration/component/test_memory_limits.py
	test/integration/component/test_mm_domain_limits.py
	test/integration/component/test_mm_project_limits.py
	test/integration/component/test_persistent_networks.py
	test/integration/component/test_portable_ip.py
	test/integration/component/test_routers.py
	test/integration/smoke/test_deploy_vm.py
	test/integration/smoke/test_deploy_vm_with_userdata.py
	test/integration/smoke/test_internal_lb.py
	test/integration/smoke/test_vm_life_cycle.py
	test/integration/smoke/test_volumes.py
	tools/marvin/marvin/codes.py
	tools/marvin/marvin/configGenerator.py
	tools/marvin/marvin/lib/base.py
	tools/marvin/marvin/lib/common.py
	tools/marvin/marvin/lib/utils.py
2014-04-08 17:53:37 +05:30
Sanjay Tripathi
4779e575bb CLOUDSTACK-5674: Minor fixes to BVT tests 2014-04-04 14:30:59 +05:30
Santhosh Edukulla
34409d74cd Fixed few issues for CLOUDSTACK-6316,CLOUDSTACK-5674
Fixed issues related to the mentioned bugs.
More information in the bug.

Signed-off-by: Santhosh Edukulla <Santhosh.Edukulla@citrix.com>
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2014-04-01 23:53:14 +05:30
SrikanteswaraRao Talluri
102c1bc9c8 CLOUDSTACK-6125: added smoke tests with following tags 1. selfservice - tests which can be run on simulator. 2. provisioning - tests that need actual hypervisor resource.
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
2014-03-25 15:43:05 +05:30
Girish Shilamkar
47c5b63881 CLOUDSTACK-5674: Fixed all BVTs and some marvin functions 2014-02-19 16:33:42 +05:30
Girish Shilamkar
2d93d83b44 CLOUDSTACK-5674: Added missing import for FAILED 2014-02-14 14:59:35 +05:30
Girish Shilamkar
f3a77c79e8 CLOUDSTACK-5674: cls.fail does not work in setUpClass fixed it with assert. 2014-02-14 14:27:13 +05:30
Santhosh Edukulla
3dbb2ae488 CLOUDSTACk-5674: Added fix for CLOUDSTACK-5674 2014-02-12 17:34:34 +05:30
Girish Shilamkar
c1d34369aa Revert "CLOUDSTACK-5674: Few fixes"
This reverts commit e6b93b0a6824a3f2845fb42596c04b348ae147e2.
2014-02-12 17:27:47 +05:30
Girish Shilamkar
e6b93b0a68 CLOUDSTACK-5674: Few fixes 2014-02-11 14:54:46 +05:30
Girish Shilamkar
995e3f5b5d Revert "CLOUDSTACK-5674: Few new fixes"
This reverts commit 3493f17bad3b8b57778b62d464c5e7f910351cc0.
2014-02-11 12:36:07 +05:30
Girish Shilamkar
3493f17bad CLOUDSTACK-5674: Few new fixes 2014-02-09 16:04:31 -05:00
Santhosh Edukulla
bf72441d13 CLOUDSTACK-6006: Remove integration folder and lib 2014-02-04 12:01:58 +05:30
Girish Shilamkar
6c5b1670b2 CLOUDSTACK-5925: Removed incorrect import 2014-01-27 19:14:45 -05:00
Girish Shilamkar
7305063fb4 CLOUDSTACK-5925: get_*() functionality changed in marvin, changed BVT too. 2014-01-28 11:12:24 +05:30
Girish Shilamkar
6a2cc9fbd0 CLOUDSTACK-5925: Moved test data from testsuites to marvin/config
Also merged redundant testdata as they were found.
2014-01-22 12:21:07 +05:30
Prasanna Santhanam
4585e46a35 CLOUDSTACK-3719: wrong declaration of random_gen call
since random_gen can take an id to prepend a testcase identifier to the
created cloud resource, we need to explicitly specify the size param. In
vmsnapshot test create the random_data string of size (100)

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
(cherry picked from commit 5bb3a56acac440b022ed6c45f97d0d85dcc94b96)
2013-07-23 11:39:08 +05:30
Prasanna Santhanam
c7315975d2 Fix tab/space issues
Several test failures occurred due to tab issues

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-06-30 13:20:27 +05:30
Prasanna Santhanam
698da2a279 Minor tagging and comments in tests
Adding tags to the deployvm test from the marvin tutorial
Adding docstrings to the vm snapshot tests
Add tag to the pvlan test

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-05-22 15:43:03 +05:30
Nitin Mehta
c11dbad9c9 merge master 2013-05-11 15:28:43 +05:30