commit mysql for openSUSE:Factory
Hello community, here is the log from the commit of package mysql for openSUSE:Factory checked in at Fri Oct 30 17:00:56 CET 2009. -------- --- mysql/mysql.changes 2009-10-16 11:33:36.000000000 +0200 +++ /mounts/work_src_done/STABLE/mysql/mysql.changes 2009-10-30 09:35:34.000000000 +0100 @@ -1,0 +2,10 @@ +Thu Oct 29 14:11:09 CET 2009 - mhrusecky@suse.cz + +- adding /var/lib/mysql/mysql.sock symlink for compatibility with + applications for older versions +- using kill instead of killproc as killproc matches by default all + running MySQL instances (even KDE ones) +- checking for log consistency in rc script instead of post of spec + as it makes more sense + +------------------------------------------------------------------- calling whatdependson for head-i586 Old: ---- minmem ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ mysql.spec ++++++ --- /var/tmp/diff_new_pack.L883uY/_old 2009-10-30 17:00:32.000000000 +0100 +++ /var/tmp/diff_new_pack.L883uY/_new 2009-10-30 17:00:32.000000000 +0100 @@ -27,7 +27,7 @@ Name: mysql Summary: A True Multiuser, Multithreaded SQL Database Server Version: 5.1.36 -Release: 6 +Release: 7 License: GPL v2 only Group: Productivity/Databases/Servers Url: http://www.mysql.com @@ -114,7 +114,7 @@ %endif # required by rcmysql Requires: mysql-client = %{version} perl-base -Obsoletes: mysql-Max <= %{version} +Obsoletes: mysql-Max < %{version} Provides: mysql-Max = %{version} %description @@ -594,27 +594,10 @@ for i in /var/lib/mysql/{.protected,.tmp}; do ( [ -d "$i" ] && rmdir "$i" ) || : done -SRCLOGS="" -DESTLOG="/var/log/mysql/mysqld.log" -test_src() { - if test -f "$1"; then - SRCLOGS="$SRCLOGS $1" - fi -} -test_src /var/lib/mysql/mysqld.log -test_src /var/log/mysqld.log -test_src "$DESTLOG" -if [ "0`echo $SRCLOGS | wc -w`" -gt 1 ]; then - echo "Log files inconsistency, please merge following files manually:" - echo $SRCLOGS | sed 's|[[:blank:]]\+|\n|' | sed 's|^|\t|' -else - if [ "$SRCLOGS" ]; then - [ $SRCLOGS = "$DESTLOG" ] || mv $SRCLOGS "$DESTLOG" - fi -fi # start mysql again if it should run -if [ "`ls /etc/rc.d/rc*.d/S*mysql`" ] || [ -d /var/run/mysql/restart ]; then +if [ "`ls /etc/rc.d/rc*.d/S*mysql 2> /dev/null`" ] || [ -d /var/run/mysql/restart ]; then [ -x /usr/sbin/rcmysql ] && /usr/sbin/rcmysql start + rmdir /var/run/mysql/restart || : fi #------------------------------------------------------------------------------- ++++++ rc.mysql-multi ++++++ --- /var/tmp/diff_new_pack.L883uY/_old 2009-10-30 17:00:33.000000000 +0100 +++ /var/tmp/diff_new_pack.L883uY/_new 2009-10-30 17:00:33.000000000 +0100 @@ -17,6 +17,7 @@ # Required-Stop: $network $remote_fs # Default-Start: 2 3 5 # Default-Stop: +# Short-Description: Start the MySQL database server # Description: Start the MySQL database server ### END INIT INFO @@ -143,7 +144,7 @@ } # Check if we want to run multiple instances. -[[ "`cat /etc/my.cnf | sed -n -e 's|#.*||' -e 's|\[mysqld[0-9]\+\]|yes|p'`" ]] && MYSQLD_MULTI=yes +[[ "`cat /etc/my.cnf | sed -n 's|^[[:blank:]]*\[mysqld[0-9]\+\]|yes|p'`" ]] && MYSQLD_MULTI=yes # This was old way how to specify this, left for backward compatibility. [[ -f /etc/sysconfig/mysql ]] && . /etc/sysconfig/mysql @@ -335,6 +336,24 @@ echo >> "$log_upgrade" echo "Will update MySQL now, if you encounter any problems, please read following file:" | tee -a "$log_upgrade" echo " /usr/share/doc/packages/mysql/README.SuSE" | tee -a "$log_upgrade" + # Check logs for inconsistencies + SRCLOGS="" + ALL_SRCLOGS="" + for i in "$log_error" /var/lib/mysql/mysqld.log \ + /var/log/mysqld.log ; do + if test -f "$i"; then + SRCLOGS="$i" + ALL_SRCLOGS="${ALL_SRCLOGS} ${i}" + fi + done + if [ "${ALL_SRCLOGS}" \!= " ${SRCLOGS}" ]; then + echo "Log files inconsistency, please merge following files manually:" + echo $ALL_SRCLOGS | sed 's|[[:blank:]]\+|\n|' | sed 's|^|\t|' + else + if [ "$SRCLOGS" ]; then + [ "$SRCLOGS" = "$log_error" ] || mv "$SRCLOGS" "$log_error" + fi + fi check_obsolete >> "$log_upgrade" # instead of running mysqld --bootstrap, which wouldn't allow # us to run mysql_upgrade, we start a full-featured server with @@ -380,9 +399,9 @@ --socket="$protected/mysql.sock" | tee -a "$log_upgrade" [ "$PIPESTATUS" -ne 0 ] && { rc_failed; rc_status -v; - killproc -p "$protected/mysqld.pid" -TERM "$MYSQLD" + kill -TERM "`cat $protected/mysqld.pid`" rc_exit; } - killproc -p "$protected/mysqld.pid" -TERM "$MYSQLD" + kill -TERM "`cat $protected/mysqld.pid`" rm -rf "$protected" # Fix ownerships and permissions for $datadir chmod 755 "$datadir" @@ -394,10 +413,14 @@ fi chown mysql:mysql "$log_upgrade" chmod 660 "$log_upgrade" + # Backward compatibility + [ "$socket" \!= "/var/run/mysql/mysql.sock" ] || ln -sf ../../run/mysql/mysql.sock /var/lib/mysql/mysql.sock fi echo -n "Starting service MySQL " + + [ "$socket" = "/var/run/mysql/mysql.sock" ] || ( [ "`readlink /var/lib/mysql/mysql.sock`" \!= "../../run/mysql/mysql.sock" ] || rm -f /var/lib/mysql/mysql.sock ) $SAFE_MYSQLD \ --mysqld=${MYSQLD#/usr/sbin/} \ @@ -445,7 +468,7 @@ reload) echo -n "Reloading service MySQL " - killproc -p "$pid_file" -HUP "$MYSQLD" + kill -HUP "`cat "$pid_file"`" touch "$pid_file" rc_status -v ;; ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org
participants (1)
-
root@Hilbert.suse.de