Plesk Automation does not allow to add MySQL service to Windows-based node.
Plesk Automation does not support Windows-based MySQL.
While Plesk for Windows provides support for MySQL databases, IIS-based web server nodes in Plesk Automation do not do that. This means that before transferring customer databases from Windows-based Plesk servers, you should first add support for MySQL to the target node.
To add support for MySQL on the target IIS web server node:
Obtain the MySQL 5.1 distribution package and install it following the installation instructions;
Add the MySQL installation directory to the PATH environment variable;
Restart the PEM service by running the following commands on behalf of the Windows administrator:
net stop pem net start pem
- Add 'MySQL' attribute to a service node where the MySQL service was installed.
After you installed MySQL manually you need to register this server as an existing database server in Plesk Automation:
1. Start the Add Database Server wizard in Administration Panel > Infrastructure > Database Servers. 2. Provide the following information to the wizard: - A server host name or an IP address and a port number. - A database server type: MySQL, PostgreSQL, or Microsoft SQL Server. - Database server administrator's credentials.
Do not use 'root' as the username. The best way is to create a special user with administrator priveleges:
First, use the 'mysql' program to connect to the server as the MySQL root user:
shell> mysql --user=root mysql
After connecting to the server as root, you can add new accounts. The following example uses CREATE USER and GRANT statements to set up 'pa_admin' account:
mysql> CREATE USER 'pa_admin'@'%' IDENTIFIED BY '<password>'; mysql> GRANT ALL PRIVILEGES ON *.* TO 'pa_admin'@'%' -> WITH GRANT OPTION; mysql> FLUSH PRIVILEGES;
When registering an existing database server, the system does not add it to the list of available service nodes and does not automatically assign any provisioning attributes to this server. This server will be shown only in the list in Infrastructure > Database Servers.
The next step is to create a new resource at Plesk Automation CP:
1. Go to Products - Resources - 'Add New Resource Type'; 2. Resource class 'Database Service'; 3. Name for example: "MySQL Windows"; 4. Databse server type - MySQL, port - 3306 (or which you are using for MySQL service on this server), IP address - ip address of the node with MySQL installed.
Then you need to add this new resource into an appropriate service template:
1. Go to Products - Service Templates - choose a service template - Resources tab - 'Add resource'; 2. Choose created on the previous step resource (for example 'MySQL Windows').