Hello community, here is the log from the commit of package mysql-community-server for openSUSE:Factory checked in at 2015-06-30 10:16:38 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/mysql-community-server (Old) and /work/SRC/openSUSE:Factory/.mysql-community-server.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "mysql-community-server" Changes: -------- --- /work/SRC/openSUSE:Factory/mysql-community-server/mysql-community-server.changes 2015-06-24 20:57:37.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.mysql-community-server.new/mysql-community-server.changes 2015-06-30 10:16:40.000000000 +0200 @@ -1,0 +2,11 @@ +Fri Jun 26 10:04:02 UTC 2015 - tchva...@suse.com + +- Enable testsuite + +------------------------------------------------------------------- +Thu Jun 25 13:52:45 UTC 2015 - tchva...@suse.com + +- Update again to git state now with reshaped initscript + now better supporting initialization/migration + +------------------------------------------------------------------- Old: ---- install.inc rc.mysql.systemd rc.mysql.sysvinit New: ---- mysql-systemd-helper mysql.target mysql@.service ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ mysql-community-server.spec ++++++ ++++ 620 lines (skipped) ++++ between /work/SRC/openSUSE:Factory/mysql-community-server/mysql-community-server.spec ++++ and /work/SRC/openSUSE:Factory/.mysql-community-server.new/mysql-community-server.spec ++++++ README.debug ++++++ --- /var/tmp/diff_new_pack.5mcFdE/_old 2015-06-30 10:16:42.000000000 +0200 +++ /var/tmp/diff_new_pack.5mcFdE/_new 2015-06-30 10:16:42.000000000 +0200 @@ -45,14 +45,6 @@ core-file - Note: this unfortunatelly doesn't work in SUSE Linux 10.1 and older. - On these systems, you need to run safe_mysqld directly under user - mysql: - - su - mysql - mysqld_safe --socket=/var/lib/mysql/mysql.sock \ - --datadir=/var/lib/mysql --core-file & - The core file will be written to the /var/lib/mysql/ directory. I suggest setting the kernel variable kernel.core_uses_pid to 1 @@ -64,31 +56,19 @@ After you got the core file, install the gdb and mysql-debuginfo packages and run - gdb /usr/sbin/mysqld /var/lib/mysql/core + gdb /usr/sbin/mysqld /var/lib/mysql/<core> (gdb) bt -Replace mysqld with the mysqld version you used (mysqld, mysqld-max) -and core with the actual name of the coredump. +Replace the <core> with the actual name of the coredump. 3) Trace files -------------- -Start mysqld using following command: - - $ MYSQLD_DEBUG=yes rcmysql start - -The init script will then start mysqld and add the --core-file, ---log and --debug options for you. The query log will be stored in - - /var/lib/mysql/myqld-query.log - -and the trace file in - - /var/lib/mysql/mysqld.trace - -If you don't like the options set by the init script, just put your own -into /etc/my.cnf and the init script will honor them. - The trace file will contain various debug information and function calls/returns and will become _extremly_ huge after a while, so don't attach it to bugzilla unless requested. +Add the following line to your /etc/my.cnf into section [mysqld]: + + stack-trace + +The trace file will be then written to /var/lib/mysql directory. \ No newline at end of file ++++++ README.install ++++++ --- /var/tmp/diff_new_pack.5mcFdE/_old 2015-06-30 10:16:42.000000000 +0200 +++ /var/tmp/diff_new_pack.5mcFdE/_new 2015-06-30 10:16:42.000000000 +0200 @@ -9,7 +9,7 @@ To do so, start the server, then issue the following commands: '/usr/bin/mysqladmin' -u root password 'new-password' -'/usr/bin/mysqladmin' -u root -h misibook password 'new-password' +'/usr/bin/mysqladmin' -u root -h <hostname> password 'new-password' Alternatively you can run: '/usr/bin/mysql_secure_installation' ++++++ configuration-tweaks.tar.bz2 ++++++ ++++++ mysql-patches.tar.bz2 ++++++ ++++++ mysql-systemd-helper ++++++ #!/bin/bash die() { echo "$1" exit 1 } # Read options from config file read_config() { # Initial settings MYSQLVER="$(echo @MYSQLVER@ | sed 's|\.[0-9]\+$||')" mysql_daemon_user=mysql mysql_daemon_group=mysql if [[ -z "$INSTANCE" || "x$INSTANCE" = "xdefault" ]]; then datadir=/var/lib/mysql socket="/var/run/mysql/mysql.sock" else datadir="/var/lib/mysql-$INSTANCE" socket="/var/run/mysql/mysql.${INSTANCE}.sock" fi # Read options - important for multi setup if [[ -n "$INSTANCE" && "x$INSTANCE" != "xdefault" ]]; then opts="$(/usr/bin/my_print_defaults --mysqld mysqld_multi "$INSTANCE")" tmp_opts="$opts" else opts="$(/usr/bin/my_print_defaults --mysqld)" tmp_opts="$opts" fi # Update local variables according to the settings from config for arg in $tmp_opts; do case "$arg" in --basedir=*) basedir="$(echo "$arg" | sed -e 's/^[^=]*=//')" ;; --socket=*) socket="$(echo "$arg" | sed -e 's/^[^=]*=//')" ;; --datadir=*) datadir="$(echo "$arg" | sed -e 's/^[^=]*=//')" ;; --user=*) mysql_daemon_user="$(echo "$arg" | sed -e 's/^[^=]*=//')" ;; --group=*) mysql_daemon_group="$(echo "$arg" | sed -e 's/^[^=]*=//')" ;; esac done } # Create new empty database if needed mysql_install() { if [[ ! -d "$datadir/mysql" ]]; then echo "Creating MySQL privilege database... " mysql_install_db --user="$mysql_daemon_user" --datadir="$datadir" || \ die "Creation of MySQL databse in $datadir failed" echo -n "$MYSQLVER" > "$datadir"/mysql_upgrade_info fi } # Upgrade database if needed mysql_upgrade() { # Run mysql_upgrade on every package install/upgrade. Not always # necessary, but doesn't do any harm. if [[ -f "$datadir/.run-mysql_upgrade" ]]; then echo "Checking MySQL configuration for obsolete options..." sed -i -e 's|^\([[:blank:]]*\)skip-locking|\1skip-external-locking|' \ -e 's|^\([[:blank:]]*skip-federated\)|#\1|' /etc/my.cnf # instead of running mysqld --bootstrap, which wouldn't allow # us to run mysql_upgrade, we start a full-featured server with # --skip-grant-tables and restict access to it by unix # permissions of the named socket echo "Trying to run upgrade of MySQL databases..." # Check whether upgrade process is not already running protected="$(cat "/var/run/mysql/protecteddir.$INSTANCE" 2> /dev/null)" if [[ -n "$protected" && -d "$protected" ]]; then pid="$(cat "$protected/mysqld.pid" 2> /dev/null)" if [[ "$pid" && -d "/proc/$pid" ]] && [[ $(readlink "/proc/$pid/exe" | grep -q "mysql") ]]; then die "Another upgrade in already in progress!" else echo "Stale files from previous upgrade detected, cleaned them up" rm -rf "$protected" rm -f "/var/run/mysql/protecteddir.$INSTANCE" fi fi protected="$(mktemp -d -p /var/tmp mysql-protected.XXXXXX | tee "/var/run/mysql/protecteddir.$INSTANCE")" [ -n "$protected" ] || die "Can't create a tmp dir '$protected'" # Create a secure tmp dir chown --no-dereference "$mysql_daemon_user:$mysql_daemon_group" "$protected" || die "Failed to set group/user to '$protected'" chmod 0700 "$protected" || die "Failed to set permissions to '$protected'" # Run protected MySQL accessible only though socket in our directory echo "Running protected MySQL... " /usr/sbin/mysqld \ --user="$mysql_daemon_user" --group="$mysql_daemon_group" \ $opts \ --skip-networking \ --skip-grant-tables \ --log-error="$protected/log_upgrade_run" \ --socket="$protected/mysql.sock" \ --pid-file="$protected/mysqld.pid" & mysql_wait "$protected/mysql.sock" || die "MySQL didn't start, can't continue" # Run upgrade itself echo "Running upgrade itself..." echo "It will do some chek first and report all errors and tries to correct them" echo if /usr/bin/mysql_upgrade --no-defaults --force --socket="$protected/mysql.sock"; then echo "Everything upgraded successfully" up_ok="" rm -f "$datadir/.run-mysql_upgrade" [[ $(grep -q "^$MYSQLVER" "$datadir/mysql_upgrade_info" 2> /dev/null) ]] || \ echo -n "$MYSQLVER" > "$datadir/mysql_upgrade_info" else echo "Upgrade failed" up_ok="false" fi # Shut down MySQL echo "Shuting down protected MySQL" kill "$(cat "$protected/mysqld.pid")" for i in {1..30}; do /usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1 || break done /usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1 && kill -9 "$(cat "$protected/mysqld.pid")" # Cleanup echo "Final cleanup" rm -rf "$protected" "/var/run/mysql/protecteddir.$INSTANCE" [[ -z "$up_ok" ]] || die "Something failed during upgrade, please check logs" fi } mysql_wait() { [[ -z "$1" ]] || socket="$1" echo "Waiting for MySQL to start" for i in {1..60}; do /usr/bin/mysqladmin --socket="$socket" ping > /dev/null 2>&1 && break sleep 1 done if /usr/bin/mysqladmin --socket="$socket" ping > /dev/null 2>&1; then echo "MySQL is alive" return 0 else echo "MySQL is still dead" return 1 fi } mysql_start() { /usr/sbin/mysqld --user="$mysql_daemon_user" --group="$mysql_daemon_group" $opts } # We rely on output in english at some points LC_ALL=C INSTANCE="$2" read_config mkdir -p /var/run/mysql chown --no-dereference "$mysql_daemon_user:$mysql_daemon_group" /var/run/mysql case "$1" in install) mysql_install ;; upgrade) mysql_upgrade ;; start) mysql_start ;; wait) mysql_wait ;; *) echo "Supported commands are:" echo " install - creates empty database if needed" echo " upgrade - tries to migrate data to newer version if needed" echo " start - tries to start instance" echo " wait - waits till instance is pingable" echo "All commands can take extra argument which is group from 'mysqld_multi' you want to work with" ;; esac ++++++ mysql.service ++++++ --- /var/tmp/diff_new_pack.5mcFdE/_old 2015-06-30 10:16:42.000000000 +0200 +++ /var/tmp/diff_new_pack.5mcFdE/_new 2015-06-30 10:16:42.000000000 +0200 @@ -1,12 +1,16 @@ [Unit] Description=MySQL server Wants=basic.target -After=basic.target network.target +Conflicts=mysql.target mysql@default.service +After=basic.target network.target syslog.target [Service] -Type=forking -ExecStart=/usr/lib/mysql/rcmysql start -ExecStop=/usr/lib/mysql/rcmysql stop +Restart=on-failure +Type=simple +ExecStartPre=/usr/lib/mysql/mysql-systemd-helper install default +ExecStartPre=/usr/lib/mysql/mysql-systemd-helper upgrade default +ExecStart=/usr/lib/mysql/mysql-systemd-helper start default +ExecStartPost=/usr/lib/mysql/mysql-systemd-helper wait default [Install] WantedBy=multi-user.target ++++++ mysql.target ++++++ [Unit] Description=MySQL target allowing to control multi setup ++++++ mysql@.service ++++++ [Unit] Description=MySQL server - %I instance Wants=basic.target PartOf=mysql.target After=basic.target network.target syslog.target [Service] Restart=on-failure Type=simple ExecStartPre=/usr/lib/mysql/mysql-systemd-helper install %i ExecStartPre=/usr/lib/mysql/mysql-systemd-helper upgrade %i ExecStart=/usr/lib/mysql/mysql-systemd-helper start %i ExecStartPost=/usr/lib/mysql/mysql-systemd-helper wait %i [Install] WantedBy=multi-user.target ++++++ suse-test-run ++++++ --- /var/tmp/diff_new_pack.5mcFdE/_old 2015-06-30 10:16:42.000000000 +0200 +++ /var/tmp/diff_new_pack.5mcFdE/_new 2015-06-30 10:16:42.000000000 +0200 @@ -1,6 +1,6 @@ #!/usr/bin/perl # -# Test the SUSE mysql(-Max) package using the MySQL testsuite +# Test the SUSE mysql package using the MySQL testsuite my $id = getpwnam("mysql") or die "can't find user \"mysql\": $!"; my $dir = "/usr/share/mysql-test/";