The method of starting Federated engine in MySQL under Linux
To configure the Federated engine (function: cross-database operation), you need a version above mysql5.0. The specific configuration method is as follows:
1. First go to the MySQL database to see if the federated engine is installed
Enter command: show engines
Note: it can be seen that the federated engine is not turned on.
two。 Exit the database and edit vim / etc/my.cnf to add a line of federated to this file and save exit
3. Restart the database (currently a centos7 system)
Service mysqld restart
4. Enter the database and query show engines again.
Yes has been shown in the image above, so it indicates that it has been enabled successfully!
There are three steps to build a MySQL database:
Create a database and specify the character set
Create database feiyu character set utf8
2. Create a user and authorize it
Grant all privileges on feiyu.* TO 'feiyu'@'%' identified by' password 'WITH GRANT OPTION
3. Refresh and take effect
Flush privileges