This topic describes the users required for the deployment of OceanBase Cloud Platform (OCP) Community Edition.
Users
| User | Description |
|---|---|
| root | The user for uploading software packages and granting permissions. It is a built-in user of the system. You do not need to create it. |
| admin | The business user for performing OCP operations and operations related to OCP. You need to manually create an admin user for each host. For more information, see Create an admin user. |
Create an admin user
To create an admin user, you can perform the following steps:
Run the following commands to create the admin user:
useradd -U admin -d /home/admin -s /bin/bash mkdir -p /home/admin sudo chown -R admin:admin /home/adminRun the following command to set a password for the admin user:
passwd adminOptional. Set sudo permissions for the admin user.
Open the
/etc/sudoersfile. Add the following code to/etc/sudoers:## Same thing without a password # %wheel ALL=(ALL) NOPASSWD: ALL admin ALL=(ALL) NOPASSWD: ALLRun the following command in the
/homedirectory to check whether the admin user is granted the permission to access the directory.ls --alThe following output is returned:
drwxr-xr-x 2 admin admin 4096 Feb. 9 18:43 drwxr-xr-x 2 admin admin 4096 Feb. 9 18:43 adminIf the admin user does not have the access permission, run the following commands as the root user:
chown -R admin:admin /data chown -R admin:admin /home/adminNote that you need to specify your actual mount directories. The
/dataand/home/admindirectories in the preceding commands are only examples for your reference.