CONTAP-675455: Cloning file fails from RESTAPI if the filename contains .snapshot
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
