diff --git a/.ansible-lint b/.ansible-lint index 7e6921a..f615bf2 100644 --- a/.ansible-lint +++ b/.ansible-lint @@ -1,7 +1,2 @@ exclude_paths: - - changelogs/ - .github/ - - meta/ - - roles/capacity_role/defaults/ - - roles/capacity_role/vars/ - - roles/capacity_role/tasks/ diff --git a/.github/workflows/ansible-test.yml b/.github/workflows/ansible-test.yml index 16464ee..efa4fff 100644 --- a/.github/workflows/ansible-test.yml +++ b/.github/workflows/ansible-test.yml @@ -2,9 +2,9 @@ name: CI on: push: - branches: [main] + branches: [ main ] pull_request: - branches: [main] + branches: [ main ] schedule: - cron: '0 3 * * *' @@ -15,15 +15,15 @@ jobs: strategy: fail-fast: false matrix: - ansible-version: [stable-2.13] + ansible-version: [stable-2.14] steps: - name: Check out code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - - name: Set up Python 3.9 - uses: actions/setup-python@v1 + - name: Set up Python 3.11 + uses: actions/setup-python@v4 with: - python-version: 3.9 + python-version: 3.11 - name: Install ansible (${{ matrix.ansible-version }}) run: pip install https://github.com/ansible/ansible/archive/${{ matrix.ansible-version }}.tar.gz --disable-pip-version-check @@ -50,15 +50,16 @@ jobs: fail-fast: false matrix: python-version: ["3.9", "3.10", "3.11"] - ansible-version: [stable-2.13, stable-2.14, stable-2.15] + ansible-version: [stable-2.14, stable-2.15, stable-2.16] exclude: - # Python 3.11 is supported only from ansible-core 2.14 onwards - - python-version: "3.11" - ansible-version: stable-2.13 + # Ansible-core 2.16 is supported only from Python 3.10 onwards + - python-version: "3.9" + ansible-version: stable-2.16 + steps: - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v1 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} @@ -92,15 +93,20 @@ jobs: strategy: fail-fast: false matrix: - ansible-version: [stable-2.13, stable-2.14, stable-2.15] + python-version: ["3.9", "3.10", "3.11"] + ansible-version: [stable-2.14, stable-2.15, stable-2.16] + exclude: + # Ansible-core 2.16 is supported only from Python 3.10 onwards + - python-version: "3.9" + ansible-version: stable-2.16 steps: - - name: Set up Python 3.9 - uses: actions/setup-python@v1 + - name: Set up Python 3.11 + uses: actions/setup-python@v4 with: # it is just required to run that once as "ansible-test sanity" in the docker image # will run on all python versions it supports. - python-version: 3.9 + python-version: 3.11 - name: Install ansible (${{ matrix.ansible-version }}) version run: pip install https://github.com/ansible/ansible/archive/${{ matrix.ansible-version }}.tar.gz --disable-pip-version-check @@ -129,7 +135,11 @@ jobs: fail-fast: false matrix: python-version: ["3.9", "3.10", "3.11"] - ansible-version: [stable-2.13, stable-2.14, stable-2.15] + ansible-version: [stable-2.14, stable-2.15, stable-2.16] + exclude: + # Ansible-core 2.16 is supported only from Python 3.10 onwards + - python-version: "3.9" + ansible-version: stable-2.16 steps: # Important: This sets up your GITHUB_WORKSPACE environment variable @@ -139,7 +149,7 @@ jobs: fetch-depth: 0 # needed for progressive mode to work - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v1 + uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} diff --git a/CHANGELOG.rst b/CHANGELOG.rst index e454b21..43a0491 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,20 @@ Dellemc.Powermax Change Logs .. contents:: Topics +v3.0.0 +====== + +Major Changes +------------- + +- Added support for PowerMax Laurel. + +Minor Changes +------------- + +- Added bug fix for SRDF module. +- Added support for connection timeout for all modules. + v2.2.1 ====== diff --git a/README.md b/README.md index 523179d..eb3841a 100644 --- a/README.md +++ b/README.md @@ -6,15 +6,15 @@ The capabilities of Ansible modules are managing volumes, storage groups, ports, ## Table of contents -* [Code of conduct](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CODE_OF_CONDUCT.md) -* [Maintainer guide](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/MAINTAINER_GUIDE.md) -* [Committer guide](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/COMMITTER_GUIDE.md) -* [Contributing guide](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CONTRIBUTING.md) -* [Branching strategy](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/BRANCHING.md) -* [List of adopters](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/ADOPTERS.md) -* [Maintainers](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/MAINTAINERS.md) -* [Support](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/SUPPORT.md) -* [Security](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/SECURITY.md) +* [Code of conduct](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CODE_OF_CONDUCT.md) +* [Maintainer guide](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/MAINTAINER_GUIDE.md) +* [Committer guide](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/COMMITTER_GUIDE.md) +* [Contributing guide](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CONTRIBUTING.md) +* [Branching strategy](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/BRANCHING.md) +* [List of adopters](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/ADOPTERS.md) +* [Maintainers](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/MAINTAINERS.md) +* [Support](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/SUPPORT.md) +* [Security](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/SECURITY.md) * [License](#license) * [Supported platforms](#supported-platforms) * [Prerequisites](#prerequisites) @@ -23,17 +23,17 @@ The capabilities of Ansible modules are managing volumes, storage groups, ports, * [Maintanence](#maintanence) ## License -Ansible collection for PowerMax is released and licensed under the GPL-3.0 license. See [LICENSE](https://github.com/dell/ansible-powermax/blob/2.2.1/LICENSE) for the full terms. Ansible modules and modules utilities that are part of the Ansible collection for PowerMax are released and licensed under the Apache 2.0 license. See [MODULE-LICENSE](https://github.com/dell/ansible-powermax/blob/2.2.1/MODULE-LICENSE) for the full terms. +Ansible collection for PowerMax is released and licensed under the GPL-3.0 license. See [LICENSE](https://github.com/dell/ansible-powermax/blob/3.0.0/LICENSE) for the full terms. Ansible modules and modules utilities that are part of the Ansible collection for PowerMax are released and licensed under the Apache 2.0 license. See [MODULE-LICENSE](https://github.com/dell/ansible-powermax/blob/3.0.0/MODULE-LICENSE) for the full terms. ## Supported platforms -Dell PowerMax and VMAX All Flash arrays support Unisphere version 9.1 and later. +Dell PowerMax and VMAX All Flash arrays support Unisphere version 9.2 and later. ## Prerequisites This table provides information about the software prerequisites for the Ansible Modules for Dell PowerMax. | **Ansible modules** | **Unisphere version** | **PowerMaxOS** | **Python version** | **Python library version** | **Ansible** | |---------------------|-----------------------|----------------|-------------------------------|----------------------------|--------------------------| -| v2.2.1 | 9.1
9.2
10.0 | 5978.444.444
5978.669.669
5978.711.711
6079.xxx.xxx | 3.9.x
3.10.x
3.11.x | 9.1.x.x
9.2.x.x
10.0.x.x | 2.13
2.1 4
2.15 | +| v3.0.0 | 9.2
10.0
10.1 | 5978.444.444
5978.669.669
5978.711.711
6079.xxx.xxx | 3.9.x
3.10.x
3.11.x | 9.2.x.x
10.0.x.x
10.1.x.x | 2.14
2.15
2.16 | * Follow PyU4V installation instructions on [PyU4V Documentation](https://pyu4v.readthedocs.io/) @@ -41,27 +41,27 @@ This table provides information about the software prerequisites for the Ansible The modules are written in such a way that all requests are idempotent and hence fault-tolerant. This means that the result of a successfully performed request is independent of the number of times it is performed. ## List of Ansible modules for Dell PowerMax - * [Volume module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/volume.rst) - * [Host module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/host.rst) - * [Host Group module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/hostgroup.rst) - * [Snapshot module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/snapshot.rst) - * [Masking View module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/maskingview.rst) - * [Port module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/port.rst) - * [Port Group module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/portgroup.rst) - * [Storage Group module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/storagegroup.rst) - * [Info module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/info.rst) - * [SRDF module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/srdf.rst) - * [RDF Group module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/rdfgroup.rst) - * [Metro DR module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/metrodr.rst) - * [Job module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/job.rst) - * [Snapshot Policy module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/snapshotpolicy.rst) - * [Storage Pool module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/storagepool.rst) - * [Process Storage Pool module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/process_storage_pool_dict.rst) - * [Initiator module](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/initiator.rst) - * [Intelligent Volume Placement](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/modules/capacity_role.rst) + * [Volume module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/volume.rst) + * [Host module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/host.rst) + * [Host Group module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/hostgroup.rst) + * [Snapshot module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/snapshot.rst) + * [Masking View module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/maskingview.rst) + * [Port module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/port.rst) + * [Port Group module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/portgroup.rst) + * [Storage Group module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/storagegroup.rst) + * [Info module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/info.rst) + * [SRDF module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/srdf.rst) + * [RDF Group module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/rdfgroup.rst) + * [Metro DR module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/metrodr.rst) + * [Job module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/job.rst) + * [Snapshot Policy module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/snapshotpolicy.rst) + * [Storage Pool module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/storagepool.rst) + * [Process Storage Pool module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/process_storage_pool_dict.rst) + * [Initiator module](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/initiator.rst) + * [Intelligent Volume Placement](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/modules/capacity_role.rst) ## Installation and execution of Ansible modules for Dell PowerMax -The installation and execution steps of Ansible modules for Dell PowerMax can be found [here](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/INSTALLATION.md). +The installation and execution steps of Ansible modules for Dell PowerMax can be found [here](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/INSTALLATION.md). ## Maintenance Ansible modules for Dell Technologies PowerMax deprecation cycle is aligned with [Ansible](https://docs.ansible.com/ansible/latest/dev_guide/module_lifecycle.html). diff --git a/changelogs/.plugin-cache.yaml b/changelogs/.plugin-cache.yaml index cfa6125..fc69af2 100644 --- a/changelogs/.plugin-cache.yaml +++ b/changelogs/.plugin-cache.yaml @@ -102,4 +102,4 @@ plugins: shell: {} strategy: {} vars: {} -version: 2.1.1 +version: 3.0.0 diff --git a/changelogs/changelog.yaml b/changelogs/changelog.yaml index ea281d3..0bae680 100644 --- a/changelogs/changelog.yaml +++ b/changelogs/changelog.yaml @@ -171,3 +171,11 @@ releases: - Added support for masking_view_name for listing masking view connections through info module. release_date: '2023-10-31' + 3.0.0: + changes: + major_changes: + - Added support for PowerMax Laurel. + minor_changes: + - Added bug fix for SRDF module. + - Added support for connection timeout for all modules. + release_date: '2023-11-30' diff --git a/docs/CONTRIBUTING.md b/docs/CONTRIBUTING.md index 1c89bb9..ec24cd0 100644 --- a/docs/CONTRIBUTING.md +++ b/docs/CONTRIBUTING.md @@ -10,7 +10,7 @@ You may obtain a copy of the License at # How to contribute -Become one of the contributors to this project! We thrive to build a welcoming and open community for anyone who wants to use the project or contribute to it. There are just a few small guidelines you need to follow. To help us create a safe and positive community experience for all, we require all participants to adhere to the [Code of Conduct](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CODE_OF_CONDUCT.md). +Become one of the contributors to this project! We thrive to build a welcoming and open community for anyone who wants to use the project or contribute to it. There are just a few small guidelines you need to follow. To help us create a safe and positive community experience for all, we require all participants to adhere to the [Code of Conduct](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CODE_OF_CONDUCT.md). ## Table of contents @@ -76,7 +76,7 @@ Triage helps resolve issues quickly by: If you do not have the knowledge or time to code, consider helping with _issue triage_. The Ansible modules for Dell PowerMax community thanks you for saving them time by spending some of yours. -Read more about the ways you can [Triage issues](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/ISSUE_TRIAGE.md). +Read more about the ways you can [Triage issues](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/ISSUE_TRIAGE.md). ## Your first contribution @@ -90,7 +90,7 @@ When you are ready to contribute, it is time to create a pull request. For information about branching, see ## Branching -* [Branching Strategy for Ansible modules for Dell PowerMax](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/BRANCHING.md) +* [Branching Strategy for Ansible modules for Dell PowerMax](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/BRANCHING.md) ## Signing your commits @@ -145,7 +145,7 @@ Ensure that the title for your pull request uses the same format as the subject ### Quality gates for pull requests -GitHub Actions are used to enforce quality gates when a pull request is created or when any commit is made to the pull request. These GitHub Actions enforce our minimum code quality requirement for any code that get checked into the repository. If any of the quality gates fail, it is expected that the contributor will investigate the check log, understand the problem, and resolve the issue. If help is needed, reach out to the maintainers of the project for [support](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/SUPPORT.md). +GitHub Actions are used to enforce quality gates when a pull request is created or when any commit is made to the pull request. These GitHub Actions enforce our minimum code quality requirement for any code that get checked into the repository. If any of the quality gates fail, it is expected that the contributor will investigate the check log, understand the problem, and resolve the issue. If help is needed, reach out to the maintainers of the project for [support](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/SUPPORT.md). #### Code sanitization diff --git a/docs/INSTALLATION.md b/docs/INSTALLATION.md index 316f824..45c26a7 100644 --- a/docs/INSTALLATION.md +++ b/docs/INSTALLATION.md @@ -40,7 +40,7 @@ Depending on which PowerMax Unisphere version is being used, follow this procedu 2. Use this command to install the collection anywhere in your system: - ansible-galaxy collection install dellemc-powermax-2.2.1.tar.gz -p + ansible-galaxy collection install dellemc-powermax-3.0.0.tar.gz -p 3. Set the environment variable: @@ -67,7 +67,7 @@ Depending on which PowerMax Unisphere version is being used, follow this procedu ## Running Ansible modules -The Ansible server must be configured with Python library for Unisphere to run the Ansible playbooks. The [Documents](https://github.com/dell/ansible-powermax/blob/2.2.1/docs) provide information on different Ansible modules along with their functions and syntax. The parameters table in the Product Guide provides information on various parameters which need to be configured before running the modules. +The Ansible server must be configured with Python library for Unisphere to run the Ansible playbooks. The [Documents](https://github.com/dell/ansible-powermax/blob/3.0.0/docs) provide information on different Ansible modules along with their functions and syntax. The parameters table in the Product Guide provides information on various parameters which need to be configured before running the modules. ## SSL certificate validation diff --git a/docs/ISSUE_TRIAGE.md b/docs/ISSUE_TRIAGE.md index c77d0b8..4866f94 100644 --- a/docs/ISSUE_TRIAGE.md +++ b/docs/ISSUE_TRIAGE.md @@ -41,9 +41,9 @@ This section describes the various issue templates and the expected content. Bug reports should explain what happened, what was expected and how to reproduce it. Additionally, any applicable material about the reported problem that may give a complete picture of what happened such as screenshots, outputs, and environment related information: - - Ansible Version: [e.g. 2.13] + - Ansible Version: [e.g. 2.14] - Python Version [e.g. 3.10] - - Ansible modules for Dell PowerMax Version: [e.g. 2.2.1] + - Ansible modules for Dell PowerMax Version: [e.g. 3.0.0] - PowerMax SDK version: [e.g. PyU4V 10.0.0.16] - Any other additional information... diff --git a/docs/MAINTAINER_GUIDE.md b/docs/MAINTAINER_GUIDE.md index b25fc73..292ec2e 100644 --- a/docs/MAINTAINER_GUIDE.md +++ b/docs/MAINTAINER_GUIDE.md @@ -27,7 +27,7 @@ If a candidate is approved, a Maintainer contacts the candidate to invite them t ## Maintainer policies * Lead by example -* Follow the [Code of Conduct](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CODE_OF_CONDUCT.md) and the guidelines in the [Contributing](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CONTRIBUTING.md) and [Committer](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/COMMITTER_GUIDE.md) guides +* Follow the [Code of Conduct](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CODE_OF_CONDUCT.md) and the guidelines in the [Contributing](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CONTRIBUTING.md) and [Committer](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/COMMITTER_GUIDE.md) guides * Promote a friendly and collaborative environment within our community * Be actively engaged in discussions, answering questions, updating defects, and reviewing pull requests * Criticize code, not people. Ideally, tell the contributor a better way to do what they need achieve. diff --git a/docs/Release Notes.md b/docs/Release Notes.md index 36afe4d..57bba91 100644 --- a/docs/Release Notes.md +++ b/docs/Release Notes.md @@ -1,7 +1,7 @@ **Ansible modules for Dell Technologies PowerMax** ========================================= -### Release Notes 2.2.1 +### Release Notes 3.0.0 > © 2022 Dell Inc. or its subsidiaries. All rights reserved. Dell > and other trademarks are trademarks of Dell Inc. or its @@ -26,7 +26,7 @@ Revision History | **Date** | **Document revision** | **Description of changes** | |------------ |-----------------------|-------------------------------------------------| -| October 2023 | 01 | Ansible modules for Dell PowerMax release 2.2.1 | +| November 2023 | 01 | Ansible modules for Dell PowerMax release 3.0.0 | Product Description ------------------- @@ -56,9 +56,9 @@ New Features and Enhancements The Ansible modules for Dell PowerMax release has the following changes: -- Added fix for storagegroup_id keyword in storage group module. -- Added support for masking_view_name for listing masking view - connections through info module. +- Added support for PowerMax Laurel. +- Added bug fix for SRDF module. +- Added support for connection timeout for all modules. > **NOTE:** Unisphere Version 9.1 is compatible with PowerMax Python > library version 9.1.x.x and similarly Unisphere versions later than 9.1 will @@ -75,7 +75,7 @@ There are no known limitations. Distribution ------------ The software package is available for download from the [Ansible modules -for PowerMax GitHub](https://github.com/dell/ansible-powermax/tree/2.2.1) page. +for PowerMax GitHub](https://github.com/dell/ansible-powermax/tree/3.0.0) page. Documentation ------------- diff --git a/docs/SECURITY.md b/docs/SECURITY.md index 0fc1d91..c59d830 100644 --- a/docs/SECURITY.md +++ b/docs/SECURITY.md @@ -12,7 +12,7 @@ You may obtain a copy of the License at The Ansible modules for Dell PowerMax repository is inspected for security vulnerabilities through blackduck scans and static code analysis. -In addition to this, there are various security checks that are performed against a branch when a pull request is created or updated. See [pull request](https://github.com/dell/ansible-powermax/blob/2.2.1/docs/CONTRIBUTING.md#Pull-requests) for more information. +In addition to this, there are various security checks that are performed against a branch when a pull request is created or updated. See [pull request](https://github.com/dell/ansible-powermax/blob/3.0.0/docs/CONTRIBUTING.md#Pull-requests) for more information. ## Reporting a vulnerability diff --git a/docs/modules/capacity_role.rst b/docs/modules/capacity_role.rst index ec0e556..acb4fd4 100644 --- a/docs/modules/capacity_role.rst +++ b/docs/modules/capacity_role.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -29,11 +29,11 @@ The below requirements are needed on the host that executes this module. Parameters ---------- - size (True, float, None) + capacity_role_size (True, float, None) The size of the storage group. - cap_unit (True, str, GB) + capacity_role_cap_unit (True, str, GB) The capacity unit. @@ -50,7 +50,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -89,27 +89,27 @@ Examples - name: Create storage group on the assigned serial number and SRP register: storage_group_details - dellemc_powermax_storagegroup: + dellemc.powermax.storagegroup: unispherehost: "{{unispherehost}}" universion: "{{universion}}" verifycert: "{{verifycert}}" user: "{{user}}" password: "{{password}}" - serial_no: "{{assigned_pool.serial_no}}" + serial_no: "{{capacity_role_assigned_pool.serial_no}}" sg_name: "test_sg" service_level: "Diamond" - srp: "{{assigned_pool.storage_pool}}" + srp: "{{capacity_role_assigned_pool.storage_pool}}" compression: True state: "present" - name: Create volume on the storage group - dellemc_powermax_volume: + dellemc.powermax.volume: unispherehost: "{{unispherehost}}" universion: "{{universion}}" verifycert: "{{verifycert}}" user: "{{user}}" password: "{{password}}" - serial_no: "{{assigned_pool.serial_no}}" + serial_no: "{{capacity_role_assigned_pool.serial_no}}" vol_name: "test_vol" sg_name: "test_sg" size: 10 @@ -156,4 +156,4 @@ Authors ~~~~~~~ - Akash Shendge (@shenda1) - +- Pavan Mudunuri (@Pavan-Mudunuri) diff --git a/docs/modules/host.rst b/docs/modules/host.rst index 0b75210..3d769f8 100644 --- a/docs/modules/host.rst +++ b/docs/modules/host.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -96,7 +96,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -111,6 +111,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/hostgroup.rst b/docs/modules/hostgroup.rst index 4a795ab..6addda4 100644 --- a/docs/modules/hostgroup.rst +++ b/docs/modules/hostgroup.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -94,7 +94,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -109,6 +109,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/info.rst b/docs/modules/info.rst index 510c595..dcf66b6 100644 --- a/docs/modules/info.rst +++ b/docs/modules/info.rst @@ -21,14 +21,15 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible 2.13, 2.14 or 2.15. +- Ansible-core 2.14 or later. +- Python 3.9, 3.10 or 3.11. Parameters ---------- - serial_no (False, str, None) + serial_no (False, str, ) The serial number of the PowerMax or VMAX array. It is not required for getting the list of arrays. @@ -99,7 +100,9 @@ Parameters filter_value (True, str, None) Value of the filter key. - masking_view_name(False, str, None) + + + masking_view_name (optional, str, None) The name of the masking view to fetch the masking view connections. @@ -108,7 +111,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -123,6 +126,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + @@ -227,7 +236,7 @@ Examples user: "{{user}}" password: "{{password}}" serial_no: "{{serial_no}}" - tdev_volumes: True + tdev_volumes: true gather_subset: - vol @@ -248,7 +257,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - health + - health - name: Get array alerts summary dellemc.powermax.info: @@ -259,7 +268,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - alert + - alert - name: Get the list of Metro DR environments for a given Unisphere host dellemc.powermax.info: @@ -270,7 +279,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - metro_dr_env + - metro_dr_env - name: Get list of storage groups dellemc.powermax.info: @@ -281,7 +290,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - sg + - sg - name: Get list of Storage Resource Pools dellemc.powermax.info: @@ -292,7 +301,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - srp + - srp - name: Get list of ports dellemc.powermax.info: @@ -303,7 +312,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - port + - port - name: Get list of Port Groups dellemc.powermax.info: @@ -314,7 +323,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - pg + - pg - name: Get list of hosts dellemc.powermax.info: @@ -325,7 +334,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - host + - host - name: Get list of Host Groups dellemc.powermax.info: @@ -336,7 +345,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - hg + - hg - name: Get list of Masking Views dellemc.powermax.info: @@ -347,7 +356,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - mv + - mv - name: Get list of RDF Groups dellemc.powermax.info: @@ -358,7 +367,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - rdf + - rdf - name: Get list of snapshot policies dellemc.powermax.info: @@ -369,7 +378,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - snapshot_policies + - snapshot_policies - name: Get list of initiators dellemc.powermax.info: @@ -380,7 +389,7 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - initiators + - initiators - name: Get list of masking view connections with filter dellemc.powermax.info: @@ -391,14 +400,14 @@ Examples password: "{{password}}" serial_no: "{{serial_no}}" gather_subset: - - mv_connections + - mv_connections filters: - - filter_key: "logged_in" - filter_operator: "equal" - filter_value: "True" - - filter_key: "cap_gb" - filter_operator: "equal" - filter_value: "10" + - filter_key: "logged_in" + filter_operator: "equal" + filter_value: "True" + - filter_key: "cap_gb" + filter_operator: "equal" + filter_value: "10" @@ -687,4 +696,5 @@ Authors - Arindam Datta (@dattaarindam) - Rajshree Khare (@khareRajshree) - Pavan Mudunuri (@Pavan-Mudunuri) +- Trisha Datta (@trisha-dell) diff --git a/docs/modules/initiator.rst b/docs/modules/initiator.rst index 9009576..5d3243e 100644 --- a/docs/modules/initiator.rst +++ b/docs/modules/initiator.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -63,7 +63,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -78,6 +78,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/job.rst b/docs/modules/job.rst index 8e0ed14..0d766de 100644 --- a/docs/modules/job.rst +++ b/docs/modules/job.rst @@ -23,7 +23,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -40,7 +40,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -55,6 +55,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + diff --git a/docs/modules/maskingview.rst b/docs/modules/maskingview.rst index 6fdf2a7..1c87de8 100644 --- a/docs/modules/maskingview.rst +++ b/docs/modules/maskingview.rst @@ -33,7 +33,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -74,7 +74,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -89,6 +89,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/metrodr.rst b/docs/modules/metrodr.rst index 12d5628..07c0e2f 100644 --- a/docs/modules/metrodr.rst +++ b/docs/modules/metrodr.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -127,7 +127,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -142,6 +142,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + @@ -184,7 +190,7 @@ Examples metro_r2_array_id: "{{metro_r2_array_id}}" dr_array_id: "{{dr_array_id}}" replication_mode: "Asynchronous" - wait_for_completion: False + wait_for_completion: false state: "present" - name: Create metro DR environment @@ -200,8 +206,8 @@ Examples metro_r2_array_id: "{{metro_r2_array_id}}" dr_array_id: "{{dr_array_id}}" replication_mode: "Asynchronous" - new_rdf_group_r1: True - new_rdf_group_r2: True + new_rdf_group_r1: true + new_rdf_group_r2: true wait_for_completion: False state: "present" @@ -216,10 +222,10 @@ Examples env_name: "ansible_metrodr_env" srdf_param: srdf_state: "Suspend" - metro: True - dr: True - keep_r2: True - wait_for_completion: True + metro: true + dr: true + keep_r2: true + wait_for_completion: true state: "present" - name: Delete metro DR environment @@ -231,7 +237,7 @@ Examples password: "{{password}}" metro_r1_array_id: "{{metro_r1_array_id}}" env_name: "ansible_metrodr_env" - remove_r1_dr_rdfg: True + remove_r1_dr_rdfg: true state: 'absent' diff --git a/docs/modules/port.rst b/docs/modules/port.rst index 092ec70..85f133c 100644 --- a/docs/modules/port.rst +++ b/docs/modules/port.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -38,7 +38,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -53,6 +53,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. @@ -83,10 +89,10 @@ Examples password: "{{password}}" serial_no: "{{array_id}}" ports: - - director_id: "FA-1D" - port_id: "5" - - director_id: "SE-1F" - port_id: "29" + - director_id: "FA-1D" + port_id: "5" + - director_id: "SE-1F" + port_id: "29" diff --git a/docs/modules/portgroup.rst b/docs/modules/portgroup.rst index ed966e6..3724cb2 100644 --- a/docs/modules/portgroup.rst +++ b/docs/modules/portgroup.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -68,7 +68,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -83,6 +83,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. @@ -139,10 +145,10 @@ Examples portgroup_name: "{{portgroup_name}}" state: "present" ports: - - director_id: "FA-1D" - port_id: "5" - - director_id: "FA-2D" - port_id: "5" + - director_id: "FA-1D" + port_id: "5" + - director_id: "FA-2D" + port_id: "5" port_state: "present-in-group" - name: Add ports to port group @@ -156,10 +162,10 @@ Examples portgroup_name: "{{portgroup_name}}" state: "present" ports: - - director_id: "FA-2D" - port_id: "8" - - director_id: "FA-2D" - port_id: "9" + - director_id: "FA-2D" + port_id: "8" + - director_id: "FA-2D" + port_id: "9" port_state: "present-in-group" - name: Remove ports from port group @@ -173,10 +179,10 @@ Examples portgroup_name: "{{portgroup_name}}" state: "present" ports: - - director_id: "FA-2D" - port_id: "8" - - director_id: "FA-2D" - port_id: "9" + - director_id: "FA-2D" + port_id: "8" + - director_id: "FA-2D" + port_id: "9" port_state: "absent-in-group" - name: Modify port group diff --git a/docs/modules/process_storage_pool_dict.rst b/docs/modules/process_storage_pool_dict.rst index 97e9cd4..7e22fbe 100644 --- a/docs/modules/process_storage_pool_dict.rst +++ b/docs/modules/process_storage_pool_dict.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -50,7 +50,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -65,6 +65,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + diff --git a/docs/modules/rdfgroup.rst b/docs/modules/rdfgroup.rst index 5a6e417..281efcf 100644 --- a/docs/modules/rdfgroup.rst +++ b/docs/modules/rdfgroup.rst @@ -25,7 +25,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -46,7 +46,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -61,6 +61,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. @@ -97,7 +103,7 @@ Examples - name: Get specific volume details of an RDF Group dellemc.powermax.rdfgroup: unispherehost: "{{unispherehost}}" - serial_no: "{{serial_no}}" + serial_no: "{{serial_no}}" universion: "{{universion}}" verifycert: "{{verifycert}}" user: "{{user}}" diff --git a/docs/modules/snapshot.rst b/docs/modules/snapshot.rst index 6710ba1..5fd39d1 100644 --- a/docs/modules/snapshot.rst +++ b/docs/modules/snapshot.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -94,7 +94,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -109,6 +109,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/snapshotpolicy.rst b/docs/modules/snapshotpolicy.rst index b4a96af..4d914e4 100644 --- a/docs/modules/snapshotpolicy.rst +++ b/docs/modules/snapshotpolicy.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -30,7 +30,7 @@ Parameters ---------- universion (False, int, None) - Unisphere version, currently '92', '100' version is supported. + Unisphere version, currently '92', '100' and '101' version is supported. snapshot_policy_name (True, str, None) @@ -115,6 +115,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/srdf.rst b/docs/modules/srdf.rst index e2cfe0f..bc378c5 100644 --- a/docs/modules/srdf.rst +++ b/docs/modules/srdf.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -100,7 +100,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -115,6 +115,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + @@ -161,7 +167,7 @@ Examples remote_serial_no: "{{remote_serial_no}}" state: 'present' srdf_mode: 'Synchronous' - wait_for_completion: True + wait_for_completion: true - name: Create storagegroup Metro SRDF pair with Witness for resiliency dellemc.powermax.srdf: @@ -175,7 +181,7 @@ Examples remote_serial_no: "{{remote_serial_no}}" state: 'present' srdf_mode: 'Active' - wait_for_completion: True + wait_for_completion: true srdf_state: 'Establish' - name: Suspend storagegroup Metro SRDF pair @@ -203,9 +209,9 @@ Examples sg_name: "{{sg_name}}" remote_serial_no: "{{remote_serial_no}}" state: 'present' - wait_for_completion: False + wait_for_completion: false srdf_state: 'Establish' - witness: False + witness: false - name: Get SRDF details dellemc.powermax.srdf: diff --git a/docs/modules/storagegroup.rst b/docs/modules/storagegroup.rst index 6a8763d..c8dd427 100644 --- a/docs/modules/storagegroup.rst +++ b/docs/modules/storagegroup.rst @@ -41,7 +41,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -145,7 +145,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -160,6 +160,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. @@ -207,7 +213,7 @@ Examples sg_name: "foo" service_level: "Diamond" srp: "SRP_1" - compression: True + compression: true state: "present" - name: Delete the storage group @@ -232,9 +238,9 @@ Examples sg_name: "foo" state: "present" volumes: - - vol_id: "00028" - - vol_id: "00018" - - vol_id: "00025" + - vol_id: "00028" + - vol_id: "00018" + - vol_id: "00025" vol_state: "present-in-group" - name: Create new volumes for existing SG @@ -248,12 +254,12 @@ Examples sg_name: "foo" state: "present" volumes: - - vol_name: "foo" - size: 1 - cap_unit: "GB" - - vol_name: "bar" - size: 1 - cap_unit: "GB" + - vol_name: "foo" + size: 1 + cap_unit: "GB" + - vol_name: "bar" + size: 1 + cap_unit: "GB" vol_state: "present-in-group" - name: Remove volumes from existing SG @@ -267,9 +273,9 @@ Examples sg_name: "foo" state: "present" volumes: - - vol_id: "00028" - - vol_id: "00018" - - vol_name: "ansible-vol" + - vol_id: "00028" + - vol_id: "00018" + - vol_name: "ansible-vol" vol_state: "absent-in-group" - name: Move volumes to target SG @@ -282,12 +288,12 @@ Examples serial_no: "{{serial_no}}" sg_name: "foo" target_sg_name: "foo_sg" - force: True + force: true state: "present" volumes: - - vol_id: "00028" - - vol_id: "00018" - - vol_name: "ansible-vol" + - vol_id: "00028" + - vol_id: "00018" + - vol_name: "ansible-vol" vol_state: "absent-in-group" - name: Adding child SG to parent SG @@ -301,8 +307,8 @@ Examples sg_name: "parent_sg" state: "present" child_storage_groups: - - "pie" - - "bar" + - "pie" + - "bar" child_sg_state: "present-in-group" - name: Removing child SG from parent SG @@ -316,8 +322,8 @@ Examples sg_name: "parent_sg" state: "present" child_storage_groups: - - "pie" - - "bar" + - "pie" + - "bar" child_sg_state: "absent-in-group" - name: Rename storage group @@ -343,7 +349,7 @@ Examples sg_name: "ansible_test_sg" service_level: "Diamond" srp: "SRP_1" - compression: True + compression: true snapshot_policies: - "10min_policy" - "30min_policy" diff --git a/docs/modules/storagepool.rst b/docs/modules/storagepool.rst index d78d4b7..bc6464e 100644 --- a/docs/modules/storagepool.rst +++ b/docs/modules/storagepool.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -42,7 +42,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -57,6 +57,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. diff --git a/docs/modules/volume.rst b/docs/modules/volume.rst index abd24a1..b6dc4ec 100644 --- a/docs/modules/volume.rst +++ b/docs/modules/volume.rst @@ -21,7 +21,7 @@ Requirements The below requirements are needed on the host that executes this module. - A Dell PowerMax storage system. -- Ansible-core 2.13 or later. +- Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. @@ -80,7 +80,7 @@ Parameters universion (False, int, None) - Unisphere version, currently '91', '92' and '100' versions are supported. + Unisphere version, currently '91', '92', '100' and '101' versions are supported. verifycert (True, str, None) @@ -95,6 +95,12 @@ Parameters The password of the Unisphere host. + timeout (optional, int, 120) + Time after which the connection will get terminated. + + It is to be mentioned in seconds. + + serial_no (True, str, None) The serial number of the PowerMax/VMAX array. It is a required parameter for all array-specific operations except for getting a list of arrays in the Gatherfacts module. @@ -134,7 +140,7 @@ Examples sg_name: "{{sg_name}}" size: 1 cap_unit: "{{cap_unit}}" - append_vol_id: True + append_vol_id: true state: 'present' - name: Expanding volume size @@ -145,7 +151,7 @@ Examples user: "{{user}}" password: "{{password}}" serial_no: "{{serial_no}}" - size: 3 + size: 3 cap_unit: "{{cap_unit}}" vol_id: "0059B" state: 'present' @@ -158,7 +164,7 @@ Examples user: "{{user}}" password: "{{password}}" serial_no: "{{serial_no}}" - new_name: "Test_GOLD_vol_Renamed" + new_name: "Test_GOLD_vol_Renamed" vol_id: "0059B" state: 'present' diff --git a/docs/samples/capacity_volumes.yml b/docs/samples/capacity_volumes.yml index 52d69a9..be4afed 100644 --- a/docs/samples/capacity_volumes.yml +++ b/docs/samples/capacity_volumes.yml @@ -4,7 +4,6 @@ - name: Capacity of volumes in a storage group above a threshold capacity hosts: localhost connection: local - vars: unispherehost: 'your_unisphere_host_url' universion: "version_of_the_unisphere" @@ -16,8 +15,7 @@ threshold_cap: enter the size in GB tasks: - -# This task gets the details of the storage group which contains the attribute storage_group_volumes(a list of all the volumes Id) + # This task gets the details of the storage group which contains the attribute storage_group_volumes(a list of all the volumes Id) - name: Get details of the Storage Group dellemc.powermax.storagegroup: unispherehost: "{{ unispherehost }}" @@ -30,12 +28,12 @@ state: "present" register: storage_details -# The set_fact assigns a variable to the list of volume id's fetched from the storage_details - - name: Setting volume IDs + # The set_fact assigns a variable to the list of volume id's fetched from the storage_details + - name: Assign a variable to the list of volume IDs ansible.builtin.set_fact: all_volumes_id: "{{ storage_details.storage_group_volumes | list }}" -# This task uses the volume id's assigned to variable all_volume_Id to get the volume details. + # This task uses the volume id's assigned to variable all_volume_Id to get the volume details. - name: Get the details of all volume in the storage group register: temp_result dellemc.powermax.volume: @@ -50,18 +48,18 @@ state: 'present' loop: "{{ all_volumes_id }}" -# The set_fact fetches the list of the volume names from the volume details(the output of the previous task). - - name: Setting volume names + # The set_fact fetches the list of the volume names from the volume details(the output of the previous task). + - name: Assign a variable to the list of volume names ansible.builtin.set_fact: all_volumes_names: "{{ temp_result['results'] | map(attribute='volume_details.volume_identifier') | list }}" -# The set_fact fetches the list of the volume size from the volume details(the output of the previous task). - - name: Setiing volume sizes + # The set_fact fetches the list of the volume size from the volume details(the output of the previous task). + - name: Assign a variable to the list of volume sizes ansible.builtin.set_fact: all_volumes_size: "{{ temp_result['results'] | map(attribute='volume_details.cap_gb') | list }}" -# This prints the list of all the volumes which satisfies the condition mentioned in the when statement. - - name: List of all the Volumes Which have capacity more than the threshold + # This prints the list of all the volumes which satisfies the condition mentioned in the when statement. + - name: List of all the volumes which have capacity more than the threshold ansible.builtin.debug: msg: "{{ item.1 }}" loop: "{{ all_volumes_size | zip(all_volumes_names) | list }}" diff --git a/docs/samples/create_multiple_volumes.yml b/docs/samples/create_multiple_volumes.yml index d216b78..8a7454f 100644 --- a/docs/samples/create_multiple_volumes.yml +++ b/docs/samples/create_multiple_volumes.yml @@ -15,7 +15,7 @@ cap_unit: 'GB' tasks: -# This task creates multiple volumes using the loop. + # This task creates multiple volumes using the loop. - name: Create volumes register: result dellemc.powermax.volume: @@ -30,5 +30,5 @@ size: 1 cap_unit: "{{ cap_unit }}" state: 'present' -# The loop will be executed for the number of elements in the list(created by the range) . + # The loop will be executed for the number of elements in the list(created by the range) . loop: "{{ range(1, 10 + 1, 1) | list }}" diff --git a/docs/samples/create_multiple_volumes_async.yml b/docs/samples/create_multiple_volumes_async.yml index ddc851f..d93c007 100644 --- a/docs/samples/create_multiple_volumes_async.yml +++ b/docs/samples/create_multiple_volumes_async.yml @@ -29,9 +29,9 @@ size: 1 cap_unit: "{{ cap_unit }}" state: 'present' - # The creation of multiple volumes in async mode depends on the values of the poll and async. For async=45 and poll=10, the - # approximate time for the creation of 100 volumes is 30 minutes. Variation in the value of poll and async will affect the volume - # creation time. + # The creation of multiple volumes in async mode depends on the values of the poll and async. For async=45 and poll=10, the + # approximate time for the creation of 100 volumes is 30 minutes. Variation in the value of poll and async will affect the volume + # creation time. loop: "{{ range(1, 100 + 1, 1) | list }}" async: 45 poll: 10 diff --git a/docs/samples/delete_volumes.yml b/docs/samples/delete_volumes.yml index b17b401..86d9a08 100644 --- a/docs/samples/delete_volumes.yml +++ b/docs/samples/delete_volumes.yml @@ -3,7 +3,6 @@ - name: Deletion of the multiple volumes hosts: localhost connection: local - vars: unispherehost: 'your_unisphere_host_url' universion: "version_of_the_unisphere" @@ -14,7 +13,7 @@ sg_name: 'sample_storage_group' tasks: -# This task collects the details of the storage group. + # This task collects the details of the storage group. - name: Get details of the Storage Group dellemc.powermax.storagegroup: unispherehost: "{{ unispherehost }}" @@ -27,12 +26,12 @@ state: "present" register: storage_details -# The set_fact fetches the Id's of all the volumes from the storage group details and creates the list. - - name: Setting volume IDs + # The set_fact fetches the Id's of all the volumes from the storage group details and creates the list. + - name: Assign a variable to the list of volume IDs ansible.builtin.set_fact: all_volumes_id: "{{ storage_details.storage_group_volumes | list }}" -# This task removes all the volumes from the storage group. vol_state attribute defines the state of the volume in a storage group. + # This task removes all the volumes from the storage group. vol_state attribute defines the state of the volume in a storage group. - name: Remove all volumes from the Storage Group dellemc.powermax.storagegroup: unispherehost: "{{ unispherehost }}" @@ -46,9 +45,9 @@ volumes: - vol_id: "{{ item }}" vol_state: "absent-in-group" - loop: "{{ all_volumes_id }}" + loop: "{{ all_volumes_Id }}" -# This task deletes the volumes which were removed from the storage group in the previous task. + # This task deletes the volumes which were removed from the storage group in the previous task. - name: Delete all the volumes dellemc.powermax.volume: unispherehost: "{{ unispherehost }}" @@ -59,4 +58,4 @@ serial_no: "{{ serial_no }}" vol_id: "{{ item }}" state: 'absent' - loop: "{{ all_volumes_id }}" + loop: "{{ all_volumes_Id }}" diff --git a/docs/samples/find_empty_storage_groups.yml b/docs/samples/find_empty_storage_groups.yml index b55298f..4537e83 100644 --- a/docs/samples/find_empty_storage_groups.yml +++ b/docs/samples/find_empty_storage_groups.yml @@ -26,7 +26,7 @@ register: subset_result # The set_fact generates the list of all the storage groups in an array. - - name: Setting all storage group names + - name: Assign a variable to the list of storage group names ansible.builtin.set_fact: all_storage_groups_names: "{{ subset_result['StorageGroups'] | list }}" @@ -34,18 +34,18 @@ - name: Get details of all the Storage Groups dellemc.powermax.storagegroup: unispherehost: "{{ unispherehost }}" - serial_no: "{{ serial_no }}" universion: "{{ universion }}" verifycert: "{{ verifycert }}" user: "{{ user }}" password: "{{ password }}" + serial_no: "{{ serial_no }}" sg_name: "{{ item }}" state: "present" loop: "{{ all_storage_groups_names }}" register: all_storage_groups_details # The set_fact generates a list of the number of volumes in each storage group. - - name: Setting number of volumes in storage group + - name: Assign a variable to the number of volumes in storage group ansible.builtin.set_fact: no_of_vols_in_sg: "{{ all_storage_groups_details.results | map(attribute='storage_group_details.num_of_vols') | list }}" @@ -54,4 +54,4 @@ ansible.builtin.debug: msg: "{{ item.1 }}" loop: "{{ no_of_vols_in_sg | zip(all_storage_groups_names) | list }}" - when: item.0|int == 0 + when: item.0 | int == 0 diff --git a/docs/samples/find_suitable_array_and_pool_using_capacity_role.yml b/docs/samples/find_suitable_array_and_pool_using_capacity_role.yml index dc2fec1..b3ab302 100644 --- a/docs/samples/find_suitable_array_and_pool_using_capacity_role.yml +++ b/docs/samples/find_suitable_array_and_pool_using_capacity_role.yml @@ -2,7 +2,6 @@ hosts: localhost gather_facts: false connection: local - vars: unispherehost: 'your_unisphere_host_url' universion: 'version_of_the_unisphere' @@ -15,4 +14,4 @@ tasks: - name: Get the Serial Number and Assigned Pool with no value for service_level ansible.builtin.include_role: - name: dellemc.powermax.capacity_role + name: capacity_role diff --git a/docs/samples/list_storage_group.yml b/docs/samples/list_storage_group.yml index a0f81e9..e3c2f3f 100644 --- a/docs/samples/list_storage_group.yml +++ b/docs/samples/list_storage_group.yml @@ -4,7 +4,6 @@ - name: List of all the Storage Groups names those name contains the search_string hosts: localhost connection: local - vars: unispherehost: "your_unisphere_host_url" universion: "version_of_the_unisphere" diff --git a/docs/samples/list_volumes.yml b/docs/samples/list_volumes.yml index 6c1a888..829410d 100644 --- a/docs/samples/list_volumes.yml +++ b/docs/samples/list_volumes.yml @@ -5,7 +5,6 @@ - name: List of all the volume IDs whose size is greater than the threshold capacity hosts: localhost connection: local - vars: unispherehost: "your_unisphere_host_url" universion: "version_of_the_unisphere" diff --git a/docs/samples/search_volumes.yml b/docs/samples/search_volumes.yml index f4b2ba5..3ed883d 100644 --- a/docs/samples/search_volumes.yml +++ b/docs/samples/search_volumes.yml @@ -27,7 +27,7 @@ register: storage_details # The set_fact fetches the Id's of all the volumes from the storage group details and creates a list. - - name: Setting volume IDs + - name: Assign a variable to the list of volume id's ansible.builtin.set_fact: all_volumes_id: "{{ storage_details.storage_group_volumes | list }}" @@ -47,7 +47,7 @@ loop: "{{ all_volumes_id }}" # The set_fact generates a list of the volume names using the details of volumes(the output of the previous task). - - name: Setting all volume names + - name: Assign a variable to the list of volume names ansible.builtin.set_fact: all_volumes_names: "{{ temp_result['results'] | map(attribute='volume_details.volume_identifier') | list }}" diff --git a/galaxy.yml b/galaxy.yml index 07a4982..d63cbfd 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -1,73 +1,73 @@ ---- -### REQUIRED - -# The namespace of the collection. This can be a company/brand/organization or product namespace under which all -# content lives. May only contain alphanumeric characters and underscores. Additionally namespaces cannot start with -# underscores or numbers and cannot contain consecutive underscores -namespace: dellemc - -# The name of the collection. Has the same character restrictions as 'namespace' -name: powermax - -# The version of the collection. Must be compatible with semantic versioning -version: 2.2.1 - -# The path to the Markdown (.md) readme file. This path is relative to the root of the collection -readme: README.md - -# A list of the collection's content authors. Can be just the name or in the format 'Full Name (url) -# @nicks:irc/im.site#channel' -authors: - - Akash Shendge - - Ambuj Dubey - - Arindam Datta - - Ashish Verma - - Manisha Agrawal - - Prashant Rakheja - - Rajshree Khare - - Vasudevu Lakhinana - - Rajendra Indukuri - - Spandita Panigrahi - - Meenakshi Dembi - - Pavan Mudunuri - - Trisha Datta - - -### OPTIONAL but strongly recommended - -# A short summary description of the collection -description: Ansible modules for PowerMax - -# Either a single license or a list of licenses for content inside of a collection. Ansible Galaxy currently only -# accepts L(SPDX,https://spdx.org/licenses/) licenses. This key is mutually exclusive with 'license_file' -license: - - GPL-3.0-or-later - - Apache-2.0 - -# A list of tags you want to associate with the collection for indexing/searching. A tag name has the same character -# requirements as 'namespace' and 'name' -tags: [storage] - -# Collections that this collection requires to be installed for it to be usable. The key of the dict is the -# collection label 'namespace.name'. The value is a version range -# L(specifiers,https://python-semanticversion.readthedocs.io/en/latest/#requirement-specification). Multiple version -# range specifiers can be set and are separated by ',' -dependencies: {} - -# The URL of the originating SCM repository -repository: https://github.com/dell/ansible-powermax/tree/2.2.1 - -# The URL to any online docs -documentation: https://github.com/dell/ansible-powermax/tree/2.2.1/docs - -# The URL to the homepage of the collection/project -homepage: https://github.com/dell/ansible-powermax/tree/2.2.1 - -# The URL to the collection issue tracker -issues: https://www.dell.com/community/Automation/bd-p/Automation - -# A list of file glob-like patterns used to filter any files or directories that should not be included in the build -# artifact. A pattern is matched from the relative path of the file or directory of the collection directory. This -# uses 'fnmatch' to match the files or directories. Some directories and files like 'galaxy.yml', '*.pyc', '*.retry', -# and '.git' are always filtered -build_ignore: [] +--- +### REQUIRED + +# The namespace of the collection. This can be a company/brand/organization or product namespace under which all +# content lives. May only contain alphanumeric characters and underscores. Additionally namespaces cannot start with +# underscores or numbers and cannot contain consecutive underscores +namespace: dellemc + +# The name of the collection. Has the same character restrictions as 'namespace' +name: powermax + +# The version of the collection. Must be compatible with semantic versioning +version: 3.0.0 + +# The path to the Markdown (.md) readme file. This path is relative to the root of the collection +readme: README.md + +# A list of the collection's content authors. Can be just the name or in the format 'Full Name (url) +# @nicks:irc/im.site#channel' +authors: + - Akash Shendge + - Ambuj Dubey + - Arindam Datta + - Ashish Verma + - Manisha Agrawal + - Prashant Rakheja + - Rajshree Khare + - Vasudevu Lakhinana + - Rajendra Indukuri + - Spandita Panigrahi + - Meenakshi Dembi + - Pavan Mudunuri + - Trisha Datta + + +### OPTIONAL but strongly recommended + +# A short summary description of the collection +description: Ansible modules for PowerMax + +# Either a single license or a list of licenses for content inside of a collection. Ansible Galaxy currently only +# accepts L(SPDX,https://spdx.org/licenses/) licenses. This key is mutually exclusive with 'license_file' +license: + - GPL-3.0-or-later + - Apache-2.0 + +# A list of tags you want to associate with the collection for indexing/searching. A tag name has the same character +# requirements as 'namespace' and 'name' +tags: [storage] + +# Collections that this collection requires to be installed for it to be usable. The key of the dict is the +# collection label 'namespace.name'. The value is a version range +# L(specifiers,https://python-semanticversion.readthedocs.io/en/latest/#requirement-specification). Multiple version +# range specifiers can be set and are separated by ',' +dependencies: {} + +# The URL of the originating SCM repository +repository: https://github.com/dell/ansible-powermax/tree/3.0.0 + +# The URL to any online docs +documentation: https://github.com/dell/ansible-powermax/tree/3.0.0/docs + +# The URL to the homepage of the collection/project +homepage: https://github.com/dell/ansible-powermax/tree/3.0.0 + +# The URL to the collection issue tracker +issues: https://www.dell.com/community/Automation/bd-p/Automation + +# A list of file glob-like patterns used to filter any files or directories that should not be included in the build +# artifact. A pattern is matched from the relative path of the file or directory of the collection directory. This +# uses 'fnmatch' to match the files or directories. Some directories and files like 'galaxy.yml', '*.pyc', '*.retry', +# and '.git' are always filtered +build_ignore: [] diff --git a/meta/runtime.yml b/meta/runtime.yml index 07eb48d..cb466a8 100644 --- a/meta/runtime.yml +++ b/meta/runtime.yml @@ -1,5 +1,5 @@ --- -requires_ansible: ">=2.13" +requires_ansible: ">=2.14.0" plugin_routing: modules: dellemc_powermax_host: diff --git a/playbooks/capacity_role.yml b/playbooks/capacity_role.yml new file mode 100644 index 0000000..eb47fa8 --- /dev/null +++ b/playbooks/capacity_role.yml @@ -0,0 +1,75 @@ +--- +- name: Intelligent Volume Placement operation on PowerMax + hosts: localhost + connection: local + vars: + # PowerMax connection parameters + unispherehost: '10.XX.XX.XX' + universion: '101' + verifycert: false + user: 'user' + password: 'password' + + # Parameters for placement logic -- note that size is total size for all volumes + size: 40 + cap_unit: 'GB' + service_level: "Diamond" + + # Return parameters by the placement role + assigned_pool: '' + + # Local variables used by this playbook + serial_no: "" + sg_name: 'intelligent_provisioning' + vol_name: 'demo_role' + vol_count: 4 + + tasks: + - name: Include the PowerMax role to get the Serial Number and Assigned Pool + ansible.builtin.include_role: + name: capacity_role + + - name: Debug assigned pool + ansible.builtin.debug: + var: assigned_pool + + - name: Show error message on unsuccessful search + ansible.builtin.fail: + msg: "failed to find suitable pool with specified size and service level. Available pools are {{ assigned_pool.all_pools }} " + when: assigned_pool.serial_no == 'NOT_FOUND' + + - name: Show best suitable system on successful search + ansible.builtin.debug: + msg: "serial no is {{ assigned_pool.serial_no }} # srp_id is {{ assigned_pool.storage_pool }} # storage group is {{ assigned_pool.storage_group }}" + + # Create storage group on the assigned serial number and SRP (if it does not exist already) + - name: Create storage group + register: storage_group_details + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ assigned_pool.serial_no }}" + sg_name: "{{ sg_name }}" + service_level: "{{ service_level }}" + srp: "{{ assigned_pool.storage_pool }}" + compression: true + state: "present" + + # Once the storage group is provisioned, multiple volumes can be created within the same storage group + - name: Create volumes + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ assigned_pool.serial_no }}" + vol_name: "{{ vol_name + '_' }}{{ item }}" + sg_name: "{{ sg_name }}" + size: "{{ (size / vol_count) | int | abs }}" + cap_unit: "{{ cap_unit }}" + state: 'present' + loop: "{{ range(0, vol_count, 1) | list }}" diff --git a/playbooks/host.yml b/playbooks/host.yml new file mode 100644 index 0000000..3ac29d0 --- /dev/null +++ b/playbooks/host.yml @@ -0,0 +1,154 @@ +--- +- name: Testing host operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + host_name: 'HG4_ansible_test_hostgroup' + host_name_1: 'Ansible_Testing_host_1' + host_name_2: 'Ansible_Testing_host_2' + serial_no: '0123456789' + new_host_name: 'Ansible_Testing_host2' + tasks: + - name: Create host with host_type 'default' + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name_1 }}" + host_type: "default" + state: 'present' + + - name: Create host with host_type 'hpux' + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name_2 }}" + host_type: "hpux" + state: 'present' + + - name: Create host with host_flags + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + initiators: + - id: 10000090fa6622a5 + - alias: 'test/host' + host_flags: + spc2_protocol_version: true + consistent_lun: true + volume_set_addressing: unset + disable_q_reset_on_ua: false + openvms: unset + state: 'present' + initiator_state: 'present-in-host' + + - name: Get host details + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + state: 'present' + + - name: Adding initiator to host + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + initiators: + - 10000000c9dbdf9f + - a/b + initiator_state: 'present-in-host' + state: 'present' + + - name: Removing initiator from host + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + initiators: + - 20000025b551ff2b + - a/b + initiator_state: 'absent-in-host' + state: 'present' + + - name: Modify flags of host using host_type + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + host_type: "hpux" + state: 'present' + + - name: Modify flags of host using host_flag + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + host_flags: + spc2_protocol_version: unset + consistent_lun: unset + volume_set_addressing: true + disable_q_reset_on_ua: false + openvms: false + avoid_reset_broadcast: true + state: 'present' + + - name: Rename host + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ host_name }}" + new_name: "{{ new_host_name }}" + state: 'present' + + - name: Delete host + dellemc.powermax.host: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + host_name: "{{ new_host_name }}" + state: 'absent' diff --git a/playbooks/hostgroup.yml b/playbooks/hostgroup.yml new file mode 100644 index 0000000..1806f8f --- /dev/null +++ b/playbooks/hostgroup.yml @@ -0,0 +1,154 @@ +--- +- name: Testing host group operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + hostgroup_name: 'Ansible_Testing_hostgroup' + hostgroup_name_1: 'Ansible_Testing_hostgroup_1' + hostgroup_name_2: 'Ansible_Testing_hostgroup_2' + serial_no: '0123456789' + + tasks: + - name: Create host group with host_type 'default' + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name_1 }}" + hosts: + - Ansible_Test_host_1 + state: 'present' + host_state: 'present-in-group' + host_type: "default" + + - name: Create host group with host_type 'hpux' + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name_2 }}" + hosts: + - Ansible_Test_host_2 + state: 'present' + host_state: 'present-in-group' + host_type: "hpux" + + - name: Create host group with host_flags + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + hosts: + - Ansible_Test_host + state: 'present' + host_state: 'present-in-group' + host_flags: + spc2_protocol_version: 'true' + consistent_lun: false + disable_q_reset_on_ua: 'false' + openvms: 'unset' + + - name: Get host group details + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + state: 'present' + + - name: Adding host to host group + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + hosts: + - Ansible_Test_host2 + state: 'present' + host_state: 'present-in-group' + + - name: Removing host from host group + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + hosts: + - Ansible_Test_host2 + state: 'present' + host_state: 'absent-in-group' + + - name: Modify flags of host group using host_type + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + host_type: "default" + state: 'present' + + - name: Modify flags of host group using host_flags + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + host_flags: + spc2_protocol_version: 'Unset' + disable_q_reset_on_ua: 'False' + openvms: false + avoid_reset_broadcast: 'True' + state: 'present' + + - name: Rename host group + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "{{ hostgroup_name }}" + new_name: "Ansible_Testing_hostgroup2" + state: 'present' + + - name: Delete host group + dellemc.powermax.hostgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + hostgroup_name: "Ansible_Testing_hostgroup2" + state: 'absent' diff --git a/playbooks/info.yml b/playbooks/info.yml new file mode 100644 index 0000000..849d393 --- /dev/null +++ b/playbooks/info.yml @@ -0,0 +1,267 @@ +--- +- name: Collect set of facts + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + serial_no: "0123456789" + tdev_volumes: true + + tasks: + - name: Get subset facts for a given PowerMax/Vmax Storage System + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + serial_no: "{{ serial_no }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + gather_subset: + - alert + - health + - vol + - sg + - pg + - srp + - host + - hg + - port + - mv + - mv_connections + - rdf + - metro_dr_env + - snapshot_policies + register: subset_result + + - name: Get list of volumes with filter -- all TDEV volumes of size equal to 5GB + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - vol + filters: + - filter_key: "tdev" + filter_operator: "equal" + filter_value: "True" + - filter_key: "cap_gb" + filter_operator: "equal" + filter_value: "5" + + - name: Get list of volumes and storage group with filter + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - vol + - sg + filters: + - filter_key: "tdev" + filter_operator: "equal" + filter_value: "True" + - filter_key: "cap_gb" + filter_operator: "equal" + filter_value: "5" + + - name: Get list of storage group with capacity between 2GB to 10GB + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - sg + filters: + - filter_key: "cap_gb" + filter_operator: "greater" + filter_value: "2" + - filter_key: "cap_gb" + filter_operator: "lesser" + filter_value: "10" + + - name: Get the list of arrays for a given Unisphere host + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + register: array_list + + - name: Get the list of metro DR environments for a given Unisphere host + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - metro_dr_env + + - name: Get list of tdev-volumes + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + tdev_volumes: "{{ tdev_volumes }}" + gather_subset: + - vol + + - name: Get the list of arrays for a given Unisphere host + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + + - name: Get array health status + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - health + + - name: Get array alert summary + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - alert + + - name: Get list of Storage groups + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - sg + + - name: Get list of Storage Resource Pools + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - srp + + - name: Get list of Ports + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - port + + - name: Get list of Port Groups + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - pg + + - name: Get list of Hosts + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - host + + - name: Get list of Host Groups + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - hg + + - name: Get list of Masking Views + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - mv + + - name: Get list of RDF Groups + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - rdf + + - name: Get list of snapshot policies + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - snapshot_policies + + - name: Get list of Initiators + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - initiators + + - name: Get list of masking view connections with filter + dellemc.powermax.info: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + gather_subset: + - mv_connections + filters: + - filter_key: "logged_in" + filter_operator: "equal" + filter_value: "True" + - filter_key: "cap_gb" + filter_operator: "equal" + filter_value: "10" diff --git a/playbooks/initiator.yml b/playbooks/initiator.yml new file mode 100644 index 0000000..232ffe4 --- /dev/null +++ b/playbooks/initiator.yml @@ -0,0 +1,48 @@ +--- +- name: Testing host operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + serial_no: "0123456789" + + tasks: + - name: Get initiator details + dellemc.powermax.initiator: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + initiator_id: 10000000c9959b8e + state: 'present' + + - name: Get initiator details using alias + dellemc.powermax.initiator: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + alias: 'test/host' + state: 'present' + + - name: Rename initiator alias + dellemc.powermax.initiator: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + initiator_id: 10000000c9959b8e + new_alias: + new_node_name: 'test' + new_port_name: 'host_new' + state: 'present' diff --git a/playbooks/job.yml b/playbooks/job.yml new file mode 100644 index 0000000..e1d6ce9 --- /dev/null +++ b/playbooks/job.yml @@ -0,0 +1,20 @@ +--- +- name: Job Operations on PowerMax Array + hosts: localhost + connection: local + vars: + unispherehost: "10.XX.XX.XX" + universion: "101" + verifycert: false + user: "user" + password: "password" + + tasks: + - name: Get job details + dellemc.powermax.job: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + job_id: "1609765491463" diff --git a/playbooks/maskingview.yml b/playbooks/maskingview.yml new file mode 100644 index 0000000..a4b5c17 --- /dev/null +++ b/playbooks/maskingview.yml @@ -0,0 +1,75 @@ +--- +- name: Test masking view operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: "user" + password: "password" + mv_name: "ansible_testing_mv_2" + serial_no: "000123456789" + + tasks: + - name: Create MV with hostgroup + dellemc.powermax.maskingview: + unispherehost: "{{ unispherehost }}" + universion: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + mv_name: "{{ mv_name }}" + portgroup_name: "1024739167_415_PG" + hostgroup_name: "102473945_415_IG" + sg_name: "fakehostlssemccom_415_CSG" + state: "present" + + - name: Rename hostgroup masking view + dellemc.powermax.maskingview: + unispherehost: "{{ unispherehost }}" + universion: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + mv_name: "{{ mv_name }}" + new_mv_name: "Ansible_Testing_mv_renamed" + state: "present" + + - name: Delete hostgroup masking view + dellemc.powermax.maskingview: + unispherehost: "{{ unispherehost }}" + universion: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + mv_name: "Ansible_Testing_mv_renamed" + state: "absent" + + - name: Create MV with host + dellemc.powermax.maskingview: + unispherehost: "{{ unispherehost }}" + universion: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + mv_name: "ansible_testing_host_mv" + portgroup_name: "portgroup-31933" + host_name: "fake_host" + sg_name: "1024739118_415_CSG" + state: "present" + + - name: Delete host masking view + dellemc.powermax.maskingview: + unispherehost: "{{ unispherehost }}" + universion: "{{ unispherehost }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + mv_name: "ansible_testing_host_mv" + state: "absent" diff --git a/playbooks/metrodr.yml b/playbooks/metrodr.yml new file mode 100644 index 0000000..0e46f11 --- /dev/null +++ b/playbooks/metrodr.yml @@ -0,0 +1,261 @@ +--- +- name: Testing MetroDR Operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: "user" + password: "password" + mv_name: "ansible_testing_mv_2" + metro_r1_array_id: "000123456789" + metro_r2_array_id: "000123456788" + dr_array_id: "000123456787" + sg_name: "ansible_sg" + env_name: "metrodr_env" + vol_name: "ansible_vol" + + tasks: + - name: Create a new Storage group - prereq + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + sg_name: "{{ sg_name }}" + service_level: "Diamond" + srp: "SRP_1" + compression: true + state: "present" + + - name: Create a volume - prereq + register: volume_details + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + vol_name: "{{ vol_name }}" + sg_name: "{{ sg_name }}" + size: 1 + cap_unit: 'GB' + state: 'present' + + - name: Create metrodr env + dellemc.powermax.metrodr: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + metro_r1_array_id: "{{ metro_r1_array_id }}" + metro_r2_array_id: "{{ metro_r2_array_id }}" + dr_array_id: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + env_name: "{{ env_name }}" + replication_mode: "Asynchronous" + wait_for_completion: true + state: "present" + + - name: Modify metrodr env + dellemc.powermax.metrodr: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + metro_r1_array_id: "{{ metro_r1_array_id }}" + env_name: "{{ env_name }}" + srdf_param: + srdf_state: "Suspend" + metro: true + dr: true + replication_mode: "Adaptive Copy" + wait_for_completion: true + state: "present" + + - name: Delete metrodr env + dellemc.powermax.metrodr: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + metro_r1_array_id: "{{ metro_r1_array_id }}" + env_name: "{{ env_name }}" + state: "absent" + + - name: Convert sg to metrodr env + dellemc.powermax.metrodr: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + metro_r1_array_id: "{{ metro_r1_array_id }}" + metro_r2_array_id: "{{ metro_r2_array_id }}" + dr_array_id: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + env_name: "{{ env_name }}" + wait_for_completion: true + state: "present" + + - name: Delete metrodr env + dellemc.powermax.metrodr: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + metro_r1_array_id: "{{ metro_r1_array_id }}" + env_name: "{{ env_name }}" + state: "absent" + + - name: Delete SRDF link from m1 - cleanup + dellemc.powermax.srdf: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' + + - name: Delete SRDF link from m2 - cleanup + dellemc.powermax.srdf: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r2_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' + + - name: Delete SRDF link from dr - cleanup + dellemc.powermax.srdf: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' + + - name: Remove volumes from SG - m1 - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ volume_details.volume_details.volumeId }}" + vol_state: "absent-in-group" + + - name: Remove volumes from SG - m2 - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r2_array_id }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ volume_details.volume_details.volumeId }}" + vol_state: "absent-in-group" + + - name: Remove volumes from SG - dr - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ volume_details.volume_details.volumeId }}" + vol_state: "absent-in-group" + + - name: Delete volume - m1 - cleanup + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + sg_name: "{{ sg_name }}" + vol_id: "{{ volume_details.volume_details.volumeId }}" + state: 'absent' + + - name: Delete volume - m2 - cleanup + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r2_array_id }}" + sg_name: "{{ sg_name }}" + vol_id: "{{ volume_details.volume_details.volumeId }}" + state: 'absent' + + - name: Delete volume - dr - cleanup + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + vol_id: "{{ volume_details.volume_details.volumeId }}" + state: 'absent' + + - name: Delete SG from m1 array - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r1_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' + + - name: Delete SG from m2 array - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ metro_r2_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' + + - name: Delete SG from dr array - cleanup + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ dr_array_id }}" + sg_name: "{{ sg_name }}" + state: 'absent' diff --git a/playbooks/port.yml b/playbooks/port.yml new file mode 100644 index 0000000..9e0d554 --- /dev/null +++ b/playbooks/port.yml @@ -0,0 +1,26 @@ +--- +- name: Testing port operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: "user" + password: "password" + array_id: "000123456789" + + tasks: + - name: Get details of single/multiple ports + dellemc.powermax.port: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + ports: + - director_id: "FA-1D" + port_id: "35" + - director_id: "FA-2D" + port_id: "10" diff --git a/playbooks/portgroup.yml b/playbooks/portgroup.yml new file mode 100644 index 0000000..ceeb4ab --- /dev/null +++ b/playbooks/portgroup.yml @@ -0,0 +1,110 @@ +--- +- name: Testing port group operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: "user" + password: "password" + portgroup_name: "01_C_pgtest_1" + new_name: "01_C_pgtest_2" + array_id: "000123456789" + + tasks: + - name: Create port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + state: "present" + + - name: Add port to port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + state: "present" + ports: + - director_id: "FA-1D" + port_id: "9" + - director_id: "FA-2D" + port_id: "9" + port_state: "present-in-group" + + - name: Remove port from port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + state: "present" + ports: + - director_id: "FA-1D" + port_id: "9" + - director_id: "FA-2D" + port_id: "9" + port_state: "absent-in-group" + + - name: Modify port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + new_name: "{{ new_name }}" + state: "present" + + - name: Delete port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ new_name }}" + state: "absent" + + - name: Create PG with ports + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + state: "present" + ports: + - director_id: "FA-1D" + port_id: "9" + - director_id: "FA-2D" + port_id: "10" + port_state: "present-in-group" + + - name: Delete port group + dellemc.powermax.portgroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ array_id }}" + portgroup_name: "{{ portgroup_name }}" + state: "absent" diff --git a/playbooks/rdfgroup.yml b/playbooks/rdfgroup.yml new file mode 100644 index 0000000..8a39456 --- /dev/null +++ b/playbooks/rdfgroup.yml @@ -0,0 +1,34 @@ +--- +- name: RDF Group Operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: "user" + password: "password" + serial_no: "000123456789" + rdfgroup_number: "63" + + tasks: + - name: Get RDF Group detail and Volumes + dellemc.powermax.rdfgroup: + unispherehost: "{{ unispherehost }}" + serial_no: "{{ serial_no }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + rdfgroup_number: "{{ rdfgroup_number }}" + + - name: Get specific volume details of an RDF Group + dellemc.powermax.rdfgroup: + unispherehost: "{{ unispherehost }}" + serial_no: "{{ serial_no }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + rdfgroup_number: "{{ rdfgroup_number }}" + vol_name: "00039" diff --git a/playbooks/snapshot.yml b/playbooks/snapshot.yml new file mode 100644 index 0000000..a8c3a8c --- /dev/null +++ b/playbooks/snapshot.yml @@ -0,0 +1,194 @@ +--- +- name: Running tests for PowerMax Snapshot module + hosts: localhost + connection: local + vars: + unispherehost: "10.XX.XX.XX" + universion: "101" + verifycert: false + user: "user" + password: "password" + sg_name: "ansible-snap-sg-source" + serial_no: "000123456789" + snapshot_name: "ansible_snap_test_x2" + ttl: "1" + ttl_none: "None" + ttl_unit_hours: "hours" + ttl_unit_days: "days" + generation: 0 + snapshot_id: 135023964929 + generation_1: 1 + snapshot_id_1: 135023964515 + new_snapshot_name: "ansible_snap_rename_test" + target_sg_name: "ansible-snap-sg-target" + link_status_linked: "linked" + link_status_unlinked: "unlinked" + state_present: "present" + state_absent: "absent" + + tasks: + - name: Create a storage group Snapshot with TTL + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + ttl: "{{ ttl }}" + ttl_unit: "{{ ttl_unit_days }}" + snapshot_name: "{{ snapshot_name }}" + state: "{{ state_present }}" + + - name: Get Storage Group Snapshot details + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + state: "{{ state_present }}" + + - name: Get Storage Group Snapshot details using generation + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + generation: "{{ generation_1 }}" + state: "{{ state_present }}" + + - name: Get Storage Group Snapshot details using snapshot_id + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + snapshot_id: "{{ snapshot_id_1 }}" + state: "{{ state_present }}" + + - name: Change SG Snapshot Link Status to Linked using generation + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + target_sg_name: "{{ target_sg_name }}" + link_status: "{{ link_status_linked }}" + generation: "{{ generation }}" + state: "{{ state_present }}" + + - name: Change SG Snapshot Link Status to UnLinked using generation + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + target_sg_name: "{{ target_sg_name }}" + link_status: "{{ link_status_unlinked }}" + generation: "{{ generation }}" + state: "{{ state_present }}" + + - name: Change SG Snapshot Link Status to Linked using snapshot_id + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + target_sg_name: "{{ target_sg_name }}" + link_status: "{{ link_status_linked }}" + snapshot_id: "{{ snapshot_id }}" + state: "{{ state_present }}" + + - name: Change SG Snapshot Link Status to UnLinked using snapshot_id + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + target_sg_name: "{{ target_sg_name }}" + link_status: "{{ link_status_unlinked }}" + snapshot_id: "{{ snapshot_id }}" + state: "{{ state_present }}" + + - name: Rename Storage Group Snapshot using generation + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + new_snapshot_name: "{{ new_snapshot_name }}" + generation: "{{ generation }}" + state: "{{ state_present }}" + + - name: Rename Storage Group Snapshot using snapshot_id + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + new_snapshot_name: "{{ new_snapshot_name }}" + snapshot_id: "{{ snapshot_id }}" + state: "{{ state_present }}" + + - name: Delete Storage Group Snapshot using generation + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + generation: "{{ generation_1 }}" + state: "{{ state_absent }}" + + - name: Delete Storage Group Snapshot using snapshot_id + dellemc.powermax.snapshot: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + snapshot_name: "{{ snapshot_name }}" + snapshot_id: "{{ snapshot_id_1 }}" + state: "{{ state_absent }}" diff --git a/playbooks/snapshotpolicy.yml b/playbooks/snapshotpolicy.yml new file mode 100644 index 0000000..ce99e0c --- /dev/null +++ b/playbooks/snapshotpolicy.yml @@ -0,0 +1,169 @@ +--- +- name: Snapshot Policy operations on PowerMax + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: '101' + verifycert: false + user: 'user' + password: 'password' + serial_no: '000123456789' + + tasks: + - name: Create a snapshot policy + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + interval: "10 Minutes" + secure: false + snapshot_count: 10 + offset_mins: 2 + compliance_count_warning: 6 + compliance_count_critical: 4 + state: "present" + + - name: Create a snapshot policy and associate storgae groups to it + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_2" + interval: "10 Minutes" + secure: false + snapshot_count: 12 + offset_mins: 5 + compliance_count_warning: 8 + compliance_count_critical: 4 + storage_groups: + - "11_ansible_test_1" + - "11_ansible_test_2" + storage_group_state: "present-in-policy" + state: "present" + + - name: Get snapshot policy details + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_2" + state: "present" + + - name: Modify snapshot policy attributes + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_2" + new_snapshot_policy_name: "10min_policy_2_new" + interval: "10 Minutes" + snapshot_count: 16 + offset_mins: 8 + compliance_count_warning: 9 + compliance_count_critical: 7 + state: "present" + + - name: Modify snapshot policy, associate to storage groups + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + storage_groups: + - "11_ansible_test_1" + - "11_ansible_test_2" + storage_group_state: "present-in-policy" + state: "present" + + - name: Modify snapshot policy, disassociate from storage groups + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + storage_groups: + - "11_ansible_test_1" + - "11_ansible_test_2" + storage_group_state: "absent-in-policy" + state: "present" + + - name: Modify snapshot policy state to suspend + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + suspend: true + state: "present" + + - name: Modify snapshot policy state to resume + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + suspend: false + state: "present" + + - name: Delete a snapshot policy + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_1" + state: "absent" + + - name: Modify snapshot policy, disassociate from storage groups + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_2_new" + storage_groups: + - "11_ansible_test_1" + - "11_ansible_test_2" + storage_group_state: "absent-in-policy" + state: "present" + + - name: Delete a snapshot policy + dellemc.powermax.snapshotpolicy: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + snapshot_policy_name: "10min_policy_2_new" + state: "absent" diff --git a/playbooks/srdf.yml b/playbooks/srdf.yml new file mode 100644 index 0000000..934d966 --- /dev/null +++ b/playbooks/srdf.yml @@ -0,0 +1,342 @@ +--- +- name: Testing Storage Group SRDF operations + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + sg_name: 'Ansible_Test_SRDF1' + sg_name2: 'Ansible_Test_SRDF2' + sg_name3: 'Ansible_Test_SRDF3' + vol_name: "Ansible_Test_SRDF_volume" + vol_name1: "Ansible_Test_SRDF_volume1" + vol_name2: "Ansible_Test_SRDF_volume2" + vol_name3: "Ansible_Test_SRDF_volume3" + vol_name4: "Ansible_Test_SRDF_volume4" + serial_no: '000123456789' + remote_serial_no_1: '000123456788' + + tasks: + - name: Create a new Storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + service_level: "Diamond" + srp: "SRP_1" + compression: true + state: "present" + register: sg_result + + - name: Create new volumes for existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_name: "ansible-test-x1" + size: 1 + cap_unit: "GB" + - vol_name: "ansible-test-x2" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Add existing volumes to existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ vol1 }}" + - vol_id: "{{ vol2 }}" + vol_state: "present-in-group" + register: sg_result + + - name: List volumes of a Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + register: sg_result + + - name: Remove existing volumes from existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ vol1 }}" + - vol_id: "{{ vol2 }}" + - vol_name: "ansible-test-x1" + vol_state: "absent-in-group" + register: sg_result + + - name: Modify the Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + service_level: "Platinum" + compression: false + register: sg_result + + - name: Add snapshot policy to storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_test_sg" + snapshot_policies: + - "ansible_SP1" + snapshot_policy_state: "present-in-group" + state: "present" + + - name: Remove snapshot policy from storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_test_sg" + snapshot_policies: + - "ansible_SP1" + snapshot_policy_state: "absent-in-group" + state: "present" + + - name: Delete the Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "absent" + + - name: Create a new Parent Storage Group with FAST policy + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + + - name: Create a new child Storage Group - prashant_child_SG_xx1 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + register: sg_result + + - name: Create a volume for child SG + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + state: "present" + volumes: + - vol_name: "prashant-child-vol" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Create a new child Storage Group - prashant_child_SG_xx2 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + register: sg_result + + - name: Create a volume for child SG + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + state: "present" + volumes: + - vol_name: "prashant-child-vol-xx2" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Modify the parent SG and add child SGs + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + srp: "SRP_1" + state: "present" + child_storage_groups: + - "prashant_child_SG_xx1" + - "prashant_child_SG_xx2" + child_sg_state: "present-in-group" + register: sg_result + + - name: Remove Child Storage Groups from Parent Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + state: "present" + child_storage_groups: + - "prashant_child_SG_xx1" + - "prashant_child_SG_xx2" + child_sg_state: "absent-in-group" + register: sg_result + + - name: Test rename SG functionality + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + new_sg_name: "ansible_sg_renamed_successful" + state: "present" + register: sg_result + + - name: Delete the storage group - prashant_child_SG_xx1 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + state: "absent" + + - name: Delete the storage group - prashant_child_SG_xx2 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + state: "absent" + + - name: Delete the storage group - ansible_sg_renamed_successful + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_sg_renamed_successful" + state: "absent" + + - name: Move volumes between Storage groups + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "Ansible_Remote_Testing" + target_sg_name: "ansible_neo_sg" + volumes: + - vol_id: "0007a" + force: true + vol_state: 'absent-in-group' + state: "present" + + - name: Set host IO limits on an existing storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + host_io_limit: + dynamic_distribution: "Always" + host_io_limit_mbps: 100 + host_io_limit_iops: 100 + state: "present" diff --git a/playbooks/storagegroup.yml b/playbooks/storagegroup.yml new file mode 100644 index 0000000..7989514 --- /dev/null +++ b/playbooks/storagegroup.yml @@ -0,0 +1,339 @@ +--- +- name: Running tests for PowerMax Storage Group module + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + sg_name: 'ansible_sg' + serial_no: '000123456789' + vol_name: 'prashant_ansible_lun' + cap_unit: 'GB' + new_sg_name: 'ansible_sg_renamed' + vol1: "0071D" + vol2: "0071E" + + tasks: + - name: Create a new Storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + service_level: "Diamond" + srp: "SRP_1" + compression: true + state: "present" + register: sg_result + + - name: Create new volumes for existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_name: "ansible-test-x1" + size: 1 + cap_unit: "GB" + - vol_name: "ansible-test-x2" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Add existing volumes to existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ vol1 }}" + - vol_id: "{{ vol2 }}" + vol_state: "present-in-group" + register: sg_result + + - name: List volumes of a Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + register: sg_result + + - name: Remove existing volumes from existing Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ vol1 }}" + - vol_id: "{{ vol2 }}" + - vol_name: "ansible-test-x1" + vol_state: "absent-in-group" + register: sg_result + + - name: Modify the Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + service_level: "Platinum" + compression: false + register: sg_result + + - name: Add snapshot policy to storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_test_sg" + snapshot_policies: + - "ansible_SP1" + snapshot_policy_state: "present-in-group" + state: "present" + + - name: Remove snapshot policy from storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_test_sg" + snapshot_policies: + - "ansible_SP1" + snapshot_policy_state: "absent-in-group" + state: "present" + + - name: Delete the Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "absent" + + - name: Create a new Parent Storage Group with FAST policy + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + + - name: Create a new child Storage Group - prashant_child_SG_xx1 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + register: sg_result + + - name: Create a volume for child SG + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + state: "present" + volumes: + - vol_name: "prashant-child-vol" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Create a new child Storage Group - prashant_child_SG_xx2 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + srp: "SRP_1" + service_level: "Diamond" + compression: false + state: "present" + register: sg_result + + - name: Create a volume for child SG + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + state: "present" + volumes: + - vol_name: "prashant-child-vol-xx2" + size: 1 + cap_unit: "GB" + vol_state: "present-in-group" + register: sg_result + + - name: Modify the parent SG and add child SGs + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + srp: "SRP_1" + state: "present" + child_storage_groups: + - "prashant_child_SG_xx1" + - "prashant_child_SG_xx2" + child_sg_state: "present-in-group" + register: sg_result + + - name: Remove Child Storage Groups from Parent Storage Group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + state: "present" + child_storage_groups: + - "prashant_child_SG_xx1" + - "prashant_child_SG_xx2" + child_sg_state: "absent-in-group" + register: sg_result + + - name: Test rename SG functionality + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_parent_SG_xx1" + new_sg_name: "ansible_sg_renamed_successful" + state: "present" + register: sg_result + + - name: Delete the storage group - prashant_child_SG_xx1 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx1" + state: "absent" + + - name: Delete the storage group - prashant_child_SG_xx2 + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "prashant_child_SG_xx2" + state: "absent" + + - name: Delete the storage group - ansible_sg_renamed_successful + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "ansible_sg_renamed_successful" + state: "absent" + + - name: Move volumes between Storage groups + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "Ansible_Remote_Testing" + target_sg_name: "ansible_neo_sg" + volumes: + - vol_id: "0007a" + force: true + vol_state: 'absent-in-group' + state: "present" + + - name: Set host IO limits on an existing storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + host_io_limit: + dynamic_distribution: "Always" + host_io_limit_mbps: 100 + host_io_limit_iops: 100 + state: "present" diff --git a/playbooks/storagepool.yml b/playbooks/storagepool.yml new file mode 100644 index 0000000..d5712e5 --- /dev/null +++ b/playbooks/storagepool.yml @@ -0,0 +1,23 @@ +--- +- name: Collect set of facts + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: "101" + verifycert: false + user: 'user' + password: 'password' + serial_no: "000123456789" + + tasks: + - name: Get storage pool details + dellemc.powermax.storagepool: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + pool: "SRP_1" + state: "present" diff --git a/playbooks/volume.yml b/playbooks/volume.yml new file mode 100644 index 0000000..b9016ab --- /dev/null +++ b/playbooks/volume.yml @@ -0,0 +1,145 @@ +--- +- name: Volume operations on VMAX + hosts: localhost + connection: local + vars: + unispherehost: '10.XX.XX.XX' + universion: '101' + verifycert: false + user: 'user' + password: 'password' + serial_no: '000123456789' + sg_name: 'Test' + new_sg_name: 'Ansible_Move_Volume_Testing' + vol_name: 'Volume' + cap_unit: 'GB' + append_vol_id: true + + tasks: + - name: Create volume + register: result + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_name: "{{ vol_name }}" + sg_name: "{{ sg_name }}" + size: 1 + cap_unit: "{{ cap_unit }}" + append_vol_id: "{{ append_vol_id }}" + state: 'present' + + - name: Expand volume using native id + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + size: 2 + cap_unit: "{{ cap_unit }}" + vol_id: "{{ result.volume_details.volumeId }}" + state: 'present' + + - name: Expand volume using volume identifier and storage group + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_name: "{{ vol_name }}" + sg_name: "{{ sg_name }}" + size: 3 + cap_unit: "{{ cap_unit }}" + state: 'present' + + - name: Move volume between storage group when current storage group is part of masking view + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_name: "{{ vol_name }}" + sg_name: "{{ sg_name }}" + new_sg_name: "{{ new_sg_name }}" + state: 'present' + + - name: Move volume between storage group when current storage group is not part of masking view + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_name: "{{ vol_name }}" + sg_name: "{{ new_sg_name }}" + new_sg_name: "{{ sg_name }}" + state: 'present' + + - name: Rename volume + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + new_name: "Ansible_Volume_Module_Playbook_Testing_Renamed" + vol_id: "{{ result.volume_details.volumeId }}" + state: "present" + + - name: Get volume details + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_id: "{{ result.volume_details.volumeId }}" + state: "present" + + - name: Get volume details using WWN + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_wwn: "{{ result.volume_details.wwn }}" + state: "present" + + - name: Remove existing volume from existing storage group + dellemc.powermax.storagegroup: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + sg_name: "{{ sg_name }}" + state: "present" + volumes: + - vol_id: "{{ result.volume_details.volumeId }}" + vol_state: "absent-in-group" + + - name: Delete volume + dellemc.powermax.volume: + unispherehost: "{{ unispherehost }}" + universion: "{{ universion }}" + verifycert: "{{ verifycert }}" + user: "{{ user }}" + password: "{{ password }}" + serial_no: "{{ serial_no }}" + vol_id: "{{ result.volume_details.volumeId }}" + state: "absent" diff --git a/plugins/doc_fragments/powermax.py b/plugins/doc_fragments/powermax.py index 7064dd7..a2efe36 100644 --- a/plugins/doc_fragments/powermax.py +++ b/plugins/doc_fragments/powermax.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -# Copyright: (c) 2019-2021, Dell Technologies. +# Copyright: (c) 2019-2023, Dell Technologies. from __future__ import absolute_import, division, print_function __metaclass__ = type @@ -16,11 +16,11 @@ class ModuleDocFragment(object): required: True universion: description: - - Unisphere version, currently '91', '92' and '100' versions are + - Unisphere version, currently '91', '92', '100' and '101' versions are supported. type: int required: False - choices: [91, 92, 100] + choices: [91, 92, 100, 101] verifycert: description: - Specifies system whether to validate SSL certificate or not, Values can be True or @@ -37,10 +37,16 @@ class ModuleDocFragment(object): - The password of the Unisphere host. type: str required: True + timeout: + description: + - Time after which the connection will get terminated. + - It is to be mentioned in seconds. + type: int + default: 120 requirements: - A Dell PowerMax storage system. - - Ansible-core 2.13 or later. + - Ansible-core 2.14 or later. - Python 3.9, 3.10 or 3.11. notes: - The modules present in this collection named as 'dellemc.powermax' diff --git a/plugins/module_utils/storage/dell/utils.py b/plugins/module_utils/storage/dell/utils.py index 89041ef..75c781e 100644 --- a/plugins/module_utils/storage/dell/utils.py +++ b/plugins/module_utils/storage/dell/utils.py @@ -54,7 +54,7 @@ def pyu4v_version_check(): "is : {1} and less than {2} ".format( curr_version, min_ver, max_ver) supported_version = (parse_version( - min_ver) <= parse_version(curr_version) < parse_version(max_ver) + min_ver) <= parse_version(curr_version) <= parse_version(max_ver) ) if supported_version is False: return unsupported_version_message @@ -80,6 +80,8 @@ def universion_check(universion): is_valid_universion = True elif curr_version.startswith("10.0") and universion == 100: is_valid_universion = True + elif curr_version.startswith("10.1") and universion == 101: + is_valid_universion = True else: user_message = "Unsupported unisphere version for current PyU4V" @@ -129,18 +131,20 @@ def get_powermax_management_host_parameters(metro_dr=False): if metro_dr: return dict( unispherehost=dict(type='str', required=True, no_log=True), - universion=dict(type='int', required=False, choices=[91, 92, 100]), + universion=dict(type='int', required=False, choices=[91, 92, 100, 101]), verifycert=dict(type='str', required=True), user=dict(type='str', required=True), - password=dict(type='str', required=True, no_log=True)) + password=dict(type='str', required=True, no_log=True), + timeout=dict(type='int', required=False, default=120)) return dict( unispherehost=dict(type='str', required=True, no_log=True), - universion=dict(type='int', required=False, choices=[91, 92, 100]), + universion=dict(type='int', required=False, choices=[91, 92, 100, 101]), verifycert=dict(type='str', required=True), user=dict(type='str', required=True), password=dict(type='str', required=True, no_log=True), - serial_no=dict(type='str', required=True)) + serial_no=dict(type='str', required=True), + timeout=dict(type='int', required=False, default=120)) ''' @@ -170,10 +174,11 @@ def get_powermax_management_host_parameters(metro_dr=False): def get_u4v_unisphere_connection_parameters(): return dict( unispherehost=dict(type='str', required=True, no_log=True), - universion=dict(type='int', required=False, choices=[91, 92, 100]), + universion=dict(type='int', required=False, choices=[91, 92, 100, 101]), verifycert=dict(type='str', required=True), user=dict(type='str', required=True), - password=dict(type='str', required=True, no_log=True) + password=dict(type='str', required=True, no_log=True), + timeout=dict(type='int', required=False, default=120) ) @@ -208,6 +213,7 @@ def get_U4V_connection(module_params, application_type=None, metro_dr=False): username=module_params['user'], password=module_params['password'], application_type=application_type) + conn.set_requests_timeout(timeout_value=module_params['timeout']) return conn @@ -236,6 +242,7 @@ def get_u4v_unisphere_connection(module_params, application_type=None): username=module_params['user'], password=module_params['password'], application_type=application_type) + conn.set_requests_timeout(timeout_value=module_params['timeout']) return conn @@ -352,5 +359,5 @@ def validate_verifycert(module_params): def is_array_v4(): curr_version = PyU4V.__version__ - if curr_version.startswith("10.0"): + if curr_version.startswith("10"): return True diff --git a/plugins/modules/host.py b/plugins/modules/host.py index a2eb6a9..b6290f2 100644 --- a/plugins/modules/host.py +++ b/plugins/modules/host.py @@ -299,7 +299,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' BASE_FLAGS = {'volume_set_addressing': {'enabled': False, 'override': False}, 'disable_q_reset_on_ua': {'enabled': False, 'override': False}, diff --git a/plugins/modules/hostgroup.py b/plugins/modules/hostgroup.py index bc6c2b4..9f070f8 100644 --- a/plugins/modules/hostgroup.py +++ b/plugins/modules/hostgroup.py @@ -300,7 +300,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' BASE_FLAGS = {'volume_set_addressing': {'enabled': False, 'override': False}, 'disable_q_reset_on_ua': {'enabled': False, 'override': False}, diff --git a/plugins/modules/info.py b/plugins/modules/info.py index 0c4819c..85394d2 100644 --- a/plugins/modules/info.py +++ b/plugins/modules/info.py @@ -394,7 +394,7 @@ filters: - filter_key: "logged_in" filter_operator: "equal" - filter_value: "true" + filter_value: "True" - filter_key: "cap_gb" filter_operator: "equal" filter_value: "10" @@ -651,7 +651,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Info(object): @@ -1260,11 +1260,12 @@ def get_info_parameters(): return dict( unispherehost=dict(type='str', required=True, no_log=True), - universion=dict(type='int', required=False, choices=[91, 92, 100]), + universion=dict(type='int', required=False, choices=[91, 92, 100, 101]), verifycert=dict(type='str', required=True), user=dict(type='str', required=True), password=dict(type='str', required=True, no_log=True), serial_no=dict(type='str', required=False, default=''), + timeout=dict(type='int', required=False, default=120), tdev_volumes=dict(type='bool', required=False, default=True, choices=[True, False]), masking_view_name=dict(type='str'), diff --git a/plugins/modules/initiator.py b/plugins/modules/initiator.py index a1a8921..cb71eb1 100644 --- a/plugins/modules/initiator.py +++ b/plugins/modules/initiator.py @@ -149,7 +149,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Initiator(object): diff --git a/plugins/modules/job.py b/plugins/modules/job.py index 77ec83a..78a9687 100644 --- a/plugins/modules/job.py +++ b/plugins/modules/job.py @@ -92,7 +92,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Job(object): diff --git a/plugins/modules/maskingview.py b/plugins/modules/maskingview.py index 6174e6e..019db0d 100644 --- a/plugins/modules/maskingview.py +++ b/plugins/modules/maskingview.py @@ -168,7 +168,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class MaskingView(object): diff --git a/plugins/modules/metrodr.py b/plugins/modules/metrodr.py index 8cf8426..afadba2 100644 --- a/plugins/modules/metrodr.py +++ b/plugins/modules/metrodr.py @@ -342,7 +342,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' # DO NOT CHANGE BELOW REPLICATION_MODES SEQUENCE AS ITS USED IN SCRIPT # USING INDEX diff --git a/plugins/modules/port.py b/plugins/modules/port.py index 8a92b33..70151ed 100644 --- a/plugins/modules/port.py +++ b/plugins/modules/port.py @@ -204,7 +204,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Port(object): diff --git a/plugins/modules/portgroup.py b/plugins/modules/portgroup.py index f81c8c7..1c53d93 100644 --- a/plugins/modules/portgroup.py +++ b/plugins/modules/portgroup.py @@ -216,7 +216,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class PortGroup(object): diff --git a/plugins/modules/process_storage_pool_dict.py b/plugins/modules/process_storage_pool_dict.py index fde42d3..2fed795 100644 --- a/plugins/modules/process_storage_pool_dict.py +++ b/plugins/modules/process_storage_pool_dict.py @@ -112,7 +112,7 @@ LOG = utils.get_logger('process_storage_pool_dict') # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class ProcessPoolDict(object): diff --git a/plugins/modules/rdfgroup.py b/plugins/modules/rdfgroup.py index fa98028..b60553f 100644 --- a/plugins/modules/rdfgroup.py +++ b/plugins/modules/rdfgroup.py @@ -393,7 +393,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class RDFGroup(object): diff --git a/plugins/modules/snapshot.py b/plugins/modules/snapshot.py index 5183499..9ae9247 100644 --- a/plugins/modules/snapshot.py +++ b/plugins/modules/snapshot.py @@ -346,7 +346,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Snapshot(object): diff --git a/plugins/modules/snapshotpolicy.py b/plugins/modules/snapshotpolicy.py index b9e7346..8f74743 100644 --- a/plugins/modules/snapshotpolicy.py +++ b/plugins/modules/snapshotpolicy.py @@ -27,10 +27,10 @@ options: universion: description: - - Unisphere version, currently '92', '100' version is supported. + - Unisphere version, currently '92', '100' and '101' version is supported. type: int required: False - choices: [92, 100] + choices: [92, 100, 101] snapshot_policy_name: description: - Name of the snapshot policy. @@ -324,7 +324,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' INTERVAL = ['10 Minutes', '12 Minutes', '15 Minutes', '20 Minutes', '30 Minutes', '1 Hour', '2 Hours', '3 Hours', '4 Hours', @@ -839,7 +839,7 @@ def convert_interval_minute(interval): def get_snapshotpolicy_parameters(): return dict( - universion=dict(type='int', required=False, choices=[92, 100]), + universion=dict(type='int', required=False, choices=[92, 100, 101]), snapshot_policy_name=dict(required=True, type='str'), interval=dict(required=False, type='str', choices=INTERVAL), secure=dict(required=False, type='bool', choices=[True, False]), diff --git a/plugins/modules/srdf.py b/plugins/modules/srdf.py index 76426fc..be088d4 100644 --- a/plugins/modules/srdf.py +++ b/plugins/modules/srdf.py @@ -382,7 +382,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class SRDF(object): @@ -395,6 +395,7 @@ def __init__(self): ''' Define all parameters required by this module''' self.module_params = utils.get_powermax_management_host_parameters() self.module_params.update(self.get_srdf_pair_parameters()) + # initialize the ansible module self.module = AnsibleModule( argument_spec=self.module_params, @@ -426,9 +427,11 @@ def __init__(self): try: self.u4v_conn = utils.get_U4V_connection( self.module.params, application_type=APPLICATION_TYPE) + except Exception as e: self.show_error_exit(msg=str(e)) self.replication = self.u4v_conn.replication + self.common = self.u4v_conn.common LOG.info('Check Mode flag is %s', self.module.check_mode) LOG.info('Got PyU4V instance for replication on PowerMax ') self.idempotency_dict = { @@ -564,15 +567,30 @@ def create_srdf_link(self): LOG.info(msg) resp = {} if not self.module.check_mode: - resp = self.replication.create_storage_group_srdf_pairings( - storage_group_id=sg_name, - remote_sid=remote_serial_no, - srdf_mode=srdf_mode, - establish=establish_flag, - force_new_rdf_group=forceNewRdfGroup, - rdfg_number=rdfg_number, - _async=async_flag) - LOG.debug('Response from create SRDF link call %s', resp) + if self.module.params['wait_for_completion'] is False: + resp = self.replication.create_storage_group_srdf_pairings( + storage_group_id=sg_name, + remote_sid=remote_serial_no, + srdf_mode=srdf_mode, + establish=establish_flag, + force_new_rdf_group=forceNewRdfGroup, + rdfg_number=rdfg_number, + _async=async_flag) + elif self.module.params['wait_for_completion'] is True: + job = self.replication.create_storage_group_srdf_pairings( + storage_group_id=sg_name, + remote_sid=remote_serial_no, + srdf_mode=srdf_mode, + establish=establish_flag, + force_new_rdf_group=forceNewRdfGroup, + rdfg_number=rdfg_number, + _async=True) + link_status = self.get_created_srdf_link_status(job) + LOG.info("The SRDF link status is: %s", link_status) + resp = self.get_srdf_link(sg_name)[0] + + LOG.info('Response from create SRDF link call %s', resp) + if async_flag: self.result['Job_details'] = resp self.result['SRDF_link_details'] = None @@ -588,6 +606,21 @@ def create_srdf_link(self): % (sg_name, str(e))) self.show_error_exit(msg=errorMsg) + def get_created_srdf_link_status(self, job): + """Get created SRDF link status""" + try: + task = self.common.wait_for_job('Create storage group SRDF link', + 202, job) + if task: + for job in task: + desc = job['description'] + if 'SRDF protect Storage Group' in desc: + break + return True + except Exception as e: + LOG.info('Failed to retrieve SRDF link status. Exception ' + 'received was %s.', e) + def _compute_required_establish_flag(self, srdf_state): if (srdf_state is None or srdf_state == 'Suspend'): return False @@ -809,6 +842,11 @@ def perform_module_operation(self): changed = False remoteSymmetrixIDs = [] + self.result = dict( + SRDF_link_details=None, + changed=False + ) + if (job_id and sg_name) or (not job_id and not sg_name): errorMsg = 'Please specify either job ID or SG name in one ' \ 'Ansible task' diff --git a/plugins/modules/storagegroup.py b/plugins/modules/storagegroup.py index 4456d63..0470deb 100644 --- a/plugins/modules/storagegroup.py +++ b/plugins/modules/storagegroup.py @@ -588,7 +588,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class StorageGroup(object): @@ -1716,7 +1716,7 @@ def perform_module_operation(self): if state == 'present' and vol_state == 'present-in-group'\ and storage_group and volumes and not target_sg_name: LOG.info('Create new volumes for storage group %s', sg_name) - result['add_new_vols_to_sg'],\ + result['add_new_vols_to_sg'], \ result['storage_group_volumes_details'] = self.\ add_volume_storage_group(sg_name) LOG.info('Add existing volumes to storage group %s', sg_name) diff --git a/plugins/modules/storagepool.py b/plugins/modules/storagepool.py index 7579bee..d316bd4 100644 --- a/plugins/modules/storagepool.py +++ b/plugins/modules/storagepool.py @@ -109,7 +109,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Pool(object): diff --git a/plugins/modules/volume.py b/plugins/modules/volume.py index 5395954..f97c93c 100644 --- a/plugins/modules/volume.py +++ b/plugins/modules/volume.py @@ -266,7 +266,7 @@ PYU4V_VERSION_CHECK = utils.pyu4v_version_check() # Application Type -APPLICATION_TYPE = 'ansible_v2.2.1' +APPLICATION_TYPE = 'ansible_v3.0.0' class Volume(object): diff --git a/requirements.txt b/requirements.txt index bc98718..1f7f556 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,2 @@ urllib3>=1.26.7 -PyU4V>=9.1.2.0 \ No newline at end of file +PyU4V>=9.1.2.0 diff --git a/roles/capacity_role/README.md b/roles/capacity_role/README.md index ae88196..faf70dc 100644 --- a/roles/capacity_role/README.md +++ b/roles/capacity_role/README.md @@ -2,15 +2,15 @@ Capacity Optimized Placement ============================ This role provides basic support for capacity optimized placement for PowerMax. The inputs are: -- size (integer) for the desired capacity -- cap_unit ('GB' or 'TB' -- default is 'GB') for the desired capacity +- capacity_role_size (integer) for the desired capacity +- capacity_role_cap_unit ('GB' or 'TB' -- default is 'GB') for the desired capacity - service_level for the desired capacity - Unisphere connection parameters The role will scan all available PowerMax arrays with the given Unisphere, and find out if there is enough capacity of the given service level in any array. If the capacity is available in multiple arrays, it will prioritize the storage pool which is least used and return that pool as the -'assigned_pool'. +'capacity_role_assigned_pool'. Requirements ------------ @@ -21,13 +21,13 @@ Role Variables -------------- input variables: -- size (float) -- cap_unit ('GB' or 'TB' -- default is 'GB') +- capacity_role_size (float) +- capacity_role_cap_unit ('GB' or 'TB' -- default is 'GB') - service_level (string) - sg_name (string) Output variable: -- assigned_pool (string) +- capacity_role_assigned_pool (string) Dependencies ------------ @@ -49,3 +49,4 @@ Author Information ------------------ - Akash Shendge (@shenda1) +- Pavan Mudunuri (@Pavan-Mudunuri) diff --git a/roles/capacity_role/defaults/main.yml b/roles/capacity_role/defaults/main.yml index 99c6b29..5a8fc84 100644 --- a/roles/capacity_role/defaults/main.yml +++ b/roles/capacity_role/defaults/main.yml @@ -1,3 +1,3 @@ --- # defaults file for capacity_role -cap_unit: 'GB' +capacity_role_cap_unit: 'GB' diff --git a/roles/capacity_role/meta/argument_specs.yml b/roles/capacity_role/meta/argument_specs.yml new file mode 100644 index 0000000..38a94cb --- /dev/null +++ b/roles/capacity_role/meta/argument_specs.yml @@ -0,0 +1,44 @@ +--- +argument_specs: + main: + short_description: Role provides basic support for capacity optimized placement for PowerMax. + description: + - Role provides basic support for capacity optimized placement for PowerMax. + options: + unispherehost: + required: true + type: str + description: IP or FQDN of the PowerMax host. + user: + required: true + type: str + description: The username of the PowerMax host. + password: + required: true + type: str + description: The password of the PowerMax host. + verifycert: + description: + - If C(false), the SSL certificates will not be validated. + - Configure C(false) only on personally controlled sites where self-signed certificates are used. + type: bool + default: false + capacity_role_size: + description: + - The size of the storage group. + type: float + required: true + capacity_role_cap_unit: + description: + - The capacity unit. + choices: [MB, GB, TB, CYL] + type: str + required: true + service_level: + description: + - The service level supported by storage pool. + type: str + sg_name: + description: + - The name of the storage group. + type: str diff --git a/roles/capacity_role/meta/main.yml b/roles/capacity_role/meta/main.yml new file mode 100644 index 0000000..e378188 --- /dev/null +++ b/roles/capacity_role/meta/main.yml @@ -0,0 +1,27 @@ +--- +galaxy_info: + author: "Akash Shendge, Pavan Mudunuri" + description: Role provides basic support for capacity optimized placement for PowerMax. + company: Dell Technologies + role_name: capacity_role + namespace: dellemc + + license: GPL-3.0-only + + min_ansible_version: "2.14.0" + + platforms: + - name: EL + versions: + - "9" + - "8" + - name: Ubuntu + versions: + - jammy + + - name: SLES + versions: + - "15SP3" + - "15SP4" + + galaxy_tags: [] diff --git a/roles/capacity_role/tasks/main.yml b/roles/capacity_role/tasks/main.yml index 43f8436..ada8a88 100644 --- a/roles/capacity_role/tasks/main.yml +++ b/roles/capacity_role/tasks/main.yml @@ -16,21 +16,21 @@ - name: Set fact for type of size ansible.builtin.set_fact: - size_type: "{{ size | type_debug }}" + capacity_role_size_type: "{{ capacity_role_size | type_debug }}" - name: Show error message on invalid type of size ansible.builtin.fail: msg: "Please provide valid value of size." - when: size_type != 'float' and size_type != 'int' + when: capacity_role_size_type != 'float' and capacity_role_size_type != 'int' - name: Take size with no change if the cap_unit is GB ansible.builtin.set_fact: - size_gb: "{{ size | float }}" + capacity_role_size_gb: "{{ capacity_role_size | float }}" when: cap_unit == 'GB' - name: Convert size to GB if the cap_unit is TB ansible.builtin.set_fact: - size_gb: "{{ size * 1024 | float }}" + capacity_role_size_gb: "{{ capacity_role_size * 1024 | float }}" when: cap_unit == 'TB' - name: Get the list of PowerMax arrays from Unisphere @@ -39,7 +39,7 @@ verifycert: "{{ verifycert }}" user: "{{ user }}" password: "{{ password }}" - register: arrays + register: capacity_role_arrays - name: Get the list of PowerMax arrays from Unisphere dellemc.powermax.info: @@ -50,8 +50,8 @@ serial_no: "{{ item }}" gather_subset: - "srp" - loop: "{{ arrays.Arrays | list }}" - register: pool_list + loop: "{{ capacity_role_arrays.Arrays | list }}" + register: capacity_role_pool_list - name: Get the list of pools across all discovered arrays dellemc.powermax.storagepool: @@ -62,23 +62,23 @@ serial_no: "{{ item.0.item }}" pool: "{{ item.1.srpId }}" state: 'present' - register: pools + register: capacity_role_pools with_subelements: - - "{{ pool_list.results }}" + - "{{ capacity_role_pool_list.results }}" - StorageResourcePools - name: Get best suitable Pool using our python sorting module - register: assigned_pool + register: capacity_role_assigned_pool dellemc.powermax.process_storage_pool_dict: unispherehost: "{{ unispherehost }}" verifycert: "{{ verifycert }}" user: "{{ user }}" password: "{{ password }}" - pool_data: "{{ pools.results | map(attribute='pool_details') | list }}" - size: "{{ size_gb }}" + pool_data: "{{ capacity_role_pools.results | map(attribute='pool_details') | list }}" + size: "{{ capacity_role_size_gb }}" service_level: "{{ service_level | default(omit) }}" sg_name: "{{ sg_name | default(omit) }}" - name: Debug print assigned pool ansible.builtin.debug: - var: assigned_pool + var: capacity_role_assigned_pool diff --git a/roles/capacity_role/vars/main.yml b/roles/capacity_role/vars/main.yml index 87a0e6a..58b82f8 100644 --- a/roles/capacity_role/vars/main.yml +++ b/roles/capacity_role/vars/main.yml @@ -1,4 +1,4 @@ --- # vars file for capacity_role -pools: "" -size_gb: "" +capacity_role_pools: "" +capacity_role_size_gb: "" diff --git a/tests/sanity/ignore-2.13.txt b/tests/sanity/ignore-2.16.txt similarity index 100% rename from tests/sanity/ignore-2.13.txt rename to tests/sanity/ignore-2.16.txt