This topic describes how to manage database accounts, such as how to modify the passwords of accounts and lock, unlock, and delete accounts.

Background information

You can create two types of database accounts in PolarDB: privileged and standard accounts. You can manage all the accounts and databases in the PolarDB console.

Considerations

To ensure data security, you cannot create and use a root account in PolarDB.

Create a database account

For more information, see Create database accounts.

Change the password of an account

  1. Log on to the PolarDB console.
  2. On the top of the page, select the region where the target cluster is located.
  3. Find the target cluster and click the cluster ID to go to the Overview page.
  4. In the left-side navigation pane, choose Settings and Management > Accounts.
  5. Find the account for which you want to change the password, and click Change Password in the Actions column.
    Change the password
  6. In the dialog box that appears, enter and confirm the new password, and click OK.

Lock or unlock an account

You can lock an account to prevent the account from logging on to the database.

  1. Log on to the PolarDB console.
  2. On the top of the page, select the region where the target cluster is located.
  3. Find the target cluster and click the cluster ID to go to the Overview page.
  4. In the left-side navigation pane, choose Settings and Management > Accounts.
  5. Find the account that you want to lock or unlock, and turn on or off the switch in the Lock Status column.
    Lock or unlock an account

Delete an account

  1. Log on to the PolarDB console.
  2. On the top of the page, select the region where the target cluster is located.
  3. Find the target cluster and click the cluster ID to go to the Overview page.
  4. In the left-side navigation pane, choose Settings and Management > Accounts.
  5. Find the account that you want to delete, and click Delete in the Actions column.
    Delete an account
  6. In the message that appears, click OK.

Related API operations

API Description
CreateAccount Creates an account.
DescribeAccounts Queries a list of accounts.
ModifyAccountDescription Modifies the description of an account.
ModifyAccountPassword Changes the password of an account.
DeleteAccount Deletes an account.