Setting Up MySQL Databases for New Websites: Difference between revisions
Jump to navigation
Jump to search
(Created page with "== Workflow == * Remote Desktop to the development web server * MySQL Administrator ** Login as "root" ** '''Catalogs''' > schema list > ''right click'' > '''Create New Schem...") |
No edit summary Tag: wikieditor |
||
| Line 38: | Line 38: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
[[Category:MySQL]] [[Category:Web Development]] | [[Category:MySQL]][[Category:MariaDB]][[Category:Databases]][[Category:Web Development]] | ||
Revision as of 13:46, 5 March 2024
Workflow
- Remote Desktop to the development web server
- MySQL Administrator
- Login as "root"
- Catalogs > schema list > right click > Create New Schema (Ctrl+n)
- User Administration > user list > right click > Add new user
- User Information tab
- Enter login
- Generate password using cPanel's MySQL administration
- Login to cPanel
- Databases > MySQL Databases
- MySQL Users > Password Generator > copy the password string
- Save the password in the site configuration
- Enter the password in MySQL Administrator
- Schema Privileges tab
- Select the new database from the Schemata list
- Click the << button to move all Available Privileges to the Assigned Privileges column.
- Click Apply changes
- User Information tab
- Service Control
- Click Stop Service
- Click Start Service
TODO
Research creating a script to create new databases for websites.
# log in
shell> mysql -h {host} -u root
# create the database
mysql> CREATE DATABASE {database_name};
# create the user
# grant user privileges on the database