#Creating file clone through API returns error "entry doesn't exist"

1 messages · Page 1 of 1 (latest)

torn urchin
#

I'm trying to create a file clone through the API, but keep getting the error message "entry doesn't exist". I'm using vsadmin to make sure that it's not due to a lack of permissions. I've verified that I can create the clone using the CLI. The ONTAP version is 9.10.1P7.

$ ssh -l vsadmin <svm>
svm::> whoami 
  (security login whoami)

User: vsadmin
Role: vsadmin

svm::> volume file clone create -volume test -source-path test.src -destination-path test.dst

The above works. However, the following doesn't.

$ cat /tmp/clone.json
{
  "volume": {
    "name": "test",
    "uuid": "<uuid>"
  },
  "source_path": "test.src",
  "destination_path": "test.dst"
}
$ curl -sk -u vsadmin:<password> --json @/tmp/clone.json https://<svm>/api/storage/file/clone
{
  "error": {
    "message": "entry doesn't exist",
    "code": "4",
    "target": "destination_path"
  }
}

Can anyone help me understand why I'm getting the error?