Drop-In:
/etc/systemd/system/(mysqld/mysql/mariadb).service.d
└─limits.conf
[Service]
LimitNOFILE=10 + [max_connections] + ([table_open_cache] * 2)
systemctl daemon-reload
SHOW VARIABLES LIKE 'open_files_limit';
+------------------+--------+
| Variable_name | Value |
+------------------+--------+
| open_files_limit | 102400 |
+------------------+--------+
1 row in set (0.00 sec)