Modifies the DNS servers used by a Smart Access Gateway (SAG) instance.
Debugging
Request parameters
| Parameter | Type | Required | Example | Description |
|---|---|---|---|---|
| Action | String | Yes | ModifySagUserDns |
The operation that you want to perform. Set the value to ModifySagUserDns. |
| RegionId | String | Yes | cn-shanghai |
The ID of the region where the SAG instance is deployed. |
| SmartAGId | String | Yes | sag-whfn**** |
The ID of the SAG instance. |
| SmartAGSn | String | Yes | sag32a30**** |
The serial number of the SAG device associated with the SAG instance. |
| MasterDns | String | Yes | 192.XX.XX.1 |
The IP address of the primary DNS server. Note If you do not set this parameter, the IP address of the existing DNS server will be
cleared.
|
| SlaveDns | String | Yes | 192.XX.XX.2 |
The IP address of the secondary DNS server. Note If you do not set this parameter, the IP address of the existing DNS server will be
cleared.
|
Response parameters
| Parameter | Type | Example | Description |
|---|---|---|---|
| RequestId | String | 1120228A-E5E1-4E9C-B56D-96887E1A2B2F |
The ID of the request. |
Examples
Sample requests
http(s)://smartag.cn-shanghai.aliyuncs.com/?Action=ModifySagUserDns
&MasterDns=192.XX.XX.1
&RegionId=cn-shanghai
&SlaveDns=192.XX.XX.2
&SmartAGId=sag-whfn****
&SmartAGSn=sag32a30****
&<Common request parameters>
Sample success responses
XML format
HTTP/1.1 200 OK
Content-Type:application/xml
<ModifySagUserDnsResponse>
<RequestId>1120228A-E5E1-4E9C-B56D-96887E1A2B2F</RequestId>
</ModifySagUserDnsResponse>
JSON format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "1120228A-E5E1-4E9C-B56D-96887E1A2B2F"
}
Error codes
| HttpCode | Error code | Error message | Description |
|---|---|---|---|
| 400 | SAG.InstanceNoFound | The specified SAG instance does not exist. | The error message returned because the specified SAG instance does not exist. |
| 400 | SAG.SoftwareNotSupport | The specified SAG software edition instance does not support ACL. | The error message returned because the SAG app instance does not support access control lists (ACLs). |
| 400 | InstanceNotExit | The specified instance does not exist. | The error message returned because the specified instance does not exist. |
| 400 | ConfigUnsynchronized | The network configuration is not synchronized. | The error message returned because the network configurations are not synchronized. |
| 403 | SmartAccessGatewayNotOnline | The specified smart access gateway is not online. | The error message returned because the specified SAG device is not connected to Alibaba Cloud and the system failed to process the request. |
| 403 | FeatureNotSupport | The current edition of the smart access gateway does not support this feature. | The error message returned because the current version of the specified SAG device does not support this feature. |
| 403 | FeatureNotSupportForActiveSmartAG | The current edition of the active smart access gateway does not support this feature. | The error message returned because the current version of the active SAG device does not support this feature. |
| 403 | FeatureNotSupportForStandBySmartAG | The current edition of the standby smart access gateway does not support this feature. | The error message returned because the current version of the standby SAG device does not support this feature. |
| 500 | SmartAccessGatewayInArrears | The specified Smart Access Gateway has expired. | The error message returned because the specified SAG instance has expired. Renew the SAG instance. |
| 500 | SmartAccessGatewayNotActivated | The specified Smart Access Gateway has not been activated. | The error message returned because the specified SAG instance is not activated. Activate the SAG instance first. |
| 500 | SmartAccessGatewayOffline | The request cannot be completed. The Smart Access Gateway is offline. | The error message returned because the specified SAG device is not connected to Alibaba Cloud and the system failed to process the request. |
For a list of error codes, visit the Error Center.