Set FTP logging config for a virtual server
Sets FTP configuration parameters for a virtual server.
HTTP request syntax (URI)
PATCH <base_URI>/v8/storage/virtual-servers/{virtualServerId}/ftp/logging
Parameters
Name | Type | Required | Values | Description |
virtualServerId | URI_PARAM | Y | string/number | Specifies either the virtual server object ID or the HNAS storage virtual server ID. |
filesystemId | BODY | N | string | HNAS filesystem ID that will hold the logs files. The filesystem should be assigned to the virtual server. |
ensurePathExists | BODY | N | boolean | True to ensure the specified path exists. |
isEnabled | BODY | N | boolean | True to enable FTP logging, False to disable logging. |
loggingDirectory | BODY | N | string | Absolute file system path to use for storing the log files. The path should be in UNIX format. |
numberOfLogFiles | BODY | N | integer | Maximum number of log files. |
numberOfRecordsPerFile | BODY | N | integer | Number of records each log file can contain. When this value is reached a new log file will be created. |
Return codes
Code | Data | Description |
204 | No Data | FTP logging config successfully updated. |
400 | Error Message | Missing or invalid request contents. |
403 | Error Message | Operation forbidden by access level. |
404 | Error Message | Requested resource not found. |
500 | Error message | Error associated with the storage system. |
Any HTTP status code other than 204 indicates that the API did not complete successfully.
Request example: Enable logging, and set the number of log files to 5
curl -vk -H "X-Api-Key: zrxvSDAv9x.RIP4gkmKarG3beF.or.4Tc2im7oeqYN88C9XPGHxbXC" https://172.17.11.11:8444/v8/storage/virtual-servers/1/ftp/logging -X PATCH -d '{"isEnabled": true, "numberOfLogFiles": 5}'
Response example
HTTP/1.1 204 No Content