Atom feed of this document
 

 4.2.7. Enable Root User

 
MethodURIDescription
POST/instances/{instanceId}/root

Enables the root user for the specified database instance and returns the root password.

Enables the root user for the specified database instance and returns the root password.

This operation enables login from any host for the root user and provides the user with a generated root password.

[Note]Note

Changes you make as a root user may cause detrimental effects to the database instance and unpredictable behavior for API operations. When you enable the root user, you accept the possibility that we will not be able to support your database instance. While enabling root does not prevent us from a “best effort” approach to helping you if something goes wrong with your instance, we cannot ensure that we will be able to assist you if you change core MySQL settings. These changes can be (but are not limited to) turning off binlogs, removing users that we use to access your instance, and so forth.

Normal response codes: 200

Error response codes: badRequest (400), unauthorized (401), forbidden (403), badMethod (405), overLimit (413), unprocessableEntity (422), instanceFault (500), notImplemented (501), serviceUnavailable (503), itemNotFound (404)

 4.2.7.1. Request

This table shows the URI parameters for the Enable Root User Request:

NameTypeDescription

{accountId}

​String

The account ID of the owner of the specified instance.

{instanceId}

​String

The instance ID for the specified database instance.

 

Example 4.37. Enable Root User Request: XML

The following examples show the Enable Root User requests:

POST /v1.0/1234/instances/dcf2c32b-241d-4c39-af70-1001dfe946d6/root HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/xml
Content-Type: application/xml



 

Example 4.38. Enable Root User Request: JSON

POST /v1.0/1234/instances/d4603f69-ec7e-4e9b-803f-600b9205576f/root HTTP/1.1
User-Agent: python-troveclient
Host: ord.databases.api.rackspacecloud.com
X-Auth-Token: 87c6033c-9ff6-405f-943e-2deb73f278b7
Accept: application/json
Content-Type: application/json



This operation does not require a request body.

 4.2.7.2. Response

 

Example 4.39. Enable Root User Response: XML

The following examples show the Enable Root User responses:

HTTP/1.1 200 OK
Content-Type: application/xml
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 89
Date: Thu, 13 Feb 2014 21:47:14 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

<user name="root" password="12345" xmlns="http://docs.openstack.org/database/api/v1.0"/>


 

Example 4.40. Enable Root User Response: JSON

HTTP/1.1 200 OK
Content-Type: application/json
Via: 1.1 Repose (Repose/2.6.7)
Content-Length: 47
Date: Thu, 13 Feb 2014 21:47:14 GMT
Server: Jetty(8.0.y.z-SNAPSHOT)

{
    "user": {
        "name": "root", 
        "password": "12345"
    }
}



loading table of contents...