Merge lp:~percona-core/percona-server/release-5.5.39-36.0 into lp:percona-server/5.5

Proposed by Tomislav Plavcic
Status: Superseded
Proposed branch: lp:~percona-core/percona-server/release-5.5.39-36.0
Merge into: lp:percona-server/5.5
Diff against target: 513 lines (+281/-7)
6 files modified
build-ps/debian/changelog (+6/-0)
build-ps/percona-server.spec (+146/-5)
build-ps/rpm/mysql-systemd (+92/-0)
build-ps/rpm/mysql.service (+31/-0)
policy/selinux/percona-server.te (+5/-1)
storage/innobase/include/univ.i (+1/-1)
To merge this branch: bzr merge lp:~percona-core/percona-server/release-5.5.39-36.0
Reviewer Review Type Date Requested Status
Laurynas Biveinis (community) Needs Information
Review via email: mp+232854@code.launchpad.net

This proposal has been superseded by a proposal from 2014-09-01.

Description of the change

Release branch for version 5.5.39-36.0

To post a comment you must log in.
Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :

See BLD-193.

review: Needs Information
Revision history for this message
Tomislav Plavcic (tplavcic) wrote :

From BLD-193:
Since we had PS releases on friday there was no time to make changes and test for PS (5.5/5.6) but "sed" part will not stay. So before GA I'll add our version of my.cnf and remove sed part (if there's no conclusion that this is wrong and something else needs to be done).

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'build-ps/debian/changelog'
--- build-ps/debian/changelog 2014-08-22 10:09:55 +0000
+++ build-ps/debian/changelog 2014-09-01 07:18:02 +0000
@@ -1,3 +1,9 @@
1percona-server-5.5 (5.5.39-rel36.0) unstable; urgency=low
2
3 * Added mysqld-debug
4
5 -- Tomislav Plavcic <tomislav.plavcic@percona.com> Thu, 28 Aug 2014 09:25:38 +0200
6
1percona-server-5.5 (5.5.38-rel35.2) unstable; urgency=low7percona-server-5.5 (5.5.38-rel35.2) unstable; urgency=low
28
3 * Fixed missing libperconaserverclient lib in lucid/squeeze9 * Fixed missing libperconaserverclient lib in lucid/squeeze
410
=== modified file 'build-ps/percona-server.spec'
--- build-ps/percona-server.spec 2014-08-22 10:09:55 +0000
+++ build-ps/percona-server.spec 2014-09-01 07:18:02 +0000
@@ -38,6 +38,19 @@
38%define release rel%{percona_server_version}%{?dist}38%define release rel%{percona_server_version}%{?dist}
3939
40#40#
41%bcond_with systemd
42#
43%if %{with systemd}
44 %define systemd 1
45%else
46 %if 0%{?rhel} > 6
47 %define systemd 1
48 %else
49 %define systemd 0
50 %endif
51%endif
52
53#
41# Macros we use which are not available in all supported versions of RPM54# Macros we use which are not available in all supported versions of RPM
42#55#
43# - defined/undefined are missing on RHEL456# - defined/undefined are missing on RHEL4
@@ -185,7 +198,7 @@
185 %define distro_description Generic Linux (kernel %{generic_kernel})198 %define distro_description Generic Linux (kernel %{generic_kernel})
186 %define distro_releasetag linux%{generic_kernel}199 %define distro_releasetag linux%{generic_kernel}
187 %define distro_buildreq gcc-c++ gperf ncurses-devel perl readline-devel time zlib-devel libaio-devel bison cmake200 %define distro_buildreq gcc-c++ gperf ncurses-devel perl readline-devel time zlib-devel libaio-devel bison cmake
188 %define distro_requires coreutils grep procps /sbin/chkconfig /usr/sbin/useradd /usr/sbin/groupadd201 %define distro_requires coreutils grep procps /usr/sbin/useradd /usr/sbin/groupadd
189%endif202%endif
190203
191# ----------------------------------------------------------------------------204# ----------------------------------------------------------------------------
@@ -226,6 +239,9 @@
226Vendor: %{percona_server_vendor}239Vendor: %{percona_server_vendor}
227Provides: mysql-server240Provides: mysql-server
228BuildRequires: %{distro_buildreq} pam-devel openssl-devel241BuildRequires: %{distro_buildreq} pam-devel openssl-devel
242%if 0%{?systemd}
243BuildRequires: systemd
244%endif
229245
230# Think about what you use here since the first step is to246# Think about what you use here since the first step is to
231# run a rm -rf247# run a rm -rf
@@ -249,6 +265,16 @@
249Summary: Percona Server: a very fast and reliable SQL database server265Summary: Percona Server: a very fast and reliable SQL database server
250Group: Applications/Databases266Group: Applications/Databases
251Requires: %{distro_requires} Percona-Server-shared%{product_suffix} Percona-Server-client%{product_suffix}267Requires: %{distro_requires} Percona-Server-shared%{product_suffix} Percona-Server-client%{product_suffix}
268Requires: perl(Data::Dumper)
269%if 0%{?systemd}
270Requires(post): systemd
271Requires(preun): systemd
272Requires(postun): systemd
273%else
274Requires(post): /sbin/chkconfig
275Requires(preun): /sbin/chkconfig
276Requires(preun): /sbin/service
277%endif
252Provides: mysql-server MySQL-server278Provides: mysql-server MySQL-server
253Conflicts: Percona-SQL-server-50 Percona-Server-server-51279Conflicts: Percona-SQL-server-50 Percona-Server-server-51
254280
@@ -268,6 +294,28 @@
268package "Percona-Server-client%{product_suffix}" as well!294package "Percona-Server-client%{product_suffix}" as well!
269295
270# ----------------------------------------------------------------------------296# ----------------------------------------------------------------------------
297%package -n Percona-Server-selinux%{product_suffix}
298Summary: Percona Server - Selinux policy module
299Group: Applications/Databases
300%if 0%{?rhel} >= 6
301BuildArch: noarch
302%endif
303Requires: selinux-policy
304Requires(post): policycoreutils
305Requires(postun): policycoreutils
306
307%if 0%{?rhel} == 6
308BuildRequires: selinux-policy
309%else
310BuildRequires: selinux-policy-devel
311%endif
312
313%description -n Percona-Server-selinux%{product_suffix}
314This package contains SELinux policy module for Percona Server package.
315
316For a description of Percona Server see http://www.percona.com/software/percona-server/
317
318# ----------------------------------------------------------------------------
271%package -n Percona-Server-client%{product_suffix}319%package -n Percona-Server-client%{product_suffix}
272Summary: Percona Server - Client320Summary: Percona Server - Client
273Group: Applications/Databases321Group: Applications/Databases
@@ -283,6 +331,7 @@
283# ----------------------------------------------------------------------------331# ----------------------------------------------------------------------------
284%package -n Percona-Server-test%{product_suffix}332%package -n Percona-Server-test%{product_suffix}
285Requires: Percona-Server-client%{product_suffix} perl333Requires: Percona-Server-client%{product_suffix} perl
334Requires: perl(Socket), perl(Time::HiRes), perl(Data::Dumper), perl(Test::More), perl(Env)
286Summary: Percona Server - Test suite335Summary: Percona Server - Test suite
287Group: Applications/Databases336Group: Applications/Databases
288Provides: mysql-test337Provides: mysql-test
@@ -474,6 +523,13 @@
474install -d $RBR%{_sbindir}523install -d $RBR%{_sbindir}
475install -d $RBR%{_libdir}/mysql/plugin524install -d $RBR%{_libdir}/mysql/plugin
476525
526# SElinux
527pushd ${MBD}/policy
528make -f /usr/share/selinux/devel/Makefile
529install -D -m 0644 $MBD/policy/percona-server.pp $RBR%{_datadir}/selinux/packages/percona-server/percona-server.pp
530popd
531# SElinux END
532
477(533(
478 cd $MBD/release534 cd $MBD/release
479 make DESTDIR=$RBR benchdir_root=%{_datadir} install535 make DESTDIR=$RBR benchdir_root=%{_datadir} install
@@ -496,7 +552,12 @@
496552
497# Install logrotate and autostart553# Install logrotate and autostart
498install -m 644 $MBD/release/support-files/mysql-log-rotate $RBR%{_sysconfdir}/logrotate.d/mysql554install -m 644 $MBD/release/support-files/mysql-log-rotate $RBR%{_sysconfdir}/logrotate.d/mysql
555%if 0%{?systemd}
556install -D -m 0755 $MBD/build-ps/rpm/mysql-systemd $RBR%{_bindir}/mysql-systemd
557install -D -m 0644 $MBD/build-ps/rpm/mysql.service $RBR%{_unitdir}/mysql.service
558%else
499install -m 755 $MBD/release/support-files/mysql.server $RBR%{_sysconfdir}/init.d/mysql559install -m 755 $MBD/release/support-files/mysql.server $RBR%{_sysconfdir}/init.d/mysql
560%endif
500561
501# Delete the symlinks to the libraries from the libdir. These are created by562# Delete the symlinks to the libraries from the libdir. These are created by
502# ldconfig(8) afterwards.563# ldconfig(8) afterwards.
@@ -522,9 +583,12 @@
522 "$RBR%{_libdir}/mysql/%{malloc_lib_target}"583 "$RBR%{_libdir}/mysql/%{malloc_lib_target}"
523%endif584%endif
524585
525# Remove man pages we explicitly do not want to package, avoids 'unpackaged586# Remove files we explicitly do not want to package, avoids 'unpackaged
526# files' warning.587# files' warning.
527rm -f $RBR%{_mandir}/man1/make_win_bin_dist.1*588rm -f $RBR%{_mandir}/man1/make_win_bin_dist.1*
589%if 0%{?systemd}
590rm -rf $RBR%{_sysconfdir}/init.d/mysql
591%endif
528592
529##############################################################################593##############################################################################
530# Post processing actions, i.e. when installed594# Post processing actions, i.e. when installed
@@ -532,6 +596,15 @@
532596
533%pre -n Percona-Server-server%{product_suffix}597%pre -n Percona-Server-server%{product_suffix}
534598
599# On rhel7 change default MariaDB options if they exists (only on initial installation)
600%if "%rhel" > "6"
601if [ $1 -eq 1 -a -f /etc/my.cnf ]; then
602 sed -i 's/log-error=\/var\/log\/mariadb\/mariadb.log/log-error=\/var\/log\/mysqld.log/g' /etc/my.cnf;
603 sed -i 's/pid-file=\/var\/run\/mariadb\/mariadb.pid/pid-file=\/var\/run\/mysqld\/mysqld.pid/g' /etc/my.cnf;
604 sed -i 's/\!includedir \/etc\/my.cnf.d/\#\!includedir \/etc\/my.cnf.d/g' /etc/my.cnf;
605fi
606%endif
607
535# ATTENTION: Parts of this are duplicated in the "triggerpostun" !608# ATTENTION: Parts of this are duplicated in the "triggerpostun" !
536609
537# There are users who deviate from the default file system layout.610# There are users who deviate from the default file system layout.
@@ -687,11 +760,31 @@
687# Note we *could* make that depend on $SERVER_TO_START, but we rather don't,760# Note we *could* make that depend on $SERVER_TO_START, but we rather don't,
688# so a "stop" is attempted even if there is no PID file.761# so a "stop" is attempted even if there is no PID file.
689# (Maybe the "stop" doesn't work then, but we might fix that in itself.)762# (Maybe the "stop" doesn't work then, but we might fix that in itself.)
763%if 0%{?systemd}
764SYSD_ACTIVE=$(systemctl is-active mysql)
765if [ $SYSD_ACTIVE == "active" ] ; then
766 %{_bindir}/systemctl stop mysql >/dev/null 2>&1
767 echo "Giving mysqld 5 seconds to exit nicely"
768 sleep 5
769fi
770%else
690if [ -x %{_sysconfdir}/init.d/mysql ] ; then771if [ -x %{_sysconfdir}/init.d/mysql ] ; then
691 %{_sysconfdir}/init.d/mysql stop > /dev/null 2>&1772 %{_sysconfdir}/init.d/mysql stop > /dev/null 2>&1
692 echo "Giving mysqld 5 seconds to exit nicely"773 echo "Giving mysqld 5 seconds to exit nicely"
693 sleep 5774 sleep 5
694fi775fi
776%endif
777
778# SElinux
779%post -n Percona-Server-selinux%{product_suffix}
780/usr/sbin/semodule -i %{_datadir}/selinux/packages/percona-server/percona-server.pp >/dev/null 2>&1 || :
781
782%postun -n Percona-Server-selinux%{product_suffix}
783if [ $1 -eq 0 ] ; then
784 /usr/sbin/semodule -r percona-server >/dev/null 2>&1 || :
785fi
786
787#SElinux
695788
696%post -n Percona-Server-server%{product_suffix}789%post -n Percona-Server-server%{product_suffix}
697if [ X${PERCONA_DEBUG} == X1 ]; then790if [ X${PERCONA_DEBUG} == X1 ]; then
@@ -761,12 +854,18 @@
761# NOTE: This still needs to be debated. Should we check whether these links854# NOTE: This still needs to be debated. Should we check whether these links
762# for the other run levels exist(ed) before the upgrade?855# for the other run levels exist(ed) before the upgrade?
763# use chkconfig on Enterprise Linux and newer SuSE releases856# use chkconfig on Enterprise Linux and newer SuSE releases
857%if 0%{?systemd}
858if [ -x %{_bindir}/systemctl ] ; then
859 %{_bindir}/systemctl enable mysql >/dev/null 2>&1
860fi
861%else
764if [ -x /sbin/chkconfig ] ; then862if [ -x /sbin/chkconfig ] ; then
765 /sbin/chkconfig --add mysql863 /sbin/chkconfig --add mysql
766# use insserv for older SuSE Linux versions864# use insserv for older SuSE Linux versions
767elif [ -x /sbin/insserv ] ; then865elif [ -x /sbin/insserv ] ; then
768 /sbin/insserv %{_sysconfdir}/init.d/mysql866 /sbin/insserv %{_sysconfdir}/init.d/mysql
769fi867fi
868%endif
770869
771# ----------------------------------------------------------------------870# ----------------------------------------------------------------------
772# Upgrade databases if needed would go here - but it cannot be automated yet871# Upgrade databases if needed would go here - but it cannot be automated yet
@@ -797,12 +896,18 @@
797896
798# Was the server running before the upgrade? If so, restart the new one.897# Was the server running before the upgrade? If so, restart the new one.
799if [ "$SERVER_TO_START" = "true" ] ; then898if [ "$SERVER_TO_START" = "true" ] ; then
899%if 0%{?systemd}
900if [ -x %{_bindir}/systemctl ] ; then
901 %{_bindir}/systemctl start mysql
902fi
903%else
800 # Restart in the same way that mysqld will be started normally.904 # Restart in the same way that mysqld will be started normally.
801 if [ -x %{_sysconfdir}/init.d/mysql ] ; then905 if [ -x %{_sysconfdir}/init.d/mysql ] ; then
802 %{_sysconfdir}/init.d/mysql start906 %{_sysconfdir}/init.d/mysql start
803 echo "Giving mysqld 5 seconds to start"
804 sleep 5
805 fi907 fi
908%endif
909 echo "Giving mysqld 5 seconds to start"
910 sleep 5
806fi911fi
807912
808echo "Percona Server is distributed with several useful UDF (User Defined Function) from Percona Toolkit."913echo "Percona Server is distributed with several useful UDF (User Defined Function) from Percona Toolkit."
@@ -839,6 +944,12 @@
839# http://docs.fedoraproject.org/en-US/Fedora_Draft_Documentation/0.1/html/RPM_Guide/ch09s04s05.html944# http://docs.fedoraproject.org/en-US/Fedora_Draft_Documentation/0.1/html/RPM_Guide/ch09s04s05.html
840 945
841if [ $1 = 0 ] ; then946if [ $1 = 0 ] ; then
947%if 0%{?systemd}
948 if [ -x %{_bindir}/systemctl ] ; then
949 %{_bindir}/systemctl stop mysql > /dev/null
950 %{_bindir}/systemctl disable mysql > /dev/null
951 fi
952%else
842 # Stop MySQL before uninstalling it953 # Stop MySQL before uninstalling it
843 if [ -x %{_sysconfdir}/init.d/mysql ] ; then954 if [ -x %{_sysconfdir}/init.d/mysql ] ; then
844 %{_sysconfdir}/init.d/mysql stop > /dev/null955 %{_sysconfdir}/init.d/mysql stop > /dev/null
@@ -851,6 +962,7 @@
851 /sbin/insserv -r %{_sysconfdir}/init.d/mysql962 /sbin/insserv -r %{_sysconfdir}/init.d/mysql
852 fi963 fi
853 fi964 fi
965%endif
854fi966fi
855967
856# We do not remove the mysql user since it may still own a lot of968# We do not remove the mysql user since it may still own a lot of
@@ -893,21 +1005,35 @@
893fi1005fi
894echo "Analyzed: SERVER_TO_START=$SERVER_TO_START"1006echo "Analyzed: SERVER_TO_START=$SERVER_TO_START"
8951007
1008%if 0%{?systemd}
1009if [ -x %{_bindir}/systemctl ] ; then
1010 %{_bindir}/systemctl enable mysql >/dev/null 2>&1
1011fi
1012%else
896if [ -x /sbin/chkconfig ] ; then1013if [ -x /sbin/chkconfig ] ; then
897 /sbin/chkconfig --add mysql1014 /sbin/chkconfig --add mysql
898# use insserv for older SuSE Linux versions1015# use insserv for older SuSE Linux versions
899elif [ -x /sbin/insserv ] ; then1016elif [ -x /sbin/insserv ] ; then
900 /sbin/insserv %{_sysconfdir}/init.d/mysql1017 /sbin/insserv %{_sysconfdir}/init.d/mysql
901fi1018fi
1019%endif
9021020
903# Was the server running before the upgrade? If so, restart the new one.1021# Was the server running before the upgrade? If so, restart the new one.
904if [ "$SERVER_TO_START" = "true" ] ; then1022if [ "$SERVER_TO_START" = "true" ] ; then
905 # Restart in the same way that mysqld will be started normally.1023# Restart in the same way that mysqld will be started normally.
1024%if 0%{?systemd}
1025 if [ -x %{_bindir}/systemctl ] ; then
1026 %{_bindir}/systemctl start mysql
1027 echo "Giving mysqld 5 seconds to start"
1028 sleep 5
1029 fi
1030%else
906 if [ -x %{_sysconfdir}/init.d/mysql ] ; then1031 if [ -x %{_sysconfdir}/init.d/mysql ] ; then
907 %{_sysconfdir}/init.d/mysql start1032 %{_sysconfdir}/init.d/mysql start
908 echo "Giving mysqld 5 seconds to start"1033 echo "Giving mysqld 5 seconds to start"
909 sleep 51034 sleep 5
910 fi1035 fi
1036%endif
911fi1037fi
9121038
913echo "Trigger 'postun --community' finished at `date`" >> $STATUS_HISTORY1039echo "Trigger 'postun --community' finished at `date`" >> $STATUS_HISTORY
@@ -926,6 +1052,10 @@
926# Files section1052# Files section
927##############################################################################1053##############################################################################
9281054
1055%files -n Percona-Server-selinux%{product_suffix}
1056%dir %attr(755, root, root) %{_datadir}/selinux/packages/percona-server
1057%attr(644, root, root) %{_datadir}/selinux/packages/percona-server/percona-server.pp
1058
929%files -n Percona-Server-server%{product_suffix}1059%files -n Percona-Server-server%{product_suffix}
930%defattr(-,root,root,0755)1060%defattr(-,root,root,0755)
9311061
@@ -965,6 +1095,9 @@
965%doc %attr(644, root, man) %{_mandir}/man1/resolve_stack_dump.1*1095%doc %attr(644, root, man) %{_mandir}/man1/resolve_stack_dump.1*
966%doc %attr(644, root, man) %{_mandir}/man1/resolveip.1*1096%doc %attr(644, root, man) %{_mandir}/man1/resolveip.1*
967%doc %attr(644, root, man) %{_mandir}/man1/mysql_plugin.1*1097%doc %attr(644, root, man) %{_mandir}/man1/mysql_plugin.1*
1098%if 0%{?systemd}
1099%attr(755, root, root) %{_bindir}/mysql-systemd
1100%endif
9681101
969%ghost %config(noreplace,missingok) %{_sysconfdir}/my.cnf1102%ghost %config(noreplace,missingok) %{_sysconfdir}/my.cnf
9701103
@@ -1052,7 +1185,11 @@
1052%endif1185%endif
10531186
1054%attr(644, root, root) %config(noreplace,missingok) %{_sysconfdir}/logrotate.d/mysql1187%attr(644, root, root) %config(noreplace,missingok) %{_sysconfdir}/logrotate.d/mysql
1188%if 0%{?systemd}
1189%attr(644, root, root) %{_unitdir}/mysql.service
1190%else
1055%attr(755, root, root) %{_sysconfdir}/init.d/mysql1191%attr(755, root, root) %{_sysconfdir}/init.d/mysql
1192%endif
10561193
1057%attr(755, root, root) %{_datadir}/percona-server/1194%attr(755, root, root) %{_datadir}/percona-server/
10581195
@@ -1141,6 +1278,10 @@
1141%doc %attr(644, root, man) %{_mandir}/man1/mysqltest_embedded.1*1278%doc %attr(644, root, man) %{_mandir}/man1/mysqltest_embedded.1*
11421279
1143%changelog1280%changelog
1281* Tue Aug 26 2014 Tomislav Plavcic <tomislav.plavcic@percona.com>
1282
1283- Added support for centos7
1284
1144* Thu May 29 2014 Tomislav Plavcic <tomislav.plavcic@percona.com>1285* Thu May 29 2014 Tomislav Plavcic <tomislav.plavcic@percona.com>
11451286
1146- UDF and HandlerSocket moved to plugin1287- UDF and HandlerSocket moved to plugin
11471288
=== added directory 'build-ps/rpm'
=== added file 'build-ps/rpm/mysql-systemd'
--- build-ps/rpm/mysql-systemd 1970-01-01 00:00:00 +0000
+++ build-ps/rpm/mysql-systemd 2014-09-01 07:18:02 +0000
@@ -0,0 +1,92 @@
1#! /bin/bash
2#
3# Scripts to run by Percona Server systemd service
4#
5# Needed argument: pre | post
6#
7# pre mode : try to run mysql_install_db and fix perms and SELinux contexts
8# post mode : ping server until answer is received
9#
10
11parse_cnf()
12{
13 local var=$1
14 shift
15 local groups=$*
16 reval=$(my_print_defaults $groups | awk -F= '{if ($1 ~ /_/) { gsub(/_/,"-",$1); print $1"="$2 } else { print $0 }}' | grep -- "--$var=" | cut -d= -f2- | tail -n 1 )
17 if [[ -z ${reval:-} ]];then
18 reval=""
19 fi
20 echo $reval
21}
22
23install_db () {
24 # Note: something different than datadir=/var/lib/mysql requires SELinux policy changes (in enforcing mode)
25 log=$(parse_cnf log-error server mysqld mysqld_safe)
26 datadir=$(parse_cnf datadir server mysqld)
27 if [[ -z ${datadir:-} ]]; then
28 datadir="/var/lib/mysql"
29 fi
30
31 # Check that pid-file directory exists and has valid permissions
32 pid_path=$(parse_cnf pid-file server mysqld mysqld_safe)
33 if [[ -z "${pid_path:-}" ]]; then
34 pid_path=$datadir/`hostname`.pid
35 else
36 case "$pid_path" in
37 /* ) ;;
38 * ) pid_path="$datadir/$pid_path" ;;
39 esac
40 fi
41 pidfiledir=$(dirname $pid_path)
42
43 if [ ! -z $pidfiledir ]; then
44 [ -d "$pidfiledir" ] || install -d -m 0755 -omysql -gmysql "$pidfiledir" || exit 1
45 fi
46
47 # Restore log, dir, perms and SELinux contexts
48 [ -d "$datadir" ] || install -d -m 0755 -omysql -gmysql "$datadir" || exit 1
49 if [ -x /usr/sbin/restorecon ]; then
50 /usr/sbin/restorecon "$datadir"
51 if [ ! -z $pidfiledir ]; then
52 /usr/sbin/restorecon "$pidfiledir"
53 fi
54 fi
55
56 # If log file is not specified it's put into datadir by default
57 if [ ! -z $log ]; then
58 [ -e $log ] || touch $log
59 chmod 0640 $log
60 chown mysql:mysql $log || exit 1
61 if [ -x /usr/sbin/restorecon ]; then
62 /usr/sbin/restorecon $log
63 fi
64 fi
65
66 # If special mysql dir is in place, skip db install
67 [ -d "$datadir/mysql" ] && exit 0
68
69 # Create initial db
70 /usr/bin/mysql_install_db --rpm --datadir="$datadir" --user=mysql
71 exit 0
72}
73
74pinger () {
75 # Wait for ping to answer to signal startup completed,
76 # might take a while in case of e.g. crash recovery
77 # MySQL systemd service will timeout script if no answer
78 while /bin/true ; do
79 sleep 1
80 mysqladmin ping >/dev/null 2>&1 && break
81 done
82 exit 0
83}
84
85# main
86case $1 in
87 "pre") install_db ;;
88 "post") pinger ;;
89esac
90
91exit 0
92
093
=== added file 'build-ps/rpm/mysql.service'
--- build-ps/rpm/mysql.service 1970-01-01 00:00:00 +0000
+++ build-ps/rpm/mysql.service 2014-09-01 07:18:02 +0000
@@ -0,0 +1,31 @@
1#
2# Systemd service file for Percona Server
3#
4# # This service file is to start PS just with mysqld_safe
5#
6
7[Unit]
8Description=MySQL Percona Server
9After=network.target
10After=syslog.target
11
12[Install]
13WantedBy=multi-user.target
14Alias=mysql.service
15
16[Service]
17# Needed to create system tables etc.
18ExecStartPre=/usr/bin/mysql-systemd pre
19
20# Start main service
21ExecStart=/usr/bin/mysqld_safe
22
23# Don't signal startup success before a ping works
24ExecStartPost=/usr/bin/mysql-systemd post
25
26# Give up if ping don't get an answer
27TimeoutSec=600
28
29Restart=always
30PrivateTmp=false
31
032
=== modified file 'policy/selinux/percona-server.te'
--- policy/selinux/percona-server.te 2013-03-01 19:17:07 +0000
+++ policy/selinux/percona-server.te 2014-09-01 07:18:02 +0000
@@ -11,8 +11,9 @@
11 class sock_file { getattr unlink create };11 class sock_file { getattr unlink create };
12 class capability { sys_nice sys_resource };12 class capability { sys_nice sys_resource };
13 class blk_file { read write open };13 class blk_file { read write open };
14 class file { write getattr read create unlink open };14 class file { append write getattr read create unlink open setattr };
15 class dir { search read write remove_name open add_name };15 class dir { search read write remove_name open add_name };
16 class process { siginh noatsecure rlimitinh };
16}17}
1718
18#============= mysqld_safe_t ==============19#============= mysqld_safe_t ==============
@@ -22,6 +23,9 @@
22allow mysqld_safe_t tmp_t:sock_file { getattr unlink };23allow mysqld_safe_t tmp_t:sock_file { getattr unlink };
23allow mysqld_safe_t user_tmp_t:sock_file { getattr unlink };24allow mysqld_safe_t user_tmp_t:sock_file { getattr unlink };
2425
26#!!!! This avc has a dontaudit rule in the current policy
27allow mysqld_safe_t mysqld_t:process { siginh rlimitinh noatsecure };
28
25#============= mysqld_t ==============29#============= mysqld_t ==============
26allow mysqld_t fixed_disk_device_t:blk_file { read write open };30allow mysqld_t fixed_disk_device_t:blk_file { read write open };
27allow mysqld_t tmp_t:sock_file { create unlink };31allow mysqld_t tmp_t:sock_file { create unlink };
2832
=== modified file 'storage/innobase/include/univ.i'
--- storage/innobase/include/univ.i 2014-08-22 10:09:55 +0000
+++ storage/innobase/include/univ.i 2014-09-01 07:18:02 +0000
@@ -64,7 +64,7 @@
64 (INNODB_VERSION_MAJOR << 8 | INNODB_VERSION_MINOR)64 (INNODB_VERSION_MAJOR << 8 | INNODB_VERSION_MINOR)
6565
66#ifndef PERCONA_INNODB_VERSION66#ifndef PERCONA_INNODB_VERSION
67#define PERCONA_INNODB_VERSION 35.267#define PERCONA_INNODB_VERSION 36.0
68#endif68#endif
6969
70#define INNODB_VERSION_STR MYSQL_SERVER_VERSION70#define INNODB_VERSION_STR MYSQL_SERVER_VERSION

Subscribers

People subscribed via source and target branches