Bug 23945 - koha-remove does not support older mysql and mariadb
Summary: koha-remove does not support older mysql and mariadb
Status: CLOSED INVALID
Alias: None
Product: Koha
Classification: Unclassified
Component: Database (show other bugs)
Version: Main
Hardware: All All
: P5 - low major (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on: 22128
Blocks:
  Show dependency treegraph
 
Reported: 2019-11-01 15:34 UTC by Martin Renvoize
Modified: 2020-11-30 21:45 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize 2019-11-01 15:34:25 UTC
koha-remove utilises IF EXISTS in the DROP USER calls and this was only introduced in later versions of MySQL and MariaDB.. as such it breaks on many otherwise stable distributions.
Comment 1 Martin Renvoize 2019-11-01 15:35:27 UTC
MariaDB introduced the IF EXISTS clause in 10.1.3 and MySQL introduced it in 5.7
Comment 2 Rudolf Byker 2019-11-04 11:30:29 UTC
If you are still using MariaDB from 2015 (when 10.1.3 was released) or earlier, you have bigger problems than not being able to run `koha-remove`, i.e. security vulnerabilities.
Comment 3 Jonathan Druart 2019-11-04 11:51:50 UTC
(In reply to Rudolf Byker from comment #2)
> If you are still using MariaDB from 2015 (when 10.1.3 was released) or
> earlier, you have bigger problems than not being able to run `koha-remove`,
> i.e. security vulnerabilities.

Debian stretch is still using MySQL 5.5, and we are suppose to support the oldstable debian version.
Comment 4 Rudolf Byker 2019-11-04 12:54:19 UTC
Sorry, I didn't know about the oldstable requirement. See my comment at https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22128
Comment 5 Jonathan Druart 2019-11-06 12:55:33 UTC
So, I tried to install MySQL 5.5 on a debian 9 (old stable, stretch) and realized that it was not possible.
Then I found this: https://mariadb.com/kb/en/library/moving-from-mysql-to-mariadb-in-debian-9/
Which basically says that it's expected and that Debian does no longer provide a MySQL package.

So I feel like we are good here.
Comment 6 Marcel de Rooy 2019-11-06 16:00:10 UTC
(In reply to Jonathan Druart from comment #3)
> Debian stretch is still using MySQL 5.5, and we are suppose to support the
> oldstable debian version.

Jessie indeed
Comment 7 Jonathan Druart 2019-11-06 16:12:52 UTC
(In reply to Marcel de Rooy from comment #6)
> (In reply to Jonathan Druart from comment #3)
> > Debian stretch is still using MySQL 5.5, and we are suppose to support the
> > oldstable debian version.
> 
> Jessie indeed

I meant Stretch:

vagrant@kohadevbox$ more /etc/debian_version
9.11
vagrant@kohadevbox$ apt show mysql-server
Package: mysql-server
Version: 5.5.9999+default

But that's not a "real" mysql-server package