Skip to main content
NetApp Knowledge Base

CONTAP-675455: Cloning file fails from RESTAPI if the filename contains .snapshot

Views:
1
Visibility:
Public
Votes:
0
Category:
ontap-9
Specialty:
core
Last Updated:

Issue

  • When the file contains the string ".snapshot" within it's file name, the file clone operation from RESTAPI fails:

[root@rhel1 rest_copy]# curl -ku admin:xxx -X POST "https://cluster1/api/storage/file/clone" -d '{"volume.name": "vtest", "source_path": "/rest_copy/file.snapshot.txt", "volume.uuid": "96185d7f-2776-11f1-90d4-0050569ce84e", "overwrite_destination": "true", "destination_path": "/rest_copy/file.snapshot.dst"}'
{
"job": {
"uuid": "0ebdd062-2864-11f1-90d4-0050569ce84e",
"_links": {
"self": {
"href": "/api/cluster/jobs/0ebdd062-2864-11f1-90d4-0050569ce84e"
}
}
}
}
[root@rhel1 rest_copy]# curl -ku admin:Netapp1! -X GET "https://cluster1/api/cluster/jobs/0ebdd062-2864-11f1-90d4-0050569ce84e"
{
"uuid": "0ebdd062-2864-11f1-90d4-0050569ce84e",
"description": "POST /api/storage/file/clone/vtest/96185d7f-2776-11f1-90d4-0050569ce84e/%2Frest_copy%2Ffile.snapshot.txt/%2Frest_copy%2Ffile.snapshot.dst",
"state": "failure",
"message": "\"source-path\" is a required field",
"code": 2,
"start_time": "2026-03-25T16:02:43+00:00",
"end_time": "2026-03-25T16:02:43+00:00",
"error": {
"message": "\"source-path\" is a required field",
"code": "2"
},
"_links": {
"self": {
"href": "/api/cluster/jobs/0ebdd062-2864-11f1-90d4-0050569ce84e"
}
}

  • Same clone operation from clustershell works:

cluster1::> file clone create -source-path /vol/vtest/rest_copy/file.snapshot.txt -destination-path /vol/vtest/rest_copy/file.snapshot_cli.txt
cluster1::>
# File from client:
[root@rhel1 rest_copy]# ls -trl *cli*
-rw-r--r--. 1 nobody nobody 1260 Mar 27 08:35 file.snapshot_cli.txt

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.