[root@wallet04 ~]# wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
[root@wallet04 ~]# rpm -ivh epel-release-latest-6.noarch.rpm
[root@wallet04 ~]# rpm -ivh https://mirror.webtatic.com/yum/el6/latest.rpm
[root@wallet04 ~]# yum install -y httpd php56w.x86_64 php56w-cli.x86_64 php56w-common.x86_64 php56w-devel.x86_64 \
php56w-gd.x86_64 php56w-ldap.x86_64 php56w-mbstring.x86_64 php56w-bcmath.x86_64 php56w-xml.x86_64 \
php56w-mysqlnd.x86_64 php56w-pdo.x86_64
[root@wallet04 ~]# vi /etc/httpd/conf/httpd.conf
ServerName 192.168.1.204:80
[root@wallet04 ~]# service httpd start
Starting httpd: [ OK ]
[root@wallet04 ~]# service httpd status
httpd (pid 1424) is running...
[root@wallet04 ~]# vi /etc/php.ini
date.timezone = Asia/Shanghai
[root@wallet04 ~]# php -v
PHP 5.6.40 (cli) (built: Jan 12 2019 09:19:57)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
安装MySQL 5.6
https://blog.51cto.com/13598811/2349351
[root@wallet04 ~]# python -V
Python 2.6.6
[root@wallet04 ~]# yum install -y python-pip
[root@wallet04 ~]# pip -V
pip 7.1.0 from /usr/lib/python2.6/site-packages (python 2.6)
[root@wallet04 ~]# pip install MySQL-python
[root@wallet04 ~]# cd lepus/python
[root@wallet04 python]# python test_driver_mysql.py
MySQL python drivier is ok!
[root@wallet04 ~]# cd lepus/sql
[root@wallet04 sql]# mysql -u root -pabcd.1234
mysql> create database lepus default character set utf8;
Query OK, 1 row affected (0.00 sec)
mysql> grant all on lepus.* to 'lepus'@'%' identified by 'lepus';
Query OK, 0 rows affected (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)
mysql> use lepus
Database changed
mysql> source lepus_table.sql
mysql> source lepus_data.sql
mysql> alter table mysql_slow_query_review modify checksum varchar(100) not null;
Query OK, 0 rows affected (0.95 sec)
mysql> alter table mysql_slow_query_review_history modify checksum varchar(100) not null;
Query OK, 0 rows affected (0.73 sec)
[root@wallet04 ~]# cd lepus/python
[root@wallet04 python]# chmod +x install.sh
[root@wallet04 python]# ./install.sh
[note] lepus will be install on basedir: /usr/local/lepus
[note] /usr/local/lepus directory does not exist,will be created.
[note] /usr/local/lepus directory created success.
[note] wait copy files.......
[note] change script permission.
[note] create links.
[note] install complete.
[root@wallet04 ~]# cd /usr/local/lepus
[root@wallet04 lepus]# vim etc/config.ini
###监控机MySQL数据库连接地址###
[monitor_server]
host="localhost"
port=3306
user="lepus"
passwd="lepus"
dbname="lepus"
[root@wallet04 ~]# cd lepus
[root@wallet04 lepus]# cp -rf php5 * * * * sh /usr/local/sbin/lepus_slowquery.sh > /dev/null 2>&1
[root@wallet01 ~]# ls -l oracle-instantclient11.2*
-rw-r--r-- 1 root root 59865008 Dec 3 11:06 oracle-instantclient11.2-basic-11.2.0.4.0-1.x86_64.rpm
-rw-r--r-- 1 root root 610222 Dec 3 11:04 oracle-instantclient11.2-devel-11.2.0.4.0-1.x86_64.rpm
-rw-r--r-- 1 root root 828333 Dec 3 11:04 oracle-instantclient11.2-sqlplus-11.2.0.4.0-1.x86_64.rpm
[root@wallet01 ~]# rpm -ivh oracle-instantclient11.2-*
[root@wallet01 ~]# vim /root/.bash_profile
export ORACLE_HOME=/usr/lib/oracle/11.2/client64
export PATH=$PATH:$ORACLE_HOME/bin
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib:/usr/local/lib
[root@wallet04 ~]# source /root/.bash_profile
[root@wallet01 ~]# vim /etc/ld.so.conf
include ld.so.conf.d/*.conf
/usr/lib/oracle/11.2/client64/lib
[root@wallet01 ~]# ldconfig
[root@wallet01 ~]# pip install cx-Oracle
[root@wallet01 ~]# cd /usr/local/lepus
[root@wallet01 lepus]# python test_driver_oracle.py
Oracle python drivier is ok!
免责声明:
① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。
② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341