cPanel provides a centralized interface for creating and maintaining MySQL databases, database users, and access permissions. Proper database management is essential for application stability, beveiliging, en prestaties.
These features are available on standard cPanel-hosting omgevingen.
Managing database users
Database users authenticate applications and control access to data. Create users before assigning them to databases.
Creating a database user
- Log in op cPanel.
- Open de Hulpmiddelen pagina.
- In de Databases sectie, klikken Manage My Databases.
- Onder Nieuwe gebruiker toevoegen, enter a username.
- Set and confirm a strong password or use the password generator.
- Klikken Gebruiker aanmaken.
[Tijdelijke aanduiding voor screenshot: Add New MySQL User]
Changing a user password
- Open Manage My Databases.
- Onder Current Users, locate the user.
- Klikken Wachtwoord wijzigen.
- Set and confirm the new password.
- Sla de wijzigingen op.
Update application configuration files to match the new credentials.
Renaming a user
- Open Manage My Databases.
- Onder Current Users, klikken Rename next to the user.
- Enter the new name and proceed.
Deleting a user
Deleting a user removes all database privileges for that user.
- Open Manage My Databases.
- Onder Current Users, klikken Verwijderen.
- Confirm the deletion.
Ensure no applications rely on the user before removal.
Managing databases
After creating users, create databases and assign appropriate privileges.
Creating a database
- Open Manage My Databases.
- Onder Maak een nieuwe database, enter a database name.
- Klikken Database maken.
Database names are automatically prefixed with your account username.
Adding a user to a database
- Onder Add User to Database, select a user.
- Select the target database.
- Klikken Add.
- Assign specific privileges or select ALL PRIVILEGES.
- Klikken Make Changes.
[Tijdelijke aanduiding voor screenshot: Assign User Privileges]
Checking and repairing a database
- Onder Modify Databases, select a database in Check Database.
- Klikken Check Database.
- If issues are found, select the database under Repair Database.
- Klikken Repair Database.
Revoking user privileges
- Onder Current Databases, locate the database.
- Click the remove icon next to the user.
- Confirm Revoke User Privileges from Database.
Deleting a database
Deleting a database permanently removes its data.
- Open Manage My Databases.
- Onder Current Databases, klikken Verwijderen next to the database.
- Confirm the deletion.
Create a backup before deletion if data retention is required.
Scaling and operational considerations
For applications with higher load, larger datasets, or custom backup strategies, omgevingen zoals cloud-servers of een speciale server provide greater control over database performance, toegang, and recovery options.