nignx

  1. 一、nginx介绍:
  2. 可以作为一个HTTP服务器进行网站的发布处理,另外Nginx可以作为反向代理进行负载均衡的实现
  3. nginx官网:
  4. https://nginx.org/
  5. nginx下载地址:
  6. https://nginx.org/en/download.html
  7. 源码包地址:http://nginx.org/download/nginx-1.22.0.tar.gz
  8. 二、nginx版本:
  9. 源码安装包: nginx-1.22.0
# 1. 基础环境 
useradd -r -s /sbin/nologin -M www  ##创建nginx用户
yum install -y gcc gcc-c++ glibc glibc-devel pcre pcre-devel zlib zlib-devel openssl openssl-devel
# 2. 下载
wget -O https://nginx.org/download/nginx-1.22.0.tar.gz
# 3. 解压
tar -xf /work/packages/nginx-1.22.0.tar.gz
# 4. 编译安装nginx---#echo $?查看是否出错
cd /work/packages/nginx-1.22.0
./configure --prefix=/usr/local/nginx --user=www --with-http_stub_status_module --with-http_ssl_module
make && make install  
# 5. 设置systemd管理
ln -s /usr/local/nginx/sbin/* /sbin/
cp /work/config/nginx/nginx.service /usr/lib/systemd/system/

# 6. 配置nginx
\cp -f /work/config/nginx/nginx.conf /usr/local/nginx/conf/

mkdir -p /usr/local/nginx/conf/vhost/ && \cp -f /work/config/nginx/default.conf /usr/local/nginx/conf/vhost/

# 6. 启动nginx
systemctl enable --now nginx  

#7. 测试
ps -ef |grep nginx
ss -antl |grep :80

mkdir -p /data/{baidu,jd}
echo "nginx install successful" /data/baidu/index.html
echo -e "<?php\n  phpinfo(); \n?>" /data/baidu/index.php

echo "127.0.0.1   www.baidu.com  www.jd.com" >> /etc/hosts
curl www.baidu.com
curl www.jd.com
[Unit]
Description=nginx - high performance web server
Documentation=http://nginx.org/en/docs/
After=network-online.target remote-fs.target nss-lookup.target
Wants=network-online.target

[Service]
Type=forking
PIDFile=/usr/local/nginx/run/nginx.pid
ExecStart=/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
ExecReload=/bin/sh -c "/bin/kill -s HUP $(/bin/cat /usr/local/nginx/run/nginx.pid)"
ExecStop=/bin/sh -c "/bin/kill -s TERM $(/bin/cat /usr/local/nginx/run/nginx.pid)"

WantedBy=multi-user.target
   # 1. 安装
      yum -y install nginx 
   # 2. 开启nginx
      systemctl enable --now nginx
      systemctl start nginx
   # 3. 测试
      ps -ef |grep nginx
      ss -antl |grep :80
      curl 127.0.0.1
day03  install rpm nginx succeed
# 这个配置文件放nginx服务的基本配置
# 1.启动用户   2.cpu亲和力   3.err_log位置   4.pid位置   5.文件最大描述符
# 6.工作模式   7.http{}放置全局优化内容如:log格式 gzip压缩 开启子配置文件

user  www www;
worker_processes auto;
worker_cpu_affinity auto;
error_log  /usr/local/nginx/logs/nginx_error.log  crit;
pid        /usr/local/nginx/logs/nginx.pid;
worker_rlimit_nofile 51200;


# 指定nginx工作模式
events
    {
        use epoll;
        worker_connections 51200;
        multi_accept off;
        accept_mutex off;
    }


# 这个大部分放nginx服务需要优化的地方
http
    {
        include       mime.types;
        default_type  application/octet-stream;

        server_names_hash_bucket_size 128;
        client_header_buffer_size 32k;
        large_client_header_buffers 4 32k;
        client_max_body_size 50m;

        sendfile on;
        sendfile_max_chunk 512k;
        tcp_nopush on;

        log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
                      '"$http_referer" $status $body_bytes_sent $request_body '
                      '"$http_user_agent" "$http_x_forwarded_for"';

        add_header Access-Control-Allow-Origin *;
        add_header Access-Control-Allow-Methods 'GET, POST, OPTIONS';
        add_header Access-Control-Allow-Headers 'DNT,X-Mx-ReqToken,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Authorization';



        keepalive_timeout 60;

        tcp_nodelay on;

        fastcgi_connect_timeout 300;
        fastcgi_send_timeout 300;
        fastcgi_read_timeout 300;
        fastcgi_buffer_size 64k;
        fastcgi_buffers 4 64k;
        fastcgi_busy_buffers_size 128k;
        fastcgi_temp_file_write_size 256k;

        gzip on;
        gzip_min_length  1k;
        gzip_buffers     4 16k;
        gzip_http_version 1.1;
        gzip_comp_level 2;
        gzip_types     text/plain application/javascript application/x-javascript text/javascript text/css application/xml application/xml+rss;
        gzip_vary on;
        gzip_proxied   expired no-cache no-store private auth;
        gzip_disable   "MSIE [1-6]\.";

        server_tokens off;
        access_log off;

        # 这个里面是nginx主要配置,开启子配置文件
        include vhost/*.conf;
    }
server {
    listen       80;
    server_name  www.baidu.com;
    location / {
        root   /data/baidu/;
        index  index.html index.htm;
    }
}
server {
    listen       80;
    server_name  www.jd.com;
    location / {
        root   /data/jd/;
        index  index.html index.htm;
    }
}

redis

# 安装redis
# 1. 创建redis用户
groupadd redis && useradd -M -s /sbin/nologin -r -g redis redis

# 2. 解压redis安装包...
tar -xf /work/packages/redis-5.0.14.tar.gz -C /usr/local/
mv /usr/local/redis-5.0.14 /usr/local/redis
cd /usr/local/redis

# 3. 解决依赖
yum -y install gcc gcc-c++

# 4. 安装redis...
make && make install PREFIX=/usr/local/redis

# 5. 设置systemd管理
cp /usr/local/redis/src/redis-server  /usr/local/bin/
cp /usr/local/redis/src/redis-cli     /usr/local/bin/
\cp -f /work/config/redis/redis.service   /etc/systemd/system/redis.service


# 6. 配置启动redis...
\cp -f /work/config/redis/redis.conf  /usr/local/redis/
systemctl enable --now redis

# 7. 测试
redis-cli -h 127.0.0.1 -p 6379 -a '^-^password!@#redis&202206'
auth ^-^password!@#redis&202206
keys *
# ./redis-server /path/to/redis.conf

# bind 192.168.1.100 10.0.0.1
# bind 127.0.0.1 ::1
#
bind 127.0.0.1 ::1

protected-mode yes

port 6379

requirepass ^-^password!@#redis&202206

tcp-backlog 511

timeout 0

tcp-keepalive 300

daemonize no

supervised no

pidfile /var/run/redis_6379.pid

loglevel notice

logfile ""

databases 16

always-show-logo yes

save 900 1
save 300 10
save 60 10000

stop-writes-on-bgsave-error yes

rdbcompression yes

rdbchecksum yes

dbfilename dump.rdb

dir ./

replica-serve-stale-data yes

replica-read-only yes

repl-diskless-sync no

repl-diskless-sync-delay 5

repl-disable-tcp-nodelay no

replica-priority 100

lazyfree-lazy-eviction no
lazyfree-lazy-expire no
lazyfree-lazy-server-del no
replica-lazy-flush no

appendonly no

appendfilename "appendonly.aof"

appendfsync everysec

no-appendfsync-on-rewrite no

auto-aof-rewrite-percentage 100
auto-aof-rewrite-min-size 64mb

aof-load-truncated yes

aof-use-rdb-preamble yes

lua-time-limit 5000

slowlog-max-len 128

latency-monitor-threshold 0

notify-keyspace-events ""

hash-max-ziplist-entries 512
hash-max-ziplist-value 64

list-max-ziplist-size -2

list-compress-depth 0

zset-max-ziplist-entries 128
zset-max-ziplist-value 64

hll-sparse-max-bytes 3000

stream-node-max-bytes 4096
stream-node-max-entries 100

activerehashing yes

client-output-buffer-limit normal 0 0 0
client-output-buffer-limit replica 256mb 64mb 60
client-output-buffer-limit pubsub 32mb 8mb 60

hz 10

dynamic-hz yes

aof-rewrite-incremental-fsync yes

rdb-save-incremental-fsync yes
[Unit]
Description=Redis
After=network.target

[Service]
# Type=forking
ExecStart=/usr/local/redis/bin/redis-server /usr/local/redis/redis-6379.conf
ExecReload=/usr/local/redis/bin/redis-server -s reload
ExecStop=/usr/local/redis/bin/redis-server -s stop
PrivateTmp=true

[Install]
WantedBy=multi-user.target

mysql

mysql介绍
   轻量级关系型数据库管理系统
   #mysql官网:
   https://www.mysql.com/
   #mysql下载地址:
   https://downloads.mysql.com/archives/community/
mysql版本:
   源码安装包: mysql-8.0.26 
   rpm安装包: mysql-5.7.36 
   二进制包 :mysql-5.7.36
# 0. 前期准备
    # 1. 系统初始化---参考之前做的系统优化
    # 2. 下载mysql二进制包并上传到/work/packages/

# 1. 解决依赖
yum -y remove `rpm -qa | grep mariadb`
yum install -y libaio-*
# 2. 创建mysql用户
groupadd mysql && useradd -M -s /sbin/nologin -r -g mysql mysql
# 3. 解压,安装
tar -xf /work/packages/mysql-5.7.36-linux-glibc2.12-x86_64.tar.gz -C /usr/local/
mv /usr/local/mysql-5.7.36-linux-glibc2.12-x86_64/ /usr/local/mysql
# 设置mysql目录权限    
chown -R mysql.mysql /usr/local/mysql

# 4. 设置systemd管理"
ln -s /usr/local/mysql/bin/* /bin/
echo  'export PATH=/usr/local/mysql/bin:$PATH' >> /etc/profile && source /etc/profile

cd /usr/lib/systemd/system && touch mysqld.service && chmod 644 mysqld.service
cp /work/config/mysql/mysqld.service /etc/systemd/system/mysqld.service

cd /usr/lib/tmpfiles.d && touch mysql.conf && chmod 644 mysql.conf
echo 'd /usr/local/mysql/data 0750 mysql mysql  -' > /usr/lib/tmpfiles.d/mysql.conf 



# 5. 配置服务器启动选项,初始化数据目录
cp /work/config/mysql/my.cnf /etc/my.cnf
mkdir -p /data/mysql/mysql3306/{data,logs,tmp}
chown -R mysql:mysql /data/mysql/

# 6. 初始化MySQL
cd /usr/local/mysql
./bin/mysqld --defaults-file=/etc/my.cnf --initialize
echo "----请及时修改密码,密码:【SET PASSWORD = PASSWORD('lnmp@123');】"
grep "temporary password" /data/mysql/mysql3306/data/error.log 


# 7. 启动mysql
systemctl enable --now mysqld 


# 8. 测试
grep "temporary password" /data/mysql/mysql3306/data/error.log 
mysql -uroot -p'passwork'
> SET PASSWORD = PASSWORD('lnmp@123');
> show databases;
#my.cnf
[client]
port            = 3306
socket          = /tmp/mysql3306.sock

[mysql]
prompt="\\u@\\h [\\d]>" 
#pager="less -i -n -S"
#tee=/opt/mysql/query.log
no-auto-rehash

[mysqld]
#misc
user = mysql
basedir = /usr/local/mysql
datadir = /data/mysql/mysql3306/data
port = 3306

socket = /tmp/mysql3306.sock
event_scheduler = 0

tmpdir = /data/mysql/mysql3306/tmp
#timeout
interactive_timeout = 300
wait_timeout = 300

#character set
character-set-server = utf8

open_files_limit = 65535
max_connections = 100
max_connect_errors = 100000
lower_case_table_names =1
#file
#@secure-file-priv=/tmp
#symi replication

#rpl_semi_sync_master_enabled=1
#rpl_semi_sync_master_timeout=1000 # 1 second
#rpl_semi_sync_slave_enabled=1

#logs
log-output=file
slow_query_log = 1
slow_query_log_file = slow.log
log-error = error.log
log_warnings = 2
pid-file = mysql.pid
long_query_time = 1
#log-slow-admin-statements = 1
#log-queries-not-using-indexes = 1
log-slow-slave-statements = 1

#binlog
#binlog_format = STATEMENT
binlog_format = row
server-id = 1003306
log-bin = /data/mysql/mysql3306/logs/mysql-bin
max_binlog_size = 256M
sync_binlog = 0
expire_logs_days = 10
#procedure 
log_bin_trust_function_creators=1

#file
secure_file_priv="/tmp"
#
gtid-mode = on
enforce-gtid-consistency=1


#relay log
#skip_slave_start = 1
max_relay_log_size = 128M
relay_log_purge = 1
relay_log_recovery = 1
relay-log=relay-bin
relay-log-index=relay-bin.index
log_slave_updates

#slave-skip-errors=1032,1053,1062
#skip-grant-tables

#buffers & cache
table_open_cache = 2048
table_definition_cache = 2048
table_open_cache = 2048
max_heap_table_size = 96M
sort_buffer_size = 128K
join_buffer_size = 128K
thread_cache_size = 200
query_cache_size = 0
query_cache_type = 0
query_cache_limit = 256K
query_cache_min_res_unit = 512
thread_stack = 192K
tmp_table_size = 96M
key_buffer_size = 8M
read_buffer_size = 2M
read_rnd_buffer_size = 16M
bulk_insert_buffer_size = 32M

#myisam
myisam_sort_buffer_size = 128M
myisam_max_sort_file_size = 10G
myisam_repair_threads = 1

#innodb
innodb_buffer_pool_size = 100M
innodb_buffer_pool_instances = 1
innodb_data_file_path = ibdata1:100M:autoextend
innodb_flush_log_at_trx_commit = 2
innodb_log_buffer_size = 8M
innodb_log_file_size = 100M
innodb_log_files_in_group = 3
innodb_max_dirty_pages_pct = 50
innodb_file_per_table = 1
innodb_rollback_on_timeout
innodb_io_capacity = 2000
transaction_isolation = READ-COMMITTED
innodb_flush_method = O_DIRECT
[Unit]
Description=MySQL Server
Documentation=man:mysqld(7)
Documentation=http://dev.mysql.com/doc/refman/en/using-systemd.html
After=network.target
After=syslog.target
[Install]
WantedBy=multi-user.target

[Service]
User=mysql
Group=mysql
Type=forking
PIDFile=/data/mysql/mysqld.pid
# Disable service start and stop timeout logic of systemd for mysqld service.
TimeoutSec=0
# Start main service
ExecStart=/usr/local/mysql/bin/mysqld --defaults-file=/etc/my.cnf --daemonize --pid-file=/data/mysql/mysqld.pid $MYSQLD_OPTS 
# Use this to switch malloc implementation
EnvironmentFile=-/etc/sysconfig/mysql
# Sets open_files_limit
LimitNOFILE = 5000
Restart=on-failure
RestartPreventExitStatus=1
PrivateTmp=false
 # 1. 使用yum直接安装MySQL
 # rpm安装方式
yum list installed mysql*  rpm –qa|grep mysql* #检查系统是否安装mysql
yum list mysql* 查看是否有安装包
yum -y install mysql                           #安装MySQL客户端
yum install mysql-server mysql-devel           #安装mysql服务端,如果输入此命令没有报错,则跳过下面步骤,继续安装下一个服务端
    # 如果报错需要输入命令:sudo rpm -Uvh http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm


echo "default-character-set=utf-8">> /etc/my.cnf   #在/etc/my.cnf 文件中加入默认字符集
systemctl start mysql  #启动mysql数据库
mysqladmin -u root password 密码   #创建root管理员


mysql -u root -p    #进入mysql容器
use mysql;  
UPDATE user SET `Host` = '%' WHERE `User` = 'root' LIMIT 1;#设置允许远程访问 
select host from user;
# 0 .前期准备
    rpm -qa | grep mariadb
    rpm -e mariadb* --nodeps #删除系统自带mariadb
  #下在安装所需的程序包
  wget https://github.com/Kitware/CMake/releases/download/v3.23.2/cmake-3.23.2.tar.gz

# 1 .解压

# 2 .创建mysql用户与组,相关目录  
   /usr/sbin/groupadd mysql
   /usr/sbin/useradd -g mysql mysql
   mkdir -p /app/soft/mysql
   chown -R mysql:mysql /app/soft/mysql
   mkdir -p /data/mysqldata
   chown -R mysql:mysql /data/mysqldata/
# 3 .安装





   yum install cmake ncurses-devel gcc gcc-c++ vim lsof bzip2 openssl-devel -y

php

# 1. 解决依赖
yum -y install  libxslt-devel bxml2 libxml2-devel openssl openssl-devel curl-devel libjpeg-devel libpng-devel freetype-devel libmcrypt-devel libzip-devel pcre-devel
# 2. 创建www用户
useradd -M -s /sbin/nologin www

# 3. 解压安装包
cd /work/packages && tar -xf php-7.3.30.tar.gz


# 4. 正在安装PHP...
cd /work/packages/php-7.3.30
./configure --prefix=/usr/local/php --enable-fpm --with-fpm-user=www --with-fpm-group=www --with-curl --with-freetype-dir --with-gd --with-gettext --with-iconv-dir  --with-libdir=lib64 --with-libxml-dir  --with-mysqli --with-pdo-mysql --with-openssl --with-pcre-regex --with-pdo-sqlite --with-pear --with-png-dir --with-xmlrpc --with-xsl  --with-zlib --enable-bcmath --enable-libxml --enable-inline-optimization --enable-mbregex --enable-mbstring --enable-opcache --enable-pcntl --enable-shmop --enable-soap --enable-sockets --enable-sysvsem --enable-xml >&/dev/null


# 5. 正在编译php7
make -j 5  && make install

# 6. 设置命令路径优化
ln -s /usr/local/php/sbin/php-fpm /usr/sbin/
ln -s /usr/local/php/bin/* /bin/
cp /usr/local/php/etc/{php-fpm.conf.default,php-fpm.conf}
cp /usr/local/php/etc/php-fpm.d/{www.conf.default,www.conf}

# 7. 配置php7
cp sapi/fpm/php-fpm.service /usr/lib/systemd/system/
cp php.ini-production /usr/local/php/etc/php.ini
sed -i 's#;date.timezone =#date.timezone = Asia/Shanghai#' /usr/local/php/etc/php.ini
sed -i 's#max_execution_time = .*#max_execution_time = 300#' /usr/local/php/etc/php.ini
sed -i 's#post_max_size =.*#post_max_size = 32M#' /usr/local/php/etc/php.ini
sed -i 's#max_input_time = .*#max_input_time = 300#' /usr/local/php/etc/php.ini

# 8. 启动php-fpm
systemctl enable --now php-fpm

# 9. 测试
# 环境配置
echo "127.0.0.1 www.jd.com" >> /etc/hosts
mkdir -p /data/jd/
echo -e "<?php\n  phpinfo(); \n?>" /data/baidu/index.php

# nginx配置
# /usr/local/nginx/conf/vhost/default.conf
server {
    listen       80;
    server_name  www.jd.com;
    root   /data/jd/;

    location / {
        index  index.html index.php;
    }

    location ~ \.php$ {
      root    /data/jd;
      fastcgi_pass   127.0.0.1:9000;
      fastcgi_index  index.php;
      fastcgi_param  SCRIPT_FILENAME $document_root$fastcgi_script_name;
      include        fastcgi_params;

      #FastCGI 相关参数调优
      fastcgi_cache_valid 200 302 1h;
      fastcgi_cache_valid 301 1d;
      fastcgi_cache_valid any 1m;
      fastcgi_cache_min_uses 1;
      fastcgi_cache_use_stale error timeout invalid_header http_500;
      fastcgi_cache_key http://$host$request_uri;
    }
}

zabbix

# server安装zabbix
# 1.获取zabbix源
rpm -Uvh https://repo.zabbix.com/zabbix/5.0/rhel/7/x86_64/zabbix-release-5.0-1.el7.noarch.rpm
sed -i 's#http://repo.zabbix.com#https://mirrors.aliyun.com/zabbix#g' /etc/yum.repos.d/zabbix.repo
sed -i 's/enabled=0/enabled=1/' /etc/yum.repos.d/zabbix.repo
yum clean all 
yum makecache

# 2.安装zabbix客户端
yum -y install zabbix-server-mysql zabbix-agent2 


# 3.安装多个版本的软件工具,并且不会影响整个系统的依赖环境
yum -y install centos-release-scl

# 4.修改前端源,安装前端环境(并且安装到scl环境下)
或者http安装:yum -y install zabbix-web-mysql-scl zabbix-apache-conf-scl 

或者nginx安装:yum -y install zabbix-web-mysql-scl zabbix-nginx-conf-scl 


# 5.安装数据库,配置数据库开机启动,查看端口
yum -y install mariadb-server mariadb
systemctl enable --now mariadb
netstat -tunlp |grep 3306

# 6.初始化数据库
mysql_secure_installation   [回车--y--password--password--y--n--y--y]
mysql -uroot -p123

# 7.添加数据库用户授权
create database zabbix character set utf8 collate utf8_bin;
create user zabbix@% identified by 'password';
grant all privileges on zabbix.* to zabbix@localhost;
flush privileges;
exit;

# 8.使用zabbix-mysql导入数据库信息【-u用户名 -p 后面是数据库的库名字  然后才需要输入密码】
zcat /usr/share/doc/zabbix-server-mysql*/create.sql.gz | mysql -uzabbix -p zabbix

# 9.修改zabbix密码
vim /etc/zabbix/zabbix_server.conf 
DBPassword=password

# 10.修改php配置
vim /etc/opt/rh/rh-php72/php-fpm.d/zabbix.conf
user = nginx
group = nginx
listen.acl_users = nginx 
php_value[date.timezone] = Asia/Shanghai

vim /etc/opt/rh/rh-php72/php.ini
383 max_execution_time = 300
393 max_input_time = 300
672 post_max_size = 16M
902 date.timezone = Asia/Shanghai


###(如果是Apache忽略)
### 修改nginx配置文件
vim /etc/opt/rh/rh-nginx116/nginx/conf.d/zabbix.conf
listen 80;
server_name 192.168.11.10;
fastcgi_pass    127.0.0.1:9000;
# fastcgi_pass    unix:/var/opt/rh/rh-php72/run/php-fpm/zabbix.sock;

vim /etc/opt/rh/rh-nginx116/nginx/nginx.conf
server {
        #listen       80 default_server;
        #listen       [::]:80 default_server;
        #server_name  _;
        #root         /opt/rh/rh-nginx116/root/usr/share/nginx/html;
        # Load configuration files for the default server block.
        #include      /etc/opt/rh/rh-nginx116/nginx/default.d/*.conf;
}




# 11.启动zabbix相关服务
     # http    systemctl restart zabbix-server zabbix-agent httpd rh-php72-php-fpm
yum -y intstall psmisc
killall nginx
     # nginx   systemctl restart zabbix-server zabbix-agent rh-nginx116-nginx rh-php72-php-fpm

#启动报错或Zabbix server is running    NO
1. 查看日志   tail -5 /var/log/zabbix/zabbix_server.log
2. 检查配置文件
3. 数据库授权问题(可能不让localhost登录)


# 12.访问zabbix入口
http://ip/zabbix
http://ip

# 13.zabbix默认用户密码
U:Admin
P:zabbix
# 同步时间
yum install ntpdate -y
ntpdate -u ntp.aliyun.com

# 14.时区的统一
mv /etc/localtime{,.bak}
ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

# 15.zabbix乱码问题  【zabbix-server安装中文字体】
yum -y install wqy-microhei-fonts
\cp /usr/share/fonts/wqy-microhei/wqy-microhei.ttc /usr/share/fonts/dejavu/DejaVuSans.ttf

java

一、环境配置:

    #1.1新建一个自定义目录用于存放下载或挂载
    mkdir /data/jdk
二、安装
    #2.1将软件包上传服务器并解压
    cd /data/
    tar -xf jdk-8u91-linux-x64.tar.gz
    #2.2移动解压后的文件夹(jdk1.8.0_91)到usr目录下并重命名(/usr/java)
    mv jdk1.8.0_91/ /usr/local/java
    #2.3配置环境变量 (vim /etc/profile)
cp /work/config/java/java.sh /etc/profile.d/
    #2.4重新生效环境变量配置文件
    source /etc/profile
    source /etc/profile.d/java.sh
三、测试
    #3.1使用java命令
    [root@mysql data]# java -version
    java version "1.8.0_91"
    Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
    Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)
export JAVA_HOME=/usr/local/java
export PATH=$PATH:$JAVA_HOME/bin
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export JRE_HOME=$JAVA_HOME/jre

ansible

yum -y install ansible

docker

一、douck介绍
   开源的应用容器引擎,Docker 可以让开发者打包他们的应用以及依赖包到一个轻量级、可移植的容器
   中,然后发布到任何流行的 Linux 机器上,也可以实现虚拟化
二、安装
yum -y install docker
systemctl start docker
docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES

jumpserver

Promethus+grafana

gitlab

jenkins