[debian-mysql] Bug#737224: mysql-server-5.5: upgrade create mysql tables as root
Clint Byrum
spamaps at debian.org
Fri Jan 31 16:58:58 UTC 2014
Thanks Ghislain. A fix is committed to the mysql-5.5 package repository.
MariaDB people: please check your version of
mariadb-server-5.5.postinst.
It would be great if somebody could build from the git repo and confirm
that this problem is fixed (and that it doesn't regress anything). I
just don't have the time right now unfortunately.
Excerpts from Ghislain's message of 2014-01-31 06:30:49 -0800:
> Package: mysql-server-5.5
> Version: 5.5.35+dfsg-0+wheezy1
> Severity: important
>
> Dear Maintainer,
> *** Please consider answering these questions, where appropriate ***
>
> * What led up to the situation?
>
> any upgrade of mysql lead to permission problems
>
> * What exactly did you do (or not do) that was effective (or
> ineffective)?
>
> apt-get upgrade
>
> * What was the outcome of this action?
>
> 5242932 4 drwx------ 2 root root 4096 Jan 24 07:54
> /var/lib/mysql/performance_schema
> 5249304 12 -rw-rw---- 1 root root 8814 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_summary_global_by_event_name.frm
> 5249329 12 -rw-rw---- 1 root root 8650 Jan 24 07:54
> /var/lib/mysql/performance_schema/threads.frm
> 5249323 12 -rw-rw---- 1 root root 8605 Jan 24 07:54
> /var/lib/mysql/performance_schema/setup_consumers.frm
> 5244876 12 -rw-rw---- 1 root root 9220 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_current.frm
> 5249309 12 -rw-rw---- 1 root root 8840 Jan 24 07:54
> /var/lib/mysql/performance_schema/file_summary_by_instance.frm
> 5249307 12 -rw-rw---- 1 root root 8800 Jan 24 07:54
> /var/lib/mysql/performance_schema/file_summary_by_event_name.frm
> 5249193 12 -rw-rw---- 1 root root 9220 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_history_long.frm
> 5244875 12 -rw-rw---- 1 root root 8624 Jan 24 07:54
> /var/lib/mysql/performance_schema/cond_instances.frm
> 5244913 12 -rw-rw---- 1 root root 9220 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_history.frm
> 5249299 12 -rw-rw---- 1 root root 8878 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_summary_by_instance.frm
> 5249327 12 -rw-rw---- 1 root root 8637 Jan 24 07:54
> /var/lib/mysql/performance_schema/setup_instruments.frm
> 5249321 12 -rw-rw---- 1 root root 8758 Jan 24 07:54
> /var/lib/mysql/performance_schema/rwlock_instances.frm
> 5249328 12 -rw-rw---- 1 root root 8650 Jan 24 07:54
> /var/lib/mysql/performance_schema/setup_timers.frm
> 5249310 12 -rw-rw---- 1 root root 8684 Jan 24 07:54
> /var/lib/mysql/performance_schema/mutex_instances.frm
> 5244799 4 -rw-rw---- 1 root root 61 Jan 24 07:54
> /var/lib/mysql/performance_schema/db.opt
> 5249305 12 -rw-rw---- 1 root root 8654 Jan 24 07:54
> /var/lib/mysql/performance_schema/file_instances.frm
> 5249303 12 -rw-rw---- 1 root root 8854 Jan 24 07:54
> /var/lib/mysql/performance_schema/events_waits_summary_by_thread_by_event_name.frm
> 5249311 12 -rw-rw---- 1 root root 8776 Jan 24 07:54
> /var/lib/mysql/performance_schema/performance_timers.frm
>
> * What outcome did you expect instead?
>
> that the files belong to mysql:mysql not root
> i think the issue lies here in postinst
>
>
> line 122: chown -R mysql $mysql_statedir
>
> but, run as root:
>
> line 146 : bash /usr/bin/mysql_install_db --rpm 2>&1 | $ERR_LOGGER
>
>
> the /usr/bin/mysql_install_db line should have '--user=mysql' or the
> line 122 should be moved after this one i guess.
>
>
>
> *** End of the template - remove these lines ***
>
>
> -- System Information:
> Debian Release: 7.3
> APT prefers stable
> APT policy: (500, 'stable')
> Architecture: amd64 (x86_64)
>
> Kernel: Linux 3.4.65-vs2.3.3.9aq (SMP w/12 CPU cores)
> Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
> Shell: /bin/sh linked to /bin/dash
>
> Versions of packages mysql-server-5.5 depends on:
> ii adduser 3.113+nmu3
> ii debconf [debconf-2.0] 1.5.49
> ii initscripts 2.88dsf-41+deb7u1
> ii libc6 2.13-38
> ii libdbi-perl 1.622-1
> ii libgcc1 1:4.7.2-5
> ii libstdc++6 4.7.2-5
> ii lsb-base 4.1+Debian8+deb7u1
> ii mysql-client-5.5 5.5.35+dfsg-0+wheezy1
> ii mysql-common 5.5.35+dfsg-0+wheezy1
> ii mysql-server-core-5.5 5.5.35+dfsg-0+wheezy1
> ii passwd 1:4.1.5.1-1
> ii perl 5.14.2-21+deb7u1
> ii psmisc 22.19-1+deb7u1
> ii zlib1g 1:1.2.7.dfsg-13
>
> Versions of packages mysql-server-5.5 recommends:
> ii bsd-mailx [mailx] 8.1.2-0.20111106cvs-1
> ii libhtml-template-perl 2.91-1
> ii mailx 1:20071201-3
>
> Versions of packages mysql-server-5.5 suggests:
> pn tinyca <none>
>
> -- debconf information:
> mysql-server/error_setting_password:
> mysql-server-5.5/postrm_remove_databases: false
> mysql-server-5.5/start_on_boot: true
> mysql-server-5.5/nis_warning:
> mysql-server-5.5/really_downgrade: false
> mysql-server/password_mismatch:
> mysql-server/no_upgrade_when_using_ndb:
>
More information about the pkg-mysql-maint
mailing list