As of MySQL 5.7.7, this is what the documentation recommends for Red Hat Enterprise Linux 7, Oracle Linux 7, CentOS 7, SUSE Linux Enterprise Server 12, Fedora 24 and 25:
https://dev.mysql.com/doc/refman/5.7/en/using-systemd.html
On Ubuntu 16.04 the service is called mysql, not mysqld, so this is what Fredik did:
sudo mkdir /etc/systemd/system/mysql.service.d
sudo vi /etc/systemd/system/mysql.service.d/override.conf
Added this in the new file override.conf:[Service]
LimitNOFILE=5000
Then restarted the service:sudo systemctl daemon-reload
sudo systemctl restart mysql
沒有留言:
張貼留言