/[smecontribs]/rpms/smeserver-mysql57/contribs10/smeserver-mysql57-2.0.0-bz11896-initscripts.patch
ViewVC logotype

Contents of /rpms/smeserver-mysql57/contribs10/smeserver-mysql57-2.0.0-bz11896-initscripts.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Sun Mar 13 03:02:21 2022 UTC (2 years, 7 months ago) by jpp
Branch: MAIN
CVS Tags: smeserver-mysql57-2_0_0-15_el7_sme, HEAD
Error occurred while calculating annotation data.
* Sat Mar 12 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.0.0-15.sme
- fix mysql.init and few other scripts [SME: 11896]

1 diff -Nur --no-dereference smeserver-mysql57-2.0.0.old/root/sbin/e-smith/mysql57-preload smeserver-mysql57-2.0.0/root/sbin/e-smith/mysql57-preload
2 --- smeserver-mysql57-2.0.0.old/root/sbin/e-smith/mysql57-preload 2022-03-12 21:52:46.616000000 -0500
3 +++ smeserver-mysql57-2.0.0/root/sbin/e-smith/mysql57-preload 2022-03-12 21:57:34.737000000 -0500
4 @@ -19,12 +19,12 @@
5
6 my $runlevel;
7
8 -open (RUNLEVEL, "-|", "/sbin/runlevel");
9 +open (RUNLEVEL, "-|", "/usr/bin/systemctl get-default");
10 (undef, $runlevel) = split(' ',<RUNLEVEL>);
11 close RUNLEVEL;
12
13
14 -if ($runlevel ne '7' || $event eq 'bootstrap-console-save')
15 +if ( ($runlevel ne 'multi-user.target' && $runlevel ne "sme-server.target") || $event eq 'bootstrap-console-save')
16 {
17 my $pid = open(KID, "|-");
18 if (defined $pid)
19 @@ -46,7 +46,7 @@
20 }
21 # Hard-code user, since it is set in mysqld_safe currently.
22 # See http://bugs.mysql.com/2163
23 - exec($mysqld, qw(--bootstrap --user=mysql --skip-grant-tables));
24 + exec("/usr/bin/scl enable rh-mysql57 -- $mysqld", qw(--bootstrap --user=mysql --skip-grant-tables));
25 }
26 }
27 else
28 diff -Nur --no-dereference smeserver-mysql57-2.0.0.old/root/sbin/e-smith/systemd/mysql57-mysql.init smeserver-mysql57-2.0.0/root/sbin/e-smith/systemd/mysql57-mysql.init
29 --- smeserver-mysql57-2.0.0.old/root/sbin/e-smith/systemd/mysql57-mysql.init 2022-03-12 21:52:46.682000000 -0500
30 +++ smeserver-mysql57-2.0.0/root/sbin/e-smith/systemd/mysql57-mysql.init 2022-03-12 21:54:57.429000000 -0500
31 @@ -1,7 +1,7 @@
32 #!/bin/sh
33
34 #----------------------------------------------------------------------
35 -# copyright (C) 2002 Mitel Networks Corporation
36 +# copyright (C) 2022 Koozali Foundation
37 #
38 # This program is free software; you can redistribute it and/or modify
39 # it under the terms of the GNU General Public License as published by
40 @@ -35,7 +35,7 @@
41
42 for i in $(seq 1 10)
43 do
44 - if test -e /var/lib/mysql/mysql.sock
45 + if test -e /var/lib/mysql/mysql57.sock
46 then
47 exit_value=0
48 HOME=/root
49 @@ -45,10 +45,10 @@
50 F=$(basename $link | sed s/S[0-9][0-9]//)
51 case $F in
52 *.sql)
53 - action "Loading $F into mysql" /usr/bin/mysql < $link && /bin/rm $link
54 + action "Loading $F into mysql 57 " /usr/bin/mysql --socket=/var/lib/mysql/mysql57.sock < $link && /bin/rm $link
55 ;;
56 *)
57 - action "Loading $F into mysql" $link && /bin/rm $link
58 + action "Loading $F into mysql 57 " $link && /bin/rm $link
59 ;;
60 esac
61 # Record any failure for the final return value.
62 @@ -58,7 +58,7 @@
63 done
64 exit $exit_value
65 fi
66 - echo "Waiting for mysql to startup" >&2
67 + echo "Waiting for mysql 57 to startup" >&2
68 sleep 2
69 done
70

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed