ruby-riddle tests start mysql server with unknown option --force

Bug #1686859 reported by Nish Aravamudan
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ruby-riddle (Ubuntu)
Fix Released
Undecided
Lars Tangvald

Bug Description

The last two uploads of src:ruby-riddle to artful have failed to build: https://launchpad.net/ubuntu/+source/ruby-riddle/1.5.12-4 and https://launchpad.net/ubuntu/+source/ruby-riddle/1.5.12-4ubuntu1.

I wonder if MariaDB in Debian (now the default) supports --force but MySQL doesn't?

Nish Aravamudan (nacc)
Changed in ruby-riddle (Ubuntu):
assignee: nobody → Lars Tangvald (lars-tangvald)
tags: added: ftbfs
Robie Basak (racb)
tags: added: mysql-default-delta
Revision history for this message
Lars Tangvald (lars-tangvald) wrote :

Yes, this option was removed in MySQL 5.7. There have been similar issues with other ruby-mysql packages, so I'll test that the same fix works

Revision history for this message
Lars Tangvald (lars-tangvald) wrote :

The following diff on start_mysqld_and_run.sh fixes the failure, but a couple of notes:
1. This will break it for MariaDB. I think there's a package in sid that has changed the same script to support both variants, so will try to find that instead
2. The --secure-file-priv= was needed because the tests load data from a file, and I also had to set MySQL's apparmor profile to complain mode to make this work. Aside from --secure-file-priv, the diff is just copied from ruby-mysql2

20,21c20,21
< mysql_install_db --no-defaults --datadir=${MYTEMP_DIR} --force --skip-name-resolve --user=${DO_MYSQL_USER}
< /usr/sbin/mysqld --no-defaults --user=${DO_MYSQL_USER} --socket=${MYSQL_UNIX_PORT} --datadir=${MYTEMP_DIR} --skip-networking --skip-grant &
---
> mysql_install_db --no-defaults --datadir=${MYTEMP_DIR} --insecure --basedir=/usr --user=${DO_MYSQL_USER}
> /usr/sbin/mysqld --no-defaults --user=${DO_MYSQL_USER} --socket=${MYSQL_UNIX_PORT} --datadir=${MYTEMP_DIR} --skip-networking --secure-file-priv= &

Revision history for this message
Lars Tangvald (lars-tangvald) wrote :

I was wrong about the other package, unfortunately, as it only added support for older MySQL packages, not MariaDB.
I've attached a patch that should fix the build for MySQL 5.7 (but is not backwards-compatible)

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Support for MySQL 5.7" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Nish Aravamudan (nacc)
description: updated
Revision history for this message
Robie Basak (racb) wrote :

16:58 <nacc> rbasak: re: LP: #1686859, my reading is that should be ok to sponsor?

16:58 <ubottu> Launchpad bug 1686859 in ruby-riddle (Ubuntu) "ruby-riddle tests start mysql server with unknown option --force" [Undecided,New] https://launchpad.net/bugs/1686859

16:59 <nacc> rbasak: as delta for us? since our default is still mysql 5.7?

17:00 <rbasak> nacc: I believe so, though I think Lars might be working on an improvement. Would you want to wait for that? If so I can confirm with him in the bug.

17:03 <nacc> rbasak: that's fine, i'm just trying to push through the php7.0 removal and that's the last build-dep to get rid of :)

@Lars, did you intend this debdiff for upload, or is a work in progress report?

PS. mostly we prefer unified diff format, though I'm sure we can manage with this if needed :)

Revision history for this message
Lars Tangvald (lars-tangvald) wrote :

There's a typo in the patch (USER set to ME instead of DO_MYSQL_USER) and I need to resolve the apparmor issue, so I'll upload another patch.

Revision history for this message
Lars Tangvald (lars-tangvald) wrote :

Patch with typo fixed (the typo didn't break the build, but was inconsistent).

I'm a bit confused about the apparmor issue. The behavior doesn't seem new, so is apparmor disabled during standard builds? Or maybe the builds happen in a way MySQL's default profile actually handles.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ruby-riddle - 1.5.12-4ubuntu2

---------------
ruby-riddle (1.5.12-4ubuntu2) artful; urgency=medium

  * d/start_mysqld_and_run.sh: fix compatbility with MySQL server.
    - Debian defaults to MariaDB which accepts different arguments.
    - LP: #1686859
    - Thanks to Lars Tangvald <email address hidden>

 -- Nishanth Aravamudan <email address hidden> Thu, 04 May 2017 09:09:32 -0700

Changed in ruby-riddle (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.