Update the Vscan On-Demand policy configuration for an SVM
- PDF of this doc site
Collection of separate PDF docs
Creating your file...
PATCH /protocols/vscan/{svm.uuid}/on-demand-policies/{name}
Introduced In: 9.6
Updates the Vscan On-Demand policy configuration of an SVM. Use schedule name or schedule UUID to schedule an On-Demand scan.
Related ONTAP commands
-
vserver vscan on-demand-task modify
-
vserver vscan on-demand-task schedule
-
vserver vscan on-demand-task unschedule
Parameters
Name | Type | In | Required | Description |
---|---|---|---|---|
name |
string |
path |
True |
|
svm.uuid |
string |
path |
True |
UUID of the SVM to which this object belongs. |
Request Body
Name | Type | Description |
---|---|---|
log_path |
string |
The path from the Vserver root where the task report is created. |
name |
string |
On-Demand task name |
scan_paths |
array[string] |
List of paths that need to be scanned. |
schedule |
Schedule of the task. |
|
scope |
||
svm |
SVM, applies only to SVM-scoped objects. |
Example request
{
"log_path": "/vol0/report_dir",
"name": "task-1",
"scan_paths": [
"/vol1/",
"/vol2/cifs/"
],
"schedule": {
"_links": {
"self": {
"href": "/api/resourcelink"
}
},
"name": "weekly",
"uuid": "1cd8a442-86d1-11e0-ae1c-123478563412"
},
"scope": {
"exclude_extensions": [
"mp3",
"mp4"
],
"exclude_paths": [
"/vol1/cold-files/",
"/vol1/cifs/names"
],
"include_extensions": [
"vmdk",
"mp*"
],
"max_file_size": 10737418240
},
"svm": {
"_links": {
"self": {
"href": "/api/resourcelink"
}
},
"name": "svm1",
"uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
}
}
Response
Status: 200, Ok
Error
Status: Default
ONTAP Error Response Codes
Error Code | Description |
---|---|
10027101 |
The file size must be in the range 1KB to 1TB |
10027107 |
The include extensions list cannot be empty. Specify at least one extension for inclusion. |
10027164 |
An On-Demand policy cannot be scheduled, as the Vscan is disabled. Enable the Vscan and retry the operation. |
10027167 |
The specified schedule does not exist. Create the schedule or create a policy without specifying the schedule. |
10027168 |
The specified scan path does not exist. The scan path must be specified from the root of the SVM, and must begin with UNIX path delimiters (use “/” not “\”) |
10027169 |
The specified scan path is not supported for scanning. |
10027174 |
The specified exclude path is invalid. The path must be specified from the root of the SVM, and must begin with UNIX path delimiters (use "/" not "\") |
10027175 |
An On-Demand policy cannot be scheduled as the SVM is not in an operational state. |
10027176 |
The log-path specified does not exist. The log path must be specified from the root of the SVM, and must begin with UNIX path delimiters (use “/” not “\”) |
10027177 |
The log path specified is not supported. |
10027253 |
The number of paths specified exceeds the configured maximum number of paths. You cannot specify more than the maximum number of configured paths. |
10027254 |
The number of extensions specified exceeds the configured maximum number of extensions. You cannot specify more than the maximum number of configured extensions. |
10027255 |
Another policy is already scheduled. Only one policy per SVM is allowed to be scheduled at any one time. Update a policy without specifying a schedule. |
Name | Type | Description |
---|---|---|
error |
Example error
{
"error": {
"arguments": [
{
"code": "string",
"message": "string"
}
],
"code": "4",
"message": "entry doesn't exist",
"target": "uuid"
}
}
Definitions
See Definitions
href
Name | Type | Description |
---|---|---|
href |
string |
_links
Name | Type | Description |
---|---|---|
self |
schedule
Schedule of the task.
Name | Type | Description |
---|---|---|
_links |
||
name |
string |
Job schedule name |
uuid |
string |
Job schedule UUID |
scope
Name | Type | Description |
---|---|---|
exclude_extensions |
array[string] |
List of file extensions for which scanning is not performed. |
exclude_paths |
array[string] |
List of file paths for which scanning must not be performed. |
include_extensions |
array[string] |
List of file extensions to be scanned. |
max_file_size |
integer |
Maximum file size, in bytes, allowed for scanning. |
scan_without_extension |
boolean |
Specifies whether or not files without any extension can be scanned. |
svm
SVM, applies only to SVM-scoped objects.
Name | Type | Description |
---|---|---|
_links |
||
name |
string |
The name of the SVM. This field cannot be specified in a PATCH method. |
uuid |
string |
The unique identifier of the SVM. This field cannot be specified in a PATCH method. |
vscan_on_demand
Use On-Demand scanning to check files for viruses on a schedule. An On-Demand policy defines the scope of an On-Demand scan.
Name | Type | Description |
---|---|---|
log_path |