Data Infrastructure Management Software Discussions

Highlighted

WFA reservations for export rules are not cleared on acquisition

I am building workflows for creating/deleting export rules. I need reservations to make newly created rules available for deletion immediately.

 

I used the script for creating export rule reservations in another thread: https://community.netapp.com/t5/OnCommand-Storage-Management-Software-Discussions/How-to-create-export-rules-and-add-reservations-while-using-the-row-...

 

The reservation appears and is working, but it doesn't get cleared during cache acquisition. What am I doing wrong?

2 REPLIES 2
Highlighted

Re: WFA reservations for export rules are not cleared on acquisition

moep,

 

in order to cancel reservations, you have to have a verification rule that matches the reservation against the OCUM DB.  In the case of export rules, it's a bit tricky since you can't reliably predict the rule index, but something like this should work (untested):

 

SELECT export_rule.id

FROM cm_storage.export_rule

JOIN cm_storage.export_policy ON export_rule.policy_id = export_policy.id

JOIN cm_storage.vserver ON export_policy.vserver_id = vserver.id

JOIN cm_storage.cluster ON vserver.cluster_id = cluster.id

WHERE

(cluster.name = '${Cluster}' OR cluster.primary_address = '${Cluster}')

AND vserver.name = '${VserverName}'

AND export_policy.name = '${PolicyName}'

AND export_rule.clientmatch = '${ClientMatch}'

AND export_rule.protocol = '${Protocol}'

AND export_rule.ro_rule = '${RoRule}'

AND export_rule.rw_rule = '${RwRule}'

AND export_rule.super_user = '${Superuser}'

 

Regards,

 

Christian

 

 

View solution in original post

Highlighted

Re: WFA reservations for export rules are not cleared on acquisition

That did the trick, thanks a lot!

Check out the KB!
Knowledge Base
All Community Forums