I just recently upgrade my server from 16.04 to 18.04 and then to 20.04, during the upgrade process I was able to see some mysql issue comes up but the upgrade kept progress. After successful upgrade to 20.04, I see that there’s a major issue in MySQL.
After checking with “systemctl status mysql.service”, I got the following thing.
mysql.service - MySQL Community Server Loaded: loaded (/lib/systemd/system/mysql.service; enabled; vendor preset: enabled) Active: activating (start) since Fri 2022-05-06 11:17:27 UTC; 641ms ago Process: 241527 ExecStartPre=/usr/share/mysql/mysql-systemd-start pre (code=exited, status=0/SUCCESS) Main PID: 241535 (mysqld) Status: “Server startup in progress” Tasks: 2 (limit: 19144) Memory: 586.8M CGroup: /system.slice/mysql.service └─241535 /usr/sbin/mysqld
May 06 11:17:27 ip-172-31-29-168 systemd[1]: Starting MySQL Community Server.
I even checked the logs and I found this:
2022-05-06T11:29:52.170077Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. 2022-05-06T11:29:52.756121Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. 2022-05-06T11:29:52.939990Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. 2022-05-06T11:29:52.940034Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. 2022-05-06T11:29:52.942525Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘query_cache_limit=4M’. 2022-05-06T11:29:52.942820Z 0 [ERROR] [MY-010119] [Server] Aborting 2022-05-06T11:29:54.568817Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.29-0ubuntu0.20.04.3) (Ubuntu). 2022-05-06T11:29:55.161047Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.29-0ubuntu0.20.04.3) starting as process 257630 2022-05-06T11:29:55.169573Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. 2022-05-06T11:29:55.734125Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. 2022-05-06T11:29:55.965961Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. 2022-05-06T11:29:55.966006Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. 2022-05-06T11:29:55.968529Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘query_cache_limit=4M’. 2022-05-06T11:29:55.968828Z 0 [ERROR] [MY-010119] [Server] Aborting 2022-05-06T11:29:57.525466Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.29-0ubuntu0.20.04.3) (Ubuntu). 2022-05-06T11:29:58.159315Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.29-0ubuntu0.20.04.3) starting as process 257692 2022-05-06T11:29:58.167275Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. 2022-05-06T11:29:58.748794Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. 2022-05-06T11:29:58.979086Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. 2022-05-06T11:29:58.979132Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. 2022-05-06T11:29:58.981610Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘query_cache_limit=4M’. 2022-05-06T11:29:58.981910Z 0 [ERROR] [MY-010119] [Server] Aborting 2022-05-06T11:30:00.544315Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.29-0ubuntu0.20.04.3) (Ubuntu). 2022-05-06T11:30:01.163197Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.29-0ubuntu0.20.04.3) starting as process 257757 2022-05-06T11:30:01.171239Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. 2022-05-06T11:30:01.801433Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. 2022-05-06T11:30:02.013448Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. 2022-05-06T11:30:02.013496Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. 2022-05-06T11:30:02.016113Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘query_cache_limit=4M’. 2022-05-06T11:30:02.016451Z 0 [ERROR] [MY-010119] [Server] Aborting 2022-05-06T11:30:03.619098Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.29-0ubuntu0.20.04.3) (Ubuntu). 2022-05-06T11:30:04.163684Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.29-0ubuntu0.20.04.3) starting as process 257853 2022-05-06T11:30:04.171781Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started. 2022-05-06T11:30:04.748591Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended. 2022-05-06T11:30:04.978916Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed. 2022-05-06T11:30:04.978961Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel. 2022-05-06T11:30:04.981501Z 0 [ERROR] [MY-000067] [Server] unknown variable ‘query_cache_limit=4M’. 2022-05-06T11:30:04.981807Z 0 [ERROR] [MY-010119] [Server] Aborting
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!
Hi @vipingoyal,
What you should be looking at is the [ERROR] code entry. In there you can see the following error
[Server] unknown variable ‘query_cache_limit=4M’
This means query_cache_limit is no longer a variable supported by your new MySQL version. You’ll need to remove it from your MySQL configuration file called my.cnf. It should be found in
/etc/mysql/my.cnf
. Open the file remove the line query_cache_limit and restart MySQL afterwards.Hi there,
In addition to what has already been mentioned, you can search for the
query_cache_limit
variable in all of the MySQL configuration files using the following command:Then you can edit all of the files and remove all of the references for that
query_cache_limit
variable.After doing so, you can restart MySQL with:
Let me know how it goes.
Best,
Bobby
Ey @vipingoyal,
Some options and variables are removed in MySQL 8.0 such as query_cache_limit, you should modify your
/etc/mysql/my.cnf
file in case there is any other deprecated variable.You can check out Options and Variables Removed in MySQL 8.0 for reference.
Hope that helps you,
Sergio Turpín