Forum Discussion
Hey Guys, I need help here. We need to have a script to permantly change the default pool. So that we are able to switch the default pool for a number of Virtual Servers. Therefore I wrote a script to use the curl command which is: curl -sk -u 'admin:admin' -H "Content-Type: application/json" -X PUT -d '{"pool":"sVirtual-2"}'
But for some reason I receive the following error message:
{"code":400,"message":"0107028c:3: The source (::) and destination (123.123.123.123) addresses for virtual server (/Common/VS1) must be be the same type (IPv4 or IPv6).","errorStack":[]}
So I checked the config of the virtual server and the Source IP is IPv4 "0.0.0.0/0"
Any input here?
Or is the curl command maybe wrong?
The PATCH method for updating the default pool of a Virtual works fine so far. Now we want to create a user which is allowed to change the default pool only for a couple of Virtual Servers. Therefore we created a role over REST API and granted Restmethod "PATCH" for those Virtual servers. But the user is not allowed to change the default pool and we receive a 401 message saying "Authorization failed" when trying to PATCH the default pool attribute. Using a admin user works fine.