MYSQL_OPT_RECONNECT is deprecated

Hi,

i am using an RT 5.03 installation on a Ubuntu Linux 22.04.3 LTS box with MariaDB Ver 10.6.12-MariaDB-0ubuntu0.22.04.1).

Starting this morning i get the following warning via rt cron daemon:

Subject of mail: Cron root@rt /opt/rt5/sbin/rt-fulltext-indexer --quiet AND
Cron root@rt /opt/rt5/sbin/rt-email-dashboards

WARNING: MYSQL_OPT_RECONNECT is deprecated and will be removed in a future version.

It is just a warning but i guess that some changes have to be made. Any suggestions?

Thx in advance and have fun,

Maurice

1 Like

I have the same setup as you, had to turn off notification in cron cause it sends every other minute.
Yes, also need to know what changes needs to be done?

I upgraded to 5.0.4 and the problem persists. I have the same setup as the previous posters.

An easy way to replicate from the command line is:
$ sudo /opt/rt5/sbin/rt-email-dashboards

(or whatever your path is to RT’s sbin/ )

1 Like

I had some software updates that I ran now and after that I ran /opt/rt5/sbin/rt-fulltext-indexer with no warning about deprecated MySQL.

Was it easy to upgrade to RT 5.0.4, did you follow any guide? Did you also upgrade the Ubuntu server?

The others in this thread are using MariaDB, not MySQL. But the error is a MySQL error, since MariaDB is interoperable.

You can run a command like “dpkg --list | grep mariadb” to see if that’s what you have.

For the upgrade: I went from 5.0.3 to 5.0.4 which was painless. Just follow the instructions in the README file.

After some system updates i got rid of the warning message. So the problem is solved.

But for my understanding: As i posted i use a MariaDB installation but i got a MySQL warning. So i guess that some client software /rt Perl stuff) uses a lib with this depricated feature. Because of the compatibility betwenn MySQl and MariaDB they are both affected or is it just a warning from the library and as MariaDB user i can ignore it?

Th@nx a lot to all posters,

Maurice

Some additional background on what happened here and the current update that removed the message:

The errors went away when I restarted my system. I had restarted my web server and various components after some system upgrades, but not the whole system. I’m not sure what specific package was causing the error pre-reboot, and then not causing error post-reboot, but the solution was to reboot.

Not sure if I should start my own thread for this, but same issue so I will comment here. RHEL 9.7 web server w/RT 5.0.3 here, database server is Ubuntu 22.04.5 LTS running MySQL 8.0.43.

My cron tasks “/opt/rt5/sbin/rt-fulltext-indexer --quiet” and “/opt/rt5/sbin/rt-clean-sessions --older 1D“ started throwing this out a few days ago, spamming me with emails. I am guessing a daily package update ran and updated the mysql package that contains libmysqlclient, which is throwing this error according to what I am reading in Jim’s links and other discussions I have seen.

I’ve been reading through the github link above and seeing some discouraging things. User “dveeden” mentions that DBD::mysql is not maintained and “for MySQL 8.1 support you really should not use DBD::mysql.” This is a Perl dependency installed by RT and so I’m guessing that BestPractical would need to be the one to make the decision to stop using this library. Otherwise, RT implementations are stuck using it even if it is not a maintained library and will be facing a wall when there is change in libmysqlclient that breaks the use of it.

Ubuntu released a patch for the libmyslclient contained in the mysql package per Jim’s other article, but as stated, I am using RHEL 9 and Red Hat may opt to not address this issue in their mysql package. This means if “MYSQL_OPT_RECONNECT “ does get removed in a future libmysqlclient packaged with the mysql package, I will be unable to upgrade to whatever MySQL version this gets removed in and will have to lock the package version. According to a comment from “MySQL Verification Team”, “It is not deprecated in 8.0, nor is it deprecated in 8.1. It remains to be seen whether it will be deprecated in 8.2 , 8.3 or some future version.” I think they meant to say “removed” here, which would make sense.

So for now, I am muting the warnings by adding “2> /dev/null” to the end of the line for both crontab entries. However, I am being asked by my manager to look into the implications of this warning appearing that we now have to ignore. If anyone has any comments above, let me know… hopefully I have a proper understanding of the issue and can come back to this thread if one day it becomes a bigger problem.