-
Notifications
You must be signed in to change notification settings - Fork 23.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add new Pure Storage module to discover facts for FlashArray #37263
Conversation
The test
The test
|
a3c28a6
to
10568bf
Compare
The test
|
The test
The test
|
7505ff2
to
b2431b5
Compare
The test
The test
|
989f4f9
to
71bdb9b
Compare
The test
|
The test
The test
The test
|
The test
The test
|
The string contained within Below is a patch to fix diff --git a/lib/ansible/modules/storage/purestorage/purefa_facts.py b/lib/ansible/modules/storage/purestorage/purefa_facts.py
index 9229dc68c5..25baac1858 100644
--- a/lib/ansible/modules/storage/purestorage/purefa_facts.py
+++ b/lib/ansible/modules/storage/purestorage/purefa_facts.py
@@ -65,229 +65,229 @@ ansible_facts:
returned: always
type: complex
contains:
- "capacity": {},
- "config": {
- "directory_service": {
- "array_admin_group": null,
- "base_dn": null,
- "bind_password": null,
- "bind_user": null,
- "check_peer": false,
- "enabled": false,
- "group_base": null,
- "readonly_group": null,
- "storage_admin_group": null,
- "uri": []
- },
- "dns": {
- "domain": "domain.com",
- "nameservers": [
- "8.8.8.8",
- "8.8.4.4"
- ]
- },
- "ntp": [
- "0.ntp.pool.org",
- "1.ntp.pool.org",
- "2.ntp.pool.org",
- "3.ntp.pool.org"
- ],
- "smtp": [
- {
- "enabled": true,
- "name": "alerts@acme.com"
- },
- {
- "enabled": true,
- "name": "user@acme.com"
- }
- ],
- "snmp": [
- {
- "auth_passphrase": null,
- "auth_protocol": null,
- "community": null,
- "host": "localhost",
- "name": "localhost",
- "privacy_passphrase": null,
- "privacy_protocol": null,
- "user": null,
- "version": "v2c"
- }
- ],
- "ssl_certs": {
- "country": null,
- "email": null,
- "issued_by": "",
- "issued_to": "",
- "key_size": 2048,
- "locality": null,
- "organization": "Acme Storage, Inc.",
- "organizational_unit": "Acme Storage, Inc.",
- "state": null,
- "status": "self-signed",
- "valid_from": "2017-08-11T23:09:06Z",
- "valid_to": "2027-08-09T23:09:06Z"
- },
- "syslog": []
+ "capacity": {}
+ "config": {
+ "directory_service": {
+ "array_admin_group": null,
+ "base_dn": null,
+ "bind_password": null,
+ "bind_user": null,
+ "check_peer": false,
+ "enabled": false,
+ "group_base": null,
+ "readonly_group": null,
+ "storage_admin_group": null,
+ "uri": []
+ },
+ "dns": {
+ "domain": "domain.com",
+ "nameservers": [
+ "8.8.8.8",
+ "8.8.4.4"
+ ]
+ },
+ "ntp": [
+ "0.ntp.pool.org",
+ "1.ntp.pool.org",
+ "2.ntp.pool.org",
+ "3.ntp.pool.org"
+ ],
+ "smtp": [
+ {
+ "enabled": true,
+ "name": "alerts@acme.com"
},
- "default": {
- "array_name": "flasharray1",
- "hostgroups": 0,
- "hosts": 10,
- "protection_groups": 1,
- "purity_version": "5.0.4",
- "snapshots": 1
- },
- "hgroups": {},
- "hosts": {
- "host1": {
- "hgroup": null,
- "iqn": [
- "iqn.1994-05.com.redhat:2f6f5715a533"
- ],
- "wwn": []
- },
- "host2": {
- "hgroup": null,
- "iqn": [
- "iqn.1994-05.com.redhat:d17fb13fe0b"
- ],
- "wwn": []
- },
- "host3": {
- "hgroup": null,
- "iqn": [
- "iqn.1994-05.com.redhat:97b1351bfb2"
- ],
- "wwn": []
- },
- "host4": {
- "hgroup": null,
- "iqn": [
- "iqn.1994-05.com.redhat:dd84e9a7b2cb"
- ],
- "wwn": [
- "10000000C96C48D1",
- "10000000C96C48D2"
- ]
- }
- },
- "interfaces": {
- "CT0.ETH4": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
- "CT0.ETH5": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
- "CT1.ETH4": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
- "CT1.ETH5": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682"
- },
- "network": {
- "ct0.eth0": {
- "address": "10.10.10.10",
- "gateway": "10.10.10.1",
- "hwaddr": "ec:f4:bb:c8:8a:04",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "management"
- ],
- "speed": 1000000000
- },
- "ct0.eth2": {
- "address": "10.10.10.11",
- "gateway": null,
- "hwaddr": "ec:f4:bb:c8:8a:00",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "replication"
- ],
- "speed": 10000000000
- },
- "ct0.eth3": {
- "address": "10.10.10.12",
- "gateway": null,
- "hwaddr": "ec:f4:bb:c8:8a:02",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "replication"
- ],
- "speed": 10000000000
- },
- "ct0.eth4": {
- "address": "10.10.10.13",
- "gateway": null,
- "hwaddr": "90:e2:ba:83:79:0c",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "iscsi"
- ],
- "speed": 10000000000
- },
- "ct0.eth5": {
- "address": "10.10.10.14",
- "gateway": null,
- "hwaddr": "90:e2:ba:83:79:0d",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "iscsi"
- ],
- "speed": 10000000000
- },
- "vir0": {
- "address": "10.10.10.20",
- "gateway": "10.10.10.1",
- "hwaddr": "fe:ba:e9:e7:6b:0f",
- "mtu": 1500,
- "netmask": "255.255.255.0",
- "services": [
- "management"
- ],
- "speed": 1000000000
- }
- },
- "performance": {
- "input_per_sec": 8191,
- "output_per_sec": 0,
- "queue_depth": 1,
- "reads_per_sec": 0,
- "san_usec_per_write_op": 15,
- "usec_per_read_op": 0,
- "usec_per_write_op": 642,
- "writes_per_sec": 2
- },
- "pgroups": {
- "consisgroup-07b6b983-986e-46f5-bdc3-deaa3dbb299e-cinder": {
- "hgroups": null,
- "hosts": null,
- "source": "host1",
- "targets": null,
- "volumes": [
- "volume-1"
- ]
- }
- },
- "snapshots": {
- "consisgroup.cgsnapshot": {
- "created": "2018-03-28T09:34:02Z",
- "size": 13958643712,
- "source": "volume-1"
- }
- },
- "subnet": {},
- "volumes": {
- "ansible_data": {
- "hosts": [
- [
- "host1",
- 1
- ]
- ],
- "serial": "43BE47C12334399B000114A6",
- "size": 1099511627776
- }
+ {
+ "enabled": true,
+ "name": "user@acme.com"
+ }
+ ],
+ "snmp": [
+ {
+ "auth_passphrase": null,
+ "auth_protocol": null,
+ "community": null,
+ "host": "localhost",
+ "name": "localhost",
+ "privacy_passphrase": null,
+ "privacy_protocol": null,
+ "user": null,
+ "version": "v2c"
}
+ ],
+ "ssl_certs": {
+ "country": null,
+ "email": null,
+ "issued_by": "",
+ "issued_to": "",
+ "key_size": 2048,
+ "locality": null,
+ "organization": "Acme Storage, Inc.",
+ "organizational_unit": "Acme Storage, Inc.",
+ "state": null,
+ "status": "self-signed",
+ "valid_from": "2017-08-11T23:09:06Z",
+ "valid_to": "2027-08-09T23:09:06Z"
+ },
+ "syslog": []
+ }
+ "default": {
+ "array_name": "flasharray1",
+ "hostgroups": 0,
+ "hosts": 10,
+ "protection_groups": 1,
+ "purity_version": "5.0.4",
+ "snapshots": 1
+ }
+ "hgroups": {}
+ "hosts": {
+ "host1": {
+ "hgroup": null,
+ "iqn": [
+ "iqn.1994-05.com.redhat:2f6f5715a533"
+ ],
+ "wwn": []
+ },
+ "host2": {
+ "hgroup": null,
+ "iqn": [
+ "iqn.1994-05.com.redhat:d17fb13fe0b"
+ ],
+ "wwn": []
+ },
+ "host3": {
+ "hgroup": null,
+ "iqn": [
+ "iqn.1994-05.com.redhat:97b1351bfb2"
+ ],
+ "wwn": []
+ },
+ "host4": {
+ "hgroup": null,
+ "iqn": [
+ "iqn.1994-05.com.redhat:dd84e9a7b2cb"
+ ],
+ "wwn": [
+ "10000000C96C48D1",
+ "10000000C96C48D2"
+ ]
+ }
+ }
+ "interfaces": {
+ "CT0.ETH4": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
+ "CT0.ETH5": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
+ "CT1.ETH4": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682",
+ "CT1.ETH5": "iqn.2010-06.com.purestorage:flasharray.2111b767484e4682"
+ }
+ "network": {
+ "ct0.eth0": {
+ "address": "10.10.10.10",
+ "gateway": "10.10.10.1",
+ "hwaddr": "ec:f4:bb:c8:8a:04",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "management"
+ ],
+ "speed": 1000000000
+ },
+ "ct0.eth2": {
+ "address": "10.10.10.11",
+ "gateway": null,
+ "hwaddr": "ec:f4:bb:c8:8a:00",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "replication"
+ ],
+ "speed": 10000000000
+ },
+ "ct0.eth3": {
+ "address": "10.10.10.12",
+ "gateway": null,
+ "hwaddr": "ec:f4:bb:c8:8a:02",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "replication"
+ ],
+ "speed": 10000000000
+ },
+ "ct0.eth4": {
+ "address": "10.10.10.13",
+ "gateway": null,
+ "hwaddr": "90:e2:ba:83:79:0c",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "iscsi"
+ ],
+ "speed": 10000000000
+ },
+ "ct0.eth5": {
+ "address": "10.10.10.14",
+ "gateway": null,
+ "hwaddr": "90:e2:ba:83:79:0d",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "iscsi"
+ ],
+ "speed": 10000000000
+ },
+ "vir0": {
+ "address": "10.10.10.20",
+ "gateway": "10.10.10.1",
+ "hwaddr": "fe:ba:e9:e7:6b:0f",
+ "mtu": 1500,
+ "netmask": "255.255.255.0",
+ "services": [
+ "management"
+ ],
+ "speed": 1000000000
+ }
+ }
+ "performance": {
+ "input_per_sec": 8191,
+ "output_per_sec": 0,
+ "queue_depth": 1,
+ "reads_per_sec": 0,
+ "san_usec_per_write_op": 15,
+ "usec_per_read_op": 0,
+ "usec_per_write_op": 642,
+ "writes_per_sec": 2
+ }
+ "pgroups": {
+ "consisgroup-07b6b983-986e-46f5-bdc3-deaa3dbb299e-cinder": {
+ "hgroups": null,
+ "hosts": null,
+ "source": "host1",
+ "targets": null,
+ "volumes": [
+ "volume-1"
+ ]
+ }
+ }
+ "snapshots": {
+ "consisgroup.cgsnapshot": {
+ "created": "2018-03-28T09:34:02Z",
+ "size": 13958643712,
+ "source": "volume-1"
+ }
+ }
+ "subnet": {}
+ "volumes": {
+ "ansible_data": {
+ "hosts": [
+ [
+ "host1",
+ 1
+ ]
+ ],
+ "serial": "43BE47C12334399B000114A6",
+ "size": 1099511627776
+ }
+ }
'''
|
SUMMARY
Add new module to discover facts for a Pure Storage FlashArray.
Facts that can be discovered are:
- all
- minimum
- config
- performance
- capacity
- network
- subnet
- interfaces
- hgorups
- pgroups
- hosts
- volumes
- snapshots
ISSUE TYPE
COMPONENT NAME
module/storage/purestorage/purefa_facts
ANSIBLE VERSION
ADDITIONAL INFORMATION