/[smeserver]/rpms/smeserver-mysql/sme10/smeserver-mysql-2.7.0-bz11899-sclo.patch
ViewVC logotype

Contents of /rpms/smeserver-mysql/sme10/smeserver-mysql-2.7.0-bz11899-sclo.patch

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


Revision 1.4 - (show annotations) (download)
Mon Mar 14 02:39:16 2022 UTC (2 years, 8 months ago) by jpp
Branch: MAIN
CVS Tags: smeserver-mysql-2_7_0-4_el7_sme
Changes since 1.3: +0 -31 lines
* Sun Mar 13 2022 Jean-Philippe Pialasse <tests@pialasse.com> 2.7.0-4.sme
- fix typo in socket, seen with phpmyadmin [SME: 11899]
- fix permissions for mariadb105 [SME: 11899]
  revert change in release 2 for root password and fix set.password

1 diff -Nur --no-dereference smeserver-mysql-2.7.0.old/rootscl/etc/logrotate.d/mariadb_VER_ smeserver-mysql-2.7.0/rootscl/etc/logrotate.d/mariadb_VER_
2 --- smeserver-mysql-2.7.0.old/rootscl/etc/logrotate.d/mariadb_VER_ 2022-03-11 21:34:28.000000000 -0500
3 +++ smeserver-mysql-2.7.0/rootscl/etc/logrotate.d/mariadb_VER_ 2022-03-13 01:33:07.924000000 -0500
4 @@ -7,10 +7,10 @@
5 compress
6 postrotate
7 # just if mysqld is really running
8 - if test -x /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin && \
9 - /usr/bin/scl enable rh-mariadb!!!VER!!! -- /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin ping &>/dev/null
10 + if test -x /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin && \
11 + /usr/bin/scl enable rh-mariadb!!!VER!!! -- /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin --socket=!!!SOCKET!!! ping &>/dev/null
12 then
13 - /usr/bin/scl enable rh-mariadb!!!VER!!! -- /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin --local flush-error-log \
14 + /usr/bin/scl enable rh-mariadb!!!VER!!! -- /opt/rh/rh-mariadb!!!VER!!!/root/usr/bin/mysqladmin --socket=!!!SOCKET!!! --local flush-error-log \
15 flush-engine-log flush-general-log flush-slow-log
16 fi
17 endscript
18 diff -Nur --no-dereference smeserver-mysql-2.7.0.old/rootscl/etc/e-smith/templates/etc/phpMyAdmin/config.inc.php/11configMysql_VER_ smeserver-mysql-2.7.0/rootscl/etc/e-smith/templates/etc/phpMyAdmin/config.inc.php/11configMysql_VER_
19 --- smeserver-mysql-2.7.0.old/rootscl/etc/e-smith/templates/etc/phpMyAdmin/config.inc.php/11configMysql_VER_ 2022-03-12 16:39:10.000000000 -0500
20 +++ smeserver-mysql-2.7.0/rootscl/etc/e-smith/templates/etc/phpMyAdmin/config.inc.php/11configMysql_VER_ 2022-03-13 21:14:10.966000000 -0400
21 @@ -3,7 +3,7 @@
22 $cfg['Servers'][$i]['host'] = 'localhost';
23 $cfg['Servers'][$i]['extension'] = 'mysqli';
24 $cfg['Servers'][$i]['connect_type'] = 'socket';
25 -$cfg['Servers'][$i]['socket'] = '/var/lib/mysql/mariadb!!!VER!!!.sock';
26 +$cfg['Servers'][$i]['socket'] = '!!!SOCKET!!!';
27 $cfg['Servers'][$i]['compress'] = false;
28 # standalone or login mode
29 $scriptname=end(explode('/',$_SERVER['PHP_SELF']));
30 diff -Nur --no-dereference smeserver-mysql-2.7.0.old/rootscl/sbin/e-smith/systemd/mariadb_VER_-mysql.init smeserver-mysql-2.7.0/rootscl/sbin/e-smith/systemd/mariadb_VER_-mysql.init
31 --- smeserver-mysql-2.7.0.old/rootscl/sbin/e-smith/systemd/mariadb_VER_-mysql.init 2022-03-11 20:43:05.000000000 -0500
32 +++ smeserver-mysql-2.7.0/rootscl/sbin/e-smith/systemd/mariadb_VER_-mysql.init 2022-03-13 21:13:39.386000000 -0400
33 @@ -52,7 +52,7 @@
34
35 for i in $(seq 1 10)
36 do
37 - if test -e /var/lib/mysql/mariadb!!!VER!!!.sock
38 + if test -e !!!SOCKET!!!
39 then
40 exit_value=0
41 HOME=/root
42 diff -Nur --no-dereference smeserver-mysql-2.7.0.old/root/etc/e-smith/templates/var/lib/mysql/set.password smeserver-mysql-2.7.0/root/etc/e-smith/templates/var/lib/mysql/set.password
43 --- smeserver-mysql-2.7.0.old/root/etc/e-smith/templates/var/lib/mysql/set.password 2022-03-11 10:32:13.000000000 -0500
44 +++ smeserver-mysql-2.7.0/root/etc/e-smith/templates/var/lib/mysql/set.password 2022-03-13 22:32:50.035000000 -0400
45 @@ -3,9 +3,20 @@
46
47 my $pw = esmith::util::LdapPassword();
48
49 - $OUT .= "use mysql;\n";
50 - $OUT .= "ALTER TABLE user MODIFY Password char(41) NOT NULL default '';\n";
51 - $OUT .= "UPDATE user SET password=password('$pw') WHERE user='root';\n";
52 - $OUT .= "DELETE FROM user WHERE user='';\n";
53 + $OUT .= "DELIMITER //\n";
54 + $OUT .= "use mysql //\n";
55 + $OUT .= "SET \@vers := (SELECT REPLACE(SUBSTRING( \@\@VERSION , 1 , LOCATE( '.' , \@\@VERSION, LOCATE( '.' , \@\@VERSION )+1 ) ), '.','' ) ) //\n";
56 + $OUT .= "BEGIN NOT ATOMIC \n";
57 + $OUT .= "IF \@vers < 104 THEN \n";
58 + $OUT .= " ALTER TABLE user MODIFY Password char(41) NOT NULL default '';\n";
59 + $OUT .= " UPDATE user SET password=password('$pw') WHERE user='root';\n";
60 + $OUT .= " DELETE FROM db WHERE user='';\n";
61 + $OUT .= " DELETE FROM user WHERE user='';\n";
62 + $OUT .= "ELSE \n";
63 + $OUT .= " SET PASSWORD FOR 'root'\@localhost = PASSWORD(\"$pw\"); \n";
64 + $OUT .= "END IF; \n";
65 + $OUT .= "END // \n";
66 + $OUT .= "DELIMITER ; \n";
67 $OUT .= "FLUSH PRIVILEGES;\n";
68 +
69 }

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