/[smecontribs]/rpms/smeserver-zabbix-server/contribs9/smeserver-zabbix-server-0.1-zabbix4.4.6.patch
ViewVC logotype

Annotation of /rpms/smeserver-zabbix-server/contribs9/smeserver-zabbix-server-0.1-zabbix4.4.6.patch

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


Revision 1.2 - (hide annotations) (download)
Sun May 10 07:29:21 2020 UTC (4 years, 6 months ago) by jpp
Branch: MAIN
CVS Tags: smeserver-zabbix-server-0_1-18_el6_sme
Changes since 1.1: +1 -1 lines
* Sun May 10 2020 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-18.sme
- adapt for zabbix 4.4.6

1 jpp 1.1 diff -Nur smeserver-zabbix-server-0.1.old/createlinks smeserver-zabbix-server-0.1/createlinks
2     --- smeserver-zabbix-server-0.1.old/createlinks 2020-05-10 01:38:01.417000000 -0400
3     +++ smeserver-zabbix-server-0.1/createlinks 2020-05-10 03:07:02.122000000 -0400
4     @@ -15,10 +15,11 @@
5     templates2events("/etc/rc.d/init.d/masq", $event);
6    
7     # Services to restart
8     -safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/mysql.init");
9     +#safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/mysql.init");
10     safe_symlink("sigusr1", "root/etc/e-smith/events/$event/services2adjust/httpd-e-smith");
11     safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/zabbix-server");
12     safe_symlink("adjust", "root/etc/e-smith/events/$event/services2adjust/masq");
13     +safe_symlink("/etc/e-smith/events/actions/zabbix-server","root/etc/e-smith/events/$event/50zabbix-server");
14    
15     # PHP header and footer
16     safe_symlink("/etc/e-smith/templates-default/template-begin-php", "root/etc/e-smith/templates/etc/zabbix/zabbix.conf.php/template-begin");
17     diff -Nur smeserver-zabbix-server-0.1.old/root/etc/e-smith/events/actions/zabbix-server smeserver-zabbix-server-0.1/root/etc/e-smith/events/actions/zabbix-server
18     --- smeserver-zabbix-server-0.1.old/root/etc/e-smith/events/actions/zabbix-server 1969-12-31 19:00:00.000000000 -0500
19     +++ smeserver-zabbix-server-0.1/root/etc/e-smith/events/actions/zabbix-server 2020-05-10 03:05:06.278000000 -0400
20     @@ -0,0 +1,7 @@
21     +#!/bin/bash
22     +# restart mysql.init
23     +/sbin/service zabbix-server stop 1>/dev/null
24     +/sbin/service mysql.init restart 1>/dev/null
25     +/sbin/service zabbix-server start 1>/dev/null
26     +exit 0
27     +
28     diff -Nur smeserver-zabbix-server-0.1.old/root/etc/e-smith/templates/etc/e-smith/sql/init/80zabbix-server smeserver-zabbix-server-0.1/root/etc/e-smith/templates/etc/e-smith/sql/init/80zabbix-server
29     --- smeserver-zabbix-server-0.1.old/root/etc/e-smith/templates/etc/e-smith/sql/init/80zabbix-server 2020-05-10 01:38:01.438000000 -0400
30     +++ smeserver-zabbix-server-0.1/root/etc/e-smith/templates/etc/e-smith/sql/init/80zabbix-server 2020-05-10 02:48:12.255000000 -0400
31     @@ -3,13 +3,8 @@
32     my $user = ${'zabbix-server'}{'DbUser'} || 'zabbix';
33     my $pass = ${'zabbix-server'}{'DbPassword'} || 'secret';
34    
35     -my $schema = `rpm -qd zabbix-server-mysql | grep schema | grep mysql`;
36     -$schema = `rpm -qd zabbix-server | grep schema | grep mysql` if $schema eq '';
37     -my $data = `rpm -qd zabbix-server-mysql | grep data.sql`;
38     -$data = `rpm -qd zabbix-server| grep mysql | grep data.sql` if $data eq '';
39     -my $images = `rpm -qd zabbix-server-mysql | grep images_mysql`;
40     -$images = `rpm -qd zabbix-server | grep mysql |grep images` if $images eq '';
41     -
42     +my $schema = `rpm -qd zabbix-server-mysql | grep create`;
43 jpp 1.2 +chomp $schema;
44 jpp 1.1
45     $OUT .= <<"END";
46     #! /bin/sh
47     @@ -18,10 +13,9 @@
48     /usr/bin/mysql $db < \$P
49     done
50     else
51     - /usr/bin/mysqladmin create $db
52     - /usr/bin/mysql $db < $schema
53     - /usr/bin/mysql $db < $data
54     - /usr/bin/mysql $db < $images
55     + echo "CREATE DATABASE $db CHARACTER SET utf8 COLLATE utf8_bin;" | /usr/bin/mysql
56     + /usr/bin/gunzip < $schema | /usr/bin/mysql $db
57     +
58     fi
59    
60     /usr/bin/mysql <<EOF
61     diff -Nur smeserver-zabbix-server-0.1.old/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/98zabbix-web smeserver-zabbix-server-0.1/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/98zabbix-web
62     --- smeserver-zabbix-server-0.1.old/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/98zabbix-web 2020-05-10 01:38:01.436000000 -0400
63     +++ smeserver-zabbix-server-0.1/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/98zabbix-web 2020-05-10 02:47:42.612000000 -0400
64     @@ -24,6 +24,7 @@
65     php_admin_value memory_limit 256M
66     php_admin_value date.timezone $tz
67     php_admin_value post_max_size 32M
68     + php_admin_value always_populate_raw_post_data -1
69     AllowOverride None
70     Order allow,deny
71     Allow from $access

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