The database
utility is used to manage databases and database users
in Plesk through CLI. By using this utility, you can perform the
following tasks:
- creating or deleting databases
- adding and removing database users
- adding or removing access control records for MySQL database users
- adding firewall access rules for PostgreSQL database users
- editing database user credentials
- setting charset for PostgreSQL databases
Usage
database <command> [<database name>] [
<option_1> [<param>]
[<option_2> [<param>]]
... [<option_N> [<param>]]
]
Example
The following command creates database jdoe-gallery on a database
server accessible at the IP address and port number 192.0.2.78:3838
and displays the ID of the created database:
plesk bin database --create jdoe-gallery -domain example.com -server 192.0.2.78:3838 -print-id
Commands
Command | Parameter | Description | Example |
---|---|---|---|
--create or -c
|
<database_name> |
Creates a database on a database server. Requires the In addition, either the |
To create the database jdoe-gallery for the domain plesk bin database --create jdoe-gallery… |