From 5b2d311e07d3305ae9efd4b06cd4f59ee25f1bc4 Mon Sep 17 00:00:00 2001 From: shenda1 Date: Wed, 22 Sep 2021 19:15:12 +0530 Subject: [PATCH] Release version 1.1.0 --- ChangeLog.md | 11 + LICENSE | 875 ++- MODULE-LICENSE | 201 + README.md | 47 +- dellemc-powerflex-1.0.0.tar.gz | Bin 45848 -> 0 bytes docs/Product Guide.md | 5812 +++++++++-------- docs/Release Notes.md | 59 +- galaxy.yml | 16 +- meta/runtime.yml | 2 + .../dell/dellemc_ansible_powerflex_utils.py | 5 +- plugins/modules/dellemc_powerflex_device.py | 1109 ++++ .../modules/dellemc_powerflex_gatherfacts.py | 412 +- plugins/modules/dellemc_powerflex_sdc.py | 102 +- plugins/modules/dellemc_powerflex_sds.py | 1167 ++++ plugins/modules/dellemc_powerflex_snapshot.py | 199 +- .../modules/dellemc_powerflex_storagepool.py | 173 +- plugins/modules/dellemc_powerflex_volume.py | 258 +- tests/sanity/ignore-2.10.txt | 7 + tests/sanity/ignore-2.11.txt | 7 + tests/sanity/ignore-2.9.txt | 7 + 20 files changed, 7112 insertions(+), 3357 deletions(-) create mode 100644 ChangeLog.md create mode 100644 MODULE-LICENSE delete mode 100644 dellemc-powerflex-1.0.0.tar.gz create mode 100644 meta/runtime.yml create mode 100644 plugins/modules/dellemc_powerflex_device.py create mode 100644 plugins/modules/dellemc_powerflex_sds.py create mode 100644 tests/sanity/ignore-2.10.txt create mode 100644 tests/sanity/ignore-2.11.txt create mode 100644 tests/sanity/ignore-2.9.txt diff --git a/ChangeLog.md b/ChangeLog.md new file mode 100644 index 0000000..10c485e --- /dev/null +++ b/ChangeLog.md @@ -0,0 +1,11 @@ +# ansible-powerflex Change Log + +## Version 1.1.0 - released on 28/09/21 +- Added dual licensing. +- Added CRUD operations for SDS and device. +- gatherfacts module is enhanced to list devices. + +## Version 1.0.0 - released on 24/03/21 +- Added CRUD operations for volumes, snapshots and storage pools. +- Added get and rename operation for SDC. +- gatherfacts module is added to list SDCs, SDSs, volumes, snapshots, storage pools, protection domains and snapshot policies. \ No newline at end of file diff --git a/LICENSE b/LICENSE index 261eeb9..e72bfdd 100644 --- a/LICENSE +++ b/LICENSE @@ -1,201 +1,674 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. \ No newline at end of file diff --git a/MODULE-LICENSE b/MODULE-LICENSE new file mode 100644 index 0000000..261eeb9 --- /dev/null +++ b/MODULE-LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/README.md b/README.md index 9ad6631..7fbe9d0 100644 --- a/README.md +++ b/README.md @@ -2,20 +2,23 @@ The Ansible Modules for Dell EMC PowerFlex allow Data Center and IT administrators to use RedHat Ansible to automate and orchestrate the provisioning and management of Dell EMC PowerFlex storage systems. -The capabilities of the Ansible modules are managing SDCs, volumes, snapshots and storage pools; and to gather high level facts from the storage system. The options available for each are list, show, create, modify and delete. These tasks can be executed by running simple playbooks written in yaml syntax. The modules are written so that all the operations are idempotent, so making multiple identical requests has the same effect as making a single request. +The capabilities of the Ansible modules are managing SDCs, volumes, snapshots, storage pools, SDSs and devices; and to gather high level facts from the storage system. The options available are list, show, create, modify and delete. These tasks can be executed by running simple playbooks written in yaml syntax. The modules are written so that all the operations are idempotent, so making multiple identical requests has the same effect as making a single request. + +## License +Ansible collection for PowerFlex is released and licensed under the GPL-3.0 license. See [LICENSE](LICENSE) for the full terms. Ansible modules and modules utilities that are part of the Ansible collection for PowerFlex are released and licensed under the Apache 2.0 license. See [MODULE-LICENSE](MODULE-LICENSE) for the full terms. ## Support -Ansible modules for PowerFlex are supported by Dell EMC and are provided under the terms of the license attached to the source code. Dell EMC does not provide support for any source code modifications. For any Ansible module issues, questions or feedback, join the [Dell EMC Automation community](https://www.dell.com/community/Automation/bd-p/Automation). +Ansible collection for PowerFlex are supported by Dell EMC and are provided under the terms of the license attached to the collection. Please see the [LICENSE](#license) section for the full terms. Dell EMC does not provide any support for the source code modifications. For any Ansible modules issues, questions or feedback, join the [Dell EMC Automation Community](https://www.dell.com/community/Automation/bd-p/Automation). -## Supported Platforms - * Dell EMC PowerFlex (VxFlex OS) version 3.5 ## Prerequisites - * Ansible 2.9 or later - * Python 3.5 or later - * Red Hat Enterprise Linux 7.6, 7.7, 7.8, 8.2 - * PyPowerFlex python library for PowerFlex 1.1.0 +| **Ansible Modules** | **PowerFlex/VxFlex OS Version** | **Red Hat Enterprise Linux**| **SDK version**| **Python version** | **Ansible** | +|---------------------|-----------------------|------------------------------|--------------------|--------------------|-------------| +| v1.1.0 | 3.5,
3.6 |7.8,
8.2 | 1.2.0 | 3.6.x
3.7.x
3.8.x | 2.9
2.10
2.11 | + + * Please follow PyPowerFlex installation instructions on [PyPowerFlex Documentation](https://github.com/dell/python-powerflex) + ## Idempotency The modules are written in such a way that all requests are idempotent and hence fault-tolerant. It essentially means that the result of a successfully performed request is independent of the number of times it is executed. @@ -25,6 +28,8 @@ The modules are written in such a way that all requests are idempotent and hence * SDC module * Storage pool module * Volume module + * SDS module + * Device Module ## Installation of SDK Install python sdk named 'PyPowerFlex'. It can be installed using pip, based on appropriate python version. @@ -37,10 +42,25 @@ Install python sdk named 'PyPowerFlex'. It can be installed using pip, based on pip install . +## Building Collections + * Use the following command to build the collection from source code: + + ansible-galaxy collection build + + For more details on how to build a tar ball, please refer: [Building the collection](https://docs.ansible.com/ansible/latest/dev_guide/developing_collections_distributing.html#building-your-collection-tarball) + ## Installing Collections - * Download the tar build and execute the following command to install the collection anywhere in your system: + +#### Online Installation of Collections + * Use the following command to install the latest collection hosted in [galaxy portal](https://galaxy.ansible.com/dellemc/powerflex): + + ansible-galaxy collection install dellemc.powerflex -p + +#### Offline Installation of Collections + + * Download the latest tar build from any of the available distribution channel [Ansible Galaxy](https://galaxy.ansible.com/dellemc/powerflex) /[Automation Hub](https://console.redhat.com/ansible/automation-hub/repo/published/dellemc/powerflex) and use the following command to install the collection anywhere in your system: - ansible-galaxy collection install dellemc-powerflex-1.0.0.tar.gz -p + ansible-galaxy collection install dellemc-powerflex-1.1.0.tar.gz -p * Set the environment variable: @@ -54,13 +74,18 @@ Install python sdk named 'PyPowerFlex'. It can be installed using pip, based on collections: - dellemc.powerflex + * In order to use installed collection in a specific task use a proper FQCN(Fully Qualified Collection Name). Refer to the following example: + + tasks: + - name: Get Volume details + dellemc.powerflex.dellemc_powerflex_volume * For generating Ansible documentation for a specific module, embed the FQCN before the module name. Refer to the following example: ansible-doc dellemc.powerflex.dellemc_powerflex_gatherfacts ## Running Ansible Modules -The Ansible server must be configured with Python library for PowerFlex to run the Ansible playbooks. The [Documents]( https://github.com/dell/ansible-powerflex/tree/1.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 needs to be configured before running the modules. +The Ansible server must be configured with Python library for PowerFlex to run the Ansible playbooks. The [Documents]( https://github.com/dell/ansible-powerflex/tree/1.1.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 needs to be configured before running the modules. ## SSL Certificate Validation diff --git a/dellemc-powerflex-1.0.0.tar.gz b/dellemc-powerflex-1.0.0.tar.gz deleted file mode 100644 index b0891d84bb271b9e68bd3e85245e2587559ca861..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 45848 zcmV)(K#RX0iwFo>AzNSq|72xsY-Md@EpTslWpZY0Wq2(yE-)@IE_7jX0PMZ{dfP^l zD4xIh6d3w9k(5JGBt>0g`5Rf19i7;+R#cKRpVuD;B$^V&B)|ng$=Yll=)A^xvR_qo zH_!kY;6T@7=)DQFj*Me72+S#M z&y5bWwr@<|xG>$!#?bZ)&C6q^#g}n$a(Mjlq&~9vgah-6X3Lvd%dr z*P0BOZwy?|IEK!RlaEKnIl|*z2#=xNXO7RJzQhmRfjy*wKb#(&oOMpBVxTdAggJei z;qZU{C1yExeLHZyJAC0f2*&>Y#>SN$Tu*wqpbcEvhFI%*xFH*X$JmCl3zplTjF=Oc zav_U!wE?~OyuWLA#Kz_oyWgyA-=ENG!#-|rZ|iciHsJq96UPqjHV!9&JEFO7^sM!< z@*Or5Ayq|~c1NaT511cF2>+>K>$}qrCmrH*eDFbVH>L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H5D!J~a9l+M`|9Z0hrghDAI2Wc+!SZ-HrO0~cr zsiiqhQU<+|HFeyFG+SYouXhH{p!aD|TmO$v!FVL!QOryr)M($U&Iz}0(YD=k>yH#5 z(Pb}n$7;Ti-q)zqGi%LJ*^kiXxGrssc=`10j!O^O#8{~qvwp5xuNZZ&l>= z8)A;(J?iZ2m1Wd$p1}!S*jRzRrYU}1030~i*{%0;nYH~g<8;aG=e7rYa*Z0}Dc~c| zOPkZY&W23ic#Y@TeqF+zf-s$~CYNxN;~~51iF7hycLJUWIle(-Rbjo#n!~NyeED?Q zfENS@J%0R%zVs`p$%nt^6K>{Hv3j?8)O*6i?Ab6EJ>7(mpS!*P02U(ODj}=)jTEx; zMRt|{F3qiu9)m*oa+Qyf9fjE(R$tArWY}{|3LBI z-r0TpP5=8s`oH<;_tRjv_xIj*RAkH5e92^c@$HKI?dRLix1Vo6f61T!4_C?!-T=r2 E0QKhw(f|Me diff --git a/docs/Product Guide.md b/docs/Product Guide.md index fafefb1..efef598 100644 --- a/docs/Product Guide.md +++ b/docs/Product Guide.md @@ -1,813 +1,778 @@ -**Ansible Modules for Dell EMC PowerFlex** -========================================= -### Product Guide 1.0 - -> © 2021 Dell Inc. or its subsidiaries. All rights reserved. Dell -> EMC, and other trademarks are trademarks of Dell Inc. or its -> subsidiaries. Other trademarks may be trademarks of their respective -> owners. - -Contents -------- -- [Common access parameters](#common-access-parameters) - -- [Gatherfacts module](#gatherfacts-module) - - [Synopsis](#synopsis) - - [Parameters](#parameters) - - [Examples](#examples) - - [Return Values](#return-values) - - [Authors](#authors) -- [SDC module](#sdc-module) - - [Synopsis](#synopsis-1) - - [Parameters](#parameters-1) - - [Examples](#examples-1) - - [Return Values](#return-values-1) - - [Authors](#authors-1) -- [Volume module](#volume-module) - - [Synopsis](#synopsis-2) - - [Parameters](#parameters-2) - - [Examples](#examples-2) - - [Return Values](#return-values-2) - - [Authors](#authors-2) -- [Snapshot module](#snapshot-module) - - [Synopsis](#synopsis-3) - - [Parameters](#parameters-3) - - [Examples](#examples-3) - - [Return Values](#return-values-3) - - [Authors](#authors-3) -- [Storage pool module](#storage-pool-module) - - [Synopsis](#synopsis-4) - - [Parameters](#parameters-4) - - [Examples](#examples-4) - - [Return Values](#return-values-4) - - [Authors](#authors-4) - -Common access parameters -================================== -These parameters are applicable to all modules, along with module-specific parameters. - -**NOTE:** If the parameter is mandatory, then required=True else it is an optional parameter. - This is applicable to all the module specific parameters also. - - +# Ansible Modules for Dell EMC PowerFlex +## Product Guide 1.1.0 +© 2021 Dell Inc. or its subsidiaries. All rights reserved. Dell, EMC, and other trademarks are trademarks of Dell Inc. or its subsidiaries. Other trademarks may be trademarks of their respective owners. + +-------------- +## Contents +* [Device Module](#device-module) + * [Synopsis](#synopsis) + * [Parameters](#parameters) + * [Notes](#notes) + * [Examples](#examples) + * [Return Values](#return-values) + * [Authors](#authors) +* [SDC Module](#sdc-module) + * [Synopsis](#synopsis-1) + * [Parameters](#parameters-1) + * [Notes](#notes-1) + * [Examples](#examples-1) + * [Return Values](#return-values-1) + * [Authors](#authors-1) +* [Volume Module](#volume-module) + * [Synopsis](#synopsis-2) + * [Parameters](#parameters-2) + * [Notes](#notes-2) + * [Examples](#examples-2) + * [Return Values](#return-values-2) + * [Authors](#authors-2) +* [SDS Module](#sds-module) + * [Synopsis](#synopsis-3) + * [Parameters](#parameters-3) + * [Notes](#notes-3) + * [Examples](#examples-3) + * [Return Values](#return-values-3) + * [Authors](#authors-3) +* [Gatherfacts Module](#gatherfacts-module) + * [Synopsis](#synopsis-4) + * [Parameters](#parameters-4) + * [Notes](#notes-4) + * [Examples](#examples-4) + * [Return Values](#return-values-4) + * [Authors](#authors-4) +* [Snapshot Module](#snapshot-module) + * [Synopsis](#synopsis-5) + * [Parameters](#parameters-5) + * [Notes](#notes-5) + * [Examples](#examples-5) + * [Return Values](#return-values-5) + * [Authors](#authors-5) +* [Storage Pool Module](#storage-pool-module) + * [Synopsis](#synopsis-6) + * [Parameters](#parameters-6) + * [Notes](#notes-6) + * [Examples](#examples-6) + * [Return Values](#return-values-6) + * [Authors](#authors-6) + +-------------- + +# Device Module + +Manage device on Dell EMC PowerFlex + +### Synopsis + Managing device on PowerFlex storage system includes adding new device, getting details of device, and removing a device. + +### Parameters + +
- - - + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - -
ParameterChoices/DefaultsCommentsParameterTypeRequiredDefaultChoicesDescription
-
- gateway_host - -
- type=string, - required=True
-
- -
IP or FQDN of the PowerFlex gateway host.
-
-
- port - -
- type=integer -
-
- Default:
443
-
-
Port number through which communication happens with PowerFlex gateway host.
-
-
- username - -
- type=string - , required=True
-
- -
The username of the PowerFlex gateway host.
-
-
- password - -
- type=string - , required=True
-
- -
The password of the PowerFlex gateway host.
-
-
- verifycert - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes ←
  • -
-
-
Boolean variable to specify whether or not to validate SSL certificate.
-
True - Indicates that the SSL certificate should be verified.
-
False - Indicates that the SSL certificate should not be verified.
-
-
- - -Gather Facts Module -==================== - -## Synopsis - -- Gathering information about Dell EMC PowerFlex storage system - includes Get the API details of a PowerFlex array, Get list of - volumes in PowerFlex array, Get list of SDSs in a PowerFlex array, - Get list of SDCs in a PowerFlex array, Get list of storage pools in - PowerFlex array, Get list of protection domains in a PowerFlex - array, Get list of snapshot policies in a PowerFlex array. - -## Parameters - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ParameterChoices/DefaultsComments
-
- filters - -
- type=list - , elements=dictionary
-
- -
List of filters to support filtered output for storage entities.
-
Each filter is a list of filter_key, filter_operator, filter_value.
-
Supports passing of multiple filters.
-
-
- filter_key - -
- type=string - , required=True
-
- -
Name identifier of the filter.
-
-
- filter_operator - -
- type=string - , required=True
-
-
    Choices: -
  • equal
  • -
-
-
Operation to be performed on filter key.
-
-
- filter_value - -
- type=string - , required=True
-
- -
Value of the filter key.
-
-
- gather_subset - -
- type=list - , elements=string
-
-
    Choices: -
  • vol
  • -
  • storage_pool
  • -
  • protection_domain
  • -
  • sdc
  • -
  • sds
  • -
  • snapshot_policy
  • -
-
-
List of string variables to specify the Powerflex storage system entities for which information is required.
-
vol
-
storage_pool
-
protection_domain
-
sdc
-
sds
-
snapshot_policy
-
-
- -## Examples - -``` yaml+jinja -- name: Get detailed list of PowerFlex entities. - dellemc_powerflex_gatherfacts: + + current_pathname + str + + + +
Full path of the device to be added.
Required while adding a device. + + + device_name + str + + + +
Device name.
Mutually exclusive with device_id. + + + device_id + str + + + +
Device ID.
Mutually exclusive with device_name. + + + sds_name + str + + + +
The name of the SDS.
Required while adding a device.
Mutually exclusive with sds_id. + + + sds_id + str + + + +
The ID of the SDS.
Required while adding a device.
Mutually exclusive with sds_name. + + + storage_pool_name + str + + + +
Storage Pool name.
Used while adding a storage device.
Mutually exclusive with storage_pool_id, acceleration_pool_id and acceleration_pool_name. + + + storage_pool_id + str + + + +
Storage Pool ID.
Used while adding a storage device.
Media type supported are SSD and HDD.
Mutually exclusive with storage_pool_name, acceleration_pool_id and acceleration_pool_name. + + + acceleration_pool_name + str + + + +
Acceleration Pool Name.
Used while adding an acceleration device.
Media type supported are SSD and NVDIMM.
Mutually exclusive with storage_pool_id, storage_pool_name and acceleration_pool_name. + + + acceleration_pool_id + str + + + +
Acceleration Pool ID.
Used while adding an acceleration device.
Media type supported are SSD and NVDIMM.
Mutually exclusive with acceleration_pool_name, storage_pool_name and storage_pool_id. + + + protection_domain_name + str + + + +
Protection domain name.
Used while identifying a storage pool along with storage_pool_name.
Mutually exclusive with protection_domain_id. + + + protection_domain_id + str + + + +
Protection domain ID.
Used while identifying a storage pool along with storage_pool_name.
Mutually exclusive with protection_domain_name. + + + external_acceleration_type + str + + +
  • Invalid
  • None
  • Read
  • Write
  • ReadAndWrite
+
Device external acceleration types.
Used while adding a device. + + + media_type + str + + +
  • HDD
  • SSD
  • NVDIMM
+
Device media types.
Required while adding a device. + + + state + str + True + +
  • present
  • absent
+
State of the device. + + + gateway_host + str + True + + +
IP or FQDN of the PowerFlex gateway host. + + + username + str + True + + +
The username of the PowerFlex gateway host. + + + password + str + True + + +
The password of the PowerFlex gateway host. + + + verifycert + bool + + True +
  • True
  • False
+
Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified. + + + port + int + + 443 + +
Port number through which communication happens with PowerFlex gateway host. + + + +### Notes +* The value for device_id is generated only after successful addition of the device. +* Unique ways to identify a device - (current_pathname , sds_id) or (current_pathname , sds_name) or (device_name , sds_name) or (device_name , sds_id) or device_id. +* It is recommended to install Rfcache driver for SSD device on SDS in order to add it to an acceleration pool. +* The check_mode is not supported. + +### Examples +``` +- name: Add a device + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node1" + media_type: "HDD" + device_name: "device2" + storage_pool_name: "pool1" + protection_domain_name: "domain1" + external_acceleration_type: "ReadAndWrite" + state: "present" +- name: Get device details using device_id + dellemc.powerflex.dellemc_powerflex_device: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" - gather_subset: - - vol - - storage_pool - - protection_domain - - sdc - - sds - - snapshot_policy - -- name: Get a subset list of PowerFlex volumes. - dellemc_powerflex_gatherfacts: + port: "{{port}}" + device_id: "d7fe088900000000" + state: "present" +- name: Get device details using (current_pathname, sds_name) + dellemc.powerflex.dellemc_powerflex_device: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" - gather_subset: - - vol - filters: - - filter_key: "name" - filter_operator: "equal" - filter_value: "ansible_test" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node0" + state: "present" +- name: Get device details using (current_pathname, sds_id) + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_id: "5717d71800000000" + state: "present" +- name: Remove a device using device_id + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + device_id: "76eb7e2f00010000" + state: "absent" +- name: Remove a device using (current_pathname, sds_id) + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node1" + state: "absent" ``` -## Return Values - - +### Return Values + +
- + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
KeyKeyType Returned Description
-
- API_Version - -
- type=string -
-
always -
API version of PowerFlex API Gateway.
-
-
-
- Array_Details - -
- type=list - , elements=string
-
always -
System entities of PowerFlex storage array.
-
-
  -
- id - -
- type=string -
-
success -
The ID of the system
-
-
  -
- installId - -
- type=string -
-
success -
installation Id
-
-
  -
- mdmSecurityPolicy - -
- type=string -
-
success -
mdm security policy
-
-
  -
- systemVersionName - -
- type=string -
-
success -
system version and name
-
-
-
- changed - -
- type=boolean -
-
always -
Whether or not the resource has changed
-
-
-
- Protection_Domains - -
- complex -
-
always -
Details of all protection domains
-
-
  -
- id - -
- type=string -
-
success -
protection domain id
-
-
  -
- name - -
- type=string -
-
success -
protection domain name
-
-
-
- SDCs - -
- complex -
-
always -
Details of storage data clients
-
-
  -
- id - -
- type=string -
-
success -
storage data client id
-
-
  -
- name - -
- type=string -
-
success -
storage data client name
-
-
-
- SDSs - -
- complex -
-
always -
Details of storage data servers
-
-
  -
- id - -
- type=string -
-
success -
storage data server id
-
-
  -
- name - -
- type=string -
-
success -
storage data server name
-
-
-
- Snapshot_Policies - -
- complex -
-
always -
Details of snapshot policies
-
-
  -
- id - -
- type=string -
-
success -
snapshot policy id
-
-
  -
- name - -
- type=string -
-
success -
snapshot policy name
-
-
-
- Storage_Pools - -
- complex -
-
always -
Details of storage pools
-
-
  -
- id - -
- type=string -
-
success -
storage pool id
-
-
  -
- name - -
- type=string -
-
success -
storage pool name
-
-
-
- Volumes - -
- complex -
-
always -
Details of volumes
-
-
  -
- id - -
- type=string -
-
success -
volume id
-
-
  -
- name - -
- type=string -
-
success -
volume name
-
-
-

+ + changed + bool + always + Whether or not the resource has changed. + + + device_details + complex + When device exists + Details of the device. + + +   + accelerationPoolId + str + success + Acceleration pool ID. + + +   + accelerationPoolName + str + success + Acceleration pool name. + + +   + accelerationProps + str + success + Indicates acceleration props. + + +   + aggregatedState + str + success + Indicates aggregated state. + + +   + ataSecurityActive + bool + success + Indicates ATA security active state. + + +   + autoDetectMediaType + str + success + Indicates auto detection of media type. + + +   + cacheLookAheadActive + bool + success + Indicates cache look ahead active state. + + +   + capacity + int + success + Device capacity. + + +   + capacityLimitInKb + int + success + Device capacity limit in KB. + + +   + deviceCurrentPathName + str + success + Device current path name. + + +   + deviceOriginalPathName + str + success + Device original path name. + + +   + deviceState + str + success + Indicates device state. + + +   + deviceType + str + success + Indicates device type. + + +   + errorState + str + success + Indicates error state. + + +   + externalAccelerationType + str + success + Indicates external acceleration type. + + +   + fglNvdimmMetadataAmortizationX100 + int + success + Indicates FGL NVDIMM meta data amortization value. + + +   + fglNvdimmWriteCacheSize + int + success + Indicates FGL NVDIMM write cache size. + + +   + firmwareVersion + str + success + Indicates firmware version. + + +   + id + str + success + Device ID. + + +   + ledSetting + str + success + Indicates LED setting. + + +   + links + list + success + Device links. + + +   +   + href + str + success + Device instance URL. + + +   +   + rel + str + success + Relationship of device with different entities. + + +   + logicalSectorSizeInBytes + int + success + Logical sector size in bytes. + + +   + longSuccessfulIos + list + success + Indicates long successful IOs. + + +   + maxCapacityInKb + int + success + Maximum device capacity limit in KB. + + +   + mediaFailing + bool + success + Indicates media failing. + + +   + mediaType + str + success + Indicates media type. + + +   + modelName + str + success + Indicates model name. + + +   + name + str + success + Device name. + + +   + persistentChecksumState + str + success + Indicates persistent checksum state. + + +   + physicalSectorSizeInBytes + int + success + Physical sector size in bytes. + + +   + protectionDomainId + str + success + Protection domain ID. + + +   + protectionDomainName + str + success + Protection domain name. + + +   + raidControllerSerialNumber + str + success + RAID controller serial number. + + +   + rfcacheErrorDeviceDoesNotExist + bool + success + Indicates RF cache error device does not exist. + + +   + rfcacheProps + str + success + RF cache props. + + +   + sdsId + str + success + SDS ID. + + +   + sdsName + str + success + SDS name. + + +   + serialNumber + str + success + Indicates Serial number. + + +   + spSdsId + str + success + Indicates SPs SDS ID. + + +   + ssdEndOfLifeState + str + success + Indicates SSD end of life state. + + +   + storagePoolId + str + success + Storage Pool ID. + + +   + storagePoolName + str + success + Storage Pool name. + + +   + storageProps + list + success + Storage props. + + +   + temperatureState + str + success + Indicates temperature state. + + +   + vendorName + str + success + Indicates vendor name. + + +   + writeCacheActive + bool + success + Indicates write cache active. + + ### Authors +* Rajshree Khare (@khareRajshree) -- Arindam Datta (@dattaarindam) <> - +-------------------------------- +# SDC Module -SDC Module -============================================== +Manage SDCs on Dell EMC PowerFlex -## Synopsis +### Synopsis + Managing SDCs on PowerFlex storage system includes getting details of SDC and renaming SDC. -- Managing SDC's on PowerFlex storage system includes getting details - of SDC and renaming SDC. - -## Parameters - - +### Parameters + +
- - - + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - -
ParameterChoices/DefaultsCommentsParameterTypeRequiredDefaultChoicesDescription
-
- sdc_id - -
- type=string -
-
- -
ID of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
-
Mutually exclusive with sdc_name and sdc_ip.
-
-
- sdc_ip - -
- type=string -
-
- -
IP of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
-
Mutually exclusive with sdc_id and sdc_name.
-
-
- sdc_name - -
- type=string -
-
- -
Name of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
-
Mutually exclusive with sdc_id and sdc_ip.
-
-
- sdc_new_name - -
- type=string -
-
- -
New name of the SDC. Used to rename the SDC.
-
-
- state - -
- type=string - , required=True
-
-
    Choices: -
  • present
  • -
  • absent
  • -
-
-
State of the storage pool.
-
-
- -## Examples - -``` yaml+jinja + + sdc_name + str + + + +
Name of the SDC.
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
Mutually exclusive with sdc_id and sdc_ip. + + + sdc_id + str + + + +
ID of the SDC.
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
Mutually exclusive with sdc_name and sdc_ip. + + + sdc_ip + str + + + +
IP of the SDC.
Specify either sdc_name, sdc_id or sdc_ip for get/rename operation.
Mutually exclusive with sdc_id and sdc_name. + + + sdc_new_name + str + + + +
New name of the SDC. Used to rename the SDC. + + + state + str + True + +
  • present
  • absent
+
State of the SDC. + + + gateway_host + str + True + + +
IP or FQDN of the PowerFlex gateway host. + + + username + str + True + + +
The username of the PowerFlex gateway host. + + + password + str + True + + +
The password of the PowerFlex gateway host. + + + verifycert + bool + + True +
  • True
  • False
+
Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified. + + + port + int + + 443 + +
Port number through which communication happens with PowerFlex gateway host. + + + +### Notes +* The check_mode is not supported. + +### Examples +``` - name: Get SDC details using SDC ip - dellemc_powerflex_sdc: + dellemc.powerflex.dellemc_powerflex_sdc: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -816,7 +781,7 @@ SDC Module state: "present" - name: Rename SDC using SDC name - dellemc_powerflex_sdc: + dellemc.powerflex.dellemc_powerflex_sdc: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -826,696 +791,380 @@ SDC Module state: "present" ``` -## Return Values - - - +### Return Values + +
- + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
KeyKeyType Returned Description
-
- changed - -
- type=boolean -
-
always -
Whether or not the resource has changed
-
-
-
- sdc_details - -
- complex -
-
When SDC exists -
Details of the SDC
-
-
  -
- id - -
- type=string -
-
success -
The ID of the SDC
-
-
  -
- mapped_volumes - -
- type=list - , elements=string
-
success -
The details of the mapped volumes
-
-
   -
- id - -
- type=string -
-
success -
The ID of the volume
-
-
   -
- name - -
- type=string -
-
success -
The name of the volume
-
-
   -
- volumeType - -
- type=string -
-
success -
Type of the volume
-
-
  -
- name - -
- type=string -
-
success -
Name of the SDC
-
-
  -
- osType - -
- type=string -
-
success -
OS type of the SDC
-
-
  -
- sdcApproved - -
- type=boolean -
-
success -
Indicates whether an SDC has approved access to the system
-
-
  -
- sdcIp - -
- type=string -
-
success -
IP of the SDC
-
-
-

+ + changed + bool + always + Whether or not the resource has changed. + + + sdc_details + complex + When SDC exists + Details of the SDC. + + +   + id + str + success + The ID of the SDC. + + +   + mapped_volumes + list + success + The details of the mapped volumes. + + +   +   + id + str + success + The ID of the volume. + + +   +   + name + str + success + The name of the volume. + + +   +   + volumeType + str + success + Type of the volume. + + +   + name + str + success + Name of the SDC. + + +   + osType + str + success + OS type of the SDC. + + +   + sdcApproved + bool + success + Indicates whether an SDC has approved access to the system. + + +   + sdcIp + str + success + IP of the SDC. + + ### Authors +* Akash Shendge (@shenda1) -- Akash Shendge (@shenda1) <> +-------------------------------- +# Volume Module +Manage volumes on Dell EMC PowerFlex -Volume Module -========================================== +### Synopsis + Managing volumes on PowerFlex storage system includes creating new volume, getting details of volume, adding/removing snapshot policy to/from volume, mapping/unmapping volume to/from SDC, listing snapshots associated with a volume, modifying attributes of volume and deleting volume. -## Synopsis - -- Managing volumes on PowerFlex storage system includes creating new - volume, getting details of volume, adding/removing snapshot policy - to/from volume, mapping/unmapping volume to/from SDC, listing - snapshots associated with a volume, modifying attributes of volume - and deleting volume. - -## Parameters - - +### Parameters + +
- - - + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ParameterChoices/DefaultsCommentsParameterTypeRequiredDefaultChoicesDescription
-
- allow_multiple_mappings - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Specifies whether to allow multiple mappings or not.
-
If the volume is mapped to one SDC then for every new mapping allow_multiple_mappings has to be passed as True.
-
-
- auto_snap_remove_type - -
- type=string -
-
-
    Choices: -
  • remove
  • -
  • detach
  • -
-
-
Whether to remove or detach the snapshot policy.
-
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type.
-
If the snapshot policy name/id is passed empty then auto_snap_remove_type is defaulted to 'detach'.
-
-
- cap_unit - -
- type=string -
-
-
    Choices: -
  • GB
  • -
  • TB
  • -
-
-
The unit of the volume size. It defaults to 'GB'.
-
-
- compression_type - -
- type=string -
-
-
    Choices: -
  • NORMAL
  • -
  • NONE
  • -
-
-
Type of the compression method.
-
-
- delete_snapshots - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
If True, the volume and all its dependent snapshots will be deleted.
-
If False, only the volume will be deleted.
-
delete_snapshots parameter can be specified only when the state is absent.
-
delete_snapshots defaults to False.
-
-
- protection_domain_id - -
- type=string -
-
- -
The id of the protection domain.
-
While creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be mentioned along with it.
-
protection_domain_name and protection_domain_id are mutually exclusive parameters.
-
-
- protection_domain_name - -
- type=string -
-
- -
The name of the protection domain.
-
While creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be mentioned along with it.
-
protection_domain_name and protection_domain_name are mutually exclusive parameters.
-
-
- sdc - -
- type=list - , elements=dictionary
-
- -
Specifies SDC parameters
-
-
- access_mode - -
- type=string -
-
-
    Choices: -
  • READ_WRITE
  • -
  • READ_ONLY
  • -
  • NO_ACCESS
  • -
-
-
Define the access mode for all mappings of the volume.
-
-
- bandwidth_limit - -
- type=integer -
-
- -
Limit of volume network bandwidth.
-
Need to mention in multiple of 1024 Kbps.
-
To set no limit, 0 is to be passed.
-
-
- iops_limit - -
- type=integer -
-
- -
Limit of volume IOPS.
-
Minimum IOPS limit is 11 and specify 0 for unlimited iops.
-
-
- sdc_id - -
- type=string -
-
- -
ID of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_name and sdc_ip.
-
-
- sdc_ip - -
- type=string -
-
- -
IP of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_id and sdc_ip.
-
-
- sdc_name - -
- type=string -
-
- -
Name of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_id and sdc_ip.
-
-
- sdc_state - -
- type=string -
-
-
    Choices: -
  • mapped
  • -
  • unmapped
  • -
-
-
Mapping state of the SDC.
-
-
- size - -
- type=integer -
-
- -
The size of the volume.
-
Size of the volume will be assigned as higher multiple of 8 GB.
-
-
- snapshot_policy_id - -
- type=string -
-
- -
ID of the snapshot policy.
-
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type.
-
-
- snapshot_policy_name - -
- type=string -
-
- -
Name of the snapshot policy.
-
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type.
-
-
- state - -
- type=string - , required=True
-
-
    Choices: -
  • present
  • -
  • absent
  • -
-
-
State of the volume.
-
-
- storage_pool_id - -
- type=string -
-
- -
The id of the storage pool.
-
Either name or the id of the storage pool is required for creating a volume.
-
storage_pool_name and storage_pool_id are mutually exclusive parameters.
-
-
- storage_pool_name - -
- type=string -
-
- -
The name of the storage pool.
-
Either name or the id of the storage pool is required for creating a volume.
-
During creation, If storage pool name is provided then either protection domain name or id must be mentioned along with it.
-
storage_pool_name and storage_pool_id are mutually exclusive parameters.
-
-
- use_rmcache - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Whether to use RM Cache or not.
-
-
- vol_id - -
- type=string -
-
- -
The ID of the volume.
-
Except create operation, all other operations can be performed using vol_id.
-
vol_name and vol_id are mutually exclusive parameters.
-
-
- vol_name - -
- type=string -
-
- -
The name of the volume.
-
Mandatory for create operation.
-
vol_name is unique across the PowerFlex array.
-
vol_name and vol_id are mutually exclusive parameters.
-
-
- vol_new_name - -
- type=string -
-
- -
New name of the volume. Used to rename the volume.
-
-
- vol_type - -
- type=string -
-
-
    Choices: -
  • THICK_PROVISIONED
  • -
  • THIN_PROVISIONED
  • -
-
-
The type of volume provisioning.
-
-
- -## Examples - -``` yaml+jinja + + vol_name + str + + + +
The name of the volume.
Mandatory for create operation.
It is unique across the PowerFlex array.
Mutually exclusive with vol_id. + + + vol_id + str + + + +
The ID of the volume.
Except create operation, all other operations can be performed using vol_id.
Mutually exclusive with vol_id. + + + storage_pool_name + str + + + +
The name of the storage pool.
Either name or the id of the storage pool is required for creating a volume.
During creation, if storage pool name is provided then either protection domain name or id must be mentioned along with it.
Mutually exclusive with storage_pool_id. + + + storage_pool_id + str + + + +
The ID of the storage pool.
Either name or the id of the storage pool is required for creating a volume.
Mutually exclusive with storage_pool_name. + + + protection_domain_name + str + + + +
The name of the protection domain.
During creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be mentioned along with it.
Mutually exclusive with protection_domain_id. + + + protection_domain_id + str + + + +
The ID of the protection domain.
During creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be mentioned along with it.
Mutually exclusive with protection_domain_name. + + + vol_type + str + + +
  • THICK_PROVISIONED
  • THIN_PROVISIONED
+
Type of volume provisioning. + + + compression_type + str + + +
  • NORMAL
  • NONE
+
Type of the compression method. + + + use_rmcache + bool + + + +
Whether to use RM Cache or not. + + + snapshot_policy_name + str + + + +
Name of the snapshot policy.
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type. + + + snapshot_policy_id + str + + + +
ID of the snapshot policy.
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type. + + + auto_snap_remove_type + str + + +
  • remove
  • detach
+
Whether to remove or detach the snapshot policy.
To remove/detach snapshot policy, empty snapshot_policy_id/snapshot_policy_name is to be passed along with auto_snap_remove_type.
If the snapshot policy name/id is passed empty then auto_snap_remove_type is defaulted to 'detach'. + + + size + int + + + +
The size of the volume.
Size of the volume will be assigned as higher multiple of 8 GB. + + + cap_unit + str + + +
  • GB
  • TB
+
The unit of the volume size. It defaults to 'GB'. + + + vol_new_name + str + + + +
New name of the volume. Used to rename the volume. + + + allow_multiple_mappings + bool + + + +
Specifies whether to allow multiple mappings or not.
If the volume is mapped to one SDC then for every new mapping allow_multiple_mappings has to be passed as True. + + + sdc + list
elements: dict + + + +
Specifies SDC parameters. + + +   + sdc_name + str + + + +
Name of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_id and sdc_ip. + + +   + sdc_id + str + + + +
ID of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_name and sdc_ip. + + +   + sdc_ip + str + + + +
IP of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_id and sdc_ip. + + +   + access_mode + str + + +
  • READ_WRITE
  • READ_ONLY
  • NO_ACCESS
+
Define the access mode for all mappings of the volume. + + +   + bandwidth_limit + int + + + +
Limit of volume network bandwidth.
Need to mention in multiple of 1024 Kbps.
To set no limit, 0 is to be passed. + + +   + iops_limit + int + + + +
Limit of volume IOPS.
Minimum IOPS limit is 11 and specify 0 for unlimited iops. + + + sdc_state + str + + +
  • mapped
  • unmapped
+
Mapping state of the SDC. + + + delete_snapshots + bool + + + +
If True, the volume and all its dependent snapshots will be deleted.
If False, only the volume will be deleted.
It can be specified only when the state is absent.
It defaults to False, if not specified. + + + state + str + True + +
  • present
  • absent
+
State of the volume. + + + gateway_host + str + True + + +
IP or FQDN of the PowerFlex gateway host. + + + username + str + True + + +
The username of the PowerFlex gateway host. + + + password + str + True + + +
The password of the PowerFlex gateway host. + + + verifycert + bool + + True +
  • True
  • False
+
Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified. + + + port + int + + 443 + +
Port number through which communication happens with PowerFlex gateway host. + + + +### Notes +* The check_mode is not supported. + +### Examples +``` - name: Create a volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1531,7 +1180,7 @@ Volume Module state: "present" - name: Map a SDC to volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1546,7 +1195,7 @@ Volume Module state: "present" - name: Unmap a SDC to volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1559,7 +1208,7 @@ Volume Module state: "present" - name: Map multiple SDCs to a volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1572,14 +1221,14 @@ Volume Module access_mode: "READ_WRITE" bandwidth_limit: 2048 iops_limit: 20 - - sdc_ip: "127.0.0.1" + - sdc_ip: "198.10.xxx.xxx" access_mode: "READ_ONLY" allow_multiple_mappings: True sdc_state: "mapped" state: "present" - name: Get the details of the volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1589,7 +1238,7 @@ Volume Module state: "present" - name: Modify the details of the Volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1602,7 +1251,7 @@ Volume Module state: "present" - name: Delete the Volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1613,7 +1262,7 @@ Volume Module state: "absent" - name: Delete the Volume and all its dependent snapshots - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -1624,740 +1273,1553 @@ Volume Module state: "absent" ``` -## Return Values - - +### Return Values + +
- + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
KeyKeyType Returned Description
-
- changed - -
- type=boolean -
-
always -
Whether or not the resource has changed
-
-
-
- volume_details - -
- complex -
-
When volume exists -
Details of the volume
-
-
  -
- id - -
- type=string -
-
success -
The ID of the volume.
-
-
  -
- mappedSdcInfo - -
- complex -
-
success -
The details of the mapped SDC
-
-
   -
- accessMode - -
- type=string -
-
success -
mapping access mode for the specified volume
-
-
   -
- limitBwInMbps - -
- type=integer -
-
success -
Bandwidth limit for the SDC
-
-
   -
- limitIops - -
- type=integer -
-
success -
IOPS limit for the SDC
-
-
   -
- sdcId - -
- type=string -
-
success -
ID of the SDC
-
-
   -
- sdcIp - -
- type=string -
-
success -
IP of the SDC
-
-
   -
- sdcName - -
- type=string -
-
success -
Name of the SDC
-
-
  -
- name - -
- type=string -
-
success -
Name of the volume
-
-
  -
- protectionDomainId - -
- type=string -
-
success -
ID of the protection domain in which volume resides.
-
-
  -
- protectionDomainName - -
- type=string -
-
success -
Name of the protection domain in which volume resides.
-
-
  -
- sizeInGb - -
- type=integer -
-
success -
Size of the volume in Gb.
-
-
  -
- sizeInKb - -
- type=integer -
-
success -
Size of the volume in Kb.
-
-
  -
- snapshotPolicyId - -
- type=string -
-
success -
ID of the snapshot policy associated with volume.
-
-
  -
- snapshotPolicyName - -
- type=string -
-
success -
Name of the snapshot policy associated with volume.
-
-
  -
- snapshotsList - -
- type=string -
-
success -
List of snapshots associated with the volume.
-
-
  -
- storagePoolId - -
- type=string -
-
success -
ID of the storage pool in which volume resides.
-
-
  -
- storagePoolName - -
- type=string -
-
success -
Name of the storage pool in which volume resides.
-
-
-

+ + changed + bool + always + Whether or not the resource has changed. + + + volume_details + complex + When volume exists + Details of the volume. + + +   + id + str + success + The ID of the volume. + + +   + mappedSdcInfo + complex + success + The details of the mapped SDC. + + +   +   + accessMode + str + success + mapping access mode for the specified volume. + + +   +   + limitBwInMbps + int + success + Bandwidth limit for the SDC. + + +   +   + limitIops + int + success + IOPS limit for the SDC. + + +   +   + sdcId + str + success + ID of the SDC. + + +   +   + sdcIp + str + success + IP of the SDC. + + +   +   + sdcName + str + success + Name of the SDC. + + +   + name + str + success + Name of the volume. + + +   + protectionDomainId + str + success + ID of the protection domain in which volume resides. + + +   + protectionDomainName + str + success + Name of the protection domain in which volume resides. + + +   + sizeInGb + int + success + Size of the volume in Gb. + + +   + sizeInKb + int + success + Size of the volume in Kb. + + +   + snapshotPolicyId + str + success + ID of the snapshot policy associated with volume. + + +   + snapshotPolicyName + str + success + Name of the snapshot policy associated with volume. + + +   + snapshotsList + str + success + List of snapshots associated with the volume. + + +   + storagePoolId + str + success + ID of the storage pool in which volume resides. + + +   + storagePoolName + str + success + Name of the storage pool in which volume resides. + + ### Authors +* P Srinivas Rao (@srinivas-rao5) -- P Srinivas Rao (@srinivas-rao5) <> +-------------------------------- +# SDS Module -# Snapshot Module +Manage SDS on Dell EMC PowerFlex + +### Synopsis + Managing SDS on PowerFlex storage system includes creating new SDS, getting details of SDS, adding/removing IP to/from SDS, modifying attributes of SDS, and deleting SDS. + +### Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeRequiredDefaultChoicesDescription
sds_name str
The name of the SDS.
Mandatory for create operation.
It is unique across the PowerFlex array.
Mutually exclusive with sds_id.
sds_id str
The ID of the SDS.
Except create operation, all other operations can be performed using sds_id.
Mutually exclusive with sds_name.
protection_domain_name str
The name of the protection domain.
Mutually exclusive with protection_domain_id.
protection_domain_id str
The ID of the protection domain.
Mutually exclusive with protection_domain_name.
sds_ip_list list
elements: dict

Dictionary of IPs and their roles for the SDS.
At least one IP-role is mandatory while creating a SDS.
IP-roles can be updated as well.
  ip str True
IP address of the SDS.
  role str True
  • sdsOnly
  • sdcOnly
  • all

Role assigned to the SDS IP address.
sds_ip_state str
  • present-in-sds
  • absent-in-sds

State of IP with respect to the SDS.
rfcache_enabled bool
Whether to enable the Read Flash cache.
rmcache_enabled bool
Whether to enable the Read RAM cache.
rmcache_size int
Read RAM cache size (in MB).
Minimum size is 128 MB.
Maximum size is 3911 MB.
sds_new_name str
SDS new name.
performance_profile str
  • Compact
  • HighPerformance

Performance profile to apply to the SDS.
The HighPerformance profile configures a predefined set of parameters for very high performance use cases.
Default value by API is "HighPerformance".
state str True
  • present
  • absent

State of the SDS.
gateway_host str True
IP or FQDN of the PowerFlex gateway host.
username str True
The username of the PowerFlex gateway host.
password str True
The password of the PowerFlex gateway host.
verifycert bool True
  • True
  • False

Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified.
port int 443
Port number through which communication happens with PowerFlex gateway host.
+ +### Notes +* The maximum limit for the IPs that can be associated with an SDS is 8. +* There needs to be at least 1 IP for SDS communication and 1 for SDC communication(if only 1 IP exists, it must be with role 'all'; else 1 IP can be with role 'all'and other IPs with role 'sdcOnly'; or 1 IP must be with role 'sdsOnly' and others with role 'sdcOnly'). +* There can be 1 or more IPs with role 'sdcOnly'. +* There must be only 1 IP with SDS role (either with role 'all' or 'sdsOnly'). +* SDS can be created with RF cache disabled, but, be aware that the RF cache is not always updated. In this case, the user should re-try the operation. +* The check_mode is not supported. + +### Examples +``` +- name: Create SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + protection_domain_name: "domain1" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "all" + sds_ip_state: "present-in-sds" + state: "present" + +- name: Create SDS with all parameters + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node1" + protection_domain_name: "domain1" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "present-in-sds" + rmcache_enabled: true + rmcache_size: 128 + performance_profile: "HighPerformance" + state: "present" + +- name: Get SDS details using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + state: "present" + +- name: Get SDS details using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + state: "present" -## Synopsis +- name: Modify SDS attributes using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_new_name: "node0_new" + rfcache_enabled: true + rmcache_enabled: true + rmcache_size: 256 + performance_profile: "HighPerformance" + state: "present" -- Managing snapshots on PowerFlex Storage System includes creating new - snapshot, getting details of snapshot, mapping/unmapping snapshot - to/from SDC, modifying attributes of snapshot and deleting snapshot. +- name: Modify SDS attributes using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + sds_new_name: "node0_new" + rfcache_enabled: true + rmcache_enabled: true + rmcache_size: 256 + performance_profile: "HighPerformance" + state: "present" -## Parameters +- name: Add IP and role to an SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "present-in-sds" + state: "present" - +- name: Remove IP and role from an SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "absent-in-sds" + state: "present" + +- name: Delete SDS using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + state: "absent" + +- name: Delete SDS using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + state: "absent" +``` + +### Return Values + +
- - - + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterChoices/DefaultsCommentsKeyTypeReturnedDescription
-
- allow_multiple_mappings - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Specifies whether to allow multiple mappings or not.
-
-
- cap_unit - -
- type=string -
-
-
    Choices: -
  • GB
  • -
  • TB
  • -
-
-
The unit of the volume size. It defaults to 'GB', if not specified.
-
-
- desired_retention - -
- type=integer -
-
- -
The retention value for the Snapshot.
-
If the desired_retention is not mentioned during creation, snapshot will be created with unlimited retention.
-
Maximum supported desired retention is 31 days.
-
-
- read_only - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Specifies whether mapping of the created snapshot volume will have read-write access or limited to read-only access.
-
If true, snapshot is created with read-only access.
-
If false, snapshot is created with read-write access.
-
-
- remove_mode - -
- type=string -
-
-
    Choices: -
  • ONLY_ME
  • -
  • INCLUDING_DESCENDANTS
  • -
-
-
Removal mode for the snapshot.
-
It defaults to 'ONLY_ME', if not specified.
-
-
- retention_unit - -
- type=string -
-
-
    Choices: -
  • hours
  • -
  • days
  • -
-
-
The unit for retention. It defaults to 'hours', if not specified.
-
-
- sdc - -
- type=list - , elements=dictionary
-
- -
Specifies SDC parameters
-
-
- access_mode - -
- type=string -
-
-
    Choices: -
  • READ_WRITE
  • -
  • READ_ONLY
  • -
  • NO_ACCESS
  • -
-
-
Define the access mode for all mappings of the snapshot.
-
-
- bandwidth_limit - -
- type=integer -
-
- -
Limit of snapshot network bandwidth.
-
Need to mention in multiple of 1024 Kbps.
-
To set no limit, 0 is to be passed.
-
-
- iops_limit - -
- type=integer -
-
- -
Limit of snapshot IOPS.
-
Minimum IOPS limit is 11 and specify 0 for unlimited iops.
-
-
- sdc_id - -
- type=string -
-
- -
ID of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_name and sdc_ip.
-
-
- sdc_ip - -
- type=string -
-
- -
IP of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_id and sdc_ip.
-
-
- sdc_name - -
- type=string -
-
- -
Name of the SDC.
-
Specify either sdc_name, sdc_id or sdc_ip.
-
Mutually exclusive with sdc_id and sdc_ip.
-
-
- sdc_state - -
- type=string -
-
-
    Choices: -
  • mapped
  • -
  • unmapped
  • -
-
-
Mapping state of the SDC.
-
-
- size - -
- type=integer -
-
- -
The size of the snapshot.
-
-
- snapshot_id - -
- type=string -
-
- -
The ID of the Snapshot.
-
-
- snapshot_name - -
- type=string -
-
- -
The name of the snapshot.
-
Mandatory for create operation.
-
Specify either snapshot name or ID (but not both) for any operation.
-
-
- snapshot_new_name - -
- type=string -
-
- -
New name of the snapshot. Used to rename the snapshot.
-
-
- state - -
- type=string - , required=True
-
-
    Choices: -
  • present
  • -
  • absent
  • -
-
-
State of the snapshot.
-
-
- vol_id - -
- type=string -
-
- -
The ID of the volume.
-
-
- vol_name - -
- type=string -
-
- -
The name of the volume for which snapshot will be taken.
-
Specify either vol_name or vol_id while creating snapshot.
-
changed bool always Whether or not the resource has changed.
sds_details complex When SDS exists Details of the SDS.
  authenticationError str success Indicates authentication error.
  certificateInfo str success Information about certificate.
  configuredDrlMode str success Configured DRL mode.
  drlMode str success DRL mode.
  faultSetId str success Fault set ID.
  fglMetadataCacheSize int success FGL metadata cache size.
  fglMetadataCacheState str success FGL metadata cache state.
  fglNumConcurrentWrites int success FGL concurrent writes.
  id str success SDS ID.
  ipList list success SDS IP list.
   ip str success IP present in the SDS.
   role str success Role of the SDS IP.
  lastUpgradeTime str success Last time SDS was upgraded.
  links list success SDS links.
   href str success SDS instance URL.
   rel str success SDS's relationship with different entities.
  maintenanceState str success Maintenance state.
  maintenanceType str success Maintenance type.
  mdmConnectionState str success MDM connection state.
  membershipState str success Membership state.
  name str success Name of the SDS.
  numOfIoBuffers int success Number of IO buffers.
  numRestarts int success Number of restarts.
  onVmWare bool success Presence on VMware.
  perfProfile str success Performance profile.
  port int success SDS port.
  protectionDomainId str success Protection Domain ID.
  protectionDomainName str success Protection Domain Name.
  raidControllers int success Number of RAID controllers.
  rfcacheEnabled bool success Whether RF cache is enabled or not.
  rfcacheErrorApiVersionMismatch bool success RF cache error for API version mismatch.
  rfcacheErrorDeviceDoesNotExist bool success RF cache error for device does not exist.
  rfcacheErrorInconsistentCacheConfiguration bool success RF cache error for inconsistent cache configuration.
  rfcacheErrorInconsistentSourceConfiguration bool success RF cache error for inconsistent source configuration.
  rfcacheErrorInvalidDriverPath bool success RF cache error for invalid driver path.
  rfcacheErrorLowResources bool success RF cache error for low resources.
  rmcacheEnabled bool success Whether Read RAM cache is enabled or not.
  rmcacheFrozen bool success RM cache frozen.
  rmcacheMemoryAllocationState bool success RM cache memory allocation state.
  rmcacheSizeInKb int success RM cache size in KB.
  rmcacheSizeInMb int success RM cache size in MB.
  sdsConfigurationFailure str success SDS configuration failure.
  sdsDecoupled str success SDS decoupled.
  sdsReceiveBufferAllocationFailures str success SDS receive buffer allocation failures.
  sdsState str success SDS state.
  softwareVersionInfo str success SDS software version information.
+ +### Authors +* Rajshree Khare (@khareRajshree) + +-------------------------------- +# Gatherfacts Module + +Gathering information about Dell EMC PowerFlex + +### Synopsis + Gathering information about Dell EMC PowerFlex storage system includes get the api details of a PowerFlex array, get list of volumes in PowerFlex array, get list of SDSs in a PowerFlex array, get list of SDCs in a PowerFlex array, get list of storage pools in PowerFlex array, get list of protection domains in a PowerFlex array, get list of snapshot policies in a PowerFlex array, and get list of devices in a PowerFlex array. + +### Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeRequiredDefaultChoicesDescription
gather_subset list
elements: str
  • vol
  • storage_pool
  • protection_domain
  • sdc
  • sds
  • snapshot_policy
  • device

List of string variables to specify the Powerflex storage system entities for which information is required.
Volumes - vol.
Storage pools - storage_pool.
Protection domains - protection_domain.
SDCs - sdc.
SDSs - sds.
Snapshot policies - snapshot_policy.
Devices - device.
filters list
elements: dict

List of filters to support filtered output for storage entities.
Each filter is a list of filter_key, filter_operator, filter_value.
Supports passing of multiple filters.
  filter_key str True
Name identifier of the filter.
  filter_operator str True
  • equal

Operation to be performed on filter key.
  filter_value str True
Value of the filter key.
gateway_host str True
IP or FQDN of the PowerFlex gateway host.
username str True
The username of the PowerFlex gateway host.
password str True
The password of the PowerFlex gateway host.
verifycert bool True
  • True
  • False

Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified.
port int 443
Port number through which communication happens with PowerFlex gateway host.
+ +### Notes +* The check_mode is not supported. + +### Examples +``` + - name: Get detailed list of PowerFlex entities + dellemc.powerflex.dellemc_powerflex_gatherfacts: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + gather_subset: + - vol + - storage_pool + - protection_domain + - sdc + - sds + - snapshot_policy + - device + + - name: Get a subset list of PowerFlex volumes + dellemc.powerflex.dellemc_powerflex_gatherfacts: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + gather_subset: + - vol + filters: + - filter_key: "name" + filter_operator: "equal" + filter_value: "ansible_test" +``` + +### Return Values + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
KeyTypeReturnedDescription
API_Version str always API version of PowerFlex API Gateway.
Array_Details dict always System entities of PowerFlex storage array.
  addressSpaceUsage str success Address space usage.
  authenticationMethod str success Authentication method.
  capacityAlertCriticalThresholdPercent int success Capacity alert critical threshold percentage.
  capacityAlertHighThresholdPercent int success Capacity alert high threshold percentage.
  capacityTimeLeftInDays str success Capacity time left in days.
  cliPasswordAllowed bool success CLI password allowed.
  daysInstalled int success Days installed.
  defragmentationEnabled bool success Defragmentation enabled.
  enterpriseFeaturesEnabled bool success Enterprise eatures enabled.
  id str success The ID of the system.
  installId str success installation Id.
  isInitialLicense bool success Initial license.
  lastUpgradeTime int success Last upgrade time.
  managementClientSecureCommunicationEnabled bool success Management client secure communication enabled.
  maxCapacityInGb dict success Maximum capacity in GB.
  mdmCluster dict success MDM cluster details.
  mdmExternalPort int success MDM external port.
  mdmManagementPort int success MDM management port.
  mdmSecurityPolicy str success MDM security policy.
  showGuid bool success Show guid.
  swid str success SWID.
  systemVersionName str success System version and name.
  tlsVersion str success TLS version.
  upgradeState str success Upgrade state.
Devices list always Details of devices.
  id str success device id.
  name str success device name.
Protection_Domains list always Details of all protection domains.
  id str success protection domain id.
  name str success protection domain name.
SDCs list always Details of storage data clients.
  id str success storage data client id.
  name str success storage data client name.
SDSs list always Details of storage data servers.
  id str success storage data server id.
  name str success storage data server name.
Snapshot_Policies list always Details of snapshot policies.
  id str success snapshot policy id.
  name str success snapshot policy name.
Storage_Pools list always Details of storage pools.
  id str success storage pool id.
  name str success storage pool name.
Volumes list always Details of volumes.
  id str success volume id.
  name str success volume name.
changed bool always Whether or not the resource has changed.
-
-## Examples +### Authors +* Arindam Datta (@dattaarindam) + +-------------------------------- +# Snapshot Module -``` yaml+jinja +Manage Snapshots on Dell EMC PowerFlex + +### Synopsis + Managing snapshots on PowerFlex Storage System includes creating new snapshot, getting details of snapshot, mapping/unmapping snapshot to/from SDC, modifying attributes of snapshot and deleting snapshot. + +### Parameters + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterTypeRequiredDefaultChoicesDescription
snapshot_name str
The name of the snapshot.
Mandatory for create operation.
Specify either snapshot name or ID (but not both) for any operation.
snapshot_id str
The ID of the Snapshot.
vol_name str
The name of the volume for which snapshot will be taken.
Specify either vol_name or vol_id while creating snapshot.
vol_id str
The ID of the volume.
read_only bool
Specifies whether mapping of the created snapshot volume will have read-write access or limited to read-only access.
If true, snapshot is created with read-only access.
If false, snapshot is created with read-write access.
size int
The size of the snapshot.
cap_unit str
  • GB
  • TB

The unit of the volume size. It defaults to 'GB', if not specified..
snapshot_new_name str
New name of the snapshot. Used to rename the snapshot.
allow_multiple_mappings bool
Specifies whether to allow multiple mappings or not.
desired_retention int
The retention value for the Snapshot.
If the desired_retention is not mentioned during creation, snapshot will be created with unlimited retention.
Maximum supported desired retention is 31 days.
retention_unit str
  • hours
  • days

The unit for retention. It defaults to 'hours', if not specified.
sdc list
elements: dict

Specifies SDC parameters.
  sdc_name str
Name of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_id and sdc_ip.
  sdc_id str
ID of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_name and sdc_ip.
  sdc_ip str
IP of the SDC.
Specify either sdc_name, sdc_id or sdc_ip.
Mutually exclusive with sdc_id and sdc_ip.
  access_mode str
  • READ_WRITE
  • READ_ONLY
  • NO_ACCESS

Define the access mode for all mappings of the snapshot.
  bandwidth_limit int
Limit of snapshot network bandwidth.
Need to mention in multiple of 1024 Kbps.
To set no limit, 0 is to be passed.
  iops_limit int
Limit of snapshot IOPS.
Minimum IOPS limit is 11 and specify 0 for unlimited iops.
sdc_state str
  • mapped
  • unmapped

Mapping state of the SDC.
remove_mode str
  • ONLY_ME
  • INCLUDING_DESCENDANTS

Removal mode for the snapshot.
It defaults to 'ONLY_ME', if not specified.
state str True
  • present
  • absent

State of the snapshot.
gateway_host str True
IP or FQDN of the PowerFlex gateway host.
username str True
The username of the PowerFlex gateway host.
password str True
The password of the PowerFlex gateway host.
verifycert bool True
  • True
  • False

Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified.
port int 443
Port number through which communication happens with PowerFlex gateway host.
+ +### Notes +* The check_mode is not supported. + +### Examples +``` - name: Create snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2369,7 +2831,7 @@ Volume Module state: "present" - name: Get snapshot details using snapshot id - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2378,28 +2840,28 @@ Volume Module state: "present" - name: Map snapshot to SDC - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" - sdc_id: "663ac0d200000001" allow_multiple_mappings: True sdc_state: "mapped" state: "present" - name: Modify the attributes of SDC mapped to snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" iops_limit: 11 bandwidth_limit: 4096 - sdc_id: "663ac0d200000001" @@ -2410,7 +2872,7 @@ Volume Module state: "present" - name: Extend the size of snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2420,20 +2882,20 @@ Volume Module state: "present" - name: Unmap SDCs from snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" - sdc_id: "663ac0d200000001" sdc_state: "unmapped" state: "present" - name: Rename snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2443,7 +2905,7 @@ Volume Module state: "present" - name: Delete snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2453,464 +2915,305 @@ Volume Module state: "absent" ``` -## Return Values - - +### Return Values + +
- + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
KeyKeyType Returned Description
-
- changed - -
- type=boolean -
-
always -
Whether or not the resource has changed
-
-
-
- snapshot_details - -
- complex -
-
When snapshot exists -
Details of the snapshot
-
-
  -
- ancestorVolumeId - -
- type=string -
-
success -
The of the root of the specified volume's V-Tree
-
-
  -
- creationTime - -
- type=integer -
-
success -
The creation time of the snapshot
-
-
  -
- id - -
- type=string -
-
success -
The ID of the snapshot
-
-
  -
- mappedSdcInfo - -
- complex -
-
success -
The details of the mapped SDC
-
-
   -
- accessMode - -
- type=string -
-
success -
mapping access mode for the specified snapshot
-
-
   -
- limitBwInMbps - -
- type=integer -
-
success -
Bandwidth limit for the SDC
-
-
   -
- limitIops - -
- type=integer -
-
success -
IOPS limit for the SDC
-
-
   -
- sdcId - -
- type=string -
-
success -
ID of the SDC
-
-
   -
- sdcIp - -
- type=string -
-
success -
IP of the SDC
-
-
   -
- sdcName - -
- type=string -
-
success -
Name of the SDC
-
-
  -
- name - -
- type=string -
-
success -
Name of the snapshot
-
-
  -
- sizeInKb - -
- type=integer -
-
success -
Size of the snapshot
-
-
  -
- storagePoolId - -
- type=string -
-
success -
Storage pool in which snapshot resides
-
-
-

+ + changed + bool + always + Whether or not the resource has changed. + + + snapshot_details + complex + When snapshot exists + Details of the snapshot. + + +   + ancestorVolumeId + str + success + The ID of the root of the specified volume's V-Tree. + + +   + ancestorVolumeName + str + success + The name of the root of the specified volume's V-Tree. + + +   + creationTime + int + success + The creation time of the snapshot. + + +   + id + str + success + The ID of the snapshot. + + +   + mappedSdcInfo + complex + success + The details of the mapped SDC. + + +   +   + accessMode + str + success + mapping access mode for the specified snapshot. + + +   +   + limitBwInMbps + int + success + Bandwidth limit for the SDC. + + +   +   + limitIops + int + success + IOPS limit for the SDC. + + +   +   + sdcId + str + success + ID of the SDC. + + +   +   + sdcIp + str + success + IP of the SDC. + + +   +   + sdcName + str + success + Name of the SDC. + + +   + name + str + success + Name of the snapshot. + + +   + retentionInHours + int + success + Retention of the snapshot in hours. + + +   + secureSnapshotExpTime + int + success + Expiry time of the snapshot. + + +   + sizeInGb + int + success + Size of the snapshot. + + +   + sizeInKb + int + success + Size of the snapshot. + + +   + storagePoolId + str + success + The ID of the Storage pool in which snapshot resides. + + +   + storagePoolName + str + success + The name of the Storage pool in which snapshot resides. + + ### Authors +* Akash Shendge (@shenda1) -- Akash Shendge (@shenda1) <> - +-------------------------------- # Storage Pool Module -## Synopsis +Managing Dell EMC PowerFlex storage pool -- Dell EMC PowerFlex storage pool module includes Get the details of - storage pool, Create a new storage pool, Modify the attribute of a - storage pool. +### Synopsis + Dell EMC PowerFlex storage pool module includes getting the details of storage pool, creating a new storage pool, and modifying the attribute of a storage pool. -## Parameters - - +### Parameters + +
- - - + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ParameterChoices/DefaultsCommentsParameterTypeRequiredDefaultChoicesDescription
-
- media_type - -
- type=string -
-
-
    Choices: -
  • HDD
  • -
  • SSD
  • -
  • TRANSITIONAL
  • -
-
-
Type of devices in the storage pool.
-
-
- protection_domain_id - -
- type=string -
-
- -
The id of the protection domain.
-
While creation of a pool, either protection domain name or id must be mentioned.
-
protection_domain_name and protection_domain_id are mutually exclusive parameters.
-
-
- protection_domain_name - -
- type=string -
-
- -
The name of the protection domain.
-
While creation of a pool, either protection domain name or id must be mentioned.
-
protection_domain_name and protection_domain_name are mutually exclusive parameters.
-
-
- state - -
- type=string - , required=True
-
-
    Choices: -
  • present
  • -
  • absent
  • -
-
-
State of the storage pool.
-
-
- storage_pool_id - -
- type=string -
-
- -
The id of the storage pool.
-
storage_pool_id is auto generated, hence should not be provided during creation of a storage pool.
-
storage_pool_name and storage_pool_id are mutually exclusive parameters.
-
-
- storage_pool_name - -
- type=string -
-
- -
The name of the storage pool.
-
If more than one storage pool is found with the same name then protection domain id/name is required to perform the task.
-
storage_pool_name and storage_pool_id are mutually exclusive parameters.
-
-
- storage_pool_new_name - -
- type=string -
-
- -
New name for the storage pool can be provided.
-
This parameter is used for renaming the storage pool.
-
-
- use_rfcache - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Enable/Disable RFcache on a specific storage pool.
-
-
- use_rmcache - -
- type=boolean -
-
-
    Choices: -
  • no
  • -
  • yes
  • -
-
-
Enable/Disable RMcache on a specific storage pool.
-
-
- -## Notes - -
- -
- -
- -- TRANSITIONAL media type is supported only during modification. -- The modules prefixed with dellemc\_powerflex are built to support the Dell -EMC PowerFlex storage platform. - -
- -## Examples - -``` yaml+jinja + + storage_pool_name + str + + + +
The name of the storage pool.
If more than one storage pool is found with the same name then protection domain id/name is required to perform the task.
Mutually exclusive with storage_pool_id. + + + storage_pool_id + str + + + +
The id of the storage pool.
It is auto generated, hence should not be provided during creation of a storage pool.
Mutually exclusive with storage_pool_name. + + + protection_domain_name + str + + + +
The name of the protection domain.
During creation of a pool, either protection domain name or id must be mentioned.
Mutually exclusive with protection_domain_id. + + + protection_domain_id + str + + + +
The id of the protection domain.
During creation of a pool, either protection domain name or id must be mentioned.
Mutually exclusive with protection_domain_name. + + + media_type + str + + +
  • HDD
  • SSD
  • TRANSITIONAL
+
Type of devices in the storage pool. + + + storage_pool_new_name + str + + + +
New name for the storage pool can be provided.
This parameter is used for renaming the storage pool. + + + use_rfcache + bool + + + +
Enable/Disable RFcache on a specific storage pool. + + + use_rmcache + bool + + + +
Enable/Disable RMcache on a specific storage pool. + + + state + str + True + +
  • present
  • absent
+
State of the storage pool. + + + gateway_host + str + True + + +
IP or FQDN of the PowerFlex gateway host. + + + username + str + True + + +
The username of the PowerFlex gateway host. + + + password + str + True + + +
The password of the PowerFlex gateway host. + + + verifycert + bool + + True +
  • True
  • False
+
Boolean variable to specify whether or not to validate SSL certificate.
True - Indicates that the SSL certificate should be verified.
False - Indicates that the SSL certificate should not be verified. + + + port + int + + 443 + +
Port number through which communication happens with PowerFlex gateway host. + + + +### Notes +* TRANSITIONAL media type is supported only during modification. +* The check_mode is not supported. + +### Examples +``` - name: Get the details of storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2920,7 +3223,7 @@ EMC PowerFlex storage platform. state: "present" - name: Get the details of storage pool by id - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2929,7 +3232,7 @@ EMC PowerFlex storage platform. state: "present" - name: Create a new storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2940,7 +3243,7 @@ EMC PowerFlex storage platform. state: "present" - name: Modify a storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2952,7 +3255,7 @@ EMC PowerFlex storage platform. state: "present" - name: Rename storage pool by id - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -2962,161 +3265,80 @@ EMC PowerFlex storage platform. state: "present" ``` -## Return Values - - - +### Return Values + +
- + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
KeyKeyType Returned Description
-
- changed - -
- type=boolean -
-
always -
Whether or not the resource has changed
-
-
-
- storage_pool_details - -
- complex -
-
When storage pool exists -
Details of the storage pool
-
-
  -
- id - -
- type=string -
-
success -
ID of the storage pool under protection domain.
-
-
  -
- mediaType - -
- type=string -
-
success -
Type of devices in the storage pool
-
-
  -
- name - -
- type=string -
-
success -
Name of the storage pool under protection domain.
-
-
  -
- protectionDomainId - -
- type=string -
-
success -
ID of the protection domain in which pool resides.
-
-
  -
- protectionDomainName - -
- type=string -
-
success -
Name of the protection domain in which pool resides.
-
-
  -
- useRfcache - -
- type=boolean -
-
success -
Enable/Disable RFcache on a specific storage pool.
-
-
  -
- useRmcache - -
- type=boolean -
-
success -
Enable/Disable RMcache on a specific storage pool.
-
-
-

+ + changed + bool + always + Whether or not the resource has changed. + + + storage_pool_details + complex + When storage pool exists + Details of the storage pool. + + +   + id + str + success + ID of the storage pool under protection domain. + + +   + mediaType + str + success + Type of devices in the storage pool. + + +   + name + str + success + Name of the storage pool under protection domain. + + +   + protectionDomainId + str + success + ID of the protection domain in which pool resides. + + +   + protectionDomainName + str + success + Name of the protection domain in which pool resides. + + +   + useRfcache + bool + success + Enable/Disable RFcache on a specific storage pool. + + +   + useRmcache + bool + success + Enable/Disable RMcache on a specific storage pool. + + ### Authors +* Arindam Datta (@dattaarindam) +* P Srinivas Rao (@srinivas-rao5) -- Arindam Datta (@dattaarindam) <> -- P Srinivas Rao (@srinivas-rao5) <> +-------------------------------- diff --git a/docs/Release Notes.md b/docs/Release Notes.md index f9a5c70..2fcbdfa 100644 --- a/docs/Release Notes.md +++ b/docs/Release Notes.md @@ -1,6 +1,6 @@ **Ansible Modules for Dell EMC PowerFlex** ========================================= -### Release Notes 1.0 +### Release Notes 1.1.0 > © 2021 Dell Inc. or its subsidiaries. All rights reserved. Dell > EMC, and other trademarks are trademarks of Dell Inc. or its @@ -23,60 +23,45 @@ Product Description ------------------- The Ansible Modules for Dell EMC PowerFlex are used for managing volumes, -storage pools, SDCs, and snapshots for PowerFlex storage devices. +storage pools, SDCs, snapshots, SDSs and devices for PowerFlex storage devices. The modules use playbooks to list, show, create, delete, and modify each of the entities. The Ansible Modules for Dell EMC PowerFlex supports the following features: -- Create volumes, storage pools and snapshots. -- Modify volumes, storage pools, SDCs and snapshots. -- Delete volumes and snapshots. -- Get details of a volumes, snapshots, SDCs and storage pool. +- Create volumes, storage pools, snapshots, SDSs. +- Add devices. +- Modify volumes, storage pools, SDCs, snapshots and SDSs. +- Delete volumes, snapshots and SDSs. +- Get details of a volumes, snapshots, SDCs, storage pools, SDSs and devices. - Get entities of the PowerFlex storage device. +- Remove devices. New Features --------------------------- -The Ansible Modules for Dell EMC PowerFlex release 1.0 supports the +The Ansible Modules for Dell EMC PowerFlex release 1.1.0 supports the following features: - The following are the features of the gatherfacts module: - - Get the API details of a PowerFlex storage device. - - Get the list of SDCs. - - Get the list of SDSs. - - Get the list of volumes. - - Get the list of snapshots. - - Get the list of storage pools. - - Get list of protection domains. - - Get list of snapshot policies. - -- The following are the features of the volume module: - - Get the details of a volume. - - Create a volume. - - Modify details of a volume. - - Delete a volume. - -- The following are the features of the snapshot module: - - Get the details of a snapshot. - - Create a snapshot. - - Modify details of a snapshot. - - Delete a snapshot. - -- The following are the features of the storage pools module: - - Get the details of a storage pool. - - Create a storage pool. - - Modify details of a storage pool. - -- The following are the features of the SDCs module: - - Get the details of the SDC. - - Rename a SDC. + - Get list of devices. +- The following are the features of the SDS module: + - Get the details of an SDS. + - Create an SDS. + - Modify details of an SDS. + - Delete an SDS. + +- The following are the features of the device module: + - Get the details of a device. + - Add a device. + - Remove a device. + Known issues ------------ -There are no known issues. +- Setting the RF cache and performance profile of the SDS during its creation fails intermittently on PowerFlex version 3.5 Limitations ----------- diff --git a/galaxy.yml b/galaxy.yml index 077904a..9a4fdd3 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -8,7 +8,7 @@ namespace: dellemc name: powerflex # The version of the collection. Must be compatible with semantic versioning -version: 1.0.0 +version: 1.1.0 # The path to the Markdown (.md) readme file. This path is relative to the root of the collection readme: README.md @@ -19,6 +19,7 @@ authors: - Akash Shendge - Arindam Datta - P Srinivas Rao +- Rajshree Khare ### OPTIONAL but strongly recommended # A short summary description of the collection @@ -27,14 +28,16 @@ description: Ansible modules for Dell EMC PowerFlex # 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 # The path to the license file for the collection. This path is relative to the root of the collection. This key is # mutually exclusive with 'license' -license_file: 'LICENSE' +license_file: # 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: [] +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 @@ -43,13 +46,13 @@ tags: [] dependencies: {} # The URL of the originating SCM repository -repository: https://github.com/dell/ansible-powerflex/tree/1.0.0 +repository: https://github.com/dell/ansible-powerflex/tree/1.1.0 # The URL to any online docs -documentation: https://github.com/dell/ansible-powerflex/tree/1.0.0/docs +documentation: https://github.com/dell/ansible-powerflex/tree/1.1.0/docs # The URL to the homepage of the collection/project -homepage: https://github.com/dell/ansible-powerflex/tree/1.0.0 +homepage: https://github.com/dell/ansible-powerflex/tree/1.1.0 # The URL to the collection issue tracker issues: https://www.dell.com/community/Automation/bd-p/Automation @@ -59,4 +62,3 @@ issues: https://www.dell.com/community/Automation/bd-p/Automation # 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 new file mode 100644 index 0000000..f620624 --- /dev/null +++ b/meta/runtime.yml @@ -0,0 +1,2 @@ +--- +requires_ansible: ">=2.9" \ No newline at end of file diff --git a/plugins/module_utils/storage/dell/dellemc_ansible_powerflex_utils.py b/plugins/module_utils/storage/dell/dellemc_ansible_powerflex_utils.py index 5d88dc0..b005f16 100644 --- a/plugins/module_utils/storage/dell/dellemc_ansible_powerflex_utils.py +++ b/plugins/module_utils/storage/dell/dellemc_ansible_powerflex_utils.py @@ -1,4 +1,5 @@ # Copyright: (c) 2021, DellEMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type @@ -22,7 +23,7 @@ except ImportError: HAS_POWERFLEX_SDK = False -'''import pkg_resources''' +"""importing pkg_resources""" try: from pkg_resources import parse_version import pkg_resources @@ -31,7 +32,7 @@ except ImportError: PKG_RSRC_IMPORTED = False -'''import dateutil''' +"""importing dateutil""" try: import dateutil.relativedelta HAS_DATEUTIL = True diff --git a/plugins/modules/dellemc_powerflex_device.py b/plugins/modules/dellemc_powerflex_device.py new file mode 100644 index 0000000..70885d5 --- /dev/null +++ b/plugins/modules/dellemc_powerflex_device.py @@ -0,0 +1,1109 @@ +#!/usr/bin/python +# Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) + +""" Ansible module for managing device on PowerFlex""" + +from __future__ import (absolute_import, division, print_function) + +__metaclass__ = type +ANSIBLE_METADATA = {'metadata_version': '1.1', + 'status': ['preview'], + 'supported_by': 'community'} + +DOCUMENTATION = r''' +module: dellemc_powerflex_device +version_added: '1.1.0' +short_description: Manage device on Dell EMC PowerFlex +description: +- Managing device on PowerFlex storage system includes + adding new device, getting details of device, and removing a device. +author: +- Rajshree Khare (@khareRajshree) +extends_documentation_fragment: + - dellemc.powerflex.dellemc_powerflex.powerflex +options: + current_pathname: + description: + - Full path of the device to be added. + - Required while adding a device. + type: str + device_name: + description: + - Device name. + - Mutually exclusive with device_id. + type: str + device_id: + description: + - Device ID. + - Mutually exclusive with device_name. + type: str + sds_name: + description: + - The name of the SDS. + - Required while adding a device. + - Mutually exclusive with sds_id. + type: str + sds_id: + description: + - The ID of the SDS. + - Required while adding a device. + - Mutually exclusive with sds_name. + type: str + storage_pool_name: + description: + - Storage Pool name. + - Used while adding a storage device. + - Mutually exclusive with storage_pool_id, acceleration_pool_id and + acceleration_pool_name. + type: str + storage_pool_id: + description: + - Storage Pool ID. + - Used while adding a storage device. + - Media type supported are SSD and HDD. + - Mutually exclusive with storage_pool_name, acceleration_pool_id and + acceleration_pool_name. + type: str + acceleration_pool_name: + description: + - Acceleration Pool Name. + - Used while adding an acceleration device. + - Media type supported are SSD and NVDIMM. + - Mutually exclusive with storage_pool_id, storage_pool_name and + acceleration_pool_name. + type: str + acceleration_pool_id: + description: + - Acceleration Pool ID. + - Used while adding an acceleration device. + - Media type supported are SSD and NVDIMM. + - Mutually exclusive with acceleration_pool_name, storage_pool_name and + storage_pool_id. + type: str + protection_domain_name: + description: + - Protection domain name. + - Used while identifying a storage pool along with storage_pool_name. + - Mutually exclusive with protection_domain_id. + type: str + protection_domain_id: + description: + - Protection domain ID. + - Used while identifying a storage pool along with storage_pool_name. + - Mutually exclusive with protection_domain_name. + type: str + external_acceleration_type: + description: + - Device external acceleration types. + - Used while adding a device. + type: str + choices: ['Invalid', 'None', 'Read', 'Write', 'ReadAndWrite'] + media_type: + description: + - Device media types. + - Required while adding a device. + type: str + choices: ['HDD', 'SSD', 'NVDIMM'] + state: + description: + - State of the device. + choices: ['present', 'absent'] + required: True + type: str +notes: + - The value for device_id is generated only after successful addition of the + device. + - Unique ways to identify a device - (current_pathname , sds_id) or + (current_pathname , sds_name) or (device_name , sds_name) or + (device_name , sds_id) or device_id. + - It is recommended to install Rfcache driver for SSD device on SDS in + order to add it to an acceleration pool. + - The check_mode is not supported. +''' + +EXAMPLES = r''' +- name: Add a device + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node1" + media_type: "HDD" + device_name: "device2" + storage_pool_name: "pool1" + protection_domain_name: "domain1" + external_acceleration_type: "ReadAndWrite" + state: "present" +- name: Get device details using device_id + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + device_id: "d7fe088900000000" + state: "present" +- name: Get device details using (current_pathname, sds_name) + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node0" + state: "present" +- name: Get device details using (current_pathname, sds_id) + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_id: "5717d71800000000" + state: "present" +- name: Remove a device using device_id + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + device_id: "76eb7e2f00010000" + state: "absent" +- name: Remove a device using (current_pathname, sds_id) + dellemc.powerflex.dellemc_powerflex_device: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + current_pathname: "/dev/sdb" + sds_name: "node1" + state: "absent" +''' + +RETURN = r''' +changed: + description: Whether or not the resource has changed. + returned: always + type: bool + sample: 'false' +device_details: + description: Details of the device. + returned: When device exists + type: complex + contains: + accelerationPoolId: + description: Acceleration pool ID. + type: str + accelerationPoolName: + description: Acceleration pool name. + type: str + accelerationProps: + description: Indicates acceleration props. + type: str + aggregatedState: + description: Indicates aggregated state. + type: str + ataSecurityActive: + description: Indicates ATA security active state. + type: bool + autoDetectMediaType: + description: Indicates auto detection of media type. + type: str + cacheLookAheadActive: + description: Indicates cache look ahead active state. + type: bool + capacity: + description: Device capacity. + type: int + capacityLimitInKb: + description: Device capacity limit in KB. + type: int + deviceCurrentPathName: + description: Device current path name. + type: str + deviceOriginalPathName: + description: Device original path name. + type: str + deviceState: + description: Indicates device state. + type: str + deviceType: + description: Indicates device type. + type: str + errorState: + description: Indicates error state. + type: str + externalAccelerationType: + description: Indicates external acceleration type. + type: str + fglNvdimmMetadataAmortizationX100: + description: Indicates FGL NVDIMM meta data amortization value. + type: int + fglNvdimmWriteCacheSize: + description: Indicates FGL NVDIMM write cache size. + type: int + firmwareVersion: + description: Indicates firmware version. + type: str + id: + description: Device ID. + type: str + ledSetting: + description: Indicates LED setting. + type: str + links: + description: Device links. + type: list + contains: + href: + description: Device instance URL. + type: str + rel: + description: Relationship of device with different + entities. + type: str + logicalSectorSizeInBytes: + description: Logical sector size in bytes. + type: int + longSuccessfulIos: + description: Indicates long successful IOs. + type: list + maxCapacityInKb: + description: Maximum device capacity limit in KB. + type: int + mediaFailing: + description: Indicates media failing. + type: bool + mediaType: + description: Indicates media type. + type: str + modelName: + description: Indicates model name. + type: str + name: + description: Device name. + type: str + persistentChecksumState: + description: Indicates persistent checksum state. + type: str + physicalSectorSizeInBytes: + description: Physical sector size in bytes. + type: int + protectionDomainId: + description: Protection domain ID. + type: str + protectionDomainName: + description: Protection domain name. + type: str + raidControllerSerialNumber: + description: RAID controller serial number. + type: str + rfcacheErrorDeviceDoesNotExist: + description: Indicates RF cache error device does not exist. + type: bool + rfcacheProps: + description: RF cache props. + type: str + sdsId: + description: SDS ID. + type: str + sdsName: + description: SDS name. + type: str + serialNumber: + description: Indicates Serial number. + type: str + spSdsId: + description: Indicates SPs SDS ID. + type: str + ssdEndOfLifeState: + description: Indicates SSD end of life state. + type: str + storagePoolId: + description: Storage Pool ID. + type: str + storagePoolName: + description: Storage Pool name. + type: str + storageProps: + description: Storage props. + type: list + temperatureState: + description: Indicates temperature state. + type: str + vendorName: + description: Indicates vendor name. + type: str + writeCacheActive: + description: Indicates write cache active. + type: bool + sample: { + "accelerationPoolId": null, + "accelerationProps": null, + "aggregatedState": "NeverFailed", + "ataSecurityActive": false, + "autoDetectMediaType": "SSD", + "cacheLookAheadActive": false, + "capacity": 0, + "capacityLimitInKb": 365772800, + "deviceCurrentPathName": "/dev/sdb", + "deviceOriginalPathName": "/dev/sdb", + "deviceState": "Normal", + "deviceType": "Unknown", + "errorState": "None", + "externalAccelerationType": "None", + "fglNvdimmMetadataAmortizationX100": 150, + "fglNvdimmWriteCacheSize": 16, + "firmwareVersion": null, + "id": "b6efa59900000000", + "ledSetting": "Off", + "links": [ + { + "href": "/api/instances/Device::b6efa59900000000", + "rel": "self" + }, + { + "href": "/api/instances/Device::b6efa59900000000/relationships + /Statistics", + "rel": "/api/Device/relationship/Statistics" + }, + { + "href": "/api/instances/Sds::8f3bb0ce00000000", + "rel": "/api/parent/relationship/sdsId" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000", + "rel": "/api/parent/relationship/storagePoolId" + }, + { + "href": "/api/instances/SpSds::fedf6f2000000000", + "rel": "/api/parent/relationship/spSdsId" + } + ], + "logicalSectorSizeInBytes": 0, + "longSuccessfulIos": { + "longWindow": null, + "mediumWindow": null, + "shortWindow": null + }, + "maxCapacityInKb": 365772800, + "mediaFailing": false, + "mediaType": "HDD", + "modelName": null, + "name": "device230", + "persistentChecksumState": "Protected", + "physicalSectorSizeInBytes": 0, + "protectionDomainId": "9300c1f900000000", + "protectionDomainName": "domain1", + "raidControllerSerialNumber": null, + "rfcacheErrorDeviceDoesNotExist": false, + "rfcacheProps": null, + "sdsId": "8f3bb0ce00000000", + "sdsName": "node1", + "serialNumber": null, + "slotNumber": null, + "spSdsId": "fedf6f2000000000", + "ssdEndOfLifeState": "NeverFailed", + "storagePoolId": "e0d8f6c900000000", + "storagePoolName": "pool1", + "storageProps": { + "destFglAccDeviceId": null, + "destFglNvdimmSizeMb": 0, + "fglAccDeviceId": null, + "fglNvdimmSizeMb": 0 + }, + "temperatureState": "NeverFailed", + "vendorName": null, + "writeCacheActive": false + } +''' + +from ansible.module_utils.basic import AnsibleModule +from ansible_collections.dellemc.powerflex.plugins.module_utils.storage.dell\ + import dellemc_ansible_powerflex_utils as utils + +LOG = utils.get_logger('dellemc_powerflex_device') + +MISSING_PACKAGES_CHECK = utils.pypowerflex_version_check() + + +class PowerFlexDevice(object): + """Class with device operations""" + + def __init__(self): + """ Define all parameters required by this module""" + self.module_params = utils.get_powerflex_gateway_host_parameters() + self.module_params.update(get_powerflex_device_parameters()) + + mut_ex_args = [['sds_name', 'sds_id'], + ['device_name', 'device_id'], + ['protection_domain_name', + 'protection_domain_id'], + ['storage_pool_name', 'storage_pool_id'], + ['acceleration_pool_name', 'acceleration_pool_id'], + ['acceleration_pool_id', 'storage_pool_id'], + ['acceleration_pool_name', 'storage_pool_name'], + ['device_id', 'sds_name'], + ['device_id', 'sds_id'], + ['device_id', 'current_pathname']] + + # initialize the Ansible module + self.module = AnsibleModule( + argument_spec=self.module_params, + supports_check_mode=False, + mutually_exclusive=mut_ex_args) + + if MISSING_PACKAGES_CHECK and \ + not MISSING_PACKAGES_CHECK['dependency_present']: + error_msg = MISSING_PACKAGES_CHECK['error_message'] + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + try: + self.powerflex_conn = utils.get_powerflex_gateway_host_connection( + self.module.params) + LOG.info("Got the PowerFlex system connection object instance") + except Exception as e: + LOG.error(str(e)) + self.module.fail_json(msg=str(e)) + + def get_device_details(self, current_pathname=None, sds_id=None, + device_name=None, device_id=None): + """Get device details + :param current_pathname: Device path name + :type current_pathname: str + :param sds_id: ID of the SDS + :type sds_id: str + :param device_name: Name of the device + :type device_name: str + :param device_id: ID of the device + :type device_id: str + :return: Details of device if it exist + :rtype: dict + """ + + try: + if current_pathname and sds_id: + device_details = self.powerflex_conn.device.get( + filter_fields={'deviceCurrentPathName': current_pathname, + 'sdsId': sds_id}) + elif device_name and sds_id: + device_details = self.powerflex_conn.device.get( + filter_fields={'name': device_name, + 'sdsId': sds_id}) + else: + device_details = self.powerflex_conn.device.get( + filter_fields={'id': device_id}) + + if len(device_details) == 0: + msg = "Device not found" + LOG.info(msg) + return None + + return device_details[0] + + except Exception as e: + error_msg = "Failed to get the device with error '%s'" % str(e) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_sds(self, sds_name=None, sds_id=None): + """Get SDS details + :param sds_name: Name of the SDS + :param sds_id: ID of the SDS + :return: SDS details + :rtype: dict + """ + name_or_id = sds_id if sds_id else sds_name + try: + sds_details = None + if sds_id: + sds_details = self.powerflex_conn.sds.get( + filter_fields={'id': sds_id}) + + if sds_name: + sds_details = self.powerflex_conn.sds.get( + filter_fields={'name': sds_name}) + + if not sds_details: + error_msg = "Unable to find the SDS with '%s'. Please " \ + "enter a valid SDS name/id." % name_or_id + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + return sds_details[0] + + except Exception as e: + error_msg = "Failed to get the SDS '%s' with error '%s'" \ + % (name_or_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_protection_domain(self, protection_domain_name=None, + protection_domain_id=None): + """Get protection domain details + :param protection_domain_name: Name of the protection domain + :param protection_domain_id: ID of the protection domain + :return: Protection domain details + :rtype: dict + """ + name_or_id = protection_domain_id if protection_domain_id \ + else protection_domain_name + try: + pd_details = None + if protection_domain_id: + pd_details = self.powerflex_conn.protection_domain.get( + filter_fields={'id': protection_domain_id}) + + if protection_domain_name: + pd_details = self.powerflex_conn.protection_domain.get( + filter_fields={'name': protection_domain_name}) + + if not pd_details: + error_msg = "Unable to find the protection domain with " \ + "'%s'. Please enter a valid protection domain " \ + "name/id." % name_or_id + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + return pd_details[0] + + except Exception as e: + error_msg = "Failed to get the protection domain '%s' with " \ + "error '%s'" % (name_or_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_storage_pool(self, storage_pool_name=None, + storage_pool_id=None, + protection_domain_id=None): + """Get storage pool details + :param storage_pool_name: Name of the storage pool + :param storage_pool_id: ID of the storage pool + :param protection_domain_id: ID of the protection domain + :return: Storage pool details + :rtype: dict + """ + name_or_id = storage_pool_id if storage_pool_id else storage_pool_name + try: + storage_pool_details = None + if storage_pool_id: + storage_pool_details = self.powerflex_conn.storage_pool.get( + filter_fields={'id': storage_pool_id}) + + if storage_pool_name: + storage_pool_details = self.powerflex_conn.storage_pool.get( + filter_fields={'name': storage_pool_name, + 'protectionDomainId': protection_domain_id} + ) + + if not storage_pool_details: + error_msg = "Unable to find the storage pool with " \ + "'%s'. Please enter a valid storage pool " \ + "name/id." % name_or_id + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + return storage_pool_details[0] + + except Exception as e: + error_msg = "Failed to get the storage_pool '%s' with " \ + "error '%s'" % (name_or_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_acceleration_pool(self, acceleration_pool_name=None, + acceleration_pool_id=None, + protection_domain_id=None): + """Get acceleration pool details + :param acceleration_pool_name: Name of the acceleration pool + :param acceleration_pool_id: ID of the acceleration pool + :param protection_domain_id: ID of the protection domain + :return: Acceleration pool details + :rtype: dict + """ + name_or_id = acceleration_pool_id \ + if acceleration_pool_id else acceleration_pool_name + try: + acceleration_pool_details = None + if acceleration_pool_id: + acceleration_pool_details = self.powerflex_conn.\ + acceleration_pool.get(filter_fields={ + 'id': acceleration_pool_id}) + + if acceleration_pool_name: + acceleration_pool_details = self.powerflex_conn.\ + acceleration_pool.get(filter_fields={ + 'name': acceleration_pool_name, + 'protectionDomainId': protection_domain_id}) + + if not acceleration_pool_details: + error_msg = "Unable to find the acceleration pool with " \ + "'%s'. Please enter a valid acceleration pool " \ + "name/id." % name_or_id + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + return acceleration_pool_details[0] + + except Exception as e: + error_msg = "Failed to get the acceleration pool '%s' with " \ + "error '%s'" % (name_or_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def add_device(self, device_name, current_pathname, sds_id, + storage_pool_id, media_type, acceleration_pool_id, + external_acceleration_type): + """Add device + :param device_name: Device name + :type device_name: str + :param current_pathname: Current pathname of device + :type current_pathname: str + :param sds_id: SDS ID + :type sds_id: str + :param storage_pool_id: Storage Pool ID + :type storage_pool_id: str + :param media_type: Media type of device + :type media_type: str + :param acceleration_pool_id: Acceleration pool ID + :type acceleration_pool_id: str + :param external_acceleration_type: External acceleration type + :type external_acceleration_type: str + return: Boolean indicating if add device operation is successful + """ + try: + if device_name is None or len(device_name.strip()) == 0: + error_msg = "Please provide valid device_name value for " \ + "adding a device." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if current_pathname is None or len(current_pathname.strip()) == 0: + error_msg = "Current pathname of device is a mandatory " \ + "parameter for adding a device. Please enter a " \ + "valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_id is None or len(sds_id.strip()) == 0: + error_msg = "Please provide valid sds_id value " \ + "for adding a device." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if storage_pool_id is None and acceleration_pool_id is None: + error_msg = "Please provide either storage pool name/ID " \ + "or acceleration pool name/ID for adding a " \ + "device." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + add_params = ("current_pathname: %s, " + "sds_id: %s, " + "acceleration_pool_id: %s," + "external_acceleration_type: %s," + "media_type: %s," + "device_name: %s," + "storage_pool_id: %s," + % (current_pathname, sds_id, + acceleration_pool_id, + external_acceleration_type, + media_type, + device_name, + storage_pool_id)) + LOG.info("Adding device with params: %s", add_params) + + self.powerflex_conn.device.create( + current_pathname=current_pathname, + sds_id=sds_id, + acceleration_pool_id=acceleration_pool_id, + external_acceleration_type=external_acceleration_type, + media_type=media_type, + name=device_name, + storage_pool_id=storage_pool_id) + return True + except Exception as e: + error_msg = "Adding device %s operation failed with " \ + "error '%s'" % (device_name, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def remove_device(self, device_id): + """Remove device + :param device_id: Device ID + :type device_id: str + return: Boolean indicating if remove device operation is + successful + """ + try: + LOG.info("Device to be removed: %s", device_id) + self.powerflex_conn.device.delete(device_id=device_id) + return True + except Exception as e: + error_msg = "Remove device '%s' operation failed with " \ + "error '%s'" % (device_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def validate_input_parameters(self, device_name=None, device_id=None, + current_pathname=None, sds_name=None, + sds_id=None): + """Validate the input parameters""" + + # Unique ways to identify a device: + # (current_pathname , sds_id) + # (current_pathname , sds_name) + # (device_name , sds_name) + # (device_name , sds_id) + # device_id. + + if current_pathname: + if (sds_name is None or len(sds_name.strip()) == 0) \ + and (sds_id is None or len(sds_id.strip()) == 0): + error_msg = "sds_name or sds_id is mandatory along with " \ + "current_pathname. Please enter a valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + elif current_pathname is not None \ + and len(current_pathname.strip()) == 0: + error_msg = "Please enter a valid value for current_pathname." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if device_name: + if (sds_name is None or len(sds_name.strip()) == 0) \ + and (sds_id is None or len(sds_id.strip()) == 0): + error_msg = "sds_name or sds_id is mandatory along with " \ + "device_name. Please enter a valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + elif device_name is not None and len(device_name.strip()) == 0: + error_msg = "Please enter a valid value for device_name." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_name: + if (current_pathname is None + or len(current_pathname.strip()) == 0) \ + and (device_name is None + or len(device_name.strip()) == 0): + error_msg = "current_pathname or device_name is mandatory " \ + "along with sds_name. Please enter a valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + elif sds_name is not None and len(sds_name.strip()) == 0: + error_msg = "Please enter a valid value for sds_name." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_id: + if (current_pathname is None + or len(current_pathname.strip()) == 0) \ + and (device_name is None + or len(device_name.strip()) == 0): + error_msg = "current_pathname or device_name is mandatory " \ + "along with sds_id. Please enter a valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + elif sds_id is not None and len(sds_id.strip()) == 0: + error_msg = "Please enter a valid value for sds_id." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if device_id is not None and len(device_id.strip()) == 0: + error_msg = "Please provide valid device_id value to identify " \ + "a device." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if current_pathname is None and device_name is None \ + and device_id is None: + error_msg = "Please specify a valid parameter combination to " \ + "identify a device." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def validate_add_parameters(self, device_id=None, + external_acceleration_type=None, + storage_pool_id=None, + storage_pool_name=None, + acceleration_pool_id=None, + acceleration_pool_name=None): + """Validate the add device parameters""" + + if device_id: + error_msg = "Addition of device is allowed using " \ + "device_name only, device_id given." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + if external_acceleration_type and storage_pool_id is None \ + and storage_pool_name is None \ + and acceleration_pool_id is None \ + and acceleration_pool_name is None: + error_msg = "Storage Pool ID/name or Acceleration Pool " \ + "ID/name is mandatory along with " \ + "external_acceleration_type." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def perform_module_operation(self): + """ + Perform different actions on device based on parameters passed in + the playbook + """ + current_pathname = self.module.params['current_pathname'] + device_name = self.module.params['device_name'] + device_id = self.module.params['device_id'] + sds_name = self.module.params['sds_name'] + sds_id = self.module.params['sds_id'] + storage_pool_name = self.module.params['storage_pool_name'] + storage_pool_id = self.module.params['storage_pool_id'] + acceleration_pool_id = self.module.params['acceleration_pool_id'] + acceleration_pool_name = self.module.params['acceleration_pool_name'] + protection_domain_name = self.module.params['protection_domain_name'] + protection_domain_id = self.module.params['protection_domain_id'] + external_acceleration_type = self.module.params[ + 'external_acceleration_type'] + media_type = self.module.params['media_type'] + state = self.module.params['state'] + + # result is a dictionary to contain end state and device details + changed = False + result = dict( + changed=False, + device_details=None + ) + + # validate input parameters + self.validate_input_parameters(device_name, device_id, + current_pathname, sds_name, sds_id) + + # get SDS ID from name + if sds_name: + sds_details = self.get_sds(sds_name) + if sds_details: + sds_id = sds_details['id'] + msg = "Fetched the SDS details with id '%s', name '%s'" \ + % (sds_id, sds_name) + LOG.info(msg) + + # get device details + device_details = self.get_device_details(current_pathname, + sds_id, device_name, + device_id) + + if device_details: + device_id = device_details['id'] + msg = "Fetched the device details %s" % (str(device_details)) + LOG.info(msg) + + # add operation + add_changed = False + if state == 'present' and not device_details: + # get Protection Domain ID from name + # it is needed to uniquely identify a storage pool or acceleration + # pool using name + if protection_domain_name \ + and (storage_pool_name or acceleration_pool_name): + pd_details = self.get_protection_domain( + protection_domain_name) + if pd_details: + protection_domain_id = pd_details['id'] + msg = "Fetched the protection domain details with id " \ + "'%s', name '%s'" % (protection_domain_id, + protection_domain_name) + LOG.info(msg) + + # get storage pool ID from name + if storage_pool_name: + if protection_domain_id: + storage_pool_details = self.get_storage_pool( + storage_pool_name=storage_pool_name, + protection_domain_id=protection_domain_id) + if storage_pool_details: + storage_pool_id = storage_pool_details['id'] + msg = "Fetched the storage pool details with id '%s', " \ + "name '%s'" % (storage_pool_id, storage_pool_name) + LOG.info(msg) + else: + error_msg = "Protection domain name/id is required to " \ + "uniquely identify a storage pool, only " \ + "storage_pool_name is given." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + + # get acceleration pool ID from name + if acceleration_pool_name: + if protection_domain_id: + acceleration_pool_details = self.get_acceleration_pool( + acceleration_pool_name=acceleration_pool_name, + protection_domain_id=protection_domain_id) + if acceleration_pool_details: + acceleration_pool_id = acceleration_pool_details['id'] + msg = "Fetched the acceleration pool details with id " \ + "'%s', name '%s'" % (acceleration_pool_id, + acceleration_pool_name) + LOG.info(msg) + else: + error_msg = "Protection domain name/id is required to " \ + "uniquely identify a acceleration pool, " \ + "only acceleration_pool_name is given." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + + # validate input parameters + self.validate_add_parameters(device_id, + external_acceleration_type, + storage_pool_id, + storage_pool_name, + acceleration_pool_id, + acceleration_pool_name) + add_changed = self.add_device(device_name, current_pathname, + sds_id, storage_pool_id, media_type, + acceleration_pool_id, + external_acceleration_type) + if add_changed: + device_details = self.get_device_details( + device_name=device_name, sds_id=sds_id) + device_id = device_details['id'] + msg = "Device created successfully, fetched device details " \ + "%s" % (str(device_details)) + LOG.info(msg) + + # remove operation + remove_changed = False + if state == 'absent' and device_details: + remove_changed = self.remove_device(device_id) + + if add_changed or remove_changed: + changed = True + + # modify operation + if device_details and state == 'present': + modify_dict = to_modify(device_details, media_type, + external_acceleration_type) + if modify_dict: + error_msg = "Modification of device attributes is " \ + "currently not supported by Ansible modules." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + + # Returning the updated device details + if state == 'present': + device_details = self.show_output(device_id) + result['device_details'] = device_details + result['changed'] = changed + self.module.exit_json(**result) + + def show_output(self, device_id): + """Show device details + :param device_id: ID of the device + :type device_id: str + :return: Details of device + :rtype: dict + """ + + try: + device_details = self.powerflex_conn.device.get( + filter_fields={'id': device_id}) + + if len(device_details) == 0: + msg = "Device with identifier '%s' not found" % device_id + LOG.error(msg) + return None + + # Append SDS name + if 'sdsId' in device_details[0] and device_details[0]['sdsId']: + sds_details = self.get_sds(sds_id=device_details[0]['sdsId']) + device_details[0]['sdsName'] = sds_details['name'] + + # Append storage pool name and its protection domain name and ID + if 'storagePoolId' in device_details[0] \ + and device_details[0]['storagePoolId']: + sp_details = self.get_storage_pool( + storage_pool_id=device_details[0]['storagePoolId']) + device_details[0]['storagePoolName'] = sp_details['name'] + pd_id = sp_details['protectionDomainId'] + device_details[0]['protectionDomainId'] = pd_id + pd_details = self.get_protection_domain( + protection_domain_id=pd_id) + device_details[0]['protectionDomainName'] = pd_details['name'] + + # Append acceleration pool name and its protection domain name + # and ID + if 'accelerationPoolId' in device_details[0] \ + and device_details[0]['accelerationPoolId']: + ap_details = self.get_acceleration_pool( + acceleration_pool_id=device_details[0][ + 'accelerationPoolId']) + device_details[0]['accelerationPoolName'] = ap_details['name'] + + return device_details[0] + + except Exception as e: + error_msg = "Failed to get the device '%s' with error '%s'"\ + % (device_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + +def to_modify(device_details, media_type, external_acceleration_type): + """Identify device attributes to be modified""" + + modify_dict = {} + + if media_type is not None and \ + device_details['mediaType'] != media_type: + modify_dict['mediaType'] = media_type + + if external_acceleration_type is not None and \ + device_details['externalAccelerationType'] \ + != external_acceleration_type: + modify_dict['externalAccelerationType'] \ + = external_acceleration_type + + if len(modify_dict) != 0: + LOG.info("Attributes to be modified: %s", modify_dict) + return modify_dict + + +def get_powerflex_device_parameters(): + """This method provide parameter required for the device module on + PowerFlex""" + return dict( + current_pathname=dict(), + device_name=dict(), + device_id=dict(), + sds_name=dict(), + sds_id=dict(), + storage_pool_name=dict(), + storage_pool_id=dict(), + acceleration_pool_id=dict(), + acceleration_pool_name=dict(), + protection_domain_name=dict(), + protection_domain_id=dict(), + external_acceleration_type=dict(choices=['Invalid', 'None', 'Read', + 'Write', 'ReadAndWrite']), + media_type=dict(choices=['HDD', 'SSD', 'NVDIMM']), + state=dict(required=True, type='str', choices=['present', 'absent']) + ) + + +def main(): + """ Create PowerFlex device object and perform actions on it + based on user input from playbook""" + obj = PowerFlexDevice() + obj.perform_module_operation() + + +if __name__ == '__main__': + main() diff --git a/plugins/modules/dellemc_powerflex_gatherfacts.py b/plugins/modules/dellemc_powerflex_gatherfacts.py index 0328d67..1b5cf53 100644 --- a/plugins/modules/dellemc_powerflex_gatherfacts.py +++ b/plugins/modules/dellemc_powerflex_gatherfacts.py @@ -1,5 +1,6 @@ #!/usr/bin/python # Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) """Ansible module for Gathering information about Dell EMC PowerFlex""" @@ -16,17 +17,18 @@ version_added: '1.0.0' -short_description: Gathering information about Dell EMC PowerFlex. +short_description: Gathering information about Dell EMC PowerFlex description: - Gathering information about Dell EMC PowerFlex storage system includes - Get the api details of a PowerFlex array, - Get list of volumes in PowerFlex array, - Get list of SDSs in a PowerFlex array, - Get list of SDCs in a PowerFlex array, - Get list of storage pools in PowerFlex array, - Get list of protection domains in a PowerFlex array, - Get list of snapshot policies in a PowerFlex array. + get the api details of a PowerFlex array, + get list of volumes in PowerFlex array, + get list of SDSs in a PowerFlex array, + get list of SDCs in a PowerFlex array, + get list of storage pools in PowerFlex array, + get list of protection domains in a PowerFlex array, + get list of snapshot policies in a PowerFlex array, and + get list of devices in a PowerFlex array. extends_documentation_fragment: - dellemc.powerflex.dellemc_powerflex.powerflex @@ -37,15 +39,17 @@ options: gather_subset: description: - - List of string variables to specify the Powerflex storage system entities - for which information is required. - - vol - - storage_pool - - protection_domain - - sdc - - sds - - snapshot_policy - choices: [vol, storage_pool, protection_domain, sdc, sds, snapshot_policy] + - List of string variables to specify the Powerflex storage system + entities for which information is required. + - Volumes - vol. + - Storage pools - storage_pool. + - Protection domains - protection_domain. + - SDCs - sdc. + - SDSs - sds. + - Snapshot policies - snapshot_policy. + - Devices - device. + choices: [vol, storage_pool, protection_domain, sdc, sds, + snapshot_policy, device] type: list elements: str filters: @@ -53,7 +57,6 @@ - List of filters to support filtered output for storage entities. - Each filter is a list of filter_key, filter_operator, filter_value. - Supports passing of multiple filters. - required: False type: list elements: dict suboptions: @@ -73,11 +76,13 @@ - Value of the filter key. type: str required: True +notes: + - The check_mode is not supported. ''' EXAMPLES = r''' - - name: Get detailed list of PowerFlex entities. - dellemc_powerflex_gatherfacts: + - name: Get detailed list of PowerFlex entities + dellemc.powerflex.dellemc_powerflex_gatherfacts: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -89,9 +94,10 @@ - sdc - sds - snapshot_policy + - device - - name: Get a subset list of PowerFlex volumes. - dellemc_powerflex_gatherfacts: + - name: Get a subset list of PowerFlex volumes + dellemc.powerflex.dellemc_powerflex_gatherfacts: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -106,112 +112,331 @@ RETURN = r''' changed: - description: Whether or not the resource has changed + description: Whether or not the resource has changed. returned: always type: bool + sample: 'false' Array_Details: description: System entities of PowerFlex storage array. returned: always - type: list + type: dict contains: - id: - description: - - The ID of the system + addressSpaceUsage: + description: Address space usage. type: str - systemVersionName: - description: - - system version and name + authenticationMethod: + description: Authentication method. + type: str + capacityAlertCriticalThresholdPercent: + description: Capacity alert critical threshold percentage. + type: int + capacityAlertHighThresholdPercent: + description: Capacity alert high threshold percentage. + type: int + capacityTimeLeftInDays: + description: Capacity time left in days. + type: str + cliPasswordAllowed: + description: CLI password allowed. + type: bool + daysInstalled: + description: Days installed. + type: int + defragmentationEnabled: + description: Defragmentation enabled. + type: bool + enterpriseFeaturesEnabled: + description: Enterprise eatures enabled. + type: bool + id: + description: The ID of the system. type: str installId: - description: - - installation Id + description: installation Id. type: str + isInitialLicense: + description: Initial license. + type: bool + lastUpgradeTime: + description: Last upgrade time. + type: int + managementClientSecureCommunicationEnabled: + description: Management client secure communication enabled. + type: bool + maxCapacityInGb: + description: Maximum capacity in GB. + type: dict + mdmCluster: + description: MDM cluster details. + type: dict + mdmExternalPort: + description: MDM external port. + type: int + mdmManagementPort: + description: MDM management port. + type: int mdmSecurityPolicy: - description: - - mdm security policy + description: MDM security policy. + type: str + showGuid: + description: Show guid. + type: bool + swid: + description: SWID. + type: str + systemVersionName: + description: System version and name. + type: str + tlsVersion: + description: TLS version. type: str + upgradeState: + description: Upgrade state. + type: str + sample: { + "addressSpaceUsage": "Normal", + "authenticationMethod": "Native", + "capacityAlertCriticalThresholdPercent": 90, + "capacityAlertHighThresholdPercent": 80, + "capacityTimeLeftInDays": "24", + "cliPasswordAllowed": true, + "daysInstalled": 66, + "defragmentationEnabled": true, + "enterpriseFeaturesEnabled": true, + "id": "4a54a8ba6df0690f", + "installId": "38622771228e56db", + "isInitialLicense": true, + "lastUpgradeTime": 0, + "managementClientSecureCommunicationEnabled": true, + "maxCapacityInGb": "Unlimited", + "mdmCluster": { + "clusterMode": "ThreeNodes", + "clusterState": "ClusteredNormal", + "goodNodesNum": 3, + "goodReplicasNum": 2, + "id": "5356091375512217871", + "master": { + "id": "6101582c2ca8db00", + "ips": [ + "10.47.xxx.xxx" + ], + "managementIPs": [ + "10.47.xxx.xxx" + ], + "name": "node0", + "opensslVersion": "OpenSSL 1.0.2k-fips 26 Jan 2017", + "port": 9011, + "role": "Manager", + "status": "Normal", + "versionInfo": "R3_6.0.0", + "virtualInterfaces": [ + "ens160" + ] + }, + "slaves": [ + { + "id": "23fb724015661901", + "ips": [ + "10.47.xxx.xxx" + ], + "managementIPs": [ + "10.47.xxx.xxx" + ], + "opensslVersion": "OpenSSL 1.0.2k-fips 26 Jan 2017", + "port": 9011, + "role": "Manager", + "status": "Normal", + "versionInfo": "R3_6.0.0", + "virtualInterfaces": [ + "ens160" + ] + } + ], + "tieBreakers": [ + { + "id": "6ef27eb20d0c1202", + "ips": [ + "10.47.xxx.xxx" + ], + "managementIPs": [ + "10.47.xxx.xxx" + ], + "opensslVersion": "N/A", + "port": 9011, + "role": "TieBreaker", + "status": "Normal", + "versionInfo": "R3_6.0.0" + } + ] + }, + "mdmExternalPort": 7611, + "mdmManagementPort": 6611, + "mdmSecurityPolicy": "None", + "showGuid": true, + "swid": "", + "systemVersionName": "DellEMC PowerFlex Version: R3_6.0.354", + "tlsVersion": "TLSv1.2", + "upgradeState": "NoUpgrade" + } API_Version: description: API version of PowerFlex API Gateway. returned: always type: str + sample: "3.5" Protection_Domains: - description: Details of all protection domains + description: Details of all protection domains. returned: always - type: complex + type: list contains: id: - description: - - protection domain id + description: protection domain id. type: str name: - description: - - protection domain name + description: protection domain name. type: str + sample: [ + { + "id": "9300e90900000001", + "name": "domain2" + }, + { + "id": "9300c1f900000000", + "name": "domain1" + } + ] SDCs: - description: Details of storage data clients + description: Details of storage data clients. returned: always - type: complex + type: list contains: id: - description: - - storage data client id + description: storage data client id. type: str name: - description: - - storage data client name + description: storage data client name. type: str + sample: [ + { + "id": "07335d3d00000006", + "name": "LGLAP203" + }, + { + "id": "07335d3c00000005", + "name": "LGLAP178" + }, + { + "id": "0733844a00000003" + } + ] SDSs: - description: Details of storage data servers + description: Details of storage data servers. returned: always - type: complex + type: list contains: id: - description: - - storage data server id + description: storage data server id. type: str name: - description: - - storage data server name + description: storage data server name. type: str + sample: [ + { + "id": "8f3bb0cc00000002", + "name": "node0" + }, + { + "id": "8f3bb0ce00000000", + "name": "node1" + }, + { + "id": "8f3bb15300000001", + "name": "node22" + } + ] Snapshot_Policies: - description: Details of snapshot policies + description: Details of snapshot policies. returned: always - type: complex + type: list contains: id: - description: - - snapshot policy id + description: snapshot policy id. type: str name: - description: - - snapshot policy name + description: snapshot policy name. type: str + sample: [ + { + "id": "2b380c5c00000000", + "name": "sample_snap_policy" + }, + { + "id": "2b380c5d00000001", + "name": "sample_snap_policy_1" + } + ] Storage_Pools: - description: Details of storage pools + description: Details of storage pools. returned: always - type: complex + type: list contains: id: - description: - - storage pool id + description: storage pool id. type: str name: - description: - - storage pool name + description: storage pool name. type: str + sample: [ + { + "id": "e0d8f6c900000000", + "name": "pool1" + }, + { + "id": "e0d96c1f00000002", + "name": "pool1" + } + ] Volumes: - description: Details of volumes + description: Details of volumes. + returned: always + type: list + contains: + id: + description: volume id. + type: str + name: + description: volume name. + type: str + sample: [ + { + "id": "cdd883cf00000002", + "name": "ansible-volume-1" + } + ] +Devices: + description: Details of devices. returned: always - type: complex + type: list contains: id: - description: - - volume id + description: device id. type: str name: - description: - - volume name + description: device name. type: str + sample: [ + { + "id": "b6efa59900000000", + "name": "device230" + }, + { + "id": "b6efa5fa00020000", + "name": "device_node0" + }, + { + "id": "b7f3a60900010000", + "name": "device22" + } + ] ''' from ansible.module_utils.basic import AnsibleModule @@ -283,9 +508,9 @@ def get_array_details(self): 'isInitialLicense', 'lastUpgradeTime', 'managementClientSecureCommunicationEnabled', 'maxCapacityInGb', 'mdmCluster', - 'mdmExternalPort', 'mdmManagementPort', 'mdmSecurityPolicy', - 'showGuid', 'swid', 'systemVersionName', - 'tlsVersion', 'upgradeState'] + 'mdmExternalPort', 'mdmManagementPort', + 'mdmSecurityPolicy', 'showGuid', 'swid', + 'systemVersionName', 'tlsVersion', 'upgradeState'] sys_list = self.powerflex_conn.system.get() sys_details_list = [] @@ -340,7 +565,8 @@ def get_sds_list(self, filter_dict=None): self.module.fail_json(msg=msg) def get_pd_list(self, filter_dict=None): - """ Get the list of Protection Domains on a given PowerFlex storage system """ + """ Get the list of Protection Domains on a given PowerFlex + storage system """ try: LOG.info('Getting protection domain list ') @@ -352,13 +578,14 @@ def get_pd_list(self, filter_dict=None): return result_list(pd) except Exception as e: - msg = 'Get protection domain list from powerflex array failed with' \ - ' error %s' % (str(e)) + msg = 'Get protection domain list from powerflex array failed ' \ + 'with error %s' % (str(e)) LOG.error(msg) self.module.fail_json(msg=msg) def get_storage_pool_list(self, filter_dict=None): - """ Get the list of storage pools on a given PowerFlex storage system """ + """ Get the list of storage pools on a given PowerFlex storage + system """ try: LOG.info('Getting storage pool list ') @@ -409,8 +636,27 @@ def get_snapshot_policy_list(self, filter_dict=None): return result_list(snapshot_schedules) except Exception as e: - msg = 'Get snapshot schedules list from powerflex array failed with' \ - ' error %s' % (str(e)) + msg = 'Get snapshot schedules list from powerflex array failed ' \ + 'with error %s' % (str(e)) + LOG.error(msg) + self.module.fail_json(msg=msg) + + def get_devices_list(self, filter_dict=None): + """ Get the list of devices on a given PowerFlex storage + system """ + + try: + LOG.info('Getting device list ') + if filter_dict: + devices = self.powerflex_conn.device.get(filter_fields=filter_dict) + else: + devices = self.powerflex_conn.device.get() + + return result_list(devices) + + except Exception as e: + msg = 'Get device list from powerflex array failed ' \ + 'with error %s' % (str(e)) LOG.error(msg) self.module.fail_json(msg=msg) @@ -478,6 +724,7 @@ def perform_module_operation(self): vol = [] snapshot_policy = [] protection_domain = [] + device = [] subset = self.module.params['gather_subset'] if subset is not None: @@ -493,6 +740,8 @@ def perform_module_operation(self): vol = self.get_volumes_list(filter_dict=filter_dict) if 'snapshot_policy' in subset: snapshot_policy = self.get_snapshot_policy_list(filter_dict=filter_dict) + if 'device' in subset: + device = self.get_devices_list(filter_dict=filter_dict) self.module.exit_json( Array_Details=array_details, @@ -502,7 +751,8 @@ def perform_module_operation(self): Storage_Pools=storage_pool, Volumes=vol, Snapshot_Policies=snapshot_policy, - Protection_Domains=protection_domain + Protection_Domains=protection_domain, + Devices=device ) @@ -533,7 +783,7 @@ def get_powerflex_gatherfacts_parameters(): gather_subset=dict(type='list', required=False, elements='str', choices=['vol', 'storage_pool', 'protection_domain', 'sdc', 'sds', - 'snapshot_policy']), + 'snapshot_policy', 'device']), filters=dict(type='list', required=False, elements='dict', options=dict(filter_key=dict(type='str', required=True), filter_operator=dict( diff --git a/plugins/modules/dellemc_powerflex_sdc.py b/plugins/modules/dellemc_powerflex_sdc.py index 0830812..94f6460 100644 --- a/plugins/modules/dellemc_powerflex_sdc.py +++ b/plugins/modules/dellemc_powerflex_sdc.py @@ -1,5 +1,6 @@ #!/usr/bin/python # Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) """ Ansible module for managing SDCs on PowerFlex""" @@ -13,9 +14,9 @@ DOCUMENTATION = r''' module: dellemc_powerflex_sdc version_added: '1.0.0' -short_description: Manage SDC's on Dell EMC PowerFlex. +short_description: Manage SDCs on Dell EMC PowerFlex description: -- Managing SDC's on PowerFlex storage system includes getting details of SDC +- Managing SDCs on PowerFlex storage system includes getting details of SDC and renaming SDC. author: @@ -53,11 +54,13 @@ choices: ['present', 'absent'] required: True type: str +notes: + - The check_mode is not supported. ''' EXAMPLES = r''' - name: Get SDC details using SDC ip - dellemc_powerflex_sdc: + dellemc.powerflex.dellemc_powerflex_sdc: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -66,7 +69,7 @@ state: "present" - name: Rename SDC using SDC name - dellemc_powerflex_sdc: + dellemc.powerflex.dellemc_powerflex_sdc: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -78,51 +81,89 @@ RETURN = r''' changed: - description: Whether or not the resource has changed + description: Whether or not the resource has changed. returned: always type: bool + sample: 'false' sdc_details: - description: Details of the SDC + description: Details of the SDC. returned: When SDC exists type: complex contains: id: - description: - - The ID of the SDC + description: The ID of the SDC. type: str name: - description: - - Name of the SDC + description: Name of the SDC. type: str sdcIp: - description: - - IP of the SDC + description: IP of the SDC. type: str osType: - description: - - OS type of the SDC + description: OS type of the SDC. type: str mapped_volumes: - description: The details of the mapped volumes + description: The details of the mapped volumes. type: list contains: id: - description: - - The ID of the volume + description: The ID of the volume. type: str name: - description: - - The name of the volume + description: The name of the volume. type: str volumeType: - description: - - Type of the volume + description: Type of the volume. type: str sdcApproved: - description: - - Indicates whether an SDC has approved access to the system + description: Indicates whether an SDC has approved access to the + system. type: bool + sample: { + "id": "07335d3d00000006", + "installedSoftwareVersionInfo": "R3_6.0.0", + "kernelBuildNumber": null, + "kernelVersion": "3.10.0", + "links": [ + { + "href": "/api/instances/Sdc::07335d3d00000006", + "rel": "self" + }, + { + "href": "/api/instances/Sdc::07335d3d00000006/relationships/ + Statistics", + "rel": "/api/Sdc/relationship/Statistics" + }, + { + "href": "/api/instances/Sdc::07335d3d00000006/relationships/ + Volume", + "rel": "/api/Sdc/relationship/Volume" + }, + { + "href": "/api/instances/System::4a54a8ba6df0690f", + "rel": "/api/parent/relationship/systemId" + } + ], + "mapped_volumes": [], + "mdmConnectionState": "Disconnected", + "memoryAllocationFailure": null, + "name": "LGLAP203", + "osType": "Linux", + "peerMdmId": null, + "perfProfile": "HighPerformance", + "sdcApproved": true, + "sdcApprovedIps": null, + "sdcGuid": "F8ECB844-23B8-4629-92BB-B6E49A1744CB", + "sdcIp": "N/A", + "sdcIps": null, + "sdcType": "AppSdc", + "sdrId": null, + "socketAllocationFailure": null, + "softwareVersionInfo": "R3_6.0.0", + "systemId": "4a54a8ba6df0690f", + "versionInfo": "R3_6.0.0" + } ''' from ansible.module_utils.basic import AnsibleModule @@ -206,7 +247,13 @@ def get_sdc(self, sdc_name=None, sdc_ip=None, sdc_id=None): :return: The dict containing SDC details """ - id_ip_name = sdc_ip if sdc_ip else sdc_name if sdc_name else sdc_id + if sdc_name: + id_ip_name = sdc_name + elif sdc_ip: + id_ip_name = sdc_ip + else: + id_ip_name = sdc_id + try: if sdc_name: sdc_details = self.powerflex_conn.sdc.get( @@ -268,7 +315,12 @@ def perform_module_operation(self): sdc_details = self.get_sdc(sdc_name=sdc_name, sdc_id=sdc_id, sdc_ip=sdc_ip) - id_ip_name = sdc_ip if sdc_ip else sdc_name if sdc_name else sdc_id + if sdc_name: + id_ip_name = sdc_name + elif sdc_ip: + id_ip_name = sdc_ip + else: + id_ip_name = sdc_id if state == 'present' and not sdc_details: error_msg = 'Could not find any SDC instance with ' \ diff --git a/plugins/modules/dellemc_powerflex_sds.py b/plugins/modules/dellemc_powerflex_sds.py new file mode 100644 index 0000000..a3adf9a --- /dev/null +++ b/plugins/modules/dellemc_powerflex_sds.py @@ -0,0 +1,1167 @@ +#!/usr/bin/python +# Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) + +""" Ansible module for managing SDS on PowerFlex""" + +from __future__ import (absolute_import, division, print_function) + +__metaclass__ = type +ANSIBLE_METADATA = {'metadata_version': '1.1', + 'status': ['preview'], + 'supported_by': 'community'} + +DOCUMENTATION = r''' +module: dellemc_powerflex_sds +version_added: '1.1.0' +short_description: Manage SDS on Dell EMC PowerFlex +description: +- Managing SDS on PowerFlex storage system includes + creating new SDS, getting details of SDS, adding/removing IP to/from SDS, + modifying attributes of SDS, and deleting SDS. +author: +- Rajshree Khare (@khareRajshree) +extends_documentation_fragment: + - dellemc.powerflex.dellemc_powerflex.powerflex +options: + sds_name: + description: + - The name of the SDS. + - Mandatory for create operation. + - It is unique across the PowerFlex array. + - Mutually exclusive with sds_id. + type: str + sds_id: + description: + - The ID of the SDS. + - Except create operation, all other operations can be performed + using sds_id. + - Mutually exclusive with sds_name. + type: str + protection_domain_name: + description: + - The name of the protection domain. + - Mutually exclusive with protection_domain_id. + type: str + protection_domain_id: + description: + - The ID of the protection domain. + - Mutually exclusive with protection_domain_name. + type: str + sds_ip_list: + description: + - Dictionary of IPs and their roles for the SDS. + - At least one IP-role is mandatory while creating a SDS. + - IP-roles can be updated as well. + type: list + elements: dict + suboptions: + ip: + description: + - IP address of the SDS. + type: str + required: True + role: + description: + - Role assigned to the SDS IP address. + choices: ['sdsOnly', 'sdcOnly', 'all'] + type: str + required: True + sds_ip_state: + description: + - State of IP with respect to the SDS. + choices: ['present-in-sds', 'absent-in-sds'] + type: str + rfcache_enabled: + description: + - Whether to enable the Read Flash cache. + type: bool + rmcache_enabled: + description: + - Whether to enable the Read RAM cache. + type: bool + rmcache_size: + description: + - Read RAM cache size (in MB). + - Minimum size is 128 MB. + - Maximum size is 3911 MB. + type: int + sds_new_name: + description: + - SDS new name. + type: str + performance_profile: + description: + - Performance profile to apply to the SDS. + - The HighPerformance profile configures a predefined set of parameters + for very high performance use cases. + - Default value by API is "HighPerformance". + choices: ['Compact', 'HighPerformance'] + type: str + state: + description: + - State of the SDS. + choices: ['present', 'absent'] + required: True + type: str +notes: + - The maximum limit for the IPs that can be associated with an SDS is 8. + - There needs to be at least 1 IP for SDS communication and 1 for SDC + communication(if only 1 IP exists, it must be with role 'all'; else 1 IP + can be with role 'all'and other IPs with role 'sdcOnly'; or 1 IP must be + with role 'sdsOnly' and others with role 'sdcOnly'). + - There can be 1 or more IPs with role 'sdcOnly'. + - There must be only 1 IP with SDS role (either with role 'all' or + 'sdsOnly'). + - SDS can be created with RF cache disabled, but, be aware that the RF cache + is not always updated. In this case, the user should re-try the operation. + - The check_mode is not supported. +''' + +EXAMPLES = r''' +- name: Create SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + protection_domain_name: "domain1" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "all" + sds_ip_state: "present-in-sds" + state: "present" + +- name: Create SDS with all parameters + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node1" + protection_domain_name: "domain1" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "present-in-sds" + rmcache_enabled: true + rmcache_size: 128 + performance_profile: "HighPerformance" + state: "present" + +- name: Get SDS details using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + state: "present" + +- name: Get SDS details using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + state: "present" + +- name: Modify SDS attributes using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_new_name: "node0_new" + rfcache_enabled: true + rmcache_enabled: true + rmcache_size: 256 + performance_profile: "HighPerformance" + state: "present" + +- name: Modify SDS attributes using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + sds_new_name: "node0_new" + rfcache_enabled: true + rmcache_enabled: true + rmcache_size: 256 + performance_profile: "HighPerformance" + state: "present" + +- name: Add IP and role to an SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "present-in-sds" + state: "present" + +- name: Remove IP and role from an SDS + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + sds_ip_list: + - ip: "198.10.xxx.xxx" + role: "sdcOnly" + sds_ip_state: "absent-in-sds" + state: "present" + +- name: Delete SDS using name + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_name: "node0" + state: "absent" + +- name: Delete SDS using ID + dellemc.powerflex.dellemc_powerflex_sds: + gateway_host: "{{gateway_host}}" + username: "{{username}}" + password: "{{password}}" + verifycert: "{{verifycert}}" + port: "{{port}}" + sds_id: "5718253c00000004" + state: "absent" +''' + +RETURN = r''' +changed: + description: Whether or not the resource has changed. + returned: always + type: bool + sample: 'false' +sds_details: + description: Details of the SDS. + returned: When SDS exists + type: complex + contains: + authenticationError: + description: Indicates authentication error. + type: str + certificateInfo: + description: Information about certificate. + type: str + configuredDrlMode: + description: Configured DRL mode. + type: str + drlMode: + description: DRL mode. + type: str + faultSetId: + description: Fault set ID. + type: str + fglMetadataCacheSize: + description: FGL metadata cache size. + type: int + fglMetadataCacheState: + description: FGL metadata cache state. + type: str + fglNumConcurrentWrites: + description: FGL concurrent writes. + type: int + id: + description: SDS ID. + type: str + ipList: + description: SDS IP list. + type: list + contains: + ip: + description: IP present in the SDS. + type: str + role: + description: Role of the SDS IP. + type: str + lastUpgradeTime: + description: Last time SDS was upgraded. + type: str + links: + description: SDS links. + type: list + contains: + href: + description: SDS instance URL. + type: str + rel: + description: SDS's relationship with different entities. + type: str + maintenanceState: + description: Maintenance state. + type: str + maintenanceType: + description: Maintenance type. + type: str + mdmConnectionState: + description: MDM connection state. + type: str + membershipState: + description: Membership state. + type: str + name: + description: Name of the SDS. + type: str + numOfIoBuffers: + description: Number of IO buffers. + type: int + numRestarts: + description: Number of restarts. + type: int + onVmWare: + description: Presence on VMware. + type: bool + perfProfile: + description: Performance profile. + type: str + port: + description: SDS port. + type: int + protectionDomainId: + description: Protection Domain ID. + type: str + protectionDomainName: + description: Protection Domain Name. + type: str + raidControllers: + description: Number of RAID controllers. + type: int + rfcacheEnabled: + description: Whether RF cache is enabled or not. + type: bool + rfcacheErrorApiVersionMismatch: + description: RF cache error for API version mismatch. + type: bool + rfcacheErrorDeviceDoesNotExist: + description: RF cache error for device does not exist. + type: bool + rfcacheErrorInconsistentCacheConfiguration: + description: RF cache error for inconsistent cache configuration. + type: bool + rfcacheErrorInconsistentSourceConfiguration: + description: RF cache error for inconsistent source configuration. + type: bool + rfcacheErrorInvalidDriverPath: + description: RF cache error for invalid driver path. + type: bool + rfcacheErrorLowResources: + description: RF cache error for low resources. + type: bool + rmcacheEnabled: + description: Whether Read RAM cache is enabled or not. + type: bool + rmcacheFrozen: + description: RM cache frozen. + type: bool + rmcacheMemoryAllocationState: + description: RM cache memory allocation state. + type: bool + rmcacheSizeInKb: + description: RM cache size in KB. + type: int + rmcacheSizeInMb: + description: RM cache size in MB. + type: int + sdsConfigurationFailure: + description: SDS configuration failure. + type: str + sdsDecoupled: + description: SDS decoupled. + type: str + sdsReceiveBufferAllocationFailures: + description: SDS receive buffer allocation failures. + type: str + sdsState: + description: SDS state. + type: str + softwareVersionInfo: + description: SDS software version information. + type: str + sample: { + "authenticationError": "None", + "certificateInfo": null, + "configuredDrlMode": "Volatile", + "drlMode": "Volatile", + "faultSetId": null, + "fglMetadataCacheSize": 0, + "fglMetadataCacheState": "Disabled", + "fglNumConcurrentWrites": 1000, + "id": "8f3bb0cc00000002", + "ipList": [ + { + "ip": "10.47.xxx.xxx", + "role": "all" + } + ], + "lastUpgradeTime": 0, + "links": [ + { + "href": "/api/instances/Sds::8f3bb0cc00000002", + "rel": "self" + }, + { + "href": "/api/instances/Sds::8f3bb0cc00000002/relationships + /Statistics", + "rel": "/api/Sds/relationship/Statistics" + }, + { + "href": "/api/instances/Sds::8f3bb0cc00000002/relationships + /SpSds", + "rel": "/api/Sds/relationship/SpSds" + }, + { + "href": "/api/instances/Sds::8f3bb0cc00000002/relationships + /Device", + "rel": "/api/Sds/relationship/Device" + }, + { + "href": "/api/instances/ProtectionDomain::9300c1f900000000", + "rel": "/api/parent/relationship/protectionDomainId" + } + ], + "maintenanceState": "NoMaintenance", + "maintenanceType": "NoMaintenance", + "mdmConnectionState": "Connected", + "membershipState": "Joined", + "name": "node0", + "numOfIoBuffers": null, + "numRestarts": 2, + "onVmWare": true, + "perfProfile": "HighPerformance", + "port": 7072, + "protectionDomainId": "9300c1f900000000", + "protectionDomainName": "domain1", + "raidControllers": null, + "rfcacheEnabled": true, + "rfcacheErrorApiVersionMismatch": false, + "rfcacheErrorDeviceDoesNotExist": false, + "rfcacheErrorInconsistentCacheConfiguration": false, + "rfcacheErrorInconsistentSourceConfiguration": false, + "rfcacheErrorInvalidDriverPath": false, + "rfcacheErrorLowResources": false, + "rmcacheEnabled": true, + "rmcacheFrozen": false, + "rmcacheMemoryAllocationState": "AllocationPending", + "rmcacheSizeInKb": 131072, + "rmcacheSizeInMb": 128, + "sdsConfigurationFailure": null, + "sdsDecoupled": null, + "sdsReceiveBufferAllocationFailures": null, + "sdsState": "Normal", + "softwareVersionInfo": "R3_6.0.0" + } +''' + +from ansible.module_utils.basic import AnsibleModule +from ansible_collections.dellemc.powerflex.plugins.module_utils.storage.dell\ + import dellemc_ansible_powerflex_utils as utils +import copy + +LOG = utils.get_logger('dellemc_powerflex_sds') + +MISSING_PACKAGES_CHECK = utils.pypowerflex_version_check() + + +class PowerFlexSDS(object): + """Class with SDS operations""" + + def __init__(self): + """ Define all parameters required by this module""" + self.module_params = utils.get_powerflex_gateway_host_parameters() + self.module_params.update(get_powerflex_sds_parameters()) + + mut_ex_args = [['sds_name', 'sds_id'], + ['protection_domain_name', 'protection_domain_id']] + + required_together_args = [['sds_ip_list', 'sds_ip_state']] + + required_one_of_args = [['sds_name', 'sds_id']] + + # initialize the Ansible module + self.module = AnsibleModule( + argument_spec=self.module_params, + supports_check_mode=False, + mutually_exclusive=mut_ex_args, + required_together=required_together_args, + required_one_of=required_one_of_args) + + if MISSING_PACKAGES_CHECK and \ + not MISSING_PACKAGES_CHECK['dependency_present']: + error_msg = MISSING_PACKAGES_CHECK['error_message'] + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + try: + self.powerflex_conn = utils.get_powerflex_gateway_host_connection( + self.module.params) + LOG.info("Got the PowerFlex system connection object instance") + except Exception as e: + LOG.error(str(e)) + self.module.fail_json(msg=str(e)) + + def validate_rmcache_size_parameter(self, rmcache_enabled, rmcache_size): + """Validate the input parameters""" + + # RM cache size cannot be set only when RM cache is enabled + if rmcache_size is not None and rmcache_enabled is False: + error_msg = "RM cache size can be set only when RM cache " \ + "is enabled, please enable it along with RM " \ + "cache size." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def validate_ip_parameter(self, sds_ip_list): + """Validate the input parameters""" + + if sds_ip_list is None or len(sds_ip_list) == 0: + error_msg = "Provide valid values for " \ + "sds_ip_list as 'ip' and 'role' for Create/Modify " \ + "operations." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_sds_details(self, sds_name=None, sds_id=None): + """Get SDS details + :param sds_name: Name of the SDS + :type sds_name: str + :param sds_id: ID of the SDS + :type sds_id: str + :return: Details of SDS if it exist + :rtype: dict + """ + + id_or_name = sds_id if sds_id else sds_name + + try: + if sds_name: + sds_details = self.powerflex_conn.sds.get( + filter_fields={'name': sds_name}) + else: + sds_details = self.powerflex_conn.sds.get( + filter_fields={'id': sds_id}) + + if len(sds_details) == 0: + msg = "SDS with identifier '%s' not found" % id_or_name + LOG.info(msg) + return None + + return sds_details[0] + + except Exception as e: + error_msg = "Failed to get the SDS '%s' with error '%s'" \ + % (id_or_name, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def get_protection_domain(self, protection_domain_name=None, + protection_domain_id=None): + """Get protection domain details + :param protection_domain_name: Name of the protection domain + :param protection_domain_id: ID of the protection domain + :return: Protection domain details + :rtype: dict + """ + name_or_id = protection_domain_id if protection_domain_id \ + else protection_domain_name + try: + pd_details = None + if protection_domain_id: + pd_details = self.powerflex_conn.protection_domain.get( + filter_fields={'id': protection_domain_id}) + + if protection_domain_name: + pd_details = self.powerflex_conn.protection_domain.get( + filter_fields={'name': protection_domain_name}) + + if not pd_details: + error_msg = "Unable to find the protection domain with " \ + "'%s'. Please enter a valid protection domain " \ + "name/id." % name_or_id + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + return pd_details[0] + + except Exception as e: + error_msg = "Failed to get the protection domain '%s' with " \ + "error '%s'" % (name_or_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def restructure_ip_role_dict(self, sds_ip_list): + """Restructure IP role dict + :param sds_ip_list: List of one or more IP addresses and + their roles + :type sds_ip_list: list[dict] + :return: List of one or more IP addresses and their roles + :rtype: list[dict] + """ + new_sds_ip_list = [] + for item in sds_ip_list: + new_sds_ip_list.append({"SdsIp": item}) + return new_sds_ip_list + + def create_sds(self, protection_domain_id, sds_ip_list, sds_ip_state, + sds_name, rmcache_enabled=None, rmcache_size=None): + """Create SDS + :param protection_domain_id: ID of the Protection Domain + :type protection_domain_id: str + :param sds_ip_list: List of one or more IP addresses associated + with the SDS over which the data will be + transferred. + :type sds_ip_list: list[dict] + :param sds_ip_state: SDS IP state + :type sds_ip_state: str + :param sds_name: SDS name + :type sds_name: str + :param rmcache_enabled: Whether to enable the Read RAM cache + :type rmcache_enabled: bool + :param rmcache_size: Read RAM cache size (in MB) + :type rmcache_size: int + :return: Boolean indicating if create operation is successful + """ + try: + if sds_name is None or len(sds_name.strip()) == 0: + error_msg = "Please provide valid sds_name value for " \ + "creation of SDS." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if protection_domain_id is None: + error_msg = "Protection Domain is a mandatory parameter " \ + "for creating a SDS. Please enter a valid value." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_ip_list is None or len(sds_ip_list) == 0: + error_msg = "Please provide valid sds_ip_list values for " \ + "creation of SDS." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_ip_state is not None and sds_ip_state != "present-in-sds": + error_msg = "Incorrect IP state given for creation of SDS." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + # Restructure IP-role parameter format + if sds_ip_list and sds_ip_state == "present-in-sds": + sds_ip_list = self.restructure_ip_role_dict(sds_ip_list) + + if rmcache_size is not None: + self.validate_rmcache_size_parameter(rmcache_enabled, + rmcache_size) + # set rmcache size in KB + rmcache_size = rmcache_size * 1024 + + create_params = ("protection_domain_id: %s," + " sds_ip_list: %s," + " sds_name: %s," + " rmcache_enabled: %s, " + " rmcache_size_KB: %s" + % (protection_domain_id, sds_ip_list, + sds_name, rmcache_enabled, rmcache_size)) + LOG.info("Creating SDS with params: %s", create_params) + + self.powerflex_conn.sds.create( + protection_domain_id=protection_domain_id, + sds_ips=sds_ip_list, + name=sds_name, + rmcache_enabled=rmcache_enabled, + rmcache_size_in_kb=rmcache_size) + return True + + except Exception as e: + error_msg = "Create SDS '%s' operation failed with error '%s'" \ + % (sds_name, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def to_modify(self, sds_details, sds_new_name, rfcache_enabled, + rmcache_enabled, rmcache_size, performance_profile): + """ + :param sds_details: Details of the SDS + :type sds_details: dict + :param sds_new_name: New name of SDS + :type sds_new_name: str + :param rfcache_enabled: Whether to enable the Read Flash cache + :type rfcache_enabled: bool + :param rmcache_enabled: Whether to enable the Read RAM cache + :type rmcache_enabled: bool + :param rmcache_size: Read RAM cache size (in MB) + :type rmcache_size: int + :param performance_profile: Performance profile to apply to the SDS + :type performance_profile: str + :return: Dictionary containing the attributes of SDS which are to be + updated + :rtype: dict + """ + modify_dict = {} + + if sds_new_name is not None: + if len(sds_new_name.strip()) == 0: + error_msg = "Please provide valid SDS name." + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + if sds_new_name != sds_details['name']: + modify_dict['name'] = sds_new_name + + if rfcache_enabled is not None and \ + sds_details['rfcacheEnabled'] != rfcache_enabled: + modify_dict['rfcacheEnabled'] = rfcache_enabled + + if rmcache_enabled is not None and \ + sds_details['rmcacheEnabled'] != rmcache_enabled: + modify_dict['rmcacheEnabled'] = rmcache_enabled + + if rmcache_size is not None: + self.validate_rmcache_size_parameter(rmcache_enabled, + rmcache_size) + exisitng_size_mb = sds_details['rmcacheSizeInKb'] / 1024 + if rmcache_size != exisitng_size_mb: + if sds_details['rmcacheEnabled']: + modify_dict['rmcacheSizeInMB'] = rmcache_size + else: + error_msg = "Failed to update RM cache size for the " \ + "SDS '%s' as RM cache is disabled " \ + "previously, please enable it before " \ + "setting the size." \ + % sds_details['name'] + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + if performance_profile is not None and \ + sds_details['perfProfile'] != performance_profile: + modify_dict['perfProfile'] = performance_profile + + return modify_dict + + def modify_sds_attributes(self, sds_id, modify_dict, + create_flag=False): + """Modify SDS attributes + :param sds_id: SDS ID + :type sds_id: str + :param modify_dict: Dictionary containing the attributes of SDS + which are to be updated + :type modify_dict: dict + :param create_flag: Flag to indicate whether modify operation is + followed by create operation or not + :type create_flag: bool + :return: Boolean indicating if the operation is successful + """ + try: + msg = "Dictionary containing attributes which are to be" \ + " updated is '%s'." % (str(modify_dict)) + LOG.info(msg) + + if 'name' in modify_dict: + self.powerflex_conn.sds.rename(sds_id, modify_dict['name']) + msg = "The name of the SDS is updated to '%s' successfully." \ + % modify_dict['name'] + LOG.info(msg) + + if 'rfcacheEnabled' in modify_dict: + self.powerflex_conn.sds.set_rfcache_enabled( + sds_id, modify_dict['rfcacheEnabled']) + msg = "The use RFcache is updated to '%s' successfully." \ + % modify_dict['rfcacheEnabled'] + LOG.info(msg) + + if 'rmcacheEnabled' in modify_dict: + self.powerflex_conn.sds.set_rmcache_enabled( + sds_id, modify_dict['rmcacheEnabled']) + msg = "The use RMcache is updated to '%s' successfully." \ + % modify_dict['rmcacheEnabled'] + LOG.info(msg) + + if 'rmcacheSizeInMB' in modify_dict: + self.powerflex_conn.sds.set_rmcache_size( + sds_id, modify_dict['rmcacheSizeInMB']) + msg = "The size of RMcache is updated to '%s' successfully." \ + % modify_dict['rmcacheSizeInMB'] + LOG.info(msg) + + if 'perfProfile' in modify_dict: + self.powerflex_conn.sds.set_performance_parameters( + sds_id, modify_dict['perfProfile']) + msg = "The performance profile is updated to '%s'" \ + % modify_dict['perfProfile'] + LOG.info(msg) + + return True + except Exception as e: + if create_flag: + error_msg = "Create SDS is successful, but failed to update" \ + " the SDS '%s' with error '%s'"\ + % (sds_id, str(e)) + else: + error_msg = "Failed to update the SDS '%s' with error '%s'" \ + % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def identify_ip_role(self, sds_ip_list, sds_details, sds_ip_state): + """Identify IPs before addition/removal + :param sds_ip_list: List of one or more IP addresses and + their roles + :type sds_ip_list: list[dict] + :param sds_details: SDS details + :type sds_details: dict + :param sds_ip_state: State of IP in SDS + :type sds_ip_state: str + :return: List containing the key-value pairs of IP-role for an + SDS + :rtype: list[dict] + """ + existing_ip_role_list = sds_details['ipList'] + + # identify IPs to add or roles to update + if sds_ip_state == "present-in-sds": + update_role = [] + ips_to_add = [] + + # identify IPs to add + existing_ip_list = [] + if existing_ip_role_list: + for ip in existing_ip_role_list: + existing_ip_list.append(ip['ip']) + for given_ip in sds_ip_list: + ip = given_ip['ip'] + if ip not in existing_ip_list: + ips_to_add.append(given_ip) + LOG.info("IP(s) to be added: %s", ips_to_add) + + if len(ips_to_add) != 0: + for ip in ips_to_add: + sds_ip_list.remove(ip) + + # identify IPs whose role needs to be updated + update_role = [ip for ip in sds_ip_list + if ip not in existing_ip_role_list] + LOG.info("Role update needed for: %s", update_role) + + return ips_to_add, update_role + + elif sds_ip_state == "absent-in-sds": + # identify IPs to remove + ips_to_remove = [ip for ip in existing_ip_role_list + if ip in sds_ip_list] + if len(ips_to_remove) != 0: + LOG.info("IP(s) to remove: %s", ips_to_remove) + return ips_to_remove + else: + LOG.info("IP(s) do not exists.") + return False, None + + def add_ip(self, sds_id, sds_ip_list): + """Add IP to SDS + :param sds_id: SDS ID + :type sds_id: str + :param sds_ip_list: List of one or more IP addresses and + their roles + :type sds_ip_list: list[dict] + :return: Boolean indicating if add IP operation is successful + """ + try: + for ip in sds_ip_list: + LOG.info("IP to add: %s", ip) + self.powerflex_conn.sds.add_ip(sds_id=sds_id, sds_ip=ip) + LOG.info("IP added successfully.") + return True + except Exception as e: + error_msg = "Add IP to SDS '%s' operation failed with " \ + "error '%s'" % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def update_role(self, sds_id, sds_ip_list): + """Update IP's role for an SDS + :param sds_id: SDS ID + :type sds_id: str + :param sds_ip_list: List of one or more IP addresses and + their roles + :type sds_ip_list: list[dict] + :return: Boolean indicating if add IP operation is successful + """ + try: + LOG.info("Role updates for: %s", sds_ip_list) + if len(sds_ip_list) != 0: + for ip in sds_ip_list: + LOG.info("ip-role: %s", ip) + self.powerflex_conn.sds.set_ip_role(sds_id, ip['ip'], + ip['role']) + msg = "The role '%s' for IP '%s' is updated " \ + "successfully." % (ip['role'], ip['ip']) + LOG.info(msg) + return True + except Exception as e: + error_msg = "Update role of IP for SDS '%s' operation failed " \ + "with error '%s'" % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def remove_ip(self, sds_id, sds_ip_list): + """Remove IP from SDS + :param sds_id: SDS ID + :type sds_id: str + :param sds_ip_list: List of one or more IP addresses and + their roles. + :type sds_ip_list: list[dict] + :return: Boolean indicating if remove IP operation is successful + """ + try: + for ip in sds_ip_list: + LOG.info("IP to remove: %s", ip) + self.powerflex_conn.sds.remove_ip(sds_id=sds_id, ip=ip['ip']) + LOG.info("IP removed successfully.") + return True + except Exception as e: + error_msg = "Remove IP from SDS '%s' operation failed with " \ + "error '%s'" % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def delete_sds(self, sds_id): + """Delete SDS + :param sds_id: SDS ID + :type sds_id: str + :return: Boolean indicating if delete operation is successful + """ + try: + self.powerflex_conn.sds.delete(sds_id) + return True + except Exception as e: + error_msg = "Delete SDS '%s' operation failed with error '%s'" \ + % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + def perform_module_operation(self): + """ + Perform different actions on SDS based on parameters passed in + the playbook + """ + sds_name = self.module.params['sds_name'] + sds_id = self.module.params['sds_id'] + sds_new_name = self.module.params['sds_new_name'] + protection_domain_name = self.module.params['protection_domain_name'] + protection_domain_id = self.module.params['protection_domain_id'] + rfcache_enabled = self.module.params['rfcache_enabled'] + rmcache_enabled = self.module.params['rmcache_enabled'] + rmcache_size = self.module.params['rmcache_size'] + sds_ip_list = copy.deepcopy(self.module.params['sds_ip_list']) + sds_ip_state = self.module.params['sds_ip_state'] + performance_profile = self.module.params['performance_profile'] + state = self.module.params['state'] + + # result is a dictionary to contain end state and SDS details + changed = False + result = dict( + changed=False, + sds_details=None + ) + + # get SDS details + sds_details = self.get_sds_details(sds_name, sds_id) + if sds_details: + sds_id = sds_details['id'] + msg = "Fetched the SDS details %s" % (str(sds_details)) + LOG.info(msg) + + # get Protection Domain ID from name + if protection_domain_name: + pd_details = self.get_protection_domain(protection_domain_name) + if pd_details: + protection_domain_id = pd_details['id'] + msg = "Fetched the protection domain details with id '%s', " \ + "name '%s'" % (protection_domain_id, protection_domain_name) + LOG.info(msg) + + # create operation + create_changed = False + if state == 'present' and not sds_details: + if sds_id: + error_msg = "Creation of SDS is allowed using sds_name " \ + "only, sds_id given." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + + if sds_new_name: + error_msg = "sds_new_name parameter is not supported " \ + "during creation of a SDS. Try renaming the " \ + "SDS after the creation." + LOG.info(error_msg) + self.module.fail_json(msg=error_msg) + + self.validate_ip_parameter(sds_ip_list) + + create_changed = self.create_sds(protection_domain_id, + sds_ip_list, sds_ip_state, + sds_name, rmcache_enabled, + rmcache_size) + if create_changed: + sds_details = self.get_sds_details(sds_name) + sds_id = sds_details['id'] + msg = "SDS created successfully, fetched SDS details %s"\ + % (str(sds_details)) + LOG.info(msg) + + # checking if basic SDS parameters are modified or not + modify_dict = {} + if sds_details and state == 'present': + modify_dict = self.to_modify(sds_details, sds_new_name, + rfcache_enabled, rmcache_enabled, + rmcache_size, performance_profile) + msg = "Parameters to be modified are as follows: %s"\ + % (str(modify_dict)) + LOG.info(msg) + + # modify operation + modify_changed = False + if modify_dict and state == 'present': + LOG.info("Modify SDS params.") + modify_changed = self.modify_sds_attributes(sds_id, modify_dict, + create_changed) + + # get updated SDS details + sds_details = self.get_sds_details(sds_id=sds_id) + + # add IPs to SDS + # update IP's role for an SDS + add_ip_changed = False + update_role_changed = False + if sds_details and state == 'present' \ + and sds_ip_state == "present-in-sds": + self.validate_ip_parameter(sds_ip_list) + ips_to_add, roles_to_update = self.identify_ip_role( + sds_ip_list, sds_details, sds_ip_state) + if ips_to_add: + add_ip_changed = self.add_ip(sds_id, ips_to_add) + if roles_to_update: + update_role_changed = self.update_role(sds_id, + roles_to_update) + + # remove IPs from SDS + remove_ip_changed = False + if sds_details and state == 'present' \ + and sds_ip_state == "absent-in-sds": + self.validate_ip_parameter(sds_ip_list) + ips_to_remove = self.identify_ip_role(sds_ip_list, sds_details, + sds_ip_state) + if ips_to_remove: + remove_ip_changed = self.remove_ip(sds_id, ips_to_remove) + + # delete operation + delete_changed = False + if sds_details and state == 'absent': + delete_changed = self.delete_sds(sds_id) + + if create_changed or modify_changed or add_ip_changed \ + or update_role_changed or remove_ip_changed or delete_changed: + changed = True + + # Returning the updated SDS details + if state == 'present': + sds_details = self.show_output(sds_id) + result['sds_details'] = sds_details + result['changed'] = changed + self.module.exit_json(**result) + + def show_output(self, sds_id): + """Show SDS details + :param sds_id: ID of the SDS + :type sds_id: str + :return: Details of SDS + :rtype: dict + """ + + try: + sds_details = self.powerflex_conn.sds.get( + filter_fields={'id': sds_id}) + + if len(sds_details) == 0: + msg = "SDS with identifier '%s' not found" % sds_id + LOG.error(msg) + return None + + # Append protection domain name + if 'protectionDomainId' in sds_details[0] \ + and sds_details[0]['protectionDomainId']: + pd_details = self.get_protection_domain( + protection_domain_id=sds_details[0]['protectionDomainId']) + sds_details[0]['protectionDomainName'] = pd_details['name'] + + # Append rmcache size in MB + if 'rmcacheSizeInKb' in sds_details[0] \ + and sds_details[0]['rmcacheSizeInKb']: + rmcache_size_mb = sds_details[0]['rmcacheSizeInKb'] / 1024 + sds_details[0]['rmcacheSizeInMb'] = int(rmcache_size_mb) + + return sds_details[0] + + except Exception as e: + error_msg = "Failed to get the SDS '%s' with error '%s'"\ + % (sds_id, str(e)) + LOG.error(error_msg) + self.module.fail_json(msg=error_msg) + + +def get_powerflex_sds_parameters(): + """This method provide parameter required for the SDS module on + PowerFlex""" + return dict( + sds_name=dict(), + sds_id=dict(), + sds_new_name=dict(), + protection_domain_name=dict(), + protection_domain_id=dict(), + sds_ip_list=dict( + type='list', elements='dict', options=dict( + ip=dict(required=True), + role=dict(required=True, choices=['all', 'sdsOnly', + 'sdcOnly']) + ) + ), + sds_ip_state=dict(choices=['present-in-sds', 'absent-in-sds']), + rfcache_enabled=dict(type='bool'), + rmcache_enabled=dict(type='bool'), + rmcache_size=dict(type='int'), + performance_profile=dict(choices=['Compact', 'HighPerformance']), + state=dict(required=True, type='str', choices=['present', 'absent']) + ) + + +def main(): + """ Create PowerFlex SDS object and perform actions on it + based on user input from playbook""" + obj = PowerFlexSDS() + obj.perform_module_operation() + + +if __name__ == '__main__': + main() diff --git a/plugins/modules/dellemc_powerflex_snapshot.py b/plugins/modules/dellemc_powerflex_snapshot.py index 6deaba1..8dbc330 100644 --- a/plugins/modules/dellemc_powerflex_snapshot.py +++ b/plugins/modules/dellemc_powerflex_snapshot.py @@ -1,5 +1,6 @@ #!/usr/bin/python # Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) """ Ansible module for managing Snapshots on PowerFlex""" @@ -13,7 +14,7 @@ DOCUMENTATION = r''' module: dellemc_powerflex_snapshot version_added: '1.0.0' -short_description: Manage Snapshots on Dell EMC PowerFlex. +short_description: Manage Snapshots on Dell EMC PowerFlex description: - Managing snapshots on PowerFlex Storage System includes creating new snapshot, getting details of snapshot, @@ -84,7 +85,7 @@ type: str sdc: description: - - Specifies SDC parameters + - Specifies SDC parameters. type: list elements: dict suboptions: @@ -139,11 +140,13 @@ choices: ['present', 'absent'] required: True type: str +notes: + - The check_mode is not supported. ''' EXAMPLES = r''' - name: Create snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -155,7 +158,7 @@ state: "present" - name: Get snapshot details using snapshot id - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -164,28 +167,28 @@ state: "present" - name: Map snapshot to SDC - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" - sdc_id: "663ac0d200000001" allow_multiple_mappings: True sdc_state: "mapped" state: "present" - name: Modify the attributes of SDC mapped to snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" iops_limit: 11 bandwidth_limit: 4096 - sdc_id: "663ac0d200000001" @@ -196,7 +199,7 @@ state: "present" - name: Extend the size of snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -206,20 +209,20 @@ state: "present" - name: Unmap SDCs from snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" verifycert: "{{verifycert}}" snapshot_id: "fe6cb28200000007" sdc: - - sdc_ip: "10.247.66.203" + - sdc_ip: "198.10.xxx.xxx" - sdc_id: "663ac0d200000001" sdc_state: "unmapped" state: "present" - name: Rename snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -229,7 +232,7 @@ state: "present" - name: Delete snapshot - dellemc_powerflex_snapshot: + dellemc.powerflex.dellemc_powerflex_snapshot: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -241,87 +244,129 @@ RETURN = r''' changed: - description: Whether or not the resource has changed + description: Whether or not the resource has changed. returned: always type: bool + sample: 'false' snapshot_details: - description: Details of the snapshot + description: Details of the snapshot. returned: When snapshot exists type: complex contains: ancestorVolumeId: - description: - - The ID of the root of the specified volume's V-Tree + description: The ID of the root of the specified volume's V-Tree. type: str ancestorVolumeName: - description: - - The name of the root of the specified volume's V-Tree + description: The name of the root of the specified volume's V-Tree. type: str creationTime: - description: - - The creation time of the snapshot + description: The creation time of the snapshot. type: int id: - description: - - The ID of the snapshot + description: The ID of the snapshot. type: str mappedSdcInfo: - description: The details of the mapped SDC + description: The details of the mapped SDC. type: complex contains: sdcId: - description: - - ID of the SDC + description: ID of the SDC. type: str sdcName: - description: - - Name of the SDC + description: Name of the SDC. type: str sdcIp: - description: - - IP of the SDC + description: IP of the SDC. type: str accessMode: - description: - - mapping access mode for the specified snapshot + description: mapping access mode for the specified snapshot. type: str limitIops: - description: - - IOPS limit for the SDC + description: IOPS limit for the SDC. type: int limitBwInMbps: - description: - - Bandwidth limit for the SDC + description: Bandwidth limit for the SDC. type: int name: - description: - - Name of the snapshot + description: Name of the snapshot. type: str secureSnapshotExpTime: - description: - - Expiry time of the snapshot + description: Expiry time of the snapshot. type: int sizeInKb: - description: - - Size of the snapshot + description: Size of the snapshot. type: int sizeInGb: - description: - - Size of the snapshot + description: Size of the snapshot. type: int retentionInHours: - description: - - Retention of the snapshot in hours + description: Retention of the snapshot in hours. type: int storagePoolId: - description: - - The ID of the Storage pool in which snapshot resides + description: The ID of the Storage pool in which snapshot resides. type: str storagePoolName: - description: - - The name of the Storage pool in which snapshot resides + description: The name of the Storage pool in which snapshot resides. type: str + sample: { + "accessModeLimit": "ReadOnly", + "ancestorVolumeId": "cdd883cf00000002", + "ancestorVolumeName": "ansible-volume-1", + "autoSnapshotGroupId": null, + "compressionMethod": "Invalid", + "consistencyGroupId": "22f1e80c00000001", + "creationTime": 1631619229, + "dataLayout": "MediumGranularity", + "id": "cdd883d000000004", + "links": [ + { + "href": "/api/instances/Volume::cdd883d000000004", + "rel": "self" + }, + { + "href": "/api/instances/Volume::cdd883d000000004/relationships + /Statistics", + "rel": "/api/Volume/relationship/Statistics" + }, + { + "href": "/api/instances/Volume::cdd883cf00000002", + "rel": "/api/parent/relationship/ancestorVolumeId" + }, + { + "href": "/api/instances/VTree::6e86255c00000001", + "rel": "/api/parent/relationship/vtreeId" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000", + "rel": "/api/parent/relationship/storagePoolId" + } + ], + "lockedAutoSnapshot": false, + "lockedAutoSnapshotMarkedForRemoval": false, + "managedBy": "ScaleIO", + "mappedSdcInfo": null, + "name": "ansible_vol_snap_1", + "notGenuineSnapshot": false, + "originalExpiryTime": 0, + "pairIds": null, + "replicationJournalVolume": false, + "replicationTimeStamp": 0, + "retentionInHours": 0, + "retentionLevels": [], + "secureSnapshotExpTime": 0, + "sizeInGb": 16, + "sizeInKb": 16777216, + "snplIdOfAutoSnapshot": null, + "snplIdOfSourceVolume": null, + "storagePoolId": "e0d8f6c900000000", + "storagePoolName": "pool1", + "timeStampIsAccurate": false, + "useRmcache": false, + "volumeReplicationState": "UnmarkedForReplication", + "volumeType": "Snapshot", + "vtreeId": "6e86255c00000001" + } ''' from ansible.module_utils.basic import AnsibleModule @@ -521,7 +566,12 @@ def get_sdc_id(self, sdc_name=None, sdc_ip=None, sdc_id=None): :return: The ID of the SDC """ - id_ip_name = sdc_ip if sdc_ip else sdc_name if sdc_name else sdc_id + if sdc_name: + id_ip_name = sdc_name + elif sdc_ip: + id_ip_name = sdc_ip + else: + id_ip_name = sdc_id try: if sdc_name: @@ -896,8 +946,6 @@ def perform_module_operation(self): size = self.module.params['size'] cap_unit = self.module.params['cap_unit'] snapshot_new_name = self.module.params['snapshot_new_name'] - allow_multiple_mappings = \ - self.module.params['allow_multiple_mappings'] sdc = copy.deepcopy(self.module.params['sdc']) sdc_state = self.module.params['sdc_state'] desired_retention = self.module.params['desired_retention'] @@ -1094,31 +1142,31 @@ def check_snapshot_modified(snapshot=None, desired_retention=None, timedelta(days=desired_retention) expiration_timestamp = time.mktime(expiration_timestamp.timetuple()) - if 'secureSnapshotExpTime' in snapshot and expiration_timestamp: - if snapshot['secureSnapshotExpTime'] != expiration_timestamp: - existing_timestamp = snapshot['secureSnapshotExpTime'] - new_timestamp = expiration_timestamp + if 'secureSnapshotExpTime' in snapshot and expiration_timestamp and \ + snapshot['secureSnapshotExpTime'] != expiration_timestamp: + existing_timestamp = snapshot['secureSnapshotExpTime'] + new_timestamp = expiration_timestamp - info_message = 'The existing timestamp is: %s and the new ' \ - 'timestamp is: %s' % (existing_timestamp, - new_timestamp) - LOG.info(info_message) + info_message = 'The existing timestamp is: %s and the new ' \ + 'timestamp is: %s' % (existing_timestamp, + new_timestamp) + LOG.info(info_message) - existing_time_obj = datetime.fromtimestamp(existing_timestamp) - new_time_obj = datetime.fromtimestamp(new_timestamp) + existing_time_obj = datetime.fromtimestamp(existing_timestamp) + new_time_obj = datetime.fromtimestamp(new_timestamp) - if existing_time_obj > new_time_obj: - td = utils.dateutil.relativedelta.relativedelta( - existing_time_obj, new_time_obj) - else: - td = utils.dateutil.relativedelta.relativedelta( - new_time_obj, existing_time_obj) + if existing_time_obj > new_time_obj: + td = utils.dateutil.relativedelta.relativedelta( + existing_time_obj, new_time_obj) + else: + td = utils.dateutil.relativedelta.relativedelta( + new_time_obj, existing_time_obj) - LOG.info("Time difference: %s", td.minutes) + LOG.info("Time difference: %s", td.minutes) - # A delta of two minutes is treated as idempotent - if td.seconds > 120 or td.minutes > 2: - is_timestamp_modified = True + # A delta of two minutes is treated as idempotent + if td.seconds > 120 or td.minutes > 2: + is_timestamp_modified = True if size: if cap_unit == 'GB': @@ -1129,9 +1177,8 @@ def check_snapshot_modified(snapshot=None, desired_retention=None, if new_size != snapshot['sizeInKb']: is_size_modified = True - if access_mode: - if snapshot['accessModeLimit'] != access_mode: - is_access_modified = True + if access_mode and snapshot['accessModeLimit'] != access_mode: + is_access_modified = True if is_timestamp_modified or is_size_modified or is_access_modified: is_modified = True diff --git a/plugins/modules/dellemc_powerflex_storagepool.py b/plugins/modules/dellemc_powerflex_storagepool.py index 9d2e82b..2f1e4a1 100644 --- a/plugins/modules/dellemc_powerflex_storagepool.py +++ b/plugins/modules/dellemc_powerflex_storagepool.py @@ -1,5 +1,6 @@ #!/usr/bin/python # Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) """Ansible module for managing Dell EMC PowerFlex storage pool""" @@ -16,13 +17,13 @@ version_added: '1.0.0' -short_description: Managing Dell EMC PowerFlex storage pool. +short_description: Managing Dell EMC PowerFlex storage pool description: - Dell EMC PowerFlex storage pool module includes - Get the details of storage pool, - Create a new storage pool, - Modify the attribute of a storage pool. + getting the details of storage pool, + creating a new storage pool, and + modifying the attribute of a storage pool. extends_documentation_fragment: - dellemc.powerflex.dellemc_powerflex.powerflex @@ -37,32 +38,28 @@ - The name of the storage pool. - If more than one storage pool is found with the same name then protection domain id/name is required to perform the task. - - storage_pool_name and storage_pool_id are mutually exclusive - parameters. + - Mutually exclusive with storage_pool_id. type: str storage_pool_id: description: - The id of the storage pool. - - storage_pool_id is auto generated, hence should not be provided during + - It is auto generated, hence should not be provided during creation of a storage pool. - - storage_pool_name and storage_pool_id are mutually exclusive - parameters. + - Mutually exclusive with storage_pool_name. type: str protection_domain_name: description: - The name of the protection domain. - - While creation of a pool, either protection domain name or id must be + - During creation of a pool, either protection domain name or id must be mentioned. - - protection_domain_name and protection_domain_name are mutually - exclusive parameters. + - Mutually exclusive with protection_domain_id. type: str protection_domain_id: description: - The id of the protection domain. - - While creation of a pool, either protection domain name or id must + - During creation of a pool, either protection domain name or id must be mentioned. - - protection_domain_name and protection_domain_id are mutually exclusive - parameters. + - Mutually exclusive with protection_domain_name. type: str media_type: description: @@ -89,13 +86,14 @@ choices: ["present", "absent"] required: true notes: -- TRANSITIONAL media type is supported only during modification. + - TRANSITIONAL media type is supported only during modification. + - The check_mode is not supported. ''' EXAMPLES = r''' - name: Get the details of storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -105,7 +103,7 @@ state: "present" - name: Get the details of storage pool by id - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -114,7 +112,7 @@ state: "present" - name: Create a new storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -125,7 +123,7 @@ state: "present" - name: Modify a storage pool by name - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -137,7 +135,7 @@ state: "present" - name: Rename storage pool by id - dellemc_powerflex_storagepool: + dellemc.powerflex.dellemc_powerflex_storagepool: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -150,42 +148,139 @@ RETURN = r''' changed: - description: Whether or not the resource has changed + description: Whether or not the resource has changed. returned: always type: bool + sample: 'false' storage_pool_details: - description: Details of the storage pool + description: Details of the storage pool. returned: When storage pool exists type: complex contains: mediaType: - description: - - Type of devices in the storage pool + description: Type of devices in the storage pool. type: str useRfcache: - description: - - Enable/Disable RFcache on a specific storage pool. + description: Enable/Disable RFcache on a specific storage pool. type: bool useRmcache: - description: - - Enable/Disable RMcache on a specific storage pool. + description: Enable/Disable RMcache on a specific storage pool. type: bool id: - description: - - ID of the storage pool under protection domain. + description: ID of the storage pool under protection domain. type: str name: - description: - - Name of the storage pool under protection domain. + description: Name of the storage pool under protection domain. type: str protectionDomainId: - description: - - ID of the protection domain in which pool resides. + description: ID of the protection domain in which pool resides. type: str protectionDomainName: - description: - - Name of the protection domain in which pool resides. + description: Name of the protection domain in which pool resides. type: str + sample: { + "addressSpaceUsage": "Normal", + "addressSpaceUsageType": "DeviceCapacityLimit", + "backgroundScannerBWLimitKBps": 3072, + "backgroundScannerMode": "DataComparison", + "bgScannerCompareErrorAction": "ReportAndFix", + "bgScannerReadErrorAction": "ReportAndFix", + "capacityAlertCriticalThreshold": 90, + "capacityAlertHighThreshold": 80, + "capacityUsageState": "Normal", + "capacityUsageType": "NetCapacity", + "checksumEnabled": false, + "compressionMethod": "Invalid", + "dataLayout": "MediumGranularity", + "externalAccelerationType": "None", + "fglAccpId": null, + "fglExtraCapacity": null, + "fglMaxCompressionRatio": null, + "fglMetadataSizeXx100": null, + "fglNvdimmMetadataAmortizationX100": null, + "fglNvdimmWriteCacheSizeInMb": null, + "fglOverProvisioningFactor": null, + "fglPerfProfile": null, + "fglWriteAtomicitySize": null, + "fragmentationEnabled": true, + "id": "e0d8f6c900000000", + "links": [ + { + "href": "/api/instances/StoragePool::e0d8f6c900000000", + "rel": "self" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000 + /relationships/Statistics", + "rel": "/api/StoragePool/relationship/Statistics" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000 + /relationships/SpSds", + "rel": "/api/StoragePool/relationship/SpSds" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000 + /relationships/Volume", + "rel": "/api/StoragePool/relationship/Volume" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000 + /relationships/Device", + "rel": "/api/StoragePool/relationship/Device" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000 + /relationships/VTree", + "rel": "/api/StoragePool/relationship/VTree" + }, + { + "href": "/api/instances/ProtectionDomain::9300c1f900000000", + "rel": "/api/parent/relationship/protectionDomainId" + } + ], + "mediaType": "HDD", + "name": "pool1", + "numOfParallelRebuildRebalanceJobsPerDevice": 2, + "persistentChecksumBuilderLimitKb": 3072, + "persistentChecksumEnabled": true, + "persistentChecksumState": "Protected", + "persistentChecksumValidateOnRead": false, + "protectedMaintenanceModeIoPriorityAppBwPerDeviceThresholdInKbps": null, + "protectedMaintenanceModeIoPriorityAppIopsPerDeviceThreshold": null, + "protectedMaintenanceModeIoPriorityBwLimitPerDeviceInKbps": 10240, + "protectedMaintenanceModeIoPriorityNumOfConcurrentIosPerDevice": 1, + "protectedMaintenanceModeIoPriorityPolicy": "limitNumOfConcurrentIos", + "protectedMaintenanceModeIoPriorityQuietPeriodInMsec": null, + "protectionDomainId": "9300c1f900000000", + "protectionDomainName": "domain1", + "rebalanceEnabled": true, + "rebalanceIoPriorityAppBwPerDeviceThresholdInKbps": null, + "rebalanceIoPriorityAppIopsPerDeviceThreshold": null, + "rebalanceIoPriorityBwLimitPerDeviceInKbps": 10240, + "rebalanceIoPriorityNumOfConcurrentIosPerDevice": 1, + "rebalanceIoPriorityPolicy": "favorAppIos", + "rebalanceIoPriorityQuietPeriodInMsec": null, + "rebuildEnabled": true, + "rebuildIoPriorityAppBwPerDeviceThresholdInKbps": null, + "rebuildIoPriorityAppIopsPerDeviceThreshold": null, + "rebuildIoPriorityBwLimitPerDeviceInKbps": 10240, + "rebuildIoPriorityNumOfConcurrentIosPerDevice": 1, + "rebuildIoPriorityPolicy": "limitNumOfConcurrentIos", + "rebuildIoPriorityQuietPeriodInMsec": null, + "replicationCapacityMaxRatio": 32, + "rmcacheWriteHandlingMode": "Cached", + "sparePercentage": 10, + "useRfcache": false, + "useRmcache": false, + "vtreeMigrationIoPriorityAppBwPerDeviceThresholdInKbps": null, + "vtreeMigrationIoPriorityAppIopsPerDeviceThreshold": null, + "vtreeMigrationIoPriorityBwLimitPerDeviceInKbps": 10240, + "vtreeMigrationIoPriorityNumOfConcurrentIosPerDevice": 1, + "vtreeMigrationIoPriorityPolicy": "favorAppIos", + "vtreeMigrationIoPriorityQuietPeriodInMsec": null, + "zeroPaddingEnabled": true + } ''' from ansible.module_utils.basic import AnsibleModule @@ -245,10 +340,8 @@ def get_protection_domain(self, protection_domain_name=None, filter_fields = {} if protection_domain_id: filter_fields = {'id': protection_domain_id} - elif protection_domain_name: + if protection_domain_name: filter_fields = {'name': protection_domain_name} - else: - pass pd_details = self.powerflex_conn.protection_domain.get( filter_fields=filter_fields) diff --git a/plugins/modules/dellemc_powerflex_volume.py b/plugins/modules/dellemc_powerflex_volume.py index 117b6e5..30ad4ab 100644 --- a/plugins/modules/dellemc_powerflex_volume.py +++ b/plugins/modules/dellemc_powerflex_volume.py @@ -1,5 +1,6 @@ #!/usr/bin/python # Copyright: (c) 2021, Dell EMC +# Apache License version 2.0 (see MODULE-LICENSE or http://www.apache.org/licenses/LICENSE-2.0.txt) """ Ansible module for managing volumes on PowerFlex""" @@ -13,7 +14,7 @@ DOCUMENTATION = r''' module: dellemc_powerflex_volume version_added: '1.0.0' -short_description: Manage volumes on Dell EMC PowerFlex. +short_description: Manage volumes on Dell EMC PowerFlex description: - Managing volumes on PowerFlex storage system includes creating new volume, getting details of volume, adding/removing snapshot @@ -29,55 +30,51 @@ description: - The name of the volume. - Mandatory for create operation. - - vol_name is unique across the PowerFlex array. - - vol_name and vol_id are mutually exclusive parameters. + - It is unique across the PowerFlex array. + - Mutually exclusive with vol_id. type: str vol_id: description: - The ID of the volume. - Except create operation, all other operations can be performed using vol_id. - - vol_name and vol_id are mutually exclusive parameters. + - Mutually exclusive with vol_id. type: str storage_pool_name: description: - The name of the storage pool. - Either name or the id of the storage pool is required for creating a volume. - - During creation, If storage pool name is provided then either + - During creation, if storage pool name is provided then either protection domain name or id must be mentioned along with it. - - storage_pool_name and storage_pool_id are mutually exclusive - parameters. + - Mutually exclusive with storage_pool_id. type: str storage_pool_id: description: - - The id of the storage pool. + - The ID of the storage pool. - Either name or the id of the storage pool is required for creating a volume. - - storage_pool_name and storage_pool_id are mutually exclusive - parameters. + - Mutually exclusive with storage_pool_name. type: str protection_domain_name: description: - The name of the protection domain. - - While creation of a volume, if more than one storage pool exists with + - During creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be - mentioned along with it. - - protection_domain_name and protection_domain_name are mutually - exclusive parameters. + mentioned along with it. + - Mutually exclusive with protection_domain_id. type: str protection_domain_id: description: - - The id of the protection domain. - - While creation of a volume, if more than one storage pool exists with + - The ID of the protection domain. + - During creation of a volume, if more than one storage pool exists with the same name then either protection domain name or id must be - mentioned along with it. - - protection_domain_name and protection_domain_id are mutually exclusive - parameters. + mentioned along with it. + - Mutually exclusive with protection_domain_name. type: str vol_type: description: - - The type of volume provisioning. + - Type of volume provisioning. choices: ["THICK_PROVISIONED", "THIN_PROVISIONED"] type: str compression_type: @@ -135,7 +132,7 @@ type: bool sdc: description: - - Specifies SDC parameters + - Specifies SDC parameters. type: list elements: dict suboptions: @@ -182,9 +179,8 @@ description: - If True, the volume and all its dependent snapshots will be deleted. - If False, only the volume will be deleted. - - delete_snapshots parameter can be specified only when the - state is absent. - - delete_snapshots defaults to False. + - It can be specified only when the state is absent. + - It defaults to False, if not specified. type: bool state: description: @@ -192,11 +188,13 @@ choices: ['present', 'absent'] required: True type: str +notes: + - The check_mode is not supported. ''' EXAMPLES = r''' - name: Create a volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -212,7 +210,7 @@ state: "present" - name: Map a SDC to volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -227,7 +225,7 @@ state: "present" - name: Unmap a SDC to volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -240,7 +238,7 @@ state: "present" - name: Map multiple SDCs to a volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -253,14 +251,14 @@ access_mode: "READ_WRITE" bandwidth_limit: 2048 iops_limit: 20 - - sdc_ip: "127.0.0.1" + - sdc_ip: "198.10.xxx.xxx" access_mode: "READ_ONLY" allow_multiple_mappings: True sdc_state: "mapped" state: "present" - name: Get the details of the volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -270,7 +268,7 @@ state: "present" - name: Modify the details of the Volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -283,7 +281,7 @@ state: "present" - name: Delete the Volume - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -294,7 +292,7 @@ state: "absent" - name: Delete the Volume and all its dependent snapshots - dellemc_powerflex_volume: + dellemc.powerflex.dellemc_powerflex_volume: gateway_host: "{{gateway_host}}" username: "{{username}}" password: "{{password}}" @@ -307,86 +305,182 @@ RETURN = r''' changed: - description: Whether or not the resource has changed + description: Whether or not the resource has changed. returned: always type: bool + sample: 'false' volume_details: - description: Details of the volume + description: Details of the volume. returned: When volume exists type: complex contains: id: - description: - - The ID of the volume. + description: The ID of the volume. type: str mappedSdcInfo: - description: The details of the mapped SDC + description: The details of the mapped SDC. type: complex contains: sdcId: - description: - - ID of the SDC + description: ID of the SDC. type: str sdcName: - description: - - Name of the SDC + description: Name of the SDC. type: str sdcIp: - description: - - IP of the SDC + description: IP of the SDC. type: str accessMode: - description: - - mapping access mode for the specified volume + description: mapping access mode for the specified volume. type: str limitIops: - description: - - IOPS limit for the SDC + description: IOPS limit for the SDC. type: int limitBwInMbps: - description: - - Bandwidth limit for the SDC + description: Bandwidth limit for the SDC. type: int name: - description: - - Name of the volume + description: Name of the volume. type: str sizeInKb: - description: - - Size of the volume in Kb. + description: Size of the volume in Kb. type: int sizeInGb: - description: - - Size of the volume in Gb. + description: Size of the volume in Gb. type: int storagePoolId: - description: - - ID of the storage pool in which volume resides. + description: ID of the storage pool in which volume resides. type: str storagePoolName: - description: - - Name of the storage pool in which volume resides. + description: Name of the storage pool in which volume resides. type: str protectionDomainId: - description: - - ID of the protection domain in which volume resides. + description: ID of the protection domain in which volume resides. type: str protectionDomainName: - description: - - Name of the protection domain in which volume resides. + description: Name of the protection domain in which volume resides. type: str snapshotPolicyId: - description: - - ID of the snapshot policy associated with volume. + description: ID of the snapshot policy associated with volume. type: str snapshotPolicyName: - description: - - Name of the snapshot policy associated with volume. + description: Name of the snapshot policy associated with volume. type: str snapshotsList: - description: - - List of snapshots associated with the volume. + description: List of snapshots associated with the volume. type: str + sample: { + "accessModeLimit": "ReadWrite", + "ancestorVolumeId": null, + "autoSnapshotGroupId": null, + "compressionMethod": "Invalid", + "consistencyGroupId": null, + "creationTime": 1631618520, + "dataLayout": "MediumGranularity", + "id": "cdd883cf00000002", + "links": [ + { + "href": "/api/instances/Volume::cdd883cf00000002", + "rel": "self" + }, + { + "href": "/api/instances/Volume::cdd883cf00000002/relationships + /Statistics", + "rel": "/api/Volume/relationship/Statistics" + }, + { + "href": "/api/instances/VTree::6e86255c00000001", + "rel": "/api/parent/relationship/vtreeId" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000", + "rel": "/api/parent/relationship/storagePoolId" + } + ], + "lockedAutoSnapshot": false, + "lockedAutoSnapshotMarkedForRemoval": false, + "managedBy": "ScaleIO", + "mappedSdcInfo": null, + "name": "ansible-volume-1", + "notGenuineSnapshot": false, + "originalExpiryTime": 0, + "pairIds": null, + "protectionDomainId": "9300c1f900000000", + "protectionDomainName": "domain1", + "replicationJournalVolume": false, + "replicationTimeStamp": 0, + "retentionLevels": [], + "secureSnapshotExpTime": 0, + "sizeInGB": 16, + "sizeInKb": 16777216, + "snapshotPolicyId": null, + "snapshotPolicyName": null, + "snapshotsList": [ + { + "accessModeLimit": "ReadOnly", + "ancestorVolumeId": "cdd883cf00000002", + "autoSnapshotGroupId": null, + "compressionMethod": "Invalid", + "consistencyGroupId": "22f1e80c00000001", + "creationTime": 1631619229, + "dataLayout": "MediumGranularity", + "id": "cdd883d000000004", + "links": [ + { + "href": "/api/instances/Volume::cdd883d000000004", + "rel": "self" + }, + { + "href": "/api/instances/Volume::cdd883d000000004 + /relationships/Statistics", + "rel": "/api/Volume/relationship/Statistics" + }, + { + "href": "/api/instances/Volume::cdd883cf00000002", + "rel": "/api/parent/relationship/ancestorVolumeId" + }, + { + "href": "/api/instances/VTree::6e86255c00000001", + "rel": "/api/parent/relationship/vtreeId" + }, + { + "href": "/api/instances/StoragePool::e0d8f6c900000000", + "rel": "/api/parent/relationship/storagePoolId" + } + ], + "lockedAutoSnapshot": false, + "lockedAutoSnapshotMarkedForRemoval": false, + "managedBy": "ScaleIO", + "mappedSdcInfo": null, + "name": "ansible_vol_snap_1", + "notGenuineSnapshot": false, + "originalExpiryTime": 0, + "pairIds": null, + "replicationJournalVolume": false, + "replicationTimeStamp": 0, + "retentionLevels": [], + "secureSnapshotExpTime": 0, + "sizeInKb": 16777216, + "snplIdOfAutoSnapshot": null, + "snplIdOfSourceVolume": null, + "storagePoolId": "e0d8f6c900000000", + "timeStampIsAccurate": false, + "useRmcache": false, + "volumeReplicationState": "UnmarkedForReplication", + "volumeType": "Snapshot", + "vtreeId": "6e86255c00000001" + } + ], + "snplIdOfAutoSnapshot": null, + "snplIdOfSourceVolume": null, + "storagePoolId": "e0d8f6c900000000", + "storagePoolName": "pool1", + "timeStampIsAccurate": false, + "useRmcache": false, + "volumeReplicationState": "UnmarkedForReplication", + "volumeType": "ThinProvisioned", + "vtreeId": "6e86255c00000001" + } ''' from ansible.module_utils.basic import AnsibleModule @@ -621,7 +715,12 @@ def get_sdc_id(self, sdc_name=None, sdc_ip=None, sdc_id=None): :return: The ID of the SDC """ - id_ip_name = sdc_ip if sdc_ip else sdc_name if sdc_name else sdc_id + if sdc_name: + id_ip_name = sdc_name + elif sdc_ip: + id_ip_name = sdc_ip + else: + id_ip_name = sdc_id try: if sdc_name: @@ -658,12 +757,7 @@ def create_volume(self, vol_name, pool_id, size, vol_type=None, """ try: if vol_name is None or len(vol_name.strip()) == 0: - self.module.fail_json(msg="Please provide valid volume " - "name.") - - if vol_name is None: - self.module.fail_json(msg="Please provide valid volume " - "name.") + self.module.fail_json(msg="Please provide valid volume name.") if not size: self.module.fail_json(msg="Size is a mandatory parameter " @@ -1025,11 +1119,11 @@ def to_modify(self, vol_details, new_size, use_rmcache, comp_type, if new_name != vol_details['name']: modify_dict['new_name'] = new_name - if snap_pol_id is not None and snap_pol_id == "": - if auto_snap_remove_type and vol_details['snplIdOfSourceVolume']: - modify_dict['auto_snap_remove_type'] = auto_snap_remove_type - modify_dict['snap_pol_id'] = \ - vol_details['snplIdOfSourceVolume'] + if snap_pol_id is not None and snap_pol_id == "" and \ + auto_snap_remove_type and vol_details['snplIdOfSourceVolume']: + modify_dict['auto_snap_remove_type'] = auto_snap_remove_type + modify_dict['snap_pol_id'] = \ + vol_details['snplIdOfSourceVolume'] if snap_pol_id is not None and snap_pol_id != "": if auto_snap_remove_type and vol_details['snplIdOfSourceVolume']: diff --git a/tests/sanity/ignore-2.10.txt b/tests/sanity/ignore-2.10.txt new file mode 100644 index 0000000..1f9f651 --- /dev/null +++ b/tests/sanity/ignore-2.10.txt @@ -0,0 +1,7 @@ +plugins/modules/dellemc_powerflex_device.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_gatherfacts.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sdc.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sds.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_snapshot.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_storagepool.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_volume.py validate-modules:missing-gplv3-license \ No newline at end of file diff --git a/tests/sanity/ignore-2.11.txt b/tests/sanity/ignore-2.11.txt new file mode 100644 index 0000000..1f9f651 --- /dev/null +++ b/tests/sanity/ignore-2.11.txt @@ -0,0 +1,7 @@ +plugins/modules/dellemc_powerflex_device.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_gatherfacts.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sdc.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sds.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_snapshot.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_storagepool.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_volume.py validate-modules:missing-gplv3-license \ No newline at end of file diff --git a/tests/sanity/ignore-2.9.txt b/tests/sanity/ignore-2.9.txt new file mode 100644 index 0000000..1f9f651 --- /dev/null +++ b/tests/sanity/ignore-2.9.txt @@ -0,0 +1,7 @@ +plugins/modules/dellemc_powerflex_device.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_gatherfacts.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sdc.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_sds.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_snapshot.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_storagepool.py validate-modules:missing-gplv3-license +plugins/modules/dellemc_powerflex_volume.py validate-modules:missing-gplv3-license \ No newline at end of file