How to Enable the Federated Engine in MySQL

The MySQL database does not enable the federated module by default. You need to modify the my.cnf configuration. If you are using the Docker version, you can handle the extension situation through volumes:

mysql:
  image: mysql:8.1.0
  volumes:
    - ./storage/mysql-conf:/etc/mysql/conf.d
  environment:
    MYSQL_DATABASE: nocobase
    MYSQL_USER: nocobase
    MYSQL_PASSWORD: nocobase
    MYSQL_ROOT_PASSWORD: nocobase
  restart: always
  networks:
    - nocobase

Create a new ./storage/mysql-conf/federated.cnf file

[mysqld]
federated

Restart MySQL

docker compose up -d mysql

Check if federated is activated

show engines

Alt text