Updated on 2024-06-04 GMT+08:00

Configuring Kafka Users

DMS for Kafka supports access control list (ACL) for topics. You can differentiate user permissions by granting users different permissions in a topic.

This section describes how to create users, reset the password, modify user information, and delete users with ciphertext access enabled. For details about how to grant user permissions, see Configuring Kafka Topic Permissions.

For Kafka instances created before July 15, 2023, a maximum of 20 users can be created for each instance. For Kafka instances created since July 15, 2023, a maximum of 500 users can be created for each instance.

There are two ways to create a user on the console. Accordingly, there are two ways to reset the user's password:

This function is unavailable for single-node instances.

Prerequisites

  • Ciphertext access has been enabled for the Kafka instance.
  • Kafka users can be configured only for Kafka instances in the Running state.

Creating a User

  1. Log in to the console.
  2. Click in the upper left corner to select a region.

    Select the region where your Kafka instance is located.

  3. Click and choose Middleware > Distributed Message Service (for Kafka) to open the console of DMS for Kafka.
  4. Click the desired Kafka instance to view the instance details.
  5. On the Users page, click Create User.
  6. In the displayed Create User dialog box, set the username, password, and description, and click OK.

    After the user is created, grant permissions to the user by referring to Configuring Kafka Topic Permissions.

Resetting the User Password (for New Users)

  1. Log in to the console.
  2. Click in the upper left corner to select a region.

    Select the region where your Kafka instance is located.

  3. Click and choose Middleware > Distributed Message Service (for Kafka) to open the console of DMS for Kafka.
  4. Reset the user password for new users in either of the following ways.

    • Choose More > Reset Kafka Password in the row containing the desired Kafka instance.
    • Click the desired Kafka instance to view its details. Choose More > Reset Kafka Password in the upper left corner.
    • Click the desired Kafka instance to view its details. On the Basic Information page, click Reset Password next to Username in the Connection section.
    • Click the desired Kafka instance to view its details. On the Users page, click Reset Password in the row containing the desired user.

  5. Enter and confirm a new password, and click OK.

    • If the password is successfully reset, a success message is displayed.
    • If the password fails to be reset, a failure message is displayed. In this case, reset the password again. If you still fail to reset the password after multiple attempts, contact customer service.

    The system will display a success message only after the password is successfully reset on all brokers.

Resetting the User Password (for Non-new Users)

  1. Log in to the console.
  2. Click in the upper left corner to select a region.

    Select the region where your Kafka instance is located.

  3. Click and choose Middleware > Distributed Message Service (for Kafka) to open the console of DMS for Kafka.
  4. Click the desired Kafka instance to view its details.
  5. On the Users page, click Reset Password in the row containing the desired user.
  6. Enter and confirm a new password, and click OK.

    • If the password is successfully reset, a success message is displayed.
    • If the password fails to be reset, a failure message is displayed. In this case, reset the password again. If you still fail to reset the password after multiple attempts, contact customer service.

    The system will display a success message only after the password is successfully reset on all brokers.

Modifying User Information

  1. Log in to the console.
  2. Click in the upper left corner to select a region.

    Select the region where your Kafka instance is located.

  3. Click and choose Middleware > Distributed Message Service (for Kafka) to open the console of DMS for Kafka.
  4. Click the desired Kafka instance to view its details.
  5. In the navigation pane, choose Users.
  6. In the row containing the desired user, click Edit.
  7. Modify the description and click OK.

    After the modification is successful, you can view the new description in the Description column.

Deleting a User

  1. Log in to the console.
  2. Click in the upper left corner to select a region.

    Select the region where your Kafka instance is located.

  3. Click and choose Middleware > Distributed Message Service (for Kafka) to open the console of DMS for Kafka.
  4. Click the desired Kafka instance to view its details.
  5. Delete a user in either of the following ways:

    • On the Users page, click Delete in the row containing the desired user.
    • On the Users page, select one or more users and click Delete above the list.

    The user set when ciphertext access is enabled for the first time cannot be deleted.

  6. In the displayed Delete User dialog box, click OK to delete the user.