Mysql – Starting MySQL with SSL option using systemd

MySQLssl

Can someone explain how to start a MySQL server with SSL options enabled using systemd? I've generated certificates and edited the my.cnf file to enable SSL but I'm not sure how to restart MySQL so that it allows SSL connections to be made with systemd.

This command did the trick before systemd but it now now longer works:

/etc/init.d/mysql start –ssl-ca=/etc/mysql/newcerts/ca.pem –ssl-cert=/etc/mysql/newcerts/server-cert.pem –ssl-key=/etc/mysql/newcerts/server-key.pem

Any help would be much appreciated.

Best Answer

You can the SSL variables into the my.cnf file and load on regular systemctl call.