zoukankan      html  css  js  c++  java
  • zabbix 2.4 install script under the OS of Ubuntu

    #!/bin/bash
    #
    #Description: The scripte of installing zabbix-server
    #Author: christian.badguy
    #Date: 2015-07-07
    #
    echo "-----------------------start install zabbix----------------------"
    wget http://repo.zabbix.com/zabbix/2.4/ubuntu/pool/main/z/zabbix-release/zabbix-release_2.4-1+trusty_all.deb
    dpkg -i zabbix-release_2.4-1+trusty_all.deb
    apt-get update
    apt-get update --fix-missing
    apt-get install zabbix-server-mysql zabbix-frontend-php
    if [ $? -ne 0 ];then
    echo "install failed ,please check it out!"
    exit 1
    else
    echo "-----------------------modifing the apache2 ----------------------"
    echo "ServerName 127.0.0.1:80" >> /etc/apache2/apache2.conf
    sed -i 's@;date.timezone =@date.timezone = Asia/shanghai@g' /etc/php5/apache2/php.ini
    sed -i 's@max_execution_time = 30@max_execution_time = 600@g' /etc/php5/apache2/php.ini
    sed -i 's@max_input_time = 60@max_input_time = 600@g' /etc/php5/apache2/php.ini
    sed -i 's@memory_limit = 128M@memory_limit = 256M@g' /etc/php5/apache2/php.ini
    sed -i 's@post_max_size = 8M@post_max_size = 32M@g' /etc/php5/apache2/php.ini
    sed -i 's@upload_max_filesize = 2M@upload_max_filesize = 16M@g' /etc/php5/apache2/php.ini
    service apache2 restart
    service zabbix-server restart
    echo "-----------------------zabbix server installs sucessfully----------------------"
    fi

     

    版权所有@chrisDuan 博客地址http://www.cnblogs.com/chrisDuan 可以转载,注明出处.
  • 相关阅读:
    C#表示空字符串
    char varchar nvarchar区别
    WCF 服务器端 上传图片
    各种算法时间复杂度
    ADO.net 对象
    走出浮躁的泥沼
    英语学习
    前端获取GridView和ASPxGridView单元格中的值
    【dfs+染色】【HDOJ】5652 India and China Origins
    【模拟】【codeforces】599B Spongebob and Joke
  • 原文地址:https://www.cnblogs.com/chrisDuan/p/4476282.html
Copyright © 2011-2022 走看看