Skip to main content
NetApp Knowledge Base

REST PATCH against api snapmirror is slower compared to api private snapmirror

Views:
160
Visibility:
Public
Votes:
3
Category:
ontap-9
Specialty:
core
Last Updated:

Applies to

  • ONTAP 9 REST API
  • Snapmirror quiesce or resume via PATCH /api/snapmirror/

Issue

  • Snapmirror relationship is quiesced using REST PATCH /api/snapmirror/relationships.
  • Extra header X-Trace-Threshold: 0 is added to the API call, to let ONTAP provide a trace for the the API execution:

curl -u <username> -ik -H 'X-Trace-Threshold: 0' -X PATCH "https://<cluster_mgmt>/api/snapmirror/relationships/abcdef12-3456-7890-abcd-ef1234567890?failover=false&force-failover=false&force=false&failback=false&return_timeout=120" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"state\": \"quiesced\"}"

  •  TRACE RESULTS output TOTAL refers the total runtime in seconds under Time(s)column, in this example 28.007054 seconds:

TOTAL         28.007054   4560520   3313496  1250047272  1245486752 7488813

  • Iterating through all snapmirror relationships as example to quiesce or resume, shows heavy fluctuation of total runtime:
TOTAL        2.243367    108536   1555280   135777912   135669376 748900
TOTAL        6.317346    812448   1316560   380904776   380092328 2225330
TOTAL        5.647037    640168   1085064   337228984   336588816 1962052
TOTAL        20.066069    256184   2077816  1149995480  1149739296 6877598
TOTAL        13.994593    271024   1246936   786166392   785895368 4685152
TOTAL        15.047924   -214920   2056520   873587096   873802016 5227347
TOTAL        10.544924   -364760   2231864   609750584   610115344 3651247
TOTAL        0.949309    618784   1059000    65859976    65241192 337164
TOTAL        0.928465    607896   1057768    65932456    65324560 331695
  • In worst case, if the REST response exceeds the return_timeout, the REST call returns with HTTP 502 error.
  • At the same time, a PATCH against other APIs, as example /api/cluster to update the location comment field, is constantly fast:
curl -u <username> -ik -H 'X-Trace-Threshold: 0' -X PATCH "https://<cluster>/api/cluster?return_timeout=120" -H "accept: application/json" -H "Content-Type: application/json" -d "{ \"location\": \"just a test to compare against snapmirror PATCH\"}"
...
TOTAL        0.005913     64296     86616      213960      149664   1005
...
  • Also CLI or alternatively REST API PATCH against /private/cli/snapmirror is constantly faster:
::*> snapmirror resume {-status quiesced  -destination-path *} -smftrace
...
----------------------------------------------------------------------------------
TOTAL        0.046835    -11936    972408     5757776     5769712  21116
...

 

Sign in to view the entire content of this KB article.

New to NetApp?

Learn more about our award-winning Support

NetApp provides no representations or warranties regarding the accuracy or reliability or serviceability of any information or recommendations provided in this publication or with respect to any results that may be obtained by the use of the information or observance of any recommendations provided herein. The information in this document is distributed AS IS and the use of this information or the implementation of any recommendations or techniques herein is a customer's responsibility and depends on the customer's ability to evaluate and integrate them into the customer's operational environment. This document and the information contained herein may be used solely in connection with the NetApp products discussed in this document.