[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2017-05-11 Thread WhyteHorse
This bug is back. I'm on 16.04 and got a failed upgrade of mysql.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-21 Thread Launchpad Bug Tracker
This bug was fixed in the package mysql-5.7 - 5.7.13-0ubuntu0.16.04.2

---
mysql-5.7 (5.7.13-0ubuntu0.16.04.2) xenial-security; urgency=medium

  * SECURITY UPDATE: Update to 5.7.13 to fix security issues (LP: #1604796)
- 
http://www.oracle.com/technetwork/security-advisory/cpujul2016-2881720.html
- CVE-2016-3424
- CVE-2016-3459
- CVE-2016-3477
- CVE-2016-3486
- CVE-2016-3501
- CVE-2016-3518
- CVE-2016-3521
- CVE-2016-3588
- CVE-2016-3614
- CVE-2016-3615
- CVE-2016-5436
- CVE-2016-5437
- CVE-2016-5439
- CVE-2016-5440
- CVE-2016-5441
- CVE-2016-5442
- CVE-2016-5443
  * debian/patches/mysql-export-scramble.patch: removed, upstream.

 -- Marc Deslauriers   Wed, 20 Jul 2016
08:44:25 -0400

** Changed in: mysql-5.7 (Ubuntu Xenial)
   Status: Fix Committed => Fix Released

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3424

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3459

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3477

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3486

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3501

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3518

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3521

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3588

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3614

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-3615

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5436

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5437

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5439

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5440

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5441

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5442

** CVE added: http://www.cve.mitre.org/cgi-
bin/cvename.cgi?name=2016-5443

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-20 Thread Robie Basak
Verified. This is tricky to test because it is a race condition, but I
have verified that it appears that mysql_upgrade isn't being called
twice, and I have also ran a test upgrade five times with no issues.

I examined /var/log/upstart/mysql.log before and after a test upgrade.
Previously, we were printing "Checking for tables which need an upgrade,
are corrupt or were not closed cleanly." there when running
mysql_upgrade from the upstart job. After a test upgrade to xenial-
proposed, we longer see this string, so it seems likely that mysql-start
was updated at the correct time. I also manually checked
/var/log/apt/term.log after a release upgrade to xenial-proposed and
this appears to be consistent with this. mysqld is running (still on
upstart) after an upgrade. After a reboot, systemd has started it as
expected.

** Tags removed: verification-needed
** Tags added: verification-done

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-15 Thread Adam Conrad
Hello Robie, or anyone else affected,

Accepted mysql-5.7 into xenial-proposed. The package will build now and
be available at
https://launchpad.net/ubuntu/+source/mysql-5.7/5.7.12-0ubuntu1.2 in a
few hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to
enable and use -proposed.  Your feedback will aid us getting this update
out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, and change the tag
from verification-needed to verification-done. If it does not fix the
bug for you, please add a comment stating that, and change the tag to
verification-failed.  In either case, details of your testing will help
us make a better decision.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance!

** Changed in: mysql-5.7 (Ubuntu Xenial)
   Status: In Progress => Fix Committed

** Tags added: verification-needed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-14 Thread Robie Basak
Uploaded to Xenial. SRU team: you may find it easier to review if you
verify my uploaded delta is the same as
https://git.launchpad.net/~racb/ubuntu/+source/mysql-5.7/log/?h=mysql-5.7/ubuntu/xenial
and then use that.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-14 Thread Lars Tangvald
** Description changed:

  Due to the old upstart script still being active, mysql_upgrade is
  called both via upstart on daemon start and by mysql-server-5.7.postinst
  when upgrading on a system that is running upstart. This seems to cause
- various mysql_upgrade failures.
+ various mysql_upgrade failures. mysql_upgrade will alter the structure
+ of the system tables, particularly performance_schema, which it will
+ delete and recreate. If one process deletes it, then the other creates
+ it, the first will also try to create it, throwing an error.
  
- Let's use this bug to track this particular root cause, since it isn't
- clear that all the other classes of report will be cleared up by this
- fix although we think that they may be. We can dupe them in as needed as
- we find out.
+ [Impact]
+ 
+ Error causes mysql_upgrade to fail, which in turn makes the package
+ installation fail.
+ 
+ [Test case]
+ 
+ Difficult to test fully since it's a race condition bug with two upgrade 
processes running together.
+ * Install mysql-server in Ubuntu Trusty
+ * Upgrade system to Xenial
+ 
+ Expected behavior:
+ The server installs, and the database is upgraded to support 5.7
+ 
+ Actual behavior:
+ Occasionally fails with errors like 'performance_schema does not exist' or 
'performance_schema already exists'.
+ 
+ [Regression potential]
+ 
+ Debian-start is made a no-op script, so if it did something useful we
+ haven't noticed, that's lost.
+ 
+ ---
+ Let's use this bug to track this particular root cause, since it isn't clear 
that all the other classes of report will be cleared up by this fix although we 
think that they may be. We can dupe them in as needed as we find out.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-14 Thread Robie Basak
** Changed in: mysql-5.7 (Ubuntu Xenial)
Milestone: None => xenial-updates

** Changed in: mysql-5.7 (Ubuntu Xenial)
Milestone: xenial-updates => ubuntu-16.04.1

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-07-13 Thread Robie Basak
** Changed in: mysql-5.7 (Ubuntu Xenial)
   Status: Triaged => In Progress

** Changed in: mysql-5.7 (Ubuntu Xenial)
 Assignee: (unassigned) => Robie Basak (racb)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-06-21 Thread Robie Basak
** Also affects: mysql-5.7 (Ubuntu Xenial)
   Importance: Undecided
   Status: New

** Changed in: mysql-5.7 (Ubuntu Xenial)
   Status: New => Triaged

** Changed in: mysql-5.7 (Ubuntu Xenial)
   Importance: Undecided => High

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-06-21 Thread Launchpad Bug Tracker
This bug was fixed in the package mysql-5.7 - 5.7.13-0ubuntu1

---
mysql-5.7 (5.7.13-0ubuntu1) yakkety; urgency=medium

  * Ubuntu merge from Debian VCS 1cdae6c. Remaining changes:
- Revert "Build with libmecab-dev" since libmecab-dev is in
  universe.
  * Drop changes:
- mysql-server-5.7: depend on apparmor (>= 2.10) for Trusty upgrade
  path (all upgrade paths go through Xenial; in hindsight this
  should have been a Breaks anyway).
- Upstreamed to Debian:
  + d/p/allowemptyport.patch: update corresponding test
  + postinst: ignore mysql_upgrade's exit status 2
  + Export my_make_scrambled_password
  + Client commands in postinst should ignore custom config
  + Enable setting password for existing database if it was empty
  + Quote $rootpw correctly
  + Add libnuma-dev, libaio-dev to libmysqld-dev deps
  + d/p/fix-man-page-links.patch: drop (fixed upstream)
  + Add d/NEWS

mysql-5.7 (5.7.13-1~exp1) UNRELEASED; urgency=medium

  [ Robie Basak ]
  * Import upstream version 5.7.13.
  * Drop d/libmysqlclient18.lintian-overrides as the problem is genuine
and should not be hidden. This addresses #812812 in part, but does
not close it.
  * AppArmor profile refactoring and updates for 5.7.
  * Rename apport hook from 5.6 to 5.7.
  * debian/watch file update to 5.7.
  * d/rules: replace 5.6 with 5.7.
  * Drop libmysqld-pic.
  * d/rules: use dh_install --list-missing.
  * d/rules: some dh_install excludes.
  * d/rules: drop large set of comments.
  * d/rules configure: switch to INSTALL_LAYOUT=DEB.
  * d/rules configure: build WITH_INNODB_MEMCACHED.
  * d/rules configure: build with supplied boost.
  * d/rules configure: build with BUILD_CONFIG=mysql_release.
  * d/rules configure: drop SYSTEM_TYPE=.
  * d/rules: chmod changes.
  * mysqld.conf: move to non-deprecated name.
  * Rename debian/*5.6* to 5.7.
  * Adjust installation debian/additions/mysql-systemd-start.
  * Drop d/mysql-client-5.7.examples.
  * Drop some lintian overrides.
  * d/control: switch to 5.7.
  * libmysqlclient soname bump.
  * Update manpage formatting lintian overrides.
  * Drop d/p/fix-mysqlhotcopy-test-failure.patch.
  * Drop d/p/spelling.patch.
  * Drop d/p/fix_standalone_tests.patch.
  * Drop d/p/disable_tests.patch.
  * Drop d/p/scripts__mysqld_safe.sh__signals.patch.
  * Update Hurd and kFreeBSD patches.
  * Add d/p/fix-mtr-search-paths.patch.
  * Non-functional (documentation) 5.6->5.7 substitutions.
  * Drop comment from .install files.
  * Apport hook: install under new name.
  * mysql-testsuite-5.7 installation adjustments for 5.7.
  * Binary installation tweaks.
  * d/p/mysql-test-run-paths: adjust test suite for generic binary
paths.
  * Move testsuite binaries to testsuite package.
  * Build with libmecab-dev.
  * Manpage changes for 5.7.
  * dep8 tests: s/5.6/5.7/.
  * dep8 test: adjust exclude list.
  * dep8 test: adjust test runner path.
  * dep8 test: fix typo (non-functional).
  * d/mysql-server-5.7.dirs: clean syntax.
  * TODO: d/copyright: misc updates for 5.7.
  * d/copyright: boost.
  * Mark scripts executable.
  * Drop gawk build dependency.
  * Add new MySQL 5.7 build dependencies.
  * Drop Perl dependencies.
  * debconf template package rename.
  * Removed d/clean.

  [ Lars Tangvald ]
  * Change service file to use mysqld instead of mysqld_safe.
  * Add new directories for purge deletion.
  * Remove dojo javascript.

  [ Robie Basak ]
  * Use pathfind
  * d/mysql-server-5.7.postinst:
- Add run_init_sql function.
- Normalise whitespace.
- Deprecate basedir in debian.cnf.
- Always forget debconf root_password.
- Stop ensuring /var/lib/mysql/mysql.
- Normalise ensuring /var/lib/mysql.
- Ensure new files and keyring dirs.

  [ Lars Tangvald ]
  * d/mysql-server-5.7.postinst:
- Moved debhelper macro to  before access checking.
- Added function for setting the password of a user.
- Added comment to specify what test_mysql_access is for.
- Add function for checking sysmaint login.
- Updated flag file.
- Moved database initialization.
- Use --initialize for database init.
- Remove old sys-maint user init.
- Removed some commenting.
- Removed BOOTSTRAP reference from comment.
- Run mysql_upgrade when installing.
- Normalised whitespace.
- Use new function to set root pw.
- Remove set_mysql_rootpw function.
- Remove MYSQL_BOOTSTRAP variable.
- Enable auth_socket for passwordless root.
  * d/mysql-server-5.7.config: only prompt root password on fresh
install.
  * d/mysql-server-5.7.preinst: Updated current version to 5.7.

  [ Robie Basak ]
  * Drop error_setting_password debconf template.
  * d/control: add Breaks/Replaces against -5.6 packages.
  * d/control: limit libnuma-dev build dependency to arches that have
it. Fixes FTBFS on arches that don't have it. Thanks to Adam Conrad.
  * d/rules: use the system libevent, not the bundled copy. 

[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-05-13 Thread Ubuntu Foundations Team Bug Bot
The attachment "0001-Change-d-additions-debian-start-to-no-op.patch"
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

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-05-13 Thread Lars Tangvald
Change d/additions/debian-start to no-op, since it's no longer needed
and was running mysql_upgrade, possibly concurrently with d/postinst

** Patch added: "0001-Change-d-additions-debian-start-to-no-op.patch"
   
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+attachment/4661903/+files/0001-Change-d-additions-debian-start-to-no-op.patch

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 1577712] Re: mysql_upgrade is called twice concurrently on upgrade from 14.04

2016-05-11 Thread Lars Tangvald
The old debian-start script used by upstart runs mysql_upgrade, checks
for crashed tables and checks for passwordless root accounts (printing a
warning if one is found).

In 5.7, d/postinst will secure passwordless root accounts with unix
socket auth and run mysql_upgrade, and mysql_upgrade itself will check
for and fix any crashed tables, so this script is no longer needed.

Additionally this could cause mysql_upgrade to be executed by both
upstart and postinst on upgrades, causing various errors.

The solution is to change the script in 5.7 to a no-op

** Changed in: mysql-5.7 (Ubuntu)
   Status: Triaged => In Progress

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577712

Title:
  mysql_upgrade is called twice concurrently on upgrade from 14.04

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1577712/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs