Delete a RAM role

更新时间:
复制 MD 格式

You can delete a RAM role when you no longer need it.

Procedure

  1. Log in to the RAM console as a RAM administrator.

  2. In the navigation pane on the left, go to Identities > Roles.

  3. On the Roles page, find the RAM role that you want to delete and click Delete Role in the Actions column.

  4. In the Delete Role dialog box, enter the RAM role name and click Delete Role.

    Role names are case-sensitive. The name that you enter must exactly match the name displayed in the role list. Otherwise, the Delete Role button will remain disabled. The names of service-linked roles are often in camelCase, such as AliyunServiceRoleForSmartService. To avoid case-sensitive errors, copy the role name from the role list and paste it into the confirmation text box.

    If policies are attached to the RAM role, they are automatically detached when you delete the role.

    If you attempt to delete a service-linked role that is in use by its corresponding cloud service, the operation will fail. You must first go to the console of the cloud service to remove its dependency on the role, and then delete the role again. For more information about service-linked roles, see Service-linked roles.

    After you submit the deletion request, the role's status changes to Deleting. Once the asynchronous deletion is complete, the role is removed from the role list.

    If a deletion task fails, click Role Deletion Tasks in the upper-right corner of the role list to view the details.