Commit Graph

372 Commits

Author SHA1 Message Date
Zuul d773353502 Merge "Fix backup creation errors with NetApp driver" 2024-06-05 15:14:17 +00:00
Zuul 83b60eb1f9 Merge "Fix backup delete issue when source and destination vserver are same" 2024-06-05 10:43:19 +00:00
Zuul cd6c20c430 Merge "Fix the backup restore issue for NetApp driver for REST client" 2024-06-04 16:58:17 +00:00
Kiran Pawar 7bcf51e962 [NetApp] Pause and resume clone split during rename snapshot
When snpashot are soft deleted i.e. they are renamed if delete fails,
sometime we face issue in rename operation. This is due to busy
snapshot clone split operations. So perform rename and then start clone
split.

Closes-bug: #2025641
Change-Id: I1093a610f31f5971bb23b9f89c64f5f129ac2fb9
2024-05-20 13:09:23 +00:00
agireesh 080d3ba669 Fix the backup restore issue for NetApp driver for REST client
Backup restore is failing across the ONTAP cluster for REST client.
Added the logic to use to destination vserver client for REST client
to restore the backup and modify the restore lib for cmode REST
client accordingly.

Closes-Bug: #2059399
Change-Id: Icd7f1b52a10659ee1cfeef3accbbb725d4046a13
2024-04-30 14:20:35 +05:30
Ubuntu 3a958c78c0 Adds usedforsecurity=False to NetApp ONTAP MD5 hashes
Bandit is yelling but these aren't used for security
purposes, I think, so this will sort out Bandit

Change-Id: I0e686c91ce02ea42719d00d17f6ed659e97470ac
2024-04-23 17:07:02 +00:00
agireesh aa8695716a Fix backup delete issue when source and destination vserver are same
Added the logic in resource cleanup part to delete the vserver
peering when source and destination vserver are not same.

Closes-bug: #2058642
Change-Id: I02a70642a22095ab202f5846fff04d25321c4c1c
2024-04-03 22:40:50 +05:30
agireesh 33dc4b767b Fix backup creation errors with NetApp driver
Fix the the below issues as part of this patch
- Fix the issue when backup is created with wrong config. Due to
  wrong config backup status is not changing from creating status
  to failed.
- Failed the backup creation when SnapMirror relationship created
  during backup creation was not healthy.
- Added few fields in snapmirror GET API to fix the REST
  workflow for backup.
- Incorporated left over review comments of patch
  I5a4edbf547e7886fb4fa9c1bed90110a33f9bf3b

Closes-Bug: #2058027
Change-Id: I013ff3eedea54d9895e4c0446017aeb62c6bb833
2024-03-19 23:23:42 +05:30
agireesh dfbf51bafd Implement the share backup for NetApp driver
Implement the share backup feature for NetApp driver.
NetApp SnapVault technology is used to create and restore
the backup for NetApp ONTAP share. backup delete workflow
just delete the transferred snapshot from destination
backup volume.

Depends-On: Ifb88ec096674ea8bc010c1c3f6dea1b51be3beaa
Change-Id: I5a4edbf547e7886fb4fa9c1bed90110a33f9bf3b
2024-03-12 10:12:25 +05:30
Zuul 357f62cf97 Merge "NetApp Derive vserver name from share server identifier" 2023-12-13 20:14:14 +00:00
Kiran Pawar 54c4f91aa1 NetApp: Stop clone split while deleting child share.
If share created from snapshot is deleted immediately after creation
and if clone split operation is in progress, then delete call fails.
Fix this issue by first stopping the clone split job and then continue
with deletion.

Closes-bug: #1960239
Change-Id: If9844b3da70cec427c6260ee239c8c6131ed77ed
2023-11-22 12:48:12 +00:00
jayaanand.borra@netapp.com 4f36847de9 Human readable export location NetApp driver changes
NetApp driver changes to accommodate human readable
share location. Export path is updated with
human frendly value if present else use share-id.

partially-implements: bp human-readable-export-locations
Depends-On: I72ac7e24ddd4330d76cafd5e7f78bac2b0174883
Change-Id: I2f5bfdbc9d0458c7b9198a3eb94b3b095d5b5e04
2024-03-13 01:34:21 -04:00
Zuul 22e568d1d3 Merge "NetApp API failed. Reason - 18177:Relationship is in use by SnapMirror in local cluster" 2023-10-13 20:43:37 +00:00
Kiran Pawar 8615ce2549 NetApp Derive vserver name from share server identifier
Instead of using the identifier the migration methods are deriving
the vserver name from the share server id. This causes failure for
migrate a share server that had been migrated before.

Closes-bug: #2037109
Change-Id: Ida13bacab960761bb7cd0708017d864db0d7358f
2023-10-03 12:17:51 +00:00
LuizSantos 1f9d51fdba NetApp API failed. Reason - 18177:Relationship is in use by SnapMirror in local cluster
Changed the client method 'get_snapmirror_destinations' instead of 'get_snapmirrors'

Closes-Bug: #1996907
Change-Id: Ie857caf8a439ca6b252baa3c1fbfb3f0e62d7562
2023-09-30 19:12:39 +05:30
Zuul 4c8dff2522 Merge "[NetApp] Fix lack of aggregate pool home state" 2023-09-28 14:26:25 +00:00
Zuul ad665137c4 Merge "[NetApp] Add exception for insufficient privilege or incorrect credentials" 2023-09-28 13:01:05 +00:00
Helena Dantas 81126d97e3 [NetApp] Add exception for insufficient privilege or incorrect credentials
When creating a share using CIFS protocol users can face errors related
with incorrect credentials or insufficient privileges which have not been properly described by the exception error message.

This patch add a more clearer error message to address this kind of
error to the user.

Closes-Bug: #1900755
Change-Id: I589c218f2c1072e17e76a6a8d8d81541d5072ad1
2023-09-25 12:47:17 +00:00
Zuul 7eef91446b Merge "[NetApp] Fix ipspace naming is confusing" 2023-09-21 20:37:53 +00:00
Helena Dantas ce13de0044 [NetApp] Fix ipspace naming is confusing
This patch resolves the NetApp ipspace naming to use
neutron_net_id rather than neutron_subnet_id manila driver.

Closes-Bug: #2007560

Change-Id: Id5f2d35dac755aa9ae47a4e42af5d6c3fc5e6f2e
2023-09-21 14:07:12 +00:00
Zuul f912aafc58 Merge "Add NetApp Active IQ scheduler weigher" 2023-09-07 03:37:24 +00:00
Zuul dc392dc81b Merge "[NetApp] Fixed replica promotion to updated autosize attributes" 2023-08-30 12:47:53 +00:00
Felipe Rodrigues 6c9d990a8f Add NetApp Active IQ scheduler weigher
Add the new scheduler weigher NetAppAIQWeigher that relies on
the NetApp Acitve IQ software to weigh the hosts. It only
works with NetApp only hosts.

It is also adding a new NetApp specific pool information
called ``netapp_cluster_name`` that contains the name
of the cluster where the pool is located.

Implements: netapp-active-iq-scheduler-weigher
Signed-off-by Felipe Rodrigues <felipefuty01@gmail.com>

Change-Id: I36b08066545afdaa37e053eee319bc9cd489efdc
2023-08-30 08:28:50 -03:00
Zuul 0cbc6439e4 Merge "[NetApp] Recreate security cert during vserver create." 2023-08-28 12:58:53 +00:00
Zuul 4ddccaf390 Merge "[RFE] NetApp share server migration get progress" 2023-08-22 10:47:28 +00:00
Zuul a93a844398 Merge "NetApp ONTAP: Fix SnapMirror snapshots not being cleaned up" 2023-08-17 14:55:58 +00:00
Zuul 624dbabc25 Merge "[NetApp] Fix share server migration" 2023-08-16 21:01:58 +00:00
MelloCaique bb7a06bf32 [RFE] NetApp share server migration get progress
Implement method share_server_migration_get_progress to get the
share server migration percent based in the total size of shares
(GB) tranfered from source to destination.

Depends-On: I9eae95ff3f66a3497b00ca582491afec58ae6dc3

Closes-bug: #2030969

Change-Id: If4bf3378388cc0d9ea03f58b0ab5abd9a268bfdd
2023-08-14 12:39:14 +00:00
Zuul 364000c140 Merge "NetApp: Improve REST API cover and fix internals" 2023-08-04 00:49:18 +00:00
Zuul 5f733d3d97 Merge "[NetApp] Fix NetApp driver create from snapshot" 2023-08-02 22:26:20 +00:00
Nahim Alves de Souza b4cc96d5fd NetApp: Improve REST API cover and fix internals
Improve coverage of REST API feature merged in stable 2023.1.
Fix Netapp internals tests

partially-implements: bp netapp-ontap-rest-api-client

Co-authored-by: Caique Mello <caiquemellosbo@gmail.com>
Co-authored-by: Helena Dantas <helenamylena@gmail.com>
Co-authored-by: Lucas Oliveira <lucasmoliveira059@gmail.com>
Co-authored-by: Matheus Andrade <matheus.andrade@netapp.com>
Co-authored-by: Renan Vitor <renanpiranguinho@gmail.com>
Change-Id: Ia5fe1834cc6643d5df0a25f9f4a074911d8ad550
2023-08-02 13:45:34 +00:00
MatheusAndrade777 a934499834 [NetApp] Fix share server migration
SVM Migration was failing using NetApp driver after changes on share server structure,
since now the share server can have more than one subnet.

This patch fix all the errors related to this change.

Closes-bug: #2018300
Change-Id: I9eae95ff3f66a3497b00ca582491afec58ae6dc3
2023-08-01 14:01:31 +00:00
Kiran Pawar 0553eb78be [NetApp] Recreate security cert during vserver create.
The certificate is automatically created on NetApp with 1 year i.e. 365
days of expiration time, and admin needs to manually extend it. It would
be nice Manila can take care to create certs with admin configuable
expiration time. Manila should first create the new cert with given
expiration time and if successful, delete the old cert.

Closes-bug: #2011693
Change-Id: I37e52b94dc492e91fe9e673b3619e6716737d39a
2023-08-01 08:04:47 +00:00
Nahim Alves de Souza 8896534bb4 [NetApp] Fixed replica promotion to updated autosize attributes
When a volume is created in NetApp ONTAP, it has a few autosize
attributes that are set by default. The values of the attributes
are defined according to the volume type (DP/RW).

During the replica promotion, the types are swaped between source
and destination volumes, but the autosize values were not being
updated. This patch fixes this behavior, calling an autosize reset
after promoting the replica.

Closes-Bug: #1957075
Change-Id: I9a4e5763927b7585a8fbd6b0004d6a123dcd7fae
2023-07-31 20:34:22 +00:00
Raffaela Cunha 69efb9ae53 [NetApp] Fix NetApp driver create from snapshot
Changes were done in create_share_from_snapshot
method so that a scoped account does not need to get the
source and the destination cluster names and does not have the
permissions.

Closes-Bug: #1922512
Change-Id: Ib36c81c213a374a918378854ce0a89ce70acf1d0
2023-07-26 13:22:24 +00:00
Kiran Pawar da23b652fb Update timedelta and old schedules as per netapp_snapmirror_schedule
Asynchronous SnapMirror schedules are set using netapp config option
'netapp_snapmirror_schedule'. The delta for determining replica is
in-sync or out-of-sync updated to twice the schedule time seconds.
Also, not only new snapmirrors, but also old ones should
have a schedule according to the current
'netapp_snapmirror_schedule' config.

Closes-bug: #1996859
Depends-On: I0390f82dfdc130d49e3af6928996dd730e3cf69f
Change-Id: Ifbe0575f6c359929344763666e4d93d8c6084e83
2023-07-26 10:47:03 +00:00
CaiqueMello 9ddddeeea3 [NetApp] Fix non-disruptive migration cifs shares
Migrate non-disruptive cifs share from different pools change the
export location. When the non-disruptive migration complete
process is started a new share and export location is created. As
result, Manila finds a conflict between the old export location and
the new one.

This patch add a condition to skip export location creation when
a CIFS migration is in progress, also change the way that the export
location is created. Instead of create the export path with share
name, the new one is taken from the backend. The fix is only for
ZAPI API calls.

Change-Id: I1bb888a0b644f0b071816d275d464c4dd27125a7
Co-authored-by: Lucas Oliveira <lucasmoliveira059@gmail.com>
Closes-bug: #1920937
2023-03-21 13:16:53 +00:00
Zuul f03e84ae62 Merge "[NetApp] Fix DHSS mode fails to create share on a new pool" 2023-03-02 12:44:15 +00:00
Fernando Ferraz 38b13bb40b NetApp ONTAP: Fix SnapMirror snapshots not being cleaned up
Replica promote is retaining unneeded snapshots from previous
SnapMirror relationships and increasing the amount of space
consumed from snapshots in the storage system.

This patch fixes the issue by calling the snapmirror release
operation after resync completes its transferring, which allows
the SnapMirror software to properly cleanup unneeded resources.

Closes-Bug: #1982808
Change-Id: I516fb3575e30d18d971d6a1b7f3b9ad7120c3bbd
2023-03-02 09:24:30 -03:00
andrebeltrami 7e08ed4ce5 [NetApp] Fix DHSS mode fails to create share on a new pool
This patch fixes #1928241 checking if the share pool name
is in vserver aggregates list, if it is not, the share server
cannot be reused and a new one is created. This fix also
includes NetApp Flexgroup and Flexvol.

Closes-Bug: #1928241
Change-Id: I24bf98f6d7c962ff9430748ff0bc88c647b9946c
2023-03-01 15:09:56 -03:00
Zuul f075b1bd7d Merge "[NetApp] catch errors on getting vserver when reusing share server" 2023-02-28 00:59:41 +00:00
Zuul 29db644db5 Merge "NetApp: move split job to end" 2023-02-27 19:35:49 +00:00
Zuul 4befddacae Merge "[NetApp] Configure VLAN/MTU through subnet metadata" 2023-02-24 08:00:58 +00:00
Felipe Rodrigues e2729946fc [NetApp] Configure VLAN/MTU through subnet metadata
The NetApp driver can setup a share server VLAN segmentation
and MTU based on the subnet metadata. If the subnet metadata has
`set_vlan`, the driver will configure the segmentation
following the metadata fields. If the subnet metadata has the
`set_mtu` field, the MTU is configured according its value.

If share network subnet does not have those metadata fields,
the segmentation configuration keeps working as before, that's it,
it is set according to the values provided by Manila network plugin.

Change-Id: I69731b187527d8d443893dcc94c604688d73e696
2023-02-23 22:26:30 -03:00
Nahim Alves de Souza 65c82408ff NetApp ONTAP: REST transition - DHSS True functions
This patch contains the functions related to DHSS True only
functions, that is, the operations related to share servers and
network configurations.

Many functions that are used on DHSS True operations were already
covered in previous patches because they are also used
by DHSS False operations.

This patch covers DHSS True specific implementation for:

  > DHSS True driver initialization and periodic tasks
  > Setup share server
  > Delete share server
  > Security services configurations (AD, LDAP and Kerberos)
  > Create share from snapshot
  > Share server migration

partially-implements: bp netapp-ontap-rest-api-client

Change-Id: Ia8992e8125c4fc7f30fb94f19449cd62b95a4831
Co-authored-by: Caique Mello <caiquemellosbo@gmail.com>
Co-authored-by: Felipe Rodrigues <felipefuty01@gmail.com>
Co-authored-by: Helena Dantas <helenamylena@gmail.com>
Co-authored-by: Matheus Andrade <matheus.andrade@netapp.com>
Co-authored-by: Lucas Oliveira <lucasmoliveira059@gmail.com>
Co-authored-by: Luisa Amaral <luisarfamaral@gmail.com>
Co-authored-by: Luiz Santos <luizfelipe.looze@gmail.com>
Co-authored-by: Raffaela de Castro Cunha <raffaelacunha@gmail.com>
Co-authored-by: Renan Vitor <renanv@netapp.com>
2023-02-23 11:52:10 +00:00
Nahim Alves de Souza b0a1ad9785 NetApp ONTAP: REST transition - Data motion related functions
This patch implements functions related to data motion with
DHSS False. It covers:
  > share migration
  > share replication
  > create share from snapshot

partially-implements: bp netapp-ontap-rest-api-client

Change-Id: I2db309651473e6bdc7ef58dd4d2ffa6f083f665a
Co-authored-by: Caique Mello <caiquemellosbo@gmail.com>
Co-authored-by: Felipe Rodrigues <felipefuty01@gmail.com>
Co-authored-by: Helena Dantas <helenamylena@gmail.com>
Co-authored-by: Matheus Andrade <matheus.andrade@netapp.com>
Co-authored-by: Lucas Oliveira <lucasmoliveira059@gmail.com>
Co-authored-by: Luisa Amaral <luisarfamaral@gmail.com>
Co-authored-by: Luiz Santos <luizfelipe.looze@gmail.com>
Co-authored-by: Raffaela de Castro Cunha <raffaelacunha@gmail.com>
Co-authored-by: Renan Vitor <renanpiranguinho@gmail.com>
2023-02-23 11:51:56 +00:00
CaiqueMello a092c79f25 NetApp ONTAP: REST transition - DHSS False Basic operations
This patch contains the implementation for the basic operations
for DHSS False (cluster and SVM scoped account) using the ONTAP
REST API. It covers:

  > Driver initialization
  > Periodic tasks
  > Share create/delete/manage/unmanage
  > Share extend/shrink
  > Share access allow/deny
  > Share snapshot create/delete/manage/unmanage

partially-implements: bp netapp-ontap-rest-api-client

Change-Id: I7ad046a45551ce5cad07e390530877bcd5cd7e93
Co-authored-by: Caique Mello <caiquemellosbo@gmail.com>
Co-authored-by: Felipe Rodrigues <felipefuty01@gmail.com>
Co-authored-by: Helena Dantas <helenamylena@gmail.com>
Co-authored-by: Matheus Andrade <matheus.andrade@netapp.com>
Co-authored-by: Lucas Oliveira <lucasmoliveira059@gmail.com>
Co-authored-by: Luisa Amaral <luisarfamaral@gmail.com>
Co-authored-by: Luiz Santos <luizfelipe.looze@gmail.com>
Co-authored-by: Raffaela de Castro Cunha <raffaelacunha@gmail.com>
Co-authored-by: Renan Vitor <renanv@netapp.com>
2023-02-22 13:56:06 +00:00
Maurice Escher dd13d5ae39
NetApp: move split job to end
Volumes may be busy during split operation, so other actions would fail,
e.g. applying snapdir visibility, setting volume size ..

Closes-Bug: #2007970
Change-Id: I3e36f77f4e46c90af8445601e10eadf9c55ed5f6
2023-02-21 13:17:40 +01:00
Kiran Pawar 0a66bd095c NetApp: Use default_ad_site in active directory
From version 2.76, 'default_ad_site' which if provided set domain
controller discovery mode to 'site'.

Related-bug: #1988146

Depends-On: I8e21e9170eace134a51efed84de1ccc58eb7eaaa
Change-Id: I251e4f94ef04e9ad2fe24844fb8ce1947f42d752
2023-02-21 11:09:30 +00:00
Zuul d94d1ae7bd Merge "NetApp ONTAP: Implemented REST transition Client" 2023-02-16 06:58:05 +00:00