最近,【运维帮】的公众号发布了一个名为【BigOps】的运维工具;
感觉很不错,于是,打算体验一下。

官方网站:
http://www.bigops.com/

BigOps首页

官方文档:
http://docs.bigops.com/

本文,会从头开始部署BigOps。

开始本文的前提:

  1. 已经有装好的Linux系统,版本:RHEL7 / CentOS7 / OEL7,进制:x86-64

下面开始:


一、准备环境


YUM配置:

[root@linux1 yum.repos.d]# pwd
/etc/yum.repos.d
[root@linux1 yum.repos.d]# 
[root@linux1 yum.repos.d]# ls -ltr
total 4
-rw-r--r-- 1 root root 2492 Jul 10 16:20 tsinghua.repo
[root@linux1 yum.repos.d]# 
[root@linux1 yum.repos.d]# cat tsinghua.repo 
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client.  You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#

[base]
name=CentOS-7 - Base
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/7/os/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=7&arch=$basearch&repo=os
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

#released updates
[updates]
name=CentOS-7 - Updates
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/7/updates/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=7&arch=$basearch&repo=updates
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

#additional packages that may be useful
[extras]
name=CentOS-7 - Extras
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/7/extras/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=7&arch=$basearch&repo=extras
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-7 - Plus
baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos/7/centosplus/$basearch/
#mirrorlist=http://mirrorlist.centos.org/?release=7&arch=$basearch&repo=centosplus
gpgcheck=0
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[epel]
name=Extra Packages for Enterprise Linux 7 - $basearch
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/$basearch
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch
failovermethod=priority
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7

[epel-debuginfo]
name=Extra Packages for Enterprise Linux 7 - $basearch - Debug
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/$basearch/debug
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-debug-7&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
gpgcheck=0

[epel-source]
name=Extra Packages for Enterprise Linux 7 - $basearch - Source
baseurl=https://mirrors.tuna.tsinghua.edu.cn/epel/7/SRPMS
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-source-7&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
gpgcheck=0
[root@linux1 yum.repos.d]# 
[root@linux1 yum.repos.d]# yum repolist
Loaded plugins: langpacks, ulninfo
repo id                          repo name                                                        status
base/x86_64                      CentOS-7 - Base                                                  10,019
epel/x86_64                      Extra Packages for Enterprise Linux 7 - x86_64                   13,291
extras/x86_64                    CentOS-7 - Extras                                                   419
updates/x86_64                   CentOS-7 - Updates                                                2,231
repolist: 25,960
[root@linux1 yum.repos.d]# 

可以看到,YUM配置没有问题。


SELINUX:禁用
防火墙:禁用

[root@linux1 yum.repos.d]# service firewalld status
Redirecting to /bin/systemctl status firewalld.service
● firewalld.service - firewalld - dynamic firewall daemon
   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
   Active: inactive (dead)
     Docs: man:firewalld(1)

Jul 09 16:53:37 linux1 systemd[1]: Starting firewalld - dynamic firewall daemon...
Jul 09 16:53:38 linux1 systemd[1]: Started firewalld - dynamic firewall daemon.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: ICMP type 'beyond-scope' is not supported by the ...pv6.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: beyond-scope: INVALID_ICMPTYPE: No supported ICMP...ime.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: ICMP type 'failed-policy' is not supported by the...pv6.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: failed-policy: INVALID_ICMPTYPE: No supported ICM...ime.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: ICMP type 'reject-route' is not supported by the ...pv6.
Jul 09 16:53:38 linux1 firewalld[745]: WARNING: reject-route: INVALID_ICMPTYPE: No supported ICMP...ime.
Jul 10 16:54:51 linux1 systemd[1]: Stopping firewalld - dynamic firewall daemon...
Jul 10 16:54:51 linux1 systemd[1]: Stopped firewalld - dynamic firewall daemon.
Hint: Some lines were ellipsized, use -l to show in full.
[root@linux1 yum.repos.d]# 
[root@linux1 yum.repos.d]# sestatus
SELinux status:                 disabled
[root@linux1 yum.repos.d]# 

开机启动:关闭与禁用:【防火墙 / SELinux】

[root@center ~]# chkconfig firewalld off
Note: Forwarding request to 'systemctl disable firewalld.service'.
[root@center ~]# 
[root@center ~]# cat /etc/selinux/config 

# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of three two values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected. 
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted 


[root@center ~]# 

文件:/etc/hostname

[root@center ~]# cat /etc/hostname
center.adamhuan.com
[root@center ~]# 
[root@center ~]# hostname
center.adamhuan.com
[root@center ~]# 

文件:/etc/hosts

[root@center bigops]# cat /etc/hosts
#127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
#::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

# Local
127.0.0.1       localhost

# Public
192.168.202.128 linux1

# Big Ops
192.168.202.128 sso.bigops.com
192.168.202.128 work.bigops.com
[root@center bigops]# 

你的当前主机名,以及SSO和WORK的解析。


调整【Linux】系统配置:

文件:/etc/security/limits.conf

[root@center ~]# cat /etc/security/limits.conf 
# /etc/security/limits.conf
#
#This file sets the resource limits for the users logged in via PAM.
#It does not affect resource limits of the system services.
#
#Also note that configuration files in /etc/security/limits.d directory,
#which are read in alphabetical order, override the settings in this
#file in case the domain is the same or more specific.
#That means for example that setting a limit for wildcard domain here
#can be overriden with a wildcard setting in a config file in the
#subdirectory, but a user specific setting here can be overriden only
#with a user specific setting in the subdirectory.
#
#Each line describes a limit for a user in the form:
#
#<domain>        <type>  <item>  <value>
#
#Where:
#<domain> can be:
#        - a user name
#        - a group name, with @group syntax
#        - the wildcard *, for default entry
#        - the wildcard %, can be also used with %group syntax,
#                 for maxlogin limit
#
#<type> can have the two values:
#        - "soft" for enforcing the soft limits
#        - "hard" for enforcing hard limits
#
#<item> can be one of the following:
#        - core - limits the core file size (KB)
#        - data - max data size (KB)
#        - fsize - maximum filesize (KB)
#        - memlock - max locked-in-memory address space (KB)
#        - nofile - max number of open file descriptors
#        - rss - max resident set size (KB)
#        - stack - max stack size (KB)
#        - cpu - max CPU time (MIN)
#        - nproc - max number of processes
#        - as - address space limit (KB)
#        - maxlogins - max number of logins for this user
#        - maxsyslogins - max number of logins on the system
#        - priority - the priority to run user process with
#        - locks - max number of file locks the user can hold
#        - sigpending - max number of pending signals
#        - msgqueue - max memory used by POSIX message queues (bytes)
#        - nice - max nice priority allowed to raise to values: [-20, 19]
#        - rtprio - max realtime priority
#
#<domain>      <type>  <item>         <value>
#

#*               soft    core            0
#*               hard    rss             10000
#@student        hard    nproc           20
#@faculty        soft    nproc           20
#@faculty        hard    nproc           50
#ftp             hard    nproc           0
#@student        -       maxlogins       4

# End of file
[root@center ~]# 
[root@center ~]# sed -i '/^[^#].*/d' /etc/security/limits.conf
[root@center ~]# echo -e "*\t\tsoft\tnofile\t\t655360">>/etc/security/limits.conf
[root@center ~]# echo -e "*\t\thard\tnofile\t\t655360">>/etc/security/limits.conf
[root@center ~]# echo -e "*\t\tsoft\tmemlock\t\tunlimited">>/etc/security/limits.conf
[root@center ~]# echo -e "*\t\thard\tmemlock \tunlimited">>/etc/security/limits.conf
[root@center ~]# 
[root@center ~]# cat /etc/security/limits.conf 
# /etc/security/limits.conf
#
#This file sets the resource limits for the users logged in via PAM.
#It does not affect resource limits of the system services.
#
#Also note that configuration files in /etc/security/limits.d directory,
#which are read in alphabetical order, override the settings in this
#file in case the domain is the same or more specific.
#That means for example that setting a limit for wildcard domain here
#can be overriden with a wildcard setting in a config file in the
#subdirectory, but a user specific setting here can be overriden only
#with a user specific setting in the subdirectory.
#
#Each line describes a limit for a user in the form:
#
#<domain>        <type>  <item>  <value>
#
#Where:
#<domain> can be:
#        - a user name
#        - a group name, with @group syntax
#        - the wildcard *, for default entry
#        - the wildcard %, can be also used with %group syntax,
#                 for maxlogin limit
#
#<type> can have the two values:
#        - "soft" for enforcing the soft limits
#        - "hard" for enforcing hard limits
#
#<item> can be one of the following:
#        - core - limits the core file size (KB)
#        - data - max data size (KB)
#        - fsize - maximum filesize (KB)
#        - memlock - max locked-in-memory address space (KB)
#        - nofile - max number of open file descriptors
#        - rss - max resident set size (KB)
#        - stack - max stack size (KB)
#        - cpu - max CPU time (MIN)
#        - nproc - max number of processes
#        - as - address space limit (KB)
#        - maxlogins - max number of logins for this user
#        - maxsyslogins - max number of logins on the system
#        - priority - the priority to run user process with
#        - locks - max number of file locks the user can hold
#        - sigpending - max number of pending signals
#        - msgqueue - max memory used by POSIX message queues (bytes)
#        - nice - max nice priority allowed to raise to values: [-20, 19]
#        - rtprio - max realtime priority
#
#<domain>      <type>  <item>         <value>
#

#*               soft    core            0
#*               hard    rss             10000
#@student        hard    nproc           20
#@faculty        soft    nproc           20
#@faculty        hard    nproc           50
#ftp             hard    nproc           0
#@student        -       maxlogins       4

# End of file
*               soft    nofile          655360
*               hard    nofile          655360
*               soft    memlock         unlimited
*               hard    memlock         unlimited
[root@center ~]# 
[root@center ~]# 

目录: /etc/security/limits.d
文件: /etc/security/limits.d/90-nproc.conf

[root@center ~]# ls -ltr /etc/security/limits.d/
total 4
-rw-r--r--. 1 root root 191 Sep  3  2016 20-nproc.conf
[root@center ~]# 
[root@center ~]# cat /etc/security/limits.d/20-nproc.conf 
# Default limit for number of user's processes to prevent
# accidental fork bombs.
# See rhbz #432903 for reasoning.

*          soft    nproc     4096
root       soft    nproc     unlimited
[root@center ~]# 
[root@center ~]# rm -rf /etc/security/limits.d/*
[root@center ~]# 
[root@center ~]# ls -ltr /etc/security/limits.d/          
total 0
[root@center ~]# 
[root@center ~]# echo -e "*\t\tsoft\tnproc\t\t655360">/etc/security/limits.d/90-nproc.conf
[root@center ~]# echo -e "*\t\thard\tnproc\t\t655360">>/etc/security/limits.d/90-nproc.conf
[root@center ~]# 
[root@center ~]# ls -ltr /etc/security/limits.d/                                           
total 4
-rw-r--r-- 1 root root 44 Jul 10 21:26 90-nproc.conf
[root@center ~]# 
[root@center ~]# cat /etc/security/limits.d/90-nproc.conf 
*               soft    nproc           655360
*               hard    nproc           655360
[root@center ~]# 

二、从官方网站下载安装介质,上传服务器,并解压到目标路径

官方下载页面:
http://www.bigops.com/dl.html

[root@center bigops]# pwd
/software/bigops
[root@center bigops]# 
[root@center bigops]# ls -ltr
total 569996
-rw-r--r-- 1 root root 583673798 Jul  9 12:57 bigops-1.0.0.tar.gz
[root@center bigops]# 
[root@center bigops]# ls -ltr /opt
total 0
drwxr-xr-x. 2 root root 6 Mar 26  2015 rh
[root@center bigops]# 
[root@center bigops]# tar -xzf bigops-1.0.0.tar.gz -C /opt/
[root@center bigops]# 
[root@center bigops]# ls -ltr /opt/
total 0
drwxr-xr-x.  2 root root   6 Mar 26  2015 rh
drwxr-xr-x  12 root root 133 Jul  8 19:32 bigops-1.0.0
[root@center bigops]# 
[root@center bigops]# ls -ltr /opt/bigops-1.0.0/
total 4
drwxr-xr-x 2 root root   23 Jul  8 09:45 ipdb
drwxr-xr-x 7 root root 4096 Jul  8 09:47 java
drwxr-xr-x 5 root root   49 Jul  8 09:50 repo
drwxr-xr-x 3 root root   19 Jul  8 10:01 install
drwxr-xr-x 4 root root  136 Jul  8 10:04 sbin
drwxr-xr-x 9 root root   91 Jul  8 11:34 sso
drwxr-xr-x 9 root root   91 Jul  8 11:35 workbe
drwxr-xr-x 4 root root  118 Jul  8 16:06 config
drwxr-xr-x 3 root root   55 Jul  8 19:18 workfe
drwxr-xr-x 2 root root   95 Jul  8 19:48 bin
[root@center bigops]# 
[root@center bigops]# du -sh *
557M    bigops-1.0.0.tar.gz
[root@center bigops]# 
[root@center bigops]# du -sh /opt/bigops-1.0.0/
818M    /opt/bigops-1.0.0/
[root@center bigops]# 
[root@center bigops]# mv /opt/bigops-1.0.0/ /opt/bigops/
[root@center bigops]# 
[root@center bigops]# ls -ltr /opt/
total 0
drwxr-xr-x.  2 root root   6 Mar 26  2015 rh
drwxr-xr-x  12 root root 133 Jul  8 19:32 bigops
[root@center bigops]# 

可以看到,官网下载的压缩包的内容都解压到了路径:/opt/bigops


三、数据库:MySQL(版本:8.x)
这一部分,也可以看我以前的文档,有很多涉及这个方面的:
http://d-prototype.com/archives/tag/mysql

对于BigOps来说,支持的MySQL版本是:5.7 / 8.0

配置MySQL8.x的YUM:

[root@center ~]# ls -ltr /etc/yum.repos.d/
total 8
-rw-r--r-- 1 root root 2492 Jul 10 16:20 tsinghua.repo
-rw-r--r-- 1 root root  192 Jul 10 21:42 mysql8.repo
[root@center ~]# 
[root@center ~]# cat /etc/yum.repos.d/mysql8.repo 
[mysql80-community]
name=MySQL 8.0 Community Server
baseurl=http://repo.mysql.com/yum/mysql-8.0-community/el/7/$basearch/
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
[root@center ~]# 
[root@center ~]# yum repolist
Loaded plugins: langpacks, ulninfo
mysql80-community                                                                | 2.5 kB  00:00:00     
mysql80-community/x86_64/primary_db                                              |  70 kB  00:00:04     
repo id                               repo name                                                   status
base/x86_64                           CentOS-7 - Base                                             10,019
epel/x86_64                           Extra Packages for Enterprise Linux 7 - x86_64              13,291
extras/x86_64                         CentOS-7 - Extras                                              419
mysql80-community/x86_64              MySQL 8.0 Community Server                                     113
updates/x86_64                        CentOS-7 - Updates                                           2,231
repolist: 26,073
[root@center ~]# 

使用YUM安装MySQL8:

[root@center ~]# yum list | grep mysql80
mysql-community-client.i686               8.0.16-2.el7             mysql80-community
mysql-community-client.x86_64             8.0.16-2.el7             mysql80-community
mysql-community-common.i686               8.0.16-2.el7             mysql80-community
mysql-community-common.x86_64             8.0.16-2.el7             mysql80-community
mysql-community-devel.i686                8.0.16-2.el7             mysql80-community
mysql-community-devel.x86_64              8.0.16-2.el7             mysql80-community
mysql-community-embedded-compat.i686      8.0.16-2.el7             mysql80-community
mysql-community-embedded-compat.x86_64    8.0.16-2.el7             mysql80-community
mysql-community-libs.i686                 8.0.16-2.el7             mysql80-community
mysql-community-libs.x86_64               8.0.16-2.el7             mysql80-community
mysql-community-libs-compat.i686          8.0.16-2.el7             mysql80-community
mysql-community-libs-compat.x86_64        8.0.16-2.el7             mysql80-community
mysql-community-server.x86_64             8.0.16-2.el7             mysql80-community
mysql-community-test.x86_64               8.0.16-2.el7             mysql80-community
                                          1-20190415               mysql80-community
mysql-ref-manual-8.0-en-pdf.noarch        1-20190415               mysql80-community
mysql80-community-release.noarch          el7-3                    mysql80-community
[root@center ~]# 
[root@center ~]# yum -y install mysql-community-server mysql-community-client mysql-community-devel mysql-community-libs-compat
Loaded plugins: langpacks, ulninfo
Resolving Dependencies
--> Running transaction check
---> Package mysql-community-client.x86_64 0:8.0.16-2.el7 will be installed
--> Processing Dependency: mysql-community-libs(x86-64) >= 8.0.11 for package: mysql-community-client-8.0.16-2.el7.x86_64
---> Package mysql-community-devel.x86_64 0:8.0.16-2.el7 will be installed
--> Processing Dependency: pkgconfig(openssl) for package: mysql-community-devel-8.0.16-2.el7.x86_64
---> Package mysql-community-libs-compat.x86_64 0:5.7.19-1.el7 will be updated
---> Package mysql-community-libs-compat.x86_64 0:8.0.16-2.el7 will be an update
---> Package mysql-community-server.x86_64 0:8.0.16-2.el7 will be installed
--> Processing Dependency: mysql-community-common(x86-64) = 8.0.16-2.el7 for package: mysql-community-server-8.0.16-2.el7.x86_64
--> Running transaction check
---> Package mysql-community-common.x86_64 0:5.7.19-1.el7 will be updated
---> Package mysql-community-common.x86_64 0:8.0.16-2.el7 will be an update
---> Package mysql-community-libs.x86_64 0:5.7.19-1.el7 will be updated
---> Package mysql-community-libs.x86_64 0:8.0.16-2.el7 will be an update
---> Package openssl-devel.x86_64 1:1.0.2k-16.el7_6.1 will be installed
--> Processing Dependency: openssl-libs(x86-64) = 1:1.0.2k-16.el7_6.1 for package: 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64
--> Processing Dependency: zlib-devel(x86-64) for package: 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64
--> Processing Dependency: krb5-devel(x86-64) for package: 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64
--> Running transaction check
---> Package krb5-devel.x86_64 0:1.15.1-37.el7_6 will be installed
--> Processing Dependency: libkadm5(x86-64) = 1.15.1-37.el7_6 for package: krb5-devel-1.15.1-37.el7_6.x86_64
--> Processing Dependency: krb5-libs(x86-64) = 1.15.1-37.el7_6 for package: krb5-devel-1.15.1-37.el7_6.x86_64
--> Processing Dependency: libverto-devel for package: krb5-devel-1.15.1-37.el7_6.x86_64
--> Processing Dependency: libselinux-devel for package: krb5-devel-1.15.1-37.el7_6.x86_64
--> Processing Dependency: libcom_err-devel for package: krb5-devel-1.15.1-37.el7_6.x86_64
--> Processing Dependency: keyutils-libs-devel for package: krb5-devel-1.15.1-37.el7_6.x86_64
---> Package openssl-libs.x86_64 1:1.0.2k-8.0.1.el7 will be updated
--> Processing Dependency: openssl-libs(x86-64) = 1:1.0.2k-8.0.1.el7 for package: 1:openssl-1.0.2k-8.0.1.el7.x86_64
---> Package openssl-libs.x86_64 1:1.0.2k-16.el7_6.1 will be an update
---> Package zlib-devel.x86_64 0:1.2.7-18.el7 will be installed
--> Processing Dependency: zlib = 1.2.7-18.el7 for package: zlib-devel-1.2.7-18.el7.x86_64
--> Running transaction check
---> Package keyutils-libs-devel.x86_64 0:1.5.8-3.el7 will be installed
---> Package krb5-libs.x86_64 0:1.15.1-8.el7 will be updated
---> Package krb5-libs.x86_64 0:1.15.1-37.el7_6 will be an update
---> Package libcom_err-devel.x86_64 0:1.42.9-13.el7 will be installed
--> Processing Dependency: libcom_err(x86-64) = 1.42.9-13.el7 for package: libcom_err-devel-1.42.9-13.el7.x86_64
---> Package libkadm5.x86_64 0:1.15.1-37.el7_6 will be installed
---> Package libselinux-devel.x86_64 0:2.5-14.1.el7 will be installed
--> Processing Dependency: libselinux(x86-64) = 2.5-14.1.el7 for package: libselinux-devel-2.5-14.1.el7.x86_64
--> Processing Dependency: libsepol-devel(x86-64) >= 2.5-10 for package: libselinux-devel-2.5-14.1.el7.x86_64
--> Processing Dependency: pkgconfig(libsepol) for package: libselinux-devel-2.5-14.1.el7.x86_64
--> Processing Dependency: pkgconfig(libpcre) for package: libselinux-devel-2.5-14.1.el7.x86_64
---> Package libverto-devel.x86_64 0:0.2.5-4.el7 will be installed
---> Package openssl.x86_64 1:1.0.2k-8.0.1.el7 will be updated
---> Package openssl.x86_64 1:1.0.2k-16.el7_6.1 will be an update
---> Package zlib.x86_64 0:1.2.7-17.el7 will be updated
---> Package zlib.x86_64 0:1.2.7-18.el7 will be an update
--> Running transaction check
---> Package libcom_err.x86_64 0:1.42.9-10.0.1.el7 will be updated
--> Processing Dependency: libcom_err(x86-64) = 1.42.9-10.0.1.el7 for package: e2fsprogs-libs-1.42.9-10.0.1.el7.x86_64
--> Processing Dependency: libcom_err(x86-64) = 1.42.9-10.0.1.el7 for package: libss-1.42.9-10.0.1.el7.x86_64
--> Processing Dependency: libcom_err(x86-64) = 1.42.9-10.0.1.el7 for package: e2fsprogs-1.42.9-10.0.1.el7.x86_64
---> Package libcom_err.x86_64 0:1.42.9-13.el7 will be an update
---> Package libselinux.x86_64 0:2.5-11.el7 will be updated
--> Processing Dependency: libselinux(x86-64) = 2.5-11.el7 for package: libselinux-utils-2.5-11.el7.x86_64
--> Processing Dependency: libselinux(x86-64) = 2.5-11.el7 for package: libselinux-python-2.5-11.el7.x86_64
---> Package libselinux.x86_64 0:2.5-14.1.el7 will be an update
--> Processing Dependency: libsepol(x86-64) >= 2.5-10 for package: libselinux-2.5-14.1.el7.x86_64
---> Package libsepol-devel.x86_64 0:2.5-10.el7 will be installed
---> Package pcre-devel.x86_64 0:8.32-17.el7 will be installed
--> Running transaction check
---> Package e2fsprogs.x86_64 0:1.42.9-10.0.1.el7 will be updated
---> Package e2fsprogs.x86_64 0:1.42.9-13.el7 will be an update
---> Package e2fsprogs-libs.x86_64 0:1.42.9-10.0.1.el7 will be updated
---> Package e2fsprogs-libs.x86_64 0:1.42.9-13.el7 will be an update
---> Package libselinux-python.x86_64 0:2.5-11.el7 will be updated
---> Package libselinux-python.x86_64 0:2.5-14.1.el7 will be an update
---> Package libselinux-utils.x86_64 0:2.5-11.el7 will be updated
---> Package libselinux-utils.x86_64 0:2.5-14.1.el7 will be an update
---> Package libsepol.x86_64 0:2.5-6.el7 will be updated
---> Package libsepol.x86_64 0:2.5-10.el7 will be an update
---> Package libss.x86_64 0:1.42.9-10.0.1.el7 will be updated
---> Package libss.x86_64 0:1.42.9-13.el7 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package                           Arch         Version                   Repository               Size
========================================================================================================
Installing:
 mysql-community-client            x86_64       8.0.16-2.el7              mysql80-community        32 M
 mysql-community-devel             x86_64       8.0.16-2.el7              mysql80-community       5.4 M
 mysql-community-server            x86_64       8.0.16-2.el7              mysql80-community       403 M
Updating:
 mysql-community-libs-compat       x86_64       8.0.16-2.el7              mysql80-community       2.1 M
Installing for dependencies:
 keyutils-libs-devel               x86_64       1.5.8-3.el7               base                     37 k
 krb5-devel                        x86_64       1.15.1-37.el7_6           updates                 271 k
 libcom_err-devel                  x86_64       1.42.9-13.el7             base                     31 k
 libkadm5                          x86_64       1.15.1-37.el7_6           updates                 178 k
 libselinux-devel                  x86_64       2.5-14.1.el7              base                    187 k
 libsepol-devel                    x86_64       2.5-10.el7                base                     77 k
 libverto-devel                    x86_64       0.2.5-4.el7               base                     12 k
 openssl-devel                     x86_64       1:1.0.2k-16.el7_6.1       updates                 1.5 M
 pcre-devel                        x86_64       8.32-17.el7               base                    480 k
 zlib-devel                        x86_64       1.2.7-18.el7              base                     50 k
Updating for dependencies:
 e2fsprogs                         x86_64       1.42.9-13.el7             base                    699 k
 e2fsprogs-libs                    x86_64       1.42.9-13.el7             base                    167 k
 krb5-libs                         x86_64       1.15.1-37.el7_6           updates                 803 k
 libcom_err                        x86_64       1.42.9-13.el7             base                     41 k
 libselinux                        x86_64       2.5-14.1.el7              base                    162 k
 libselinux-python                 x86_64       2.5-14.1.el7              base                    235 k
 libselinux-utils                  x86_64       2.5-14.1.el7              base                    151 k
 libsepol                          x86_64       2.5-10.el7                base                    297 k
 libss                             x86_64       1.42.9-13.el7             base                     46 k
 mysql-community-common            x86_64       8.0.16-2.el7              mysql80-community       575 k
 mysql-community-libs              x86_64       8.0.16-2.el7              mysql80-community       3.0 M
 openssl                           x86_64       1:1.0.2k-16.el7_6.1       updates                 493 k
 openssl-libs                      x86_64       1:1.0.2k-16.el7_6.1       updates                 1.2 M
 zlib                              x86_64       1.2.7-18.el7              base                     90 k

Transaction Summary
========================================================================================================
Install  3 Packages (+10 Dependent packages)
Upgrade  1 Package  (+14 Dependent packages)

Total size: 453 M
Total download size: 5.4 M
Downloading packages:
No Presto metadata available for mysql80-community
mysql-community-devel-8.0.16-2.el7.x86_64.rpm                                    | 5.4 MB  00:02:08     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Updating   : libcom_err-1.42.9-13.el7.x86_64                                                     1/43 
  Updating   : libsepol-2.5-10.el7.x86_64                                                          2/43 
  Updating   : libselinux-2.5-14.1.el7.x86_64                                                      3/43 
  Updating   : zlib-1.2.7-18.el7.x86_64                                                            4/43 
  Updating   : 1:openssl-libs-1.0.2k-16.el7_6.1.x86_64                                             5/43 
  Updating   : krb5-libs-1.15.1-37.el7_6.x86_64                                                    6/43 
  Updating   : mysql-community-common-8.0.16-2.el7.x86_64                                          7/43 
  Updating   : mysql-community-libs-8.0.16-2.el7.x86_64                                            8/43 
  Installing : mysql-community-client-8.0.16-2.el7.x86_64                                          9/43 
  Installing : libkadm5-1.15.1-37.el7_6.x86_64                                                    10/43 
  Installing : zlib-devel-1.2.7-18.el7.x86_64                                                     11/43 
  Installing : libsepol-devel-2.5-10.el7.x86_64                                                   12/43 
  Installing : libcom_err-devel-1.42.9-13.el7.x86_64                                              13/43 
  Updating   : libss-1.42.9-13.el7.x86_64                                                         14/43 
  Updating   : e2fsprogs-libs-1.42.9-13.el7.x86_64                                                15/43 
  Installing : libverto-devel-0.2.5-4.el7.x86_64                                                  16/43 
  Installing : pcre-devel-8.32-17.el7.x86_64                                                      17/43 
  Installing : libselinux-devel-2.5-14.1.el7.x86_64                                               18/43 
  Installing : keyutils-libs-devel-1.5.8-3.el7.x86_64                                             19/43 
  Installing : krb5-devel-1.15.1-37.el7_6.x86_64                                                  20/43 
  Installing : 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64                                           21/43 
  Installing : mysql-community-devel-8.0.16-2.el7.x86_64                                          22/43 
  Updating   : e2fsprogs-1.42.9-13.el7.x86_64                                                     23/43 
  Installing : mysql-community-server-8.0.16-2.el7.x86_64                                         24/43 
  Updating   : mysql-community-libs-compat-8.0.16-2.el7.x86_64                                    25/43 
  Updating   : 1:openssl-1.0.2k-16.el7_6.1.x86_64                                                 26/43 
  Updating   : libselinux-python-2.5-14.1.el7.x86_64                                              27/43 
  Updating   : libselinux-utils-2.5-14.1.el7.x86_64                                               28/43 
  Cleanup    : 1:openssl-1.0.2k-8.0.1.el7.x86_64                                                  29/43 
  Cleanup    : e2fsprogs-1.42.9-10.0.1.el7.x86_64                                                 30/43 
  Cleanup    : 1:openssl-libs-1.0.2k-8.0.1.el7.x86_64                                             31/43 
  Cleanup    : krb5-libs-1.15.1-8.el7.x86_64                                                      32/43 
  Cleanup    : libselinux-utils-2.5-11.el7.x86_64                                                 33/43 
  Cleanup    : e2fsprogs-libs-1.42.9-10.0.1.el7.x86_64                                            34/43 
  Cleanup    : libss-1.42.9-10.0.1.el7.x86_64                                                     35/43 
  Cleanup    : libselinux-python-2.5-11.el7.x86_64                                                36/43 
  Cleanup    : libselinux-2.5-11.el7.x86_64                                                       37/43 
  Cleanup    : mysql-community-libs-compat-5.7.19-1.el7.x86_64                                    38/43 
  Cleanup    : mysql-community-libs-5.7.19-1.el7.x86_64                                           39/43 
  Cleanup    : mysql-community-common-5.7.19-1.el7.x86_64                                         40/43 
  Cleanup    : libsepol-2.5-6.el7.x86_64                                                          41/43 
  Cleanup    : libcom_err-1.42.9-10.0.1.el7.x86_64                                                42/43 
  Cleanup    : zlib-1.2.7-17.el7.x86_64                                                           43/43 
  Verifying  : mysql-community-libs-8.0.16-2.el7.x86_64                                            1/43 
  Verifying  : keyutils-libs-devel-1.5.8-3.el7.x86_64                                              2/43 
  Verifying  : pcre-devel-8.32-17.el7.x86_64                                                       3/43 
  Verifying  : mysql-community-common-8.0.16-2.el7.x86_64                                          4/43 
  Verifying  : libcom_err-devel-1.42.9-13.el7.x86_64                                               5/43 
  Verifying  : krb5-devel-1.15.1-37.el7_6.x86_64                                                   6/43 
  Verifying  : e2fsprogs-1.42.9-13.el7.x86_64                                                      7/43 
  Verifying  : libverto-devel-0.2.5-4.el7.x86_64                                                   8/43 
  Verifying  : mysql-community-libs-compat-8.0.16-2.el7.x86_64                                     9/43 
  Verifying  : zlib-devel-1.2.7-18.el7.x86_64                                                     10/43 
  Verifying  : krb5-libs-1.15.1-37.el7_6.x86_64                                                   11/43 
  Verifying  : mysql-community-devel-8.0.16-2.el7.x86_64                                          12/43 
  Verifying  : zlib-1.2.7-18.el7.x86_64                                                           13/43 
  Verifying  : 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64                                           14/43 
  Verifying  : 1:openssl-1.0.2k-16.el7_6.1.x86_64                                                 15/43 
  Verifying  : libss-1.42.9-13.el7.x86_64                                                         16/43 
  Verifying  : libsepol-2.5-10.el7.x86_64                                                         17/43 
  Verifying  : 1:openssl-libs-1.0.2k-16.el7_6.1.x86_64                                            18/43 
  Verifying  : mysql-community-server-8.0.16-2.el7.x86_64                                         19/43 
  Verifying  : libsepol-devel-2.5-10.el7.x86_64                                                   20/43 
  Verifying  : libselinux-python-2.5-14.1.el7.x86_64                                              21/43 
  Verifying  : e2fsprogs-libs-1.42.9-13.el7.x86_64                                                22/43 
  Verifying  : libselinux-utils-2.5-14.1.el7.x86_64                                               23/43 
  Verifying  : mysql-community-client-8.0.16-2.el7.x86_64                                         24/43 
  Verifying  : libkadm5-1.15.1-37.el7_6.x86_64                                                    25/43 
  Verifying  : libselinux-devel-2.5-14.1.el7.x86_64                                               26/43 
  Verifying  : libcom_err-1.42.9-13.el7.x86_64                                                    27/43 
  Verifying  : libselinux-2.5-14.1.el7.x86_64                                                     28/43 
  Verifying  : libselinux-2.5-11.el7.x86_64                                                       29/43 
  Verifying  : mysql-community-libs-compat-5.7.19-1.el7.x86_64                                    30/43 
  Verifying  : libselinux-utils-2.5-11.el7.x86_64                                                 31/43 
  Verifying  : e2fsprogs-libs-1.42.9-10.0.1.el7.x86_64                                            32/43 
  Verifying  : libcom_err-1.42.9-10.0.1.el7.x86_64                                                33/43 
  Verifying  : mysql-community-libs-5.7.19-1.el7.x86_64                                           34/43 
  Verifying  : libss-1.42.9-10.0.1.el7.x86_64                                                     35/43 
  Verifying  : zlib-1.2.7-17.el7.x86_64                                                           36/43 
  Verifying  : mysql-community-common-5.7.19-1.el7.x86_64                                         37/43 
  Verifying  : libsepol-2.5-6.el7.x86_64                                                          38/43 
  Verifying  : e2fsprogs-1.42.9-10.0.1.el7.x86_64                                                 39/43 
  Verifying  : 1:openssl-libs-1.0.2k-8.0.1.el7.x86_64                                             40/43 
  Verifying  : libselinux-python-2.5-11.el7.x86_64                                                41/43 
  Verifying  : 1:openssl-1.0.2k-8.0.1.el7.x86_64                                                  42/43 
  Verifying  : krb5-libs-1.15.1-8.el7.x86_64                                                      43/43 

Installed:
  mysql-community-client.x86_64 0:8.0.16-2.el7        mysql-community-devel.x86_64 0:8.0.16-2.el7       
  mysql-community-server.x86_64 0:8.0.16-2.el7       

Dependency Installed:
  keyutils-libs-devel.x86_64 0:1.5.8-3.el7           krb5-devel.x86_64 0:1.15.1-37.el7_6               
  libcom_err-devel.x86_64 0:1.42.9-13.el7            libkadm5.x86_64 0:1.15.1-37.el7_6                 
  libselinux-devel.x86_64 0:2.5-14.1.el7             libsepol-devel.x86_64 0:2.5-10.el7                
  libverto-devel.x86_64 0:0.2.5-4.el7                openssl-devel.x86_64 1:1.0.2k-16.el7_6.1          
  pcre-devel.x86_64 0:8.32-17.el7                    zlib-devel.x86_64 0:1.2.7-18.el7                  

Updated:
  mysql-community-libs-compat.x86_64 0:8.0.16-2.el7                                                     

Dependency Updated:
  e2fsprogs.x86_64 0:1.42.9-13.el7                  e2fsprogs-libs.x86_64 0:1.42.9-13.el7              
  krb5-libs.x86_64 0:1.15.1-37.el7_6                libcom_err.x86_64 0:1.42.9-13.el7                  
  libselinux.x86_64 0:2.5-14.1.el7                  libselinux-python.x86_64 0:2.5-14.1.el7            
  libselinux-utils.x86_64 0:2.5-14.1.el7            libsepol.x86_64 0:2.5-10.el7                       
  libss.x86_64 0:1.42.9-13.el7                      mysql-community-common.x86_64 0:8.0.16-2.el7       
  mysql-community-libs.x86_64 0:8.0.16-2.el7        openssl.x86_64 1:1.0.2k-16.el7_6.1                 
  openssl-libs.x86_64 1:1.0.2k-16.el7_6.1           zlib.x86_64 0:1.2.7-18.el7                         

Complete!
[root@center ~]# 

设置开机启动:

[root@center ~]# chkconfig mysqld on
Note: Forwarding request to 'systemctl enable mysqld.service'.
[root@center ~]# 

启动服务:

[root@center ~]# service mysqld status
Redirecting to /bin/systemctl status mysqld.service
● mysqld.service - MySQL Server
   Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
   Active: inactive (dead)
     Docs: man:mysqld(8)
           http://dev.mysql.com/doc/refman/en/using-systemd.html
[root@center ~]# 
[root@center ~]# service mysqld start
Redirecting to /bin/systemctl start mysqld.service
[root@center ~]# 
[root@center ~]# service mysqld status
Redirecting to /bin/systemctl status mysqld.service
● mysqld.service - MySQL Server
   Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
   Active: active (running) since Wed 2019-07-10 22:22:02 CST; 9s ago
     Docs: man:mysqld(8)
           http://dev.mysql.com/doc/refman/en/using-systemd.html
  Process: 2384 ExecStartPre=/usr/bin/mysqld_pre_systemd (code=exited, status=0/SUCCESS)
 Main PID: 2481 (mysqld)
   Status: "SERVER_OPERATING"
   CGroup: /system.slice/mysqld.service
           └─2481 /usr/sbin/mysqld

Jul 10 22:21:41 center.adamhuan.com systemd[1]: Starting MySQL Server...
Jul 10 22:22:02 center.adamhuan.com systemd[1]: Started MySQL Server.
[root@center ~]# 

服务启动后:

[root@center ~]# netstat -tupln | grep mysql
tcp6       0      0 :::3306                 :::*                    LISTEN      2481/mysqld         
tcp6       0      0 :::33060                :::*                    LISTEN      2481/mysqld         
[root@center ~]# 
[root@center ~]# ps -ef | grep mysql
mysql     2481     1  1 22:22 ?        00:00:01 /usr/sbin/mysqld
root      2575  1414  0 22:23 pts/0    00:00:00 grep --color=auto mysql
[root@center ~]# 

修改MySQL的默认随机口令:

[root@center ~]# egrep 'temporary password' /var/log/mysqld.log
2019-07-10T14:21:59.135687Z 5 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: r3zrSkrxta*h
[root@center ~]# 
[root@center ~]# mysqladmin -u root -p password "****"
Enter password: 
mysqladmin: [Warning] Using a password on the command line interface can be insecure.
Warning: Since password will be sent to server in plain text, use ssl connection to ensure password safety.
[root@center ~]# 

访问MySQL数据库,并做用户权限的设置:

[root@center ~]# mysql -u root -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 8.0.16 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> 
mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
| sys                |
+--------------------+
4 rows in set (0.01 sec)

mysql> 
mysql> select user,host from mysql.user;
+------------------+-----------+
| user             | host      |
+------------------+-----------+
| mysql.infoschema | localhost |
| mysql.session    | localhost |
| mysql.sys        | localhost |
| root             | localhost |
+------------------+-----------+
4 rows in set (0.00 sec)

mysql> 
mysql> alter user root@'127.0.0.1' identified with mysql_native_password by '****' password expire never;
Query OK, 0 rows affected (0.00 sec)

mysql>
mysql> grant all privileges on *.* to root@'127.0.0.1';
Query OK, 0 rows affected (0.01 sec)

mysql> 
mysql> select user,host from mysql.user;
+------------------+-----------+
| user             | host      |
+------------------+-----------+
| root             | 127.0.0.1 |
| mysql.infoschema | localhost |
| mysql.session    | localhost |
| mysql.sys        | localhost |
| root             | localhost |
+------------------+-----------+
5 rows in set (0.00 sec)

mysql> 

修改MySQL的参数文件:

[root@center ~]# cat /etc/my.cnf | grep -v "^#"

[mysqld]

datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock

log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

innodb_buffer_pool_size=1G
[root@center ~]# 

可以看到,增加了参数【innodb_buffer_pool_size】;
该参数,通常是服务器真实内存的【60%】;

重启MySQL,以便于刚刚增加的参数【innodb_buffer_pool_size】生效:

[root@center ~]# service mysqld restart
Redirecting to /bin/systemctl restart mysqld.service
[root@center ~]# 

然后,查看下参数现在的设置状态:

[root@center ~]# mysql -u root -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.16 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> 
mysql> show variables like 'innodb_buffer_pool_size';
+-------------------------+------------+
| Variable_name           | Value      |
+-------------------------+------------+
| innodb_buffer_pool_size | 1073741824 |
+-------------------------+------------+
1 row in set (0.00 sec)

mysql> 

这样,数据库的相关设置,就暂告一段落。


四、二进制安装(手动版本)

  1. 创建数据库
  2. 导入数据
  3. 安装:Medusa
  4. 安装Ansible
  5. 安装:jq / json
  6. 安装:Nmap
  7. 安装:Nginx
  8. 设置配置文件

配置数据库并导入数据:

[root@center install]# pwd
/opt/bigops/install
[root@center install]# 
[root@center install]# ls -ltr
total 4
drwxr-xr-x 2 root root  30 Jul  8 10:48 mysql
-rw-r--r-- 1 root root 231 Jul  9 23:57 ansible.cfg
drwxr-xr-x 2 root root  70 Jul 10 00:54 soft
drwxr-xr-x 2 root root 110 Jul 10 08:53 yum.repos.d
drwxr-xr-x 4 root root 111 Jul 10 19:34 lnmp_conf
[root@center install]# 
[root@center install]# ls -ltr mysql/
total 8496
-rw-r--r-- 1 root root 8696207 Jul 10 15:04 bigops-1.0.0.sql
[root@center install]# 
[root@center install]# du -sh mysql/*
8.3M    mysql/bigops-1.0.0.sql
[root@center install]# 
[root@center install]# mysql -u root -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 13
Server version: 8.0.16 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> 
mysql> create database bigops;
Query OK, 1 row affected (0.00 sec)

mysql> 
mysql> exit
Bye
[root@center install]# 
[root@center install]# cd /opt/bigops/install/mysql/
[root@center mysql]# 
[root@center mysql]# ls -ltr
total 8496
-rw-r--r-- 1 root root 8696207 Jul 10 15:04 bigops-1.0.0.sql
[root@center mysql]# 
[root@center mysql]# mysql -u root -p bigops < bigops-1.0.0.sql 
Enter password: 
[root@center mysql]# 
[root@center mysql]# mysql -u root -p             
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 15
Server version: 8.0.16 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> 
mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| bigops             |
| information_schema |
| mysql              |
| performance_schema |
| sys                |
+--------------------+
5 rows in set (0.00 sec)

mysql> 
mysql> use bigops;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> 
mysql> show tables;
+--------------------------------+
| Tables_in_bigops               |
+--------------------------------+
| alert                          |
| alert_api                      |
| alert_compress                 |
| alert_operation                |
| alert_rule                     |
| alert_rule_and                 |
| alert_rule_or                  |
| auto_op                        |
| auto_op_cat                    |
| auto_op_parm                   |
| auto_pb                        |
| auto_pb_default_exec_host      |
| auto_pb_log                    |
| auto_pb_log_detail             |
| auto_pb_op                     |
| auto_pb_op_parm                |
| avatar                         |
| bastion_cmd_filter             |
| bastion_mysession_display      |
| bastion_setting                |
| bg_img                         |
| check_report                   |
| check_result                   |
| checkitem                      |
| checkitem_cat                  |
| checkitem_exclude              |
| checkitem_include              |
| clean_duty_data                |
| clean_history_data             |
| cloud                          |
| company                        |
| deploy                         |
| deploy_history                 |
| desktop_shortcut               |
| desktop_user_pref              |
| desktop_user_pref_shortcut     |
| discovery_history              |
| discovery_rule                 |
| env                            |
| hostdebug                      |
| hostsession                    |
| hw_port                        |
| hw_position                    |
| icon                           |
| ip_db                          |
| ip_subnet                      |
| locks                          |
| log_login                      |
| log_operation                  |
| mon_alarm_api                  |
| mon_zabbix_api                 |
| msg_box                        |
| msg_send_history               |
| nav_desktop                    |
| nav_sysadmin                   |
| notifications                  |
| org                            |
| r_host_hw                      |
| r_host_service_tree            |
| r_hw_position                  |
| r_user_org                     |
| r_user_referer                 |
| r_user_usergroup               |
| regexregisteredservice         |
| regexregisteredserviceproperty |
| registeredservice_contacts     |
| registeredserviceimpl_props    |
| registeredserviceimplcontact   |
| res_api                        |
| res_cat                        |
| res_changelog                  |
| res_model                      |
| res_relation                   |
| res_user_pref                  |
| ri_firewall                    |
| ri_host                        |
| ri_router                      |
| ri_server                      |
| ri_switch                      |
| ri_user                        |
| search                         |
| service_tree                   |
| serviceticket                  |
| sms_history                    |
| sms_sp                         |
| sms_template                   |
| software                       |
| sso_auth                       |
| sso_find_pwd                   |
| sys_setting                    |
| sysbak_filebaklog              |
| sysbak_filebakplan             |
| sysman_common                  |
| sysman_connections_detail      |
| sysman_crontab_detail          |
| sysman_iptables_global_rule    |
| sysman_iptables_rule           |
| sysman_iptables_table          |
| sysman_ps_detail               |
| sysman_sockets_detail          |
| sysman_sysctl_detail           |
| t_right                        |
| t_role                         |
| t_role_hostsession             |
| t_role_right                   |
| t_role_service_tree            |
| t_router                       |
| t_user_role                    |
| t_usergroup_role               |
| ticketgrantingticket           |
| transientsessionticket         |
| usergroup                      |
| workorder                      |
| workorder_setting              |
+--------------------------------+
114 rows in set (0.00 sec)

mysql> 

安装,并配置Medusa:
前置条件,需要安装【gcc】

[root@center ~]# yum -y install libssh2 openssl openssl-libs openssl-devel
Loaded plugins: langpacks, ulninfo
base                                                                             | 3.6 kB  00:00:00     
epel                                                                             | 5.3 kB  00:00:00     
extras                                                                           | 3.4 kB  00:00:00     
updates                                                                          | 3.4 kB  00:00:00     
(1/2): epel/x86_64/updateinfo                                                    | 988 kB  00:00:05     
(2/2): epel/x86_64/primary_db                                                    | 6.8 MB  00:00:13     
Package 1:openssl-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Package 1:openssl-libs-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Package 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package libssh2.x86_64 0:1.4.3-10.el7_2.1 will be updated
---> Package libssh2.x86_64 0:1.4.3-12.el7_6.2 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package               Arch                 Version                         Repository             Size
========================================================================================================
Updating:
 libssh2               x86_64               1.4.3-12.el7_6.2                updates               135 k

Transaction Summary
========================================================================================================
Upgrade  1 Package

Total download size: 135 k
Downloading packages:
Delta RPMs reduced 135 k of updates to 24 k (82% saved)
libssh2-1.4.3-10.el7_2.1_1.4.3-12.el7_6.2.x86_64.drpm                            |  24 kB  00:00:01     
Finishing delta rebuilds of 1 package(s) (135 k)
delta does not match installed data
Some delta RPMs failed to download or rebuild. Retrying..
libssh2-1.4.3-12.el7_6.2.x86_64.rpm                                              | 135 kB  00:00:00     
--------------------------------------------------------------------------------------------------------
Total                                                                    94 kB/s | 159 kB  00:00:01     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Updating   : libssh2-1.4.3-12.el7_6.2.x86_64                                                      1/2 
  Cleanup    : libssh2-1.4.3-10.el7_2.1.x86_64                                                      2/2 
  Verifying  : libssh2-1.4.3-12.el7_6.2.x86_64                                                      1/2 
  Verifying  : libssh2-1.4.3-10.el7_2.1.x86_64                                                      2/2 

Updated:
  libssh2.x86_64 0:1.4.3-12.el7_6.2                                                                     

Complete!
[root@center ~]# 
[root@center ~]# cd /opt/bigops/install/soft/
[root@center soft]# 
[root@center soft]# ls -ltr
total 16952
-rw-r--r-- 1 root root   399836 Nov 25  2015 medusa-2.2.tar.gz
-rw-r--r-- 1 root root 13000480 Mar 21  2018 nmap-7.70.tgz
-rw-r--r-- 1 root root  3953824 Nov  2  2018 jq-linux64
[root@center soft]# 
[root@center soft]# tar -xzf medusa-2.2.tar.gz 
[root@center soft]#  
[root@center soft]# ls -ltr
total 16956
drwxr-xr-x 5 adamhuan 1001     4096 Nov 25  2015 medusa-2.2
-rw-r--r-- 1 root     root   399836 Nov 25  2015 medusa-2.2.tar.gz
-rw-r--r-- 1 root     root 13000480 Mar 21  2018 nmap-7.70.tgz
-rw-r--r-- 1 root     root  3953824 Nov  2  2018 jq-linux64
[root@center soft]# 
[root@center soft]# cd medusa-2.2/
[root@center medusa-2.2]# 
[root@center medusa-2.2]# ls -ltr
total 768
-rw-r--r-- 1 adamhuan 1001    271 Nov 10  2015 TODO
-rw-r--r-- 1 adamhuan 1001      0 Nov 10  2015 NEWS
-rwxr--r-- 1 adamhuan 1001   1988 Nov 10  2015 mkinstalldirs
-rwxr--r-- 1 adamhuan 1001   6872 Nov 10  2015 missing
-rw-r--r-- 1 adamhuan 1001    154 Nov 10  2015 Makefile.am
-rw-r--r-- 1 adamhuan 1001 189680 Nov 10  2015 ltmain.sh
-rwxr--r-- 1 adamhuan 1001   6315 Nov 10  2015 install-sh
-rw-r--r-- 1 adamhuan 1001   6970 Nov 10  2015 INSTALL
-rwxr--r-- 1 adamhuan 1001  12924 Nov 10  2015 depcomp
-rw-r--r-- 1 adamhuan 1001  18092 Nov 10  2015 COPYING
-rwxr--r-- 1 adamhuan 1001  31803 Nov 10  2015 config.sub
-rwxr--r-- 1 adamhuan 1001  44252 Nov 10  2015 config.guess
-rwxr--r-- 1 adamhuan 1001   7333 Nov 10  2015 compile
-rw-r--r-- 1 adamhuan 1001  12486 Nov 10  2015 ChangeLog
-rw-r--r-- 1 adamhuan 1001    836 Nov 10  2015 AUTHORS
-rw-r--r-- 1 adamhuan 1001  41113 Nov 25  2015 configure.ac
-rw-r--r-- 1 adamhuan 1001   1269 Nov 25  2015 README
-rw-r--r-- 1 adamhuan 1001  42914 Nov 25  2015 aclocal.m4
-rw-r--r-- 1 adamhuan 1001  27793 Nov 25  2015 Makefile.in
-rwxr--r-- 1 adamhuan 1001 278107 Nov 25  2015 configure
-rw-r--r-- 1 adamhuan 1001   3787 Nov 25  2015 config.h.in
drwxr-xr-x 4 adamhuan 1001     37 Nov 25  2015 misc
drwxr-xr-x 3 adamhuan 1001   4096 Nov 25  2015 src
drwxr-xr-x 2 adamhuan 1001   4096 Nov 25  2015 doc
[root@center medusa-2.2]# 
[root@center medusa-2.2]# ./configure --prefix=/usr
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking size of int... 4
checking size of long... 8
checking size of long long... 8
checking size of short... 2
checking whether to enable debugging... yes
configure: checking for pthread support...
checking for main in -lpthread... yes
configure: checking for dlopen/dlclose...
checking for dlclose in -ldl... yes
checking for library containing clock_gettime... none required
checking for clock_gettime... yes
configure: checking for OpenSSL Library and Header files...
checking /usr//include/openssl/ssh.h... found
checking for CRYPTO_lock in -lcrypto... yes
checking openssl/ssl.h usability... yes
checking openssl/ssl.h presence... yes
checking for openssl/ssl.h... yes
checking for main in -lssl... yes
configure: *** Checking module dependencies and enabling accordingly ***
configure: checking for AFPFS-NG Library and Header files...
checking afpfs-ng/afp_protocol.h usability... no
checking afpfs-ng/afp_protocol.h presence... no
checking for afpfs-ng/afp_protocol.h... no
configure: WARNING:  *** AFPFS-NG header files required for AFP module. ***

    The AFPFS-NG package must be installed for the AFP module to function. This includes
    both the library and header files. AFPFS-NG is available at the following site:
    http://alexthepuffin.googlepages.com/. The AFP module will NOT be built.

  
checking whether to enable AFP module... no
checking whether to enable CVS module... yes
checking whether to enable FTP module... yes
checking whether to enable HTTP module... yes
checking whether to enable IMAP module... yes
checking whether to enable MSSQL module... yes
checking whether to enable MYSQL module... yes
configure: checking for NCPFS Library and Header files...
checking ncp/nwcalls.h usability... no
checking ncp/nwcalls.h presence... no
checking for ncp/nwcalls.h... no
configure: WARNING:  *** NCPFS header files required for NCP module. ***

    The NCPFS package must be installed for the NCP module to function. This includes
    both the library and header files. If your distribution does not include these
    files or offer a ncpfs-devel package, the files can be manually installed using
    "make install-dev" within the NCPFS source. The NCP module will NOT be built.

  
checking whether to enable NCP module... no
checking whether to enable NNTP module... yes
checking whether to enable PCANYWHERE module... yes
checking whether to enable POP3 module... yes
configure: checking for PostgreSQL Library and Header files...
checking libpq-fe.h usability... no
checking libpq-fe.h presence... no
checking for libpq-fe.h... no
configure: WARNING:  *** LIBPQ header files required for PostgreSQL module. ***

      The PostgreSQL package must be installed for PostgreSQL module to function. This
      includes both the library and header files. Your distribution may offer a package
      such as libpq-devel or postgresql-devel, which will provide these files.

  
checking whether to enable POSTGRES module... no
configure: checking for FreeRDP Library and Header files...
checking freerdp/freerdp.h usability... no
checking freerdp/freerdp.h presence... no
checking for freerdp/freerdp.h... no
configure: WARNING:  *** FreeRDP header files required for RDP module. ***

        The FreeRDP package must be installed for RDP module to function. This
        includes both the library and header files. Your distribution may offer
        packages such as freerdp and libfreerdp-dev, which will provide these files.

    
checking whether to enable RDP module... no
checking whether to enable REXEC module... yes
checking whether to enable RLOGIN module... yes
checking whether to enable RSH module... yes
checking whether to enable SMBNT module... yes
checking whether to enable SMTP module... yes
checking whether to enable SMTP-VRFY module... yes
checking whether to enable SNMP module... yes
configure: checking for Libssh2 Library files...
checking for main in -lssh2... no
configure: WARNING:  *** Libssh2 required for SSH2 module. ***

  Libssh2 (http://www.libssh2.org) is not the same as libssh (http://0xbadc0de.be).
  Make sure you have the correct library. The SSH2 module will NOT be built.

  
checking whether to enable SSH module... no
configure: checking for Subversion Library and Header files...
checking for apr-1-config... no
checking for apr-config... no
configure: WARNING:  *** apr-config/apr-1-config not found and required for SVN module ***

      Make sure to install libapr1-dev or whatever package your distribution uses
      to distribute this file.

    
checking whether to enable SVN module... no
checking whether to enable TELNET module... yes
checking whether to enable VMAUTHD module... yes
checking whether to enable VNC module... yes
checking whether to enable WRAPPER module... yes
checking whether to enable WEB-FORM module... yes
configure: 
configure: *******************************************************
configure:     Medusa Module Build Summary
configure: 
configure:     AFP             ** Disabled **
configure:     CVS             Enabled
configure:     FTP             Enabled
configure:     HTTP            Enabled
configure:     IMAP            Enabled
configure:     MSSQL           Enabled
configure:     MYSQL           Enabled
configure:     NCP             ** Disabled **
configure:     NNTP            Enabled
configure:     PCANYWHERE      Enabled
configure:     POP3            Enabled
configure:     POSTGRES        ** Disabled **
configure:     RDP             ** Disabled **
configure:     REXEC           Enabled
configure:     RLOGIN          Enabled
configure:     RSH             Enabled
configure:     SMBNT           Enabled
configure:     SMTP            Enabled
configure:     SMTP-VRFY       Enabled
configure:     SNMP            Enabled
configure:     SSH             ** Disabled **
configure:     SVN             ** Disabled **
configure:     TELNET          Enabled
configure:     VMAUTHD         Enabled
configure:     VNC             Enabled
configure:     WRAPPER         Enabled
configure:     WEB-FORM        Enabled
configure: 
configure:  If a module is unexpectedly marked as disabled, check 
configure:  above output and verify dependancies were satisfied. 
configure: 
configure:  It should also be noted that, by default, not all of 
configure:  the modules are built. Incomplete modules or modules 
configure:  which have not been sufficiently tested may be 
configure:  disabled. To enable non-default modules, use the 
configure:  "--enable-module-MODULE_NAME" configure option.
configure: *******************************************************
configure: 
checking for strcasestr... yes
checking for asprintf... yes
checking for vasprintf... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating src/modsrc/Makefile
config.status: creating config.h
config.status: executing depfiles commands
[root@center medusa-2.2]# 

注意,这里的前置条件时,安装GCC;
如果你的环境中没有GCC,则你可能遇到这样的问题:

[root@center medusa-2.2]# ./configure --prefix=/usr
checking build system type... Invalid configuration `x86_64-unknown-linux-': machine `x86_64-unknown-linux' not recognized
configure: error: /bin/sh ./config.sub x86_64-unknown-linux- failed
[root@center medusa-2.2]# 

安装GCC:

[root@center medusa-2.2]# rpm -qa | grep gcc
libgcc-4.8.5-16.el7.x86_64
[root@center medusa-2.2]# 
[root@center medusa-2.2]# yum install -y gcc
Loaded plugins: langpacks, ulninfo
Resolving Dependencies
--> Running transaction check
---> Package gcc.x86_64 0:4.8.5-36.el7_6.2 will be installed
--> Processing Dependency: libgomp = 4.8.5-36.el7_6.2 for package: gcc-4.8.5-36.el7_6.2.x86_64
--> Processing Dependency: cpp = 4.8.5-36.el7_6.2 for package: gcc-4.8.5-36.el7_6.2.x86_64
--> Processing Dependency: libgcc >= 4.8.5-36.el7_6.2 for package: gcc-4.8.5-36.el7_6.2.x86_64
--> Processing Dependency: glibc-devel >= 2.2.90-12 for package: gcc-4.8.5-36.el7_6.2.x86_64
--> Processing Dependency: libmpc.so.3()(64bit) for package: gcc-4.8.5-36.el7_6.2.x86_64
--> Running transaction check
---> Package cpp.x86_64 0:4.8.5-36.el7_6.2 will be installed
---> Package glibc-devel.x86_64 0:2.17-260.el7_6.6 will be installed
--> Processing Dependency: glibc-headers = 2.17-260.el7_6.6 for package: glibc-devel-2.17-260.el7_6.6.x86_64
--> Processing Dependency: glibc = 2.17-260.el7_6.6 for package: glibc-devel-2.17-260.el7_6.6.x86_64
--> Processing Dependency: glibc-headers for package: glibc-devel-2.17-260.el7_6.6.x86_64
---> Package libgcc.x86_64 0:4.8.5-16.el7 will be updated
---> Package libgcc.x86_64 0:4.8.5-36.el7_6.2 will be an update
---> Package libgomp.x86_64 0:4.8.5-16.el7 will be updated
---> Package libgomp.x86_64 0:4.8.5-36.el7_6.2 will be an update
---> Package libmpc.x86_64 0:1.0.1-3.el7 will be installed
--> Running transaction check
---> Package glibc.x86_64 0:2.17-196.el7 will be updated
--> Processing Dependency: glibc = 2.17-196.el7 for package: glibc-common-2.17-196.el7.x86_64
---> Package glibc.x86_64 0:2.17-260.el7_6.6 will be an update
---> Package glibc-headers.x86_64 0:2.17-260.el7_6.6 will be installed
--> Processing Dependency: kernel-headers >= 2.2.1 for package: glibc-headers-2.17-260.el7_6.6.x86_64
--> Processing Dependency: kernel-headers for package: glibc-headers-2.17-260.el7_6.6.x86_64
--> Running transaction check
---> Package glibc-common.x86_64 0:2.17-196.el7 will be updated
---> Package glibc-common.x86_64 0:2.17-260.el7_6.6 will be an update
---> Package kernel-headers.x86_64 0:3.10.0-957.21.3.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package                   Arch              Version                           Repository          Size
========================================================================================================
Installing:
 gcc                       x86_64            4.8.5-36.el7_6.2                  updates             16 M
Installing for dependencies:
 cpp                       x86_64            4.8.5-36.el7_6.2                  updates            5.9 M
 glibc-devel               x86_64            2.17-260.el7_6.6                  updates            1.1 M
 glibc-headers             x86_64            2.17-260.el7_6.6                  updates            684 k
 kernel-headers            x86_64            3.10.0-957.21.3.el7               updates            8.0 M
 libmpc                    x86_64            1.0.1-3.el7                       base                51 k
Updating for dependencies:
 glibc                     x86_64            2.17-260.el7_6.6                  updates            3.7 M
 glibc-common              x86_64            2.17-260.el7_6.6                  updates             12 M
 libgcc                    x86_64            4.8.5-36.el7_6.2                  updates            102 k
 libgomp                   x86_64            4.8.5-36.el7_6.2                  updates            158 k

Transaction Summary
========================================================================================================
Install  1 Package  (+5 Dependent packages)
Upgrade             ( 4 Dependent packages)

Total download size: 47 M
Downloading packages:
(1/10): cpp-4.8.5-36.el7_6.2.x86_64.rpm                                          | 5.9 MB  00:00:20     
(2/10): glibc-2.17-260.el7_6.6.x86_64.rpm                                        | 3.7 MB  00:00:09     
(3/10): glibc-common-2.17-260.el7_6.6.x86_64.rpm                                 |  12 MB  00:00:33     
(4/10): gcc-4.8.5-36.el7_6.2.x86_64.rpm                                          |  16 MB  00:01:04     
(5/10): glibc-headers-2.17-260.el7_6.6.x86_64.rpm                                | 684 kB  00:00:02     
(6/10): glibc-devel-2.17-260.el7_6.6.x86_64.rpm                                  | 1.1 MB  00:00:03     
(7/10): libgcc-4.8.5-36.el7_6.2.x86_64.rpm                                       | 102 kB  00:00:00     
(8/10): libgomp-4.8.5-36.el7_6.2.x86_64.rpm                                      | 158 kB  00:00:00     
(9/10): libmpc-1.0.1-3.el7.x86_64.rpm                                            |  51 kB  00:00:00     
(10/10): kernel-headers-3.10.0-957.21.3.el7.x86_64.rpm                           | 8.0 MB  00:00:14     
--------------------------------------------------------------------------------------------------------
Total                                                                   594 kB/s |  47 MB  00:01:21     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Updating   : libgcc-4.8.5-36.el7_6.2.x86_64                                                      1/14 
  Updating   : glibc-common-2.17-260.el7_6.6.x86_64                                                2/14 
  Updating   : glibc-2.17-260.el7_6.6.x86_64                                                       3/14 
  Installing : libmpc-1.0.1-3.el7.x86_64                                                           4/14 
  Installing : cpp-4.8.5-36.el7_6.2.x86_64                                                         5/14 
  Updating   : libgomp-4.8.5-36.el7_6.2.x86_64                                                     6/14 
  Installing : kernel-headers-3.10.0-957.21.3.el7.x86_64                                           7/14 
  Installing : glibc-headers-2.17-260.el7_6.6.x86_64                                               8/14 
  Installing : glibc-devel-2.17-260.el7_6.6.x86_64                                                 9/14 
  Installing : gcc-4.8.5-36.el7_6.2.x86_64                                                        10/14 
  Cleanup    : libgomp-4.8.5-16.el7.x86_64                                                        11/14 
  Cleanup    : glibc-common-2.17-196.el7.x86_64                                                   12/14 
  Cleanup    : glibc-2.17-196.el7.x86_64                                                          13/14 
  Cleanup    : libgcc-4.8.5-16.el7.x86_64                                                         14/14 
  Verifying  : glibc-devel-2.17-260.el7_6.6.x86_64                                                 1/14 
  Verifying  : kernel-headers-3.10.0-957.21.3.el7.x86_64                                           2/14 
  Verifying  : glibc-2.17-260.el7_6.6.x86_64                                                       3/14 
  Verifying  : libgcc-4.8.5-36.el7_6.2.x86_64                                                      4/14 
  Verifying  : libgomp-4.8.5-36.el7_6.2.x86_64                                                     5/14 
  Verifying  : cpp-4.8.5-36.el7_6.2.x86_64                                                         6/14 
  Verifying  : gcc-4.8.5-36.el7_6.2.x86_64                                                         7/14 
  Verifying  : glibc-headers-2.17-260.el7_6.6.x86_64                                               8/14 
  Verifying  : glibc-common-2.17-260.el7_6.6.x86_64                                                9/14 
  Verifying  : libmpc-1.0.1-3.el7.x86_64                                                          10/14 
  Verifying  : libgcc-4.8.5-16.el7.x86_64                                                         11/14 
  Verifying  : glibc-common-2.17-196.el7.x86_64                                                   12/14 
  Verifying  : libgomp-4.8.5-16.el7.x86_64                                                        13/14 
  Verifying  : glibc-2.17-196.el7.x86_64                                                          14/14 

Installed:
  gcc.x86_64 0:4.8.5-36.el7_6.2                                                                         

Dependency Installed:
  cpp.x86_64 0:4.8.5-36.el7_6.2                    glibc-devel.x86_64 0:2.17-260.el7_6.6               
  glibc-headers.x86_64 0:2.17-260.el7_6.6          kernel-headers.x86_64 0:3.10.0-957.21.3.el7         
  libmpc.x86_64 0:1.0.1-3.el7                     

Dependency Updated:
  glibc.x86_64 0:2.17-260.el7_6.6                 glibc-common.x86_64 0:2.17-260.el7_6.6               
  libgcc.x86_64 0:4.8.5-36.el7_6.2                libgomp.x86_64 0:4.8.5-36.el7_6.2                    

Complete!
[root@center medusa-2.2]# 
[root@center medusa-2.2]# rpm -qa | grep gcc
libgcc-4.8.5-36.el7_6.2.x86_64
gcc-4.8.5-36.el7_6.2.x86_64
[root@center medusa-2.2]# 

【Configure】结束后,就需要【make / make install】了:

[root@center medusa-2.2]# make

(过多的输出,..)

mv -f $depbase.Tpo $depbase.Po
depbase=`echo medusa-utils.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
gcc -DHAVE_CONFIG_H -I. -I..  -I../src  -g -DDEBUG -fPIC -I/usr/include -I/usr/local/include -I/usr/include/postgresql -I/usr/include/pgsql -I/usr/include/afpfs-ng -I/usr//include  -g -O2 -MT medusa-utils.o -MD -MP -MF $depbase.Tpo -c -o medusa-utils.o medusa-utils.c &&\
mv -f $depbase.Tpo $depbase.Po
gcc  -g -O2  -L/usr/local/lib -L/usr//lib -rdynamic  -o medusa listModules.o medusa.o medusa-thread-pool.o medusa-thread-ssl.o medusa-net.o medusa-trace.o medusa-utils.o  -lcrypto -ldl -lpthread  -lssl -lcrypto -ldl -lrt -lm
make[3]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src'
make[2]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src'
make[2]: Entering directory `/opt/bigops/install/soft/medusa-2.2'
make[2]: Leaving directory `/opt/bigops/install/soft/medusa-2.2'
make[1]: Leaving directory `/opt/bigops/install/soft/medusa-2.2'
[root@center medusa-2.2]# 

[root@center medusa-2.2]# make install
Making install in src
make[1]: Entering directory `/opt/bigops/install/soft/medusa-2.2/src'
Making install in modsrc
make[2]: Entering directory `/opt/bigops/install/soft/medusa-2.2/src/modsrc'
make[3]: Entering directory `/opt/bigops/install/soft/medusa-2.2/src/modsrc'
make[3]: Nothing to be done for `install-exec-am'.
 /usr/bin/mkdir -p '/usr/lib/medusa/modules'
  /usr/bin/install -c cvs.mod ftp.mod http.mod imap.mod mssql.mod mysql.mod nntp.mod pcanywhere.mod pop3.mod rexec.mod rlogin.mod rsh.mod smbnt.mod smtp.mod smtp-vrfy.mod snmp.mod telnet.mod vmauthd.mod vnc.mod web-form.mod wrapper.mod '/usr/lib/medusa/modules'
make[3]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src/modsrc'
make[2]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src/modsrc'
make[2]: Entering directory `/opt/bigops/install/soft/medusa-2.2/src'
make[3]: Entering directory `/opt/bigops/install/soft/medusa-2.2/src'
 /usr/bin/mkdir -p '/usr/bin'
  /usr/bin/install -c medusa '/usr/bin'
make[3]: Nothing to be done for `install-data-am'.
make[3]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src'
make[2]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src'
make[1]: Leaving directory `/opt/bigops/install/soft/medusa-2.2/src'
make[1]: Entering directory `/opt/bigops/install/soft/medusa-2.2'
make[2]: Entering directory `/opt/bigops/install/soft/medusa-2.2'
make[2]: Nothing to be done for `install-exec-am'.
 /usr/bin/mkdir -p '/usr/share/man/man1'
 /usr/bin/install -c -m 644 doc/medusa.1 '/usr/share/man/man1'
make[2]: Leaving directory `/opt/bigops/install/soft/medusa-2.2'
make[1]: Leaving directory `/opt/bigops/install/soft/medusa-2.2'
[root@center medusa-2.2]# 

安装Ansible:

[root@center ~]# yum install -y ansible
Loaded plugins: langpacks, ulninfo
Resolving Dependencies
--> Running transaction check
---> Package ansible.noarch 0:2.8.1-1.el7 will be installed
--> Processing Dependency: PyYAML for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: python-httplib2 for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: python-jinja2 for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: python-paramiko for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: python2-cryptography for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: python2-jmespath for package: ansible-2.8.1-1.el7.noarch
--> Processing Dependency: sshpass for package: ansible-2.8.1-1.el7.noarch
--> Running transaction check
---> Package PyYAML.x86_64 0:3.10-11.el7 will be installed
--> Processing Dependency: libyaml-0.so.2()(64bit) for package: PyYAML-3.10-11.el7.x86_64
---> Package python-httplib2.noarch 0:0.9.2-1.el7 will be installed
---> Package python-jinja2.noarch 0:2.7.2-3.el7_6 will be installed
--> Processing Dependency: python-babel >= 0.8 for package: python-jinja2-2.7.2-3.el7_6.noarch
--> Processing Dependency: python-markupsafe for package: python-jinja2-2.7.2-3.el7_6.noarch
---> Package python-paramiko.noarch 0:2.1.1-9.el7 will be installed
--> Processing Dependency: python2-pyasn1 for package: python-paramiko-2.1.1-9.el7.noarch
---> Package python2-cryptography.x86_64 0:1.7.2-2.el7 will be installed
--> Processing Dependency: python-idna >= 2.0 for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-cffi >= 1.4.1 for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-ipaddress for package: python2-cryptography-1.7.2-2.el7.x86_64
--> Processing Dependency: python-enum34 for package: python2-cryptography-1.7.2-2.el7.x86_64
---> Package python2-jmespath.noarch 0:0.9.0-3.el7 will be installed
---> Package sshpass.x86_64 0:1.06-2.el7 will be installed
--> Running transaction check
---> Package libyaml.x86_64 0:0.1.4-11.el7_0 will be installed
---> Package python-babel.noarch 0:0.9.6-8.el7 will be installed
---> Package python-cffi.x86_64 0:1.6.0-5.el7 will be installed
--> Processing Dependency: python-pycparser for package: python-cffi-1.6.0-5.el7.x86_64
---> Package python-enum34.noarch 0:1.0.4-1.el7 will be installed
---> Package python-idna.noarch 0:2.4-1.el7 will be installed
---> Package python-ipaddress.noarch 0:1.0.16-2.el7 will be installed
---> Package python-markupsafe.x86_64 0:0.11-10.el7 will be installed
---> Package python2-pyasn1.noarch 0:0.1.9-7.el7 will be installed
--> Running transaction check
---> Package python-pycparser.noarch 0:2.14-1.el7 will be installed
--> Processing Dependency: python-ply for package: python-pycparser-2.14-1.el7.noarch
--> Running transaction check
---> Package python-ply.noarch 0:3.4-11.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package                         Arch              Version                     Repository          Size
========================================================================================================
Installing:
 ansible                         noarch            2.8.1-1.el7                 epel                15 M
Installing for dependencies:
 PyYAML                          x86_64            3.10-11.el7                 base               153 k
 libyaml                         x86_64            0.1.4-11.el7_0              base                55 k
 python-babel                    noarch            0.9.6-8.el7                 base               1.4 M
 python-cffi                     x86_64            1.6.0-5.el7                 base               218 k
 python-enum34                   noarch            1.0.4-1.el7                 base                52 k
 python-httplib2                 noarch            0.9.2-1.el7                 extras             115 k
 python-idna                     noarch            2.4-1.el7                   base                94 k
 python-ipaddress                noarch            1.0.16-2.el7                base                34 k
 python-jinja2                   noarch            2.7.2-3.el7_6               updates            518 k
 python-markupsafe               x86_64            0.11-10.el7                 base                25 k
 python-paramiko                 noarch            2.1.1-9.el7                 updates            269 k
 python-ply                      noarch            3.4-11.el7                  base               123 k
 python-pycparser                noarch            2.14-1.el7                  base               104 k
 python2-cryptography            x86_64            1.7.2-2.el7                 base               502 k
 python2-jmespath                noarch            0.9.0-3.el7                 extras              39 k
 python2-pyasn1                  noarch            0.1.9-7.el7                 base               100 k
 sshpass                         x86_64            1.06-2.el7                  extras              21 k

Transaction Summary
========================================================================================================
Install  1 Package (+17 Dependent packages)

Total download size: 18 M
Installed size: 101 M
Downloading packages:
(1/18): libyaml-0.1.4-11.el7_0.x86_64.rpm                                        |  55 kB  00:00:00     
(2/18): PyYAML-3.10-11.el7.x86_64.rpm                                            | 153 kB  00:00:00     
(3/18): python-cffi-1.6.0-5.el7.x86_64.rpm                                       | 218 kB  00:00:02     
(4/18): python-enum34-1.0.4-1.el7.noarch.rpm                                     |  52 kB  00:00:00     
(5/18): python-babel-0.9.6-8.el7.noarch.rpm                                      | 1.4 MB  00:00:03     
(6/18): python-ipaddress-1.0.16-2.el7.noarch.rpm                                 |  34 kB  00:00:00     
(7/18): python-markupsafe-0.11-10.el7.x86_64.rpm                                 |  25 kB  00:00:00     
(8/18): python-idna-2.4-1.el7.noarch.rpm                                         |  94 kB  00:00:00     
(9/18): python-httplib2-0.9.2-1.el7.noarch.rpm                                   | 115 kB  00:00:01     
(10/18): python-paramiko-2.1.1-9.el7.noarch.rpm                                  | 269 kB  00:00:01     
(11/18): python-pycparser-2.14-1.el7.noarch.rpm                                  | 104 kB  00:00:00     
(12/18): python-ply-3.4-11.el7.noarch.rpm                                        | 123 kB  00:00:01     
(13/18): python-jinja2-2.7.2-3.el7_6.noarch.rpm                                  | 518 kB  00:00:03     
(14/18): python2-jmespath-0.9.0-3.el7.noarch.rpm                                 |  39 kB  00:00:01     
(15/18): sshpass-1.06-2.el7.x86_64.rpm                                           |  21 kB  00:00:00     
(16/18): python2-cryptography-1.7.2-2.el7.x86_64.rpm                             | 502 kB  00:00:02     
(17/18): python2-pyasn1-0.1.9-7.el7.noarch.rpm                                   | 100 kB  00:00:01     
(18/18): ansible-2.8.1-1.el7.noarch.rpm                                          |  15 MB  00:00:36     
--------------------------------------------------------------------------------------------------------
Total                                                                   518 kB/s |  18 MB  00:00:36     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : python2-pyasn1-0.1.9-7.el7.noarch                                                   1/18 
  Installing : python-httplib2-0.9.2-1.el7.noarch                                                  2/18 
  Installing : sshpass-1.06-2.el7.x86_64                                                           3/18 
  Installing : python-ipaddress-1.0.16-2.el7.noarch                                                4/18 
  Installing : python-babel-0.9.6-8.el7.noarch                                                     5/18 
  Installing : python-markupsafe-0.11-10.el7.x86_64                                                6/18 
  Installing : python-jinja2-2.7.2-3.el7_6.noarch                                                  7/18 
  Installing : python2-jmespath-0.9.0-3.el7.noarch                                                 8/18 
  Installing : python-enum34-1.0.4-1.el7.noarch                                                    9/18 
  Installing : python-ply-3.4-11.el7.noarch                                                       10/18 
  Installing : python-pycparser-2.14-1.el7.noarch                                                 11/18 
  Installing : python-cffi-1.6.0-5.el7.x86_64                                                     12/18 
  Installing : libyaml-0.1.4-11.el7_0.x86_64                                                      13/18 
  Installing : PyYAML-3.10-11.el7.x86_64                                                          14/18 
  Installing : python-idna-2.4-1.el7.noarch                                                       15/18 
  Installing : python2-cryptography-1.7.2-2.el7.x86_64                                            16/18 
  Installing : python-paramiko-2.1.1-9.el7.noarch                                                 17/18 
  Installing : ansible-2.8.1-1.el7.noarch                                                         18/18 
warning: /etc/ansible/ansible.cfg created as /etc/ansible/ansible.cfg.rpmnew
  Verifying  : python-idna-2.4-1.el7.noarch                                                        1/18 
  Verifying  : libyaml-0.1.4-11.el7_0.x86_64                                                       2/18 
  Verifying  : python-ply-3.4-11.el7.noarch                                                        3/18 
  Verifying  : python-enum34-1.0.4-1.el7.noarch                                                    4/18 
  Verifying  : python2-jmespath-0.9.0-3.el7.noarch                                                 5/18 
  Verifying  : python-paramiko-2.1.1-9.el7.noarch                                                  6/18 
  Verifying  : python-markupsafe-0.11-10.el7.x86_64                                                7/18 
  Verifying  : python-babel-0.9.6-8.el7.noarch                                                     8/18 
  Verifying  : python-cffi-1.6.0-5.el7.x86_64                                                      9/18 
  Verifying  : python-ipaddress-1.0.16-2.el7.noarch                                               10/18 
  Verifying  : python-jinja2-2.7.2-3.el7_6.noarch                                                 11/18 
  Verifying  : sshpass-1.06-2.el7.x86_64                                                          12/18 
  Verifying  : python-httplib2-0.9.2-1.el7.noarch                                                 13/18 
  Verifying  : python2-pyasn1-0.1.9-7.el7.noarch                                                  14/18 
  Verifying  : ansible-2.8.1-1.el7.noarch                                                         15/18 
  Verifying  : PyYAML-3.10-11.el7.x86_64                                                          16/18 
  Verifying  : python-pycparser-2.14-1.el7.noarch                                                 17/18 
  Verifying  : python2-cryptography-1.7.2-2.el7.x86_64                                            18/18 

Installed:
  ansible.noarch 0:2.8.1-1.el7                                                                          

Dependency Installed:
  PyYAML.x86_64 0:3.10-11.el7                      libyaml.x86_64 0:0.1.4-11.el7_0                     
  python-babel.noarch 0:0.9.6-8.el7                python-cffi.x86_64 0:1.6.0-5.el7                    
  python-enum34.noarch 0:1.0.4-1.el7               python-httplib2.noarch 0:0.9.2-1.el7                
  python-idna.noarch 0:2.4-1.el7                   python-ipaddress.noarch 0:1.0.16-2.el7              
  python-jinja2.noarch 0:2.7.2-3.el7_6             python-markupsafe.x86_64 0:0.11-10.el7              
  python-paramiko.noarch 0:2.1.1-9.el7             python-ply.noarch 0:3.4-11.el7                      
  python-pycparser.noarch 0:2.14-1.el7             python2-cryptography.x86_64 0:1.7.2-2.el7           
  python2-jmespath.noarch 0:0.9.0-3.el7            python2-pyasn1.noarch 0:0.1.9-7.el7                 
  sshpass.x86_64 0:1.06-2.el7                     

Complete!
[root@center ~]# 

配置ANSIBLE

文件:/root/.ansible.cfg

[root@center ~]# ls -ltr /opt/bigops/install/ansible.cfg 
-rw-r--r-- 1 root root 231 Jul  9 23:57 /opt/bigops/install/ansible.cfg
[root@center ~]# 
[root@center ~]# cat /opt/bigops/install/ansible.cfg        
[defaults]
inventory = /etc/ansible/hosts
stdout =json
host_key_checking= False
deprecation_warnings=False

[ssh_connection]
scp_if_ssh=True
ssh_args = -o LogLevel=quiet -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null

[root@center ~]# 
[root@center ~]# cp /opt/bigops/install/ansible.cfg /root/.ansible.cfg
[root@center ~]# 
[root@center ~]# ls -ltra /root | grep ansible
-rw-r--r--   1 root root  231 Jul 10 23:57 .ansible.cfg
[root@center ~]# 

文件:/etc/ansible/ansible.cfg

[root@center ~]# cat /etc/ansible/ansible.cfg
[defaults]

inventory = /etc/ansible/hosts
stdout =json
host_key_checking= False
deprecation_warnings=False

[ssh_connection]

scp_if_ssh=True
ssh_args = -o LogLevel=quiet -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null
[root@center ~]# 
[root@center ~]# vi /etc/ansible/ansible.cfg 
[root@center ~]# 
[root@center ~]# cat /etc/ansible/ansible.cfg
[defaults]

inventory = /etc/ansible/hosts

stdout =json

host_key_checking= False

deprecation_warnings=False

[ssh_connection]

scp_if_ssh=True

ssh_args = -o LogLevel=quiet -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null
[root@center ~]# 

文件:/etc/ssh/ssh_config

[root@center ~]# cat /etc/ssh/ssh_config | grep Strict
#   StrictHostKeyChecking ask
[root@center ~]# 
[root@center ~]# vi /etc/ssh/ssh_config 
[root@center ~]# 
[root@center ~]# cat /etc/ssh/ssh_config | grep Strict
#   StrictHostKeyChecking ask
StrictHostKeyChecking no
[root@center ~]# 

JQ

[root@center soft]# pwd
/opt/bigops/install/soft
[root@center soft]# 
[root@center soft]# ls -ltr
total 16956
-rw-r--r-- 1 root     root   399836 Nov 25  2015 medusa-2.2.tar.gz
-rw-r--r-- 1 root     root 13000480 Mar 21  2018 nmap-7.70.tgz
-rw-r--r-- 1 root     root  3953824 Nov  2  2018 jq-linux64
drwxr-xr-x 5 adamhuan 1001     4096 Jul 10 23:51 medusa-2.2
[root@center soft]# 
[root@center soft]# cp jq-linux64 /usr/bin/jq
[root@center soft]# chmod -R 777 /usr/bin/jq 
[root@center soft]# 

NMAP

[root@center soft]# pwd
/opt/bigops/install/soft
[root@center soft]# 
[root@center soft]# ls -ltr
total 16956
-rw-r--r-- 1 root     root   399836 Nov 25  2015 medusa-2.2.tar.gz
-rw-r--r-- 1 root     root 13000480 Mar 21  2018 nmap-7.70.tgz
-rw-r--r-- 1 root     root  3953824 Nov  2  2018 jq-linux64
drwxr-xr-x 5 adamhuan 1001     4096 Jul 10 23:51 medusa-2.2
[root@center soft]# 
[root@center soft]# tar -xzf nmap-7.70.tgz 
[root@center soft]# 
[root@center soft]# cd nmap-7.70/
[root@center nmap-7.70]# ls -ltr
total 15820
-rw-r--r--  1 root root     129 Oct 23  2007 nse_pcrelib.h
-rwxr-xr-x  1 root root   17574 Nov 27  2007 depcomp
-rwxr-xr-x  1 root root   23033 Aug 20  2008 shtool
-rw-r--r--  1 root root     167 Mar 10  2009 nse_debug.h
-rw-r--r--  1 root root     173 Jun 30  2009 BSDmakefile
-rw-r--r--  1 root root  243268 Aug  8  2009 ltmain.sh
-rw-r--r--  1 root root     267 Aug  9  2012 nse_nmaplib.h
-rw-r--r--  1 root root    2307 Dec 25  2013 checklibs.sh
-rw-r--r--  1 root root    4975 Jun 18  2014 struct_ip.h
-rw-r--r--  1 root root     108 Jun 18  2014 nse_fs.h
-rw-r--r--  1 root root     102 Jun 18  2014 nse_dnet.h
-rw-r--r--  1 root root     107 Jun 27  2014 nse_lpeg.h
-rwxr-xr-x  1 root root   35994 Feb 15  2015 config.sub
-rwxr-xr-x  1 root root   42938 Feb 15  2015 config.guess
-rw-r--r--  1 root root     128 May  2  2015 nse_openssl.h
-rw-r--r--  1 root root     211 May 11  2015 INSTALL
-rw-r--r--  1 root root     139 Jul  2  2015 nse_nsock.h
-rw-r--r--  1 root root     200 Oct 10  2015 FPModel.h
-rw-r--r--  1 root root    6703 Nov  6  2015 nmap-protocols
-rw-r--r--  1 root root   12328 Jul  3  2016 nse_pcrelib.cc
-rw-r--r--  1 root root     509 Jul  3  2016 nse_lpeg.cc
-rw-r--r--  1 root root    6740 Jul  3  2016 nse_fs.cc
-rw-r--r--  1 root root    4130 Nov 22  2016 HACKING
-rw-r--r--  1 root root    1821 Apr 19  2017 nse_main.h
-rw-r--r--  1 root root    2362 Apr 20  2017 nse_debug.cc
-rw-r--r--  1 root root   10997 Apr 20  2017 nse_dnet.cc
-rw-r--r--  1 root root   34358 Apr 21  2017 nse_nsock.cc
-rw-r--r--  1 root root    1664 Apr 30  2017 README.md
-rw-r--r--  1 root root    5915 Jun 30  2017 nse_utility.h
-rw-r--r--  1 root root   26452 Jun 30  2017 nse_libssh2.cc
-rw-r--r--  1 root root     111 Jul 19  2017 nse_libssh2.h
-rw-r--r--  1 root root    6067 Aug  7  2017 nse_utility.cc
-rw-r--r--  1 root root  590258 Aug 18  2017 nmap-mac-prefixes
-rw-r--r--  1 root root   49647 Aug 23  2017 nmap-rpc
-rwxr-xr-x  1 root root   10677 Aug 23  2017 missing
-rw-r--r--  1 root root    2662 Aug 23  2017 CONTRIBUTING.md
-rw-r--r--  1 root root   11738 Aug 23  2017 acinclude.m4
-rw-r--r--  1 root root     108 Sep 13  2017 nse_zlib.h
-rw-r--r--  1 root root   28094 Sep 13  2017 nse_zlib.cc
-rw-r--r--  1 root root   11453 Sep 20  2017 aclocal.m4
-rw-r--r--  1 root root  104340 Sep 24  2017 lpeg.c
-rw-r--r--  1 root root   33091 Nov  2  2017 configure.ac
-rwxr-xr-x  1 root root  268714 Nov  2  2017 configure
-rw-r--r--  1 root root   22976 Dec  8  2017 nse_main.cc
-rw-r--r--  1 root root   31651 Dec 10  2017 nse_nmaplib.cc
-rw-r--r--  1 root root   48348 Jan 10  2018 nse_main.lua
-rw-r--r--  1 root root   21015 Jan 22  2018 nse_openssl.cc
-rw-r--r--  1 root root   10679 Jan 29  2018 xml.h
-rw-r--r--  1 root root   20368 Jan 29  2018 xml.cc
-rw-r--r--  1 root root   11586 Jan 29  2018 utils.h
-rw-r--r--  1 root root   25310 Jan 29  2018 utils.cc
-rw-r--r--  1 root root    9973 Jan 29  2018 traceroute.h
-rw-r--r--  1 root root   58609 Jan 29  2018 traceroute.cc
-rw-r--r--  1 root root   17913 Jan 29  2018 timing.h
-rw-r--r--  1 root root   31970 Jan 29  2018 timing.cc
-rw-r--r--  1 root root   26596 Jan 29  2018 tcpip.h
-rw-r--r--  1 root root   74273 Jan 29  2018 tcpip.cc
-rw-r--r--  1 root root   12232 Jan 29  2018 targets.h
-rw-r--r--  1 root root   27251 Jan 29  2018 targets.cc
-rw-r--r--  1 root root   19798 Jan 29  2018 Target.h
-rw-r--r--  1 root root   11485 Jan 29  2018 TargetGroup.h
-rw-r--r--  1 root root   32530 Jan 29  2018 TargetGroup.cc
-rw-r--r--  1 root root   23294 Jan 29  2018 Target.cc
-rw-r--r--  1 root root   10589 Jan 29  2018 services.h
-rw-r--r--  1 root root   24161 Jan 29  2018 services.cc
-rw-r--r--  1 root root   21689 Jan 29  2018 service_scan.h
-rw-r--r--  1 root root   11592 Jan 29  2018 scan_lists.h
-rw-r--r--  1 root root   27593 Jan 29  2018 scan_lists.cc
-rw-r--r--  1 root root   10788 Jan 29  2018 scan_engine_raw.h
-rw-r--r--  1 root root   92458 Jan 29  2018 scan_engine_raw.cc
-rw-r--r--  1 root root   35315 Jan 29  2018 scan_engine.h
-rw-r--r--  1 root root   10232 Jan 29  2018 scan_engine_connect.h
-rw-r--r--  1 root root   25362 Jan 29  2018 scan_engine_connect.cc
-rw-r--r--  1 root root  106151 Jan 29  2018 scan_engine.cc
-rw-r--r--  1 root root   10612 Jan 29  2018 protocols.h
-rw-r--r--  1 root root   13301 Jan 29  2018 protocols.cc
-rw-r--r--  1 root root   13491 Jan 29  2018 portreasons.h
-rw-r--r--  1 root root   24782 Jan 29  2018 portreasons.cc
-rw-r--r--  1 root root   19090 Jan 29  2018 portlist.h
-rw-r--r--  1 root root   36874 Jan 29  2018 portlist.cc
-rw-r--r--  1 root root   10082 Jan 29  2018 payload.h
-rw-r--r--  1 root root   17393 Jan 29  2018 payload.cc
-rw-r--r--  1 root root   16814 Jan 29  2018 output.h
-rw-r--r--  1 root root   97539 Jan 29  2018 output.cc
-rw-r--r--  1 root root   15255 Jan 29  2018 osscan.h
-rw-r--r--  1 root root   45650 Jan 29  2018 osscan.cc
-rw-r--r--  1 root root   27117 Jan 29  2018 osscan2.h
-rw-r--r--  1 root root  120298 Jan 29  2018 osscan2.cc
-rw-r--r--  1 root root    9980 Jan 29  2018 nse_ssl_cert.h
-rw-r--r--  1 root root   25797 Jan 29  2018 nse_ssl_cert.cc
-rw-r--r--  1 root root   10858 Jan 29  2018 nmap_winconfig.h
-rw-r--r--  1 root root   10379 Jan 29  2018 nmap_tty.h
-rw-r--r--  1 root root   16501 Jan 29  2018 nmap_tty.cc
-rw-r--r--  1 root root   13043 Jan 29  2018 NmapOutputTable.h
-rw-r--r--  1 root root   15382 Jan 29  2018 NmapOutputTable.cc
-rw-r--r--  1 root root   22612 Jan 29  2018 NmapOps.h
-rw-r--r--  1 root root   27648 Jan 29  2018 NmapOps.cc
-rw-r--r--  1 root root   10939 Jan 29  2018 nmap_ftp.h
-rw-r--r--  1 root root   19967 Jan 29  2018 nmap_ftp.cc
-rw-r--r--  1 root root   10707 Jan 29  2018 nmap_error.h
-rw-r--r--  1 root root   13649 Jan 29  2018 nmap_error.cc
-rw-r--r--  1 root root   14199 Jan 29  2018 nmap_dns.h
-rw-r--r--  1 root root   55677 Jan 29  2018 nmap_dns.cc
-rw-r--r--  1 root root   11866 Jan 29  2018 nmap_config.h.in
-rw-r--r--  1 root root   11336 Jan 29  2018 nmap_amigaos.h
-rw-r--r--  1 root root   11156 Jan 29  2018 NewTargets.h
-rw-r--r--  1 root root   12749 Jan 29  2018 NewTargets.cc
-rw-r--r--  1 root root   13363 Jan 29  2018 main.cc
-rw-r--r--  1 root root   10797 Jan 29  2018 MACLookup.h
-rw-r--r--  1 root root   13485 Jan 29  2018 MACLookup.cc
-rw-r--r--  1 root root   10655 Jan 29  2018 idle_scan.h
-rw-r--r--  1 root root   65870 Jan 29  2018 idle_scan.cc
-rw-r--r--  1 root root   22828 Jan 29  2018 FPEngine.h
-rw-r--r--  1 root root  111067 Jan 29  2018 FPEngine.cc
-rw-r--r--  1 root root   14105 Jan 29  2018 FingerPrintResults.h
-rw-r--r--  1 root root   16786 Jan 29  2018 FingerPrintResults.cc
-rw-r--r--  1 root root   27921 Jan 29  2018 COPYING
-rw-r--r--  1 root root   10045 Jan 29  2018 charpool.h
-rw-r--r--  1 root root   12032 Jan 29  2018 charpool.cc
-rw-r--r--  1 root root  112635 Feb 12  2018 service_scan.cc
-rw-r--r--  1 root root  111589 Feb 21  2018 nmap.cc
-rw-r--r--  1 root root 2701626 Feb 24  2018 FPModel.cc
-rw-r--r--  1 root root   14512 Mar  3  2018 nmap-payloads
-rw-r--r--  1 root root 2428001 Mar  8  2018 nmap-service-probes
-rw-r--r--  1 root root 5002933 Mar  9  2018 nmap-os-db
-rw-r--r--  1 root root   20012 Mar 10  2018 Makefile.in
-rw-r--r--  1 root root     186 Mar 15  2018 README-WIN32
-rw-r--r--  1 root root  998637 Mar 15  2018 nmap-services
-rw-r--r--  1 root root   16507 Mar 15  2018 nmap.h
-rw-r--r--  1 root root  725381 Mar 16  2018 CHANGELOG
drwxr-xr-x  2 root root   24576 Mar 19  2018 scripts
drwxr-xr-x  2 root root    4096 Mar 19  2018 libnetutil
drwxr-xr-x  2 root root      30 Mar 19  2018 tests
drwxr-xr-x 10 root root    4096 Mar 19  2018 libssh2
drwxr-xr-x 13 root root    8192 Mar 19  2018 libpcap
drwxr-xr-x  2 root root    4096 Mar 19  2018 todo
drwxr-xr-x  2 root root    4096 Mar 19  2018 nmap-update
drwxr-xr-x  5 root root     132 Mar 19  2018 ndiff
drwxr-xr-x  3 root root    4096 Mar 19  2018 nbase
drwxr-xr-x  3 root root    4096 Mar 19  2018 macosx
drwxr-xr-x  2 root root    4096 Mar 19  2018 libpcre
drwxr-xr-x  3 root root    4096 Mar 19  2018 nselib
drwxr-xr-x 12 root root    4096 Mar 19  2018 libz
drwxr-xr-x  3 root root    4096 Mar 19  2018 liblinear
drwxr-xr-x  6 root root    4096 Mar 19  2018 ncat
drwxr-xr-x  2 root root    4096 Mar 19  2018 liblua
-rw-r--r--  1 root root    3086 Mar 19  2018 zenmap-7.70-1.spec
drwxr-xr-x  8 root root    4096 Mar 19  2018 zenmap
-rw-r--r--  1 root root    5518 Mar 19  2018 nmap-7.70-1.spec
drwxr-xr-x 10 root root    4096 Mar 19  2018 mswin32
drwxr-xr-x  5 root root    4096 Mar 19  2018 libdnet-stripped
drwxr-xr-x  5 root root      66 Mar 19  2018 nsock
drwxr-xr-x  3 root root    4096 Mar 19  2018 nping
drwxr-xr-x  5 root root    4096 Mar 19  2018 docs
[root@center nmap-7.70]# 
[root@center nmap-7.70]# ./configure --prefix=/usr

(过多的输出,...)

checking for lua version >= 503... checking for g++... no
checking for c++... no
checking for gpp... no
checking for aCC... no
checking for CC... no
checking for cxx... no
checking for cc++... no
checking for cl.exe... no
checking for FCC... no
checking for KCC... no
checking for RCC... no
checking for xlC_r... no
checking for xlC... no
checking whether we are using the GNU C++ compiler... no
checking whether g++ accepts -g... no
no
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
            .       .
            \`-"'"-'/
             } 6 6 {
            ==. Y ,==
              /^^^\  .
             /     \  )  Ncat: A modern interpretation of classic Netcat
            (  )-(  )/
            -""---""---   /
           /   Ncat    \_/
          (     ____
           \_.=|____E
Configuration complete.
   (  )   /\   _                 (
    \ |  (  \ ( \.(               )                      _____
  \  \ \  `  `   ) \             (  ___                 / _   \
 (_`    \+   . x  ( .\            \/   \____-----------/ (o)   \_
- .-               \+  ;          (  O                           \____
(__                +- .( -'.- <.   \_____________  `              \  /
(_____            ._._: <_ - <- _- _  VVVVVVV VV V\                \/
  .    /./.+-  . .- /  +--  - .    (--_AAAAAAA__A_/                |
  (__ ' /x  / x _/ (                \______________//_              \_______
 , x / ( '  . / .  /                                  \___'          \     /
    /  /  _/ /    +                                       |           \   /
   '  (__/                                               /              \/
                                                       /                  \
  NMAP IS A POWERFUL TOOL -- USE CAREFULLY AND RESPONSIBLY
Configured with: ndiff zenmap nping openssl zlib libssh2 lua ncat
Configured without: localdirs nmap-update
Type make (or gmake on some *BSD machines) to compile.
[root@center nmap-7.70]# 

继续做Make和Make Install的之前,先检查相关的软件包是否装了;
如果没有装,就按照下面的方法安装:

[root@center nmap-7.70]# yum -y install gcc automake autoconf libtool make gcc-c++ 
Loaded plugins: langpacks, ulninfo
base                                                                             | 3.6 kB  00:00:00     
epel                                                                             | 5.3 kB  00:00:00     
extras                                                                           | 3.4 kB  00:00:00     
mysql80-community                                                                | 2.5 kB  00:00:00     
updates                                                                          | 3.4 kB  00:00:00     
Package gcc-4.8.5-36.el7_6.2.x86_64 already installed and latest version
Package 1:make-3.82-23.el7.x86_64 already installed and latest version
Resolving Dependencies
--> Running transaction check
---> Package autoconf.noarch 0:2.69-11.el7 will be installed
--> Processing Dependency: m4 >= 1.4.14 for package: autoconf-2.69-11.el7.noarch
---> Package automake.noarch 0:1.13.4-3.el7 will be installed
--> Processing Dependency: perl(Thread::Queue) for package: automake-1.13.4-3.el7.noarch
--> Processing Dependency: perl(TAP::Parser) for package: automake-1.13.4-3.el7.noarch
---> Package gcc-c++.x86_64 0:4.8.5-36.el7_6.2 will be installed
--> Processing Dependency: libstdc++-devel = 4.8.5-36.el7_6.2 for package: gcc-c++-4.8.5-36.el7_6.2.x86_64
--> Processing Dependency: libstdc++ = 4.8.5-36.el7_6.2 for package: gcc-c++-4.8.5-36.el7_6.2.x86_64
---> Package libtool.x86_64 0:2.4.2-22.el7_3 will be installed
--> Running transaction check
---> Package libstdc++.x86_64 0:4.8.5-16.el7 will be updated
---> Package libstdc++.x86_64 0:4.8.5-36.el7_6.2 will be an update
---> Package libstdc++-devel.x86_64 0:4.8.5-36.el7_6.2 will be installed
---> Package m4.x86_64 0:1.4.16-10.el7 will be installed
---> Package perl-Test-Harness.noarch 0:3.28-3.el7 will be installed
---> Package perl-Thread-Queue.noarch 0:3.02-2.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package                      Arch              Version                        Repository          Size
========================================================================================================
Installing:
 autoconf                     noarch            2.69-11.el7                    base               701 k
 automake                     noarch            1.13.4-3.el7                   base               679 k
 gcc-c++                      x86_64            4.8.5-36.el7_6.2               updates            7.2 M
 libtool                      x86_64            2.4.2-22.el7_3                 base               588 k
Installing for dependencies:
 libstdc++-devel              x86_64            4.8.5-36.el7_6.2               updates            1.5 M
 m4                           x86_64            1.4.16-10.el7                  base               256 k
 perl-Test-Harness            noarch            3.28-3.el7                     base               302 k
 perl-Thread-Queue            noarch            3.02-2.el7                     base                17 k
Updating for dependencies:
 libstdc++                    x86_64            4.8.5-36.el7_6.2               updates            305 k

Transaction Summary
========================================================================================================
Install  4 Packages (+4 Dependent packages)
Upgrade             ( 1 Dependent package)

Total download size: 11 M
Downloading packages:
(1/9): automake-1.13.4-3.el7.noarch.rpm                                          | 679 kB  00:00:02     
(2/9): libstdc++-4.8.5-36.el7_6.2.x86_64.rpm                                     | 305 kB  00:00:03     
(3/9): autoconf-2.69-11.el7.noarch.rpm                                           | 701 kB  00:00:07     
(4/9): m4-1.4.16-10.el7.x86_64.rpm                                               | 256 kB  00:00:02     
(5/9): libtool-2.4.2-22.el7_3.x86_64.rpm                                         | 588 kB  00:00:06     
(6/9): perl-Thread-Queue-3.02-2.el7.noarch.rpm                                   |  17 kB  00:00:00     
(7/9): perl-Test-Harness-3.28-3.el7.noarch.rpm                                   | 302 kB  00:00:01     
(8/9): libstdc++-devel-4.8.5-36.el7_6.2.x86_64.rpm                               | 1.5 MB  00:00:08     
(9/9): gcc-c++-4.8.5-36.el7_6.2.x86_64.rpm                                       | 7.2 MB  00:00:20     
--------------------------------------------------------------------------------------------------------
Total                                                                   559 kB/s |  11 MB  00:00:20     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Updating   : libstdc++-4.8.5-36.el7_6.2.x86_64                                                   1/10 
  Installing : libstdc++-devel-4.8.5-36.el7_6.2.x86_64                                             2/10 
  Installing : m4-1.4.16-10.el7.x86_64                                                             3/10 
  Installing : autoconf-2.69-11.el7.noarch                                                         4/10 
  Installing : perl-Thread-Queue-3.02-2.el7.noarch                                                 5/10 
  Installing : perl-Test-Harness-3.28-3.el7.noarch                                                 6/10 
  Installing : automake-1.13.4-3.el7.noarch                                                        7/10 
  Installing : libtool-2.4.2-22.el7_3.x86_64                                                       8/10 
  Installing : gcc-c++-4.8.5-36.el7_6.2.x86_64                                                     9/10 
  Cleanup    : libstdc++-4.8.5-16.el7.x86_64                                                      10/10 
  Verifying  : autoconf-2.69-11.el7.noarch                                                         1/10 
  Verifying  : perl-Test-Harness-3.28-3.el7.noarch                                                 2/10 
  Verifying  : gcc-c++-4.8.5-36.el7_6.2.x86_64                                                     3/10 
  Verifying  : perl-Thread-Queue-3.02-2.el7.noarch                                                 4/10 
  Verifying  : automake-1.13.4-3.el7.noarch                                                        5/10 
  Verifying  : m4-1.4.16-10.el7.x86_64                                                             6/10 
  Verifying  : libstdc++-devel-4.8.5-36.el7_6.2.x86_64                                             7/10 
  Verifying  : libtool-2.4.2-22.el7_3.x86_64                                                       8/10 
  Verifying  : libstdc++-4.8.5-36.el7_6.2.x86_64                                                   9/10 
  Verifying  : libstdc++-4.8.5-16.el7.x86_64                                                      10/10 

Installed:
  autoconf.noarch 0:2.69-11.el7     automake.noarch 0:1.13.4-3.el7   gcc-c++.x86_64 0:4.8.5-36.el7_6.2  
  libtool.x86_64 0:2.4.2-22.el7_3  

Dependency Installed:
  libstdc++-devel.x86_64 0:4.8.5-36.el7_6.2            m4.x86_64 0:1.4.16-10.el7                       
  perl-Test-Harness.noarch 0:3.28-3.el7                perl-Thread-Queue.noarch 0:3.02-2.el7           

Dependency Updated:
  libstdc++.x86_64 0:4.8.5-36.el7_6.2                                                                   

Complete!
[root@center nmap-7.70]# 

然后,【make】

[root@center nmap-7.70]# make

(过多的输出,...)

.o output.o stats.o NpingTargets.o NpingTarget.o EchoHeader.o EchoServer.o EchoClient.o ProbeMode.o NEPContext.o Crypto.o ../nsock/src/libnsock.a ../nbase/libnbase.a ../libnetutil/libnetutil.a -lssl -lcrypto ../libpcap/libpcap.a ../libdnet-stripped/src/.libs/libdnet.a -ldl 
Nping compiled successfully!
make[2]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/nping'
make[1]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/nping'
cd ncat && make
make[1]: Entering directory `/opt/bigops/install/soft/nmap-7.70/ncat'
gcc -MM -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase ncat_main.c ncat_connect.c ncat_core.c ncat_posix.c ncat_listen.c ncat_proxy.c ncat_ssl.c base64.c http.c util.c sys_wrap.c http_digest.c ncat_lua.c > makefile.dep
make[1]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/ncat'
make[1]: Entering directory `/opt/bigops/install/soft/nmap-7.70/ncat'
Compiling liblua
make[2]: Entering directory `/opt/bigops/install/soft/nmap-7.70/liblua'
make[2]: `liblua.a' is up to date.
make[2]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/liblua'
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_main.c -o ncat_main.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_connect.c -o ncat_connect.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_core.c -o ncat_core.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_posix.c -o ncat_posix.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_listen.c -o ncat_listen.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_proxy.c -o ncat_proxy.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_ssl.c -o ncat_ssl.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c base64.c -o base64.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c http.c -o http.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c util.c -o util.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c sys_wrap.c -o sys_wrap.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c http_digest.c -o http_digest.o
gcc -I./../liblua  -I../libpcap -DHAVE_CONFIG_H -DNCAT_DATADIR="\"/usr/share/ncat\"" -D_FORTIFY_SOURCE=2 -I. -I.. -I../nsock/include/ -I../nbase -DLUA_USE_POSIX -DLUA_USE_DLOPEN -DHAVE_LUA=1 -I../liblua -g -O2 -Wall -c ncat_lua.c -o ncat_lua.o
gcc -o ncat -g -O2 -Wall  -L../libpcap  ncat_main.o ncat_connect.o ncat_core.o ncat_posix.o ncat_listen.o ncat_proxy.o ncat_ssl.o base64.o http.o util.o sys_wrap.o http_digest.o ncat_lua.o ../nsock/src/libnsock.a ../nbase/libnbase.a -lssl -lcrypto -lpcap ./../liblua/liblua.a -lm -ldl 
make[1]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/ncat'
[root@center nmap-7.70]# 

然后,【make install】

[root@center nmap-7.70]# make install

(过多的输出,...)

copying docs/ndiff.1 -> /usr/share/man/man1
running install_egg_info
make[1]: Entering directory `/opt/bigops/install/soft/nmap-7.70/nping'
make nping
make[2]: Entering directory `/opt/bigops/install/soft/nmap-7.70/nping'
make[2]: `nping' is up to date.
make[2]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/nping'
make[1]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/nping'
cd nping && make install
make[1]: Entering directory `/opt/bigops/install/soft/nmap-7.70/nping'
/usr/bin/install -c -d /usr/bin /usr/share/man/man1
/usr/bin/install -c -c -m 755 nping /usr/bin/nping
/usr/bin/strip -x /usr/bin/nping
/usr/bin/install -c -c -m 644 docs/nping.1 /usr/share/man/man1/
NPING SUCCESSFULLY INSTALLED
make[1]: Leaving directory `/opt/bigops/install/soft/nmap-7.70/nping'
NMAP SUCCESSFULLY INSTALLED
[root@center nmap-7.70]# 

安装:Nginx

[root@center ~]# rpm -qa | grep nginx
[root@center ~]# 
[root@center ~]# yum list | grep nginx
collectd-nginx.x86_64                     5.8.1-1.el7              epel         
munin-nginx.noarch                        2.0.49-1.el7             epel         
nextcloud-nginx.noarch                    10.0.4-2.el7             epel         
nginx.x86_64                              1:1.12.2-3.el7           epel         
nginx-all-modules.noarch                  1:1.12.2-3.el7           epel         
nginx-filesystem.noarch                   1:1.12.2-3.el7           epel         
nginx-mod-http-geoip.x86_64               1:1.12.2-3.el7           epel         
nginx-mod-http-image-filter.x86_64        1:1.12.2-3.el7           epel         
nginx-mod-http-perl.x86_64                1:1.12.2-3.el7           epel         
nginx-mod-http-xslt-filter.x86_64         1:1.12.2-3.el7           epel         
nginx-mod-mail.x86_64                     1:1.12.2-3.el7           epel         
nginx-mod-stream.x86_64                   1:1.12.2-3.el7           epel         
owncloud-nginx.noarch                     9.1.5-1.el7              epel         
pcp-pmda-nginx.x86_64                     4.1.0-5.el7_6            updates      
python2-certbot-nginx.noarch              0.35.1-1.el7             epel         
[root@center ~]# 
[root@center ~]# yum install -y nginx

(过多的输出,...)

---> Package nginx-mod-http-xslt-filter.x86_64 1:1.12.2-3.el7 will be installed
---> Package nginx-mod-mail.x86_64 1:1.12.2-3.el7 will be installed
---> Package nginx-mod-stream.x86_64 1:1.12.2-3.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

========================================================================================================
 Package                               Arch             Version                    Repository      Size
========================================================================================================
Installing:
 nginx                                 x86_64           1:1.12.2-3.el7             epel           531 k
Installing for dependencies:
 nginx-all-modules                     noarch           1:1.12.2-3.el7             epel            16 k
 nginx-filesystem                      noarch           1:1.12.2-3.el7             epel            17 k
 nginx-mod-http-geoip                  x86_64           1:1.12.2-3.el7             epel            23 k
 nginx-mod-http-image-filter           x86_64           1:1.12.2-3.el7             epel            27 k
 nginx-mod-http-perl                   x86_64           1:1.12.2-3.el7             epel            36 k
 nginx-mod-http-xslt-filter            x86_64           1:1.12.2-3.el7             epel            26 k
 nginx-mod-mail                        x86_64           1:1.12.2-3.el7             epel            54 k
 nginx-mod-stream                      x86_64           1:1.12.2-3.el7             epel            76 k

Transaction Summary
========================================================================================================
Install  1 Package (+8 Dependent packages)

Total download size: 807 k
Installed size: 1.9 M
Downloading packages:
(1/9): nginx-all-modules-1.12.2-3.el7.noarch.rpm                                 |  16 kB  00:00:00     
(2/9): nginx-filesystem-1.12.2-3.el7.noarch.rpm                                  |  17 kB  00:00:00     
(3/9): nginx-mod-http-geoip-1.12.2-3.el7.x86_64.rpm                              |  23 kB  00:00:00     
(4/9): nginx-mod-http-image-filter-1.12.2-3.el7.x86_64.rpm                       |  27 kB  00:00:00     
(5/9): nginx-mod-http-perl-1.12.2-3.el7.x86_64.rpm                               |  36 kB  00:00:00     
(6/9): nginx-mod-http-xslt-filter-1.12.2-3.el7.x86_64.rpm                        |  26 kB  00:00:00     
(7/9): nginx-mod-mail-1.12.2-3.el7.x86_64.rpm                                    |  54 kB  00:00:00     
(8/9): nginx-mod-stream-1.12.2-3.el7.x86_64.rpm                                  |  76 kB  00:00:00     
(9/9): nginx-1.12.2-3.el7.x86_64.rpm                                             | 531 kB  00:00:02     
--------------------------------------------------------------------------------------------------------
Total                                                                   318 kB/s | 807 kB  00:00:02     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : 1:nginx-filesystem-1.12.2-3.el7.noarch                                               1/9 
  Installing : 1:nginx-mod-http-xslt-filter-1.12.2-3.el7.x86_64                                     2/9 
  Installing : 1:nginx-mod-http-perl-1.12.2-3.el7.x86_64                                            3/9 
  Installing : 1:nginx-mod-http-image-filter-1.12.2-3.el7.x86_64                                    4/9 
  Installing : 1:nginx-mod-mail-1.12.2-3.el7.x86_64                                                 5/9 
  Installing : 1:nginx-mod-stream-1.12.2-3.el7.x86_64                                               6/9 
  Installing : 1:nginx-mod-http-geoip-1.12.2-3.el7.x86_64                                           7/9 
  Installing : 1:nginx-all-modules-1.12.2-3.el7.noarch                                              8/9 
  Installing : 1:nginx-1.12.2-3.el7.x86_64                                                          9/9 
  Verifying  : 1:nginx-all-modules-1.12.2-3.el7.noarch                                              1/9 
  Verifying  : 1:nginx-mod-http-xslt-filter-1.12.2-3.el7.x86_64                                     2/9 
  Verifying  : 1:nginx-mod-http-perl-1.12.2-3.el7.x86_64                                            3/9 
  Verifying  : 1:nginx-mod-http-image-filter-1.12.2-3.el7.x86_64                                    4/9 
  Verifying  : 1:nginx-1.12.2-3.el7.x86_64                                                          5/9 
  Verifying  : 1:nginx-filesystem-1.12.2-3.el7.noarch                                               6/9 
  Verifying  : 1:nginx-mod-mail-1.12.2-3.el7.x86_64                                                 7/9 
  Verifying  : 1:nginx-mod-stream-1.12.2-3.el7.x86_64                                               8/9 
  Verifying  : 1:nginx-mod-http-geoip-1.12.2-3.el7.x86_64                                           9/9 

Installed:
  nginx.x86_64 1:1.12.2-3.el7                                                                           

Dependency Installed:
  nginx-all-modules.noarch 1:1.12.2-3.el7         nginx-filesystem.noarch 1:1.12.2-3.el7                
  nginx-mod-http-geoip.x86_64 1:1.12.2-3.el7      nginx-mod-http-image-filter.x86_64 1:1.12.2-3.el7     
  nginx-mod-http-perl.x86_64 1:1.12.2-3.el7       nginx-mod-http-xslt-filter.x86_64 1:1.12.2-3.el7      
  nginx-mod-mail.x86_64 1:1.12.2-3.el7            nginx-mod-stream.x86_64 1:1.12.2-3.el7                

Complete!
[root@center ~]# 

配置Nginx:

[root@center ~]# mkdir /opt/ngxlog
[root@center ~]# 
[root@center ~]# cp -f /opt/bigops/install/lnmp_conf/nginx.conf /etc/nginx/nginx.conf
cp: overwrite ‘/etc/nginx/nginx.conf’? y
[root@center ~]# 
[root@center ~]# cp -f /opt/bigops/install/lnmp_conf/conf.d/default.conf /etc/nginx/conf.d/default.conf
[root@center ~]# 
[root@center ~]# cp -f /opt/bigops/install/lnmp_conf/conf.d/sso.conf /etc/nginx/conf.d/sso.conf
[root@center ~]# 
[root@center ~]# cp -f /opt/bigops/install/lnmp_conf/conf.d/work.conf /etc/nginx/conf.d/work.conf
[root@center ~]# 
[root@center ~]# cp -f /opt/bigops/install/lnmp_conf/conf.d/zabbix.conf /etc/nginx/conf.d/zabbix.conf
[root@center ~]# 
[root@center ~]# cd /etc/nginx/conf.d/
[root@center conf.d]# 
[root@center conf.d]# ls -ltr
total 16
-rw-r--r-- 1 root root 1093 Jul 11 20:57 default.conf
-rw-r--r-- 1 root root 1164 Jul 11 20:58 sso.conf
-rw-r--r-- 1 root root 1547 Jul 11 20:58 work.conf
-rw-r--r-- 1 root root  740 Jul 11 20:58 zabbix.conf
[root@center conf.d]# 

配置:BigOps

[root@center ~]# cd /opt/bigops/config/
[root@center config]# ls -ltr
total 12
drwxr-xr-x 2 root root   99 Jul  8 09:44 tomcat_key
drwxr-xr-x 2 root root 4096 Jul  8 09:44 nginx_key
-rw-r--r-- 1 root root 1636 Jul 10 12:36 bigops.properties
-rw-r--r-- 1 root root 1636 Jul 10 12:36 bigops.properties.example
[root@center config]# 
[root@center config]# vi bigops.properties
[root@center config]# 
[root@center config]# cat bigops.properties
######### sso #########
cas.ticket.registry.jpa.ddlAuto=validate
cas.ticket.registry.jpa.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
cas.serviceRegistry.jpa.ddlAuto=update
cas.serviceRegistry.jpa.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
cas.ticket.tgt.rememberMe.timeToKillInSeconds=1209600
cas.ticket.tgt.max-time-to-live-in-seconds=1209600
cas.ticket.tgt.time-to-kill-in-seconds=1209600
sso.client.session.expire.time=604800
sso.client.cookie.expire.time=604800

######### mysql parameter #########
spring.datasource.druid.initial-size=20
spring.datasource.druid.max-active=100
spring.datasource.druid.min-idle=5
spring.datasource.druid.max-wait=60000
spring.datasource.druid.max-pool-prepared-statement-per-connection-size=20
spring.datasource.druid.max-open-prepared-statements=20
spring.datasource.druid.validation-query=SELECT 1
spring.datasource.druid.validation-query-timeout=30000
spring.datasource.druid.testWhileIdle=true
spring.datasource.druid.timeBetweenEvictionRunsMillis=7200
spring.datasource.driverClassName=com.mysql.jdbc.Driver

######### main #########
sso.url=http://sso.bigops.com
home.url=http://work.bigops.com
sso.principal.attributes=id,name,account,email,mobile,weixin,dingding

######### database #########
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/bigops?useSSL=false&useUnicode=true&autoReconnect=true&characterEncoding=UTF-8
spring.datasource.username=admin
spring.datasource.password=bigops

######## es ###########
elasticsearch.ip=127.0.0.1
elasticsearch.port=9300
elasticsearch.pool=5
elasticsearch.cluster.name=bigops
elasticsearch.shardCount=5
elasticsearch.repliceCount=1
[root@center config]# 

上面需要注意【database】部分,【username / password】需要填写正确;
其中【spring.datasource.url】中的【IP地址】填写你的环境里实际的地址;
否则,后面,会报错;错误信息如下:

[root@center ~]# tail -f /opt/bigops/log/bigserver.log 
2019-07-11 21:08:29 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.

2019-07-11 21:09:36 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:09:36 - [ INFO ] sysman - startTime:2019-07-11 21:09:36
2019-07-11 21:10:43 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:10:43 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:10:43 - [ ERROR ] nullselect h.bigproxy,s.host_id,s.ip,s.port,s.user,s.pass from hostsession s,ri_host h where h.id=s.host_id and s.user_type=1 and s.test_pass_status=1 and s.host_id in(select id from ri_host where system_cat='Linux')
2019-07-11 21:10:43 - [ INFO ] sysman - 没发现hostsession
2019-07-11 21:11:50 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:12:58 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:12:58 - [ ERROR ] nullselect * from clean_history_data
2019-07-11 21:12:58 - [ INFO ] clean_history_data - CleanHistoryData 没有查到要清理数据
2019-07-11 21:12:58 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:14:05 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:15:12 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:16:19 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:17:26 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:17:26 - [ ERROR ] nullselect h.bigproxy,h.system_cat,s.id,s.host_id,s.ip,s.proto,s.port,s.user,s.pass,s.pass_auth,s.key_auth,s.ssh_priv,s.allow_test,s.test_pass_time,s.test_key_time from ri_host h ,hostsession s where h.id=s.host_id and s.user_type=1 and s.proto in (?,?,?,?,?,?,?,?)
2019-07-11 21:17:26 - [ INFO ] hostsession_test - 没发现 [rdp, ssh, mysql, telnet, vnc, mssql, snmpv1, snmpv2] 的 hostsession
2019-07-11 21:17:26 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:17:26 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:18:33 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:18:33 - [ ERROR ] nullselect id,bigproxy from ip_subnet where type=2
2019-07-11 21:18:33 - [ INFO ] nmap - 没有符合条件的ipsubnet列表
2019-07-11 21:18:33 - [ INFO ] nmap - 完成
2019-07-11 21:18:33 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:19:40 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:19:40 - [ ERROR ] nullselect * from ri_user where account= ? 
2019-07-11 21:19:40 - [ ERROR ] zabbix 登录失败
2019-07-11 21:19:40 - [ ERROR ] Could not create connection to database server. Attempted reconnect 3 times. Giving up.
2019-07-11 21:19:41 - [ ERROR ] com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Could not create connection to database server. Attempted reconnect 3 times. Giving up.

(过多的输出,...)

启动【BigOps】服务:

[root@center ~]# sh /opt/bigops/sbin/bigserver.sh start
start bigserver ......
[root@center ~]#

启动过程中的日志:

[root@center ~]# tail -f /opt/bigops/log/bigserver.log 
2019-07-11 21:47:52 - [ INFO ] clean_duty_data - 清除 auto_pb_default_exec_host : 0条
2019-07-11 21:47:52 - [ INFO ] clean_duty_data - 清除 t_user_role : 0条
2019-07-11 21:47:52 - [ INFO ] clean_duty_data - 清除 CleanDutyData 完成
2019-07-11 21:47:53 - [ ERROR ] zabbix 登录失败
2019-07-11 21:47:53 - [ INFO ] bind_monhost - 成功智能映射了[0]个主机
2019-07-11 21:47:53 - [ INFO ] bigops同步权限到zbx开始
2019-07-11 21:57:52 - [ INFO ] check_ipbindhost - 检查完成
2019-07-11 22:02:51 - [ INFO ] nmap - 没有符合条件的ipsubnet列表
2019-07-11 22:02:51 - [ INFO ] nmap - 完成
2019-07-11 22:07:52 - [ INFO ] check_ipbindhost - 检查完成


============


2019-07-11 22:17:24 - [ INFO ] sysman - startTime:2019-07-11 22:17:24
2019-07-11 22:17:24 - [ INFO ] clean_history_data - 清除主机发现日志0条
2019-07-11 22:17:24 - [ INFO ] clean_history_data - 清除重置密码临时Token0条
2019-07-11 22:17:24 - [ INFO ] clean_history_data - 清除 CleanHistoryData 完成
2019-07-11 22:17:24 - [ INFO ] nmap - 没有符合条件的ipsubnet列表
2019-07-11 22:17:24 - [ INFO ] nmap - 完成
2019-07-11 22:17:24 - [ INFO ] sysman - 没发现hostsession
2019-07-11 22:17:24 - [ INFO ] hostsession_test - 没发现 [rdp, ssh, mysql, telnet, vnc, mssql, snmpv1, snmpv2] 的 hostsession
2019-07-11 22:17:24 - [ INFO ] res_update - 清除7天前的alertlog --0条
2019-07-11 22:17:24 - [ INFO ] res_update - 没有发现hostsession
2019-07-11 22:17:24 - [ INFO ] res_update - 完成
2019-07-11 22:17:24 - [ INFO ] check_ipbindhost - 检查完成
2019-07-11 22:17:24 - [ INFO ] scan_host - 完成
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_host_hw : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_host_service_tree : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_hw_position : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_user_org : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_user_referer : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 r_user_usergroup : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_user_pref : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 res_changelog : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 search : 0条
2019-07-11 22:17:24 - [ INFO ] clean_duty_data - 清除 sysman_connections_detail : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 sysman_crontab_detail : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 sysman_iptables_rule : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 sysman_ps_detail : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 sysman_sockets_detail : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 t_user_role : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 msg_box : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 hw_port : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 hostdebug : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 hostsession : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 desktop_user_pref : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 desktop_user_pref_shortcut : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 ip_db : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 log_login : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 log_operation : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 auto_pb_default_exec_host : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 t_user_role : 0条
2019-07-11 22:17:25 - [ INFO ] clean_duty_data - 清除 CleanDutyData 完成
2019-07-11 22:17:25 - [ ERROR ] zabbix 登录失败
2019-07-11 22:17:25 - [ INFO ] bind_monhost - 成功智能映射了[0]个主机
2019-07-11 22:17:25 - [ INFO ] bigops同步权限到zbx开始

2019-07-11 22:27:24 - [ INFO ] check_ipbindhost - 检查完成
2019-07-11 22:32:24 - [ INFO ] nmap - 没有符合条件的ipsubnet列表
2019-07-11 22:32:24 - [ INFO ] nmap - 完成

启动后检查:

[root@center ~]# ps -ef | grep bigserver
root      2243  2197  0 22:16 pts/2    00:00:00 tail -f /opt/bigops/log/bigserver.log
root      2268     1  0 22:17 pts/0    00:00:03 java -jar -Xms1G -Xmx1G bigserver.jar
root      2726  2120  0 22:33 pts/0    00:00:00 grep --color=auto bigserver
[root@center ~]# 
[root@center ~]# netstat -tupln | grep java
tcp6       0      0 127.0.0.1:60001         :::*                    LISTEN      2268/java           
[root@center ~]# 

有时候,你可能会遇到这样的错误:

[root@center ~]# 
com.zabbix4j.ZabbixApiException: HTTP Error : <html>
<head><title>502 Bad Gateway</title></head>
<body>
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx/1.16.0</center>
</body>
</html>

        at com.zabbix4j.ZabbixApiMethod.sendRequest(ZabbixApiMethod.java:79)
        at com.zabbix4j.user.User.login(User.java:50)
        at com.zabbix4j.ZabbixApi.login(ZabbixApi.java:92)
        at com.yunweibang.tool.util.ZBXGetUtil.login(ZBXGetUtil.java:437)
        at com.yunweibang.tool.runnable.BindHostRunnable.run(BindHostRunnable.java:25)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:748)

[root@center ~]# 

不过,它们似乎是可以忽略的?


然后,使用浏览器访问BigOps:
http://work.bigops.com

这里需要注意:
文件【/etc/hosts】,【Nginx】配置文件【config.d】,以及【主机名:hostname】的域名设置必须一致;
否则,在这一步打开页面的时候,你可能遇到【505】的错误。

如果没有异常,你打开的画面应该是这样的:

浏览器的URL,会自动的从【work.bigops.com】跳转到:
http://sso.bigops.com/signin/login?service=http://work.bigops.com/api/auth/login?locationhref=http://work.bigops.com/

默认的登录口令是:【admin / bigops】

不过有时候,可能,你会遇到问题:输入密码后,提示用户名与密码错误:

BigOps的用户信息存放在MySQL的数据库中:

[root@center ~]# mysql -u root -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 21
Server version: 8.0.16 MySQL Community Server - GPL

Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> 
mysql> use bigops
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> 
mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| bigops             |
| information_schema |
| mysql              |
| performance_schema |
| sys                |
+--------------------+
5 rows in set (0.00 sec)

mysql> 
mysql> show tables;
+--------------------------------+
| Tables_in_bigops               |
+--------------------------------+
| alert                          |
| alert_api                      |
| alert_compress                 |
| alert_operation                |
| alert_rule                     |
| alert_rule_and                 |
| alert_rule_or                  |
| auto_op                        |
| auto_op_cat                    |
| auto_op_parm                   |
| auto_pb                        |
| auto_pb_default_exec_host      |
| auto_pb_log                    |
| auto_pb_log_detail             |
| auto_pb_op                     |
| auto_pb_op_parm                |
| avatar                         |
| bastion_cmd_filter             |
| bastion_mysession_display      |
| bastion_setting                |
| bg_img                         |
| check_report                   |
| check_result                   |
| checkitem                      |
| checkitem_cat                  |
| checkitem_exclude              |
| checkitem_include              |
| clean_duty_data                |
| clean_history_data             |
| cloud                          |
| company                        |
| deploy                         |
| deploy_history                 |
| desktop_shortcut               |
| desktop_user_pref              |
| desktop_user_pref_shortcut     |
| discovery_history              |
| discovery_rule                 |
| env                            |
| hostdebug                      |
| hostsession                    |
| hw_port                        |
| hw_position                    |
| icon                           |
| ip_db                          |
| ip_subnet                      |
| locks                          |
| log_login                      |
| log_operation                  |
| mon_alarm_api                  |
| mon_zabbix_api                 |
| msg_box                        |
| msg_send_history               |
| nav_desktop                    |
| nav_sysadmin                   |
| notifications                  |
| org                            |
| r_host_hw                      |
| r_host_service_tree            |
| r_hw_position                  |
| r_user_org                     |
| r_user_referer                 |
| r_user_usergroup               |
| regexregisteredservice         |
| regexregisteredserviceproperty |
| registeredservice_contacts     |
| registeredserviceimpl_props    |
| registeredserviceimplcontact   |
| res_api                        |
| res_cat                        |
| res_changelog                  |
| res_model                      |
| res_relation                   |
| res_user_pref                  |
| ri_firewall                    |
| ri_host                        |
| ri_router                      |
| ri_server                      |
| ri_switch                      |
| ri_user                        |
| search                         |
| service_tree                   |
| serviceticket                  |
| sms_history                    |
| sms_sp                         |
| sms_template                   |
| software                       |
| sso_auth                       |
| sso_find_pwd                   |
| sys_setting                    |
| sysbak_filebaklog              |
| sysbak_filebakplan             |
| sysman_common                  |
| sysman_connections_detail      |
| sysman_crontab_detail          |
| sysman_iptables_global_rule    |
| sysman_iptables_rule           |
| sysman_iptables_table          |
| sysman_ps_detail               |
| sysman_sockets_detail          |
| sysman_sysctl_detail           |
| t_right                        |
| t_role                         |
| t_role_hostsession             |
| t_role_right                   |
| t_role_service_tree            |
| t_router                       |
| t_user_role                    |
| t_usergroup_role               |
| ticketgrantingticket           |
| transientsessionticket         |
| usergroup                      |
| workorder                      |
| workorder_setting              |
+--------------------------------+
114 rows in set (0.00 sec)

mysql>
mysql> desc ri_user;
+------------+--------------+------+-----+-------------------+-----------------------------------------------+
| Field      | Type         | Null | Key | Default           | Extra                                         |
+------------+--------------+------+-----+-------------------+-----------------------------------------------+
| id         | bigint(20)   | NO   | PRI | NULL              | auto_increment                                |
| ctime      | datetime     | YES  |     | CURRENT_TIMESTAMP | DEFAULT_GENERATED                             |
| mtime      | datetime     | YES  |     | CURRENT_TIMESTAMP | DEFAULT_GENERATED on update CURRENT_TIMESTAMP |
| mfa_secret | varchar(255) | YES  |     | NULL              |                                               |
| ssh_pri    | text         | YES  |     | NULL              |                                               |
| ssh_pub    | text         | YES  |     | NULL              |                                               |
| name       | varchar(255) | YES  |     | NULL              |                                               |
| account    | varchar(255) | YES  |     | NULL              |                                               |
| nickname   | varchar(255) | YES  |     | NULL              |                                               |
| pass       | varchar(255) | YES  |     | NULL              |                                               |
| email      | varchar(255) | YES  |     | NULL              |                                               |
| phone      | varchar(255) | YES  |     | NULL              |                                               |
| mobile     | varchar(255) | YES  |     | NULL              |                                               |
| weixin     | varchar(255) | YES  |     | NULL              |                                               |
| dingding   | varchar(255) | YES  |     | NULL              |                                               |
| mfa        | varchar(255) | YES  |     | NULL              |                                               |
| status     | varchar(255) | YES  |     | NULL              |                                               |
| etime      | datetime     | YES  |     | NULL              |                                               |
+------------+--------------+------+-----+-------------------+-----------------------------------------------+
18 rows in set (0.00 sec)

mysql> select name,pass,email from ri_user;
+-----------+--------------------------------------------------------------+-------+
| name      | pass                                                         | email |
+-----------+--------------------------------------------------------------+-------+
| 管理员    | $2a$10$Ew.Als4IDP3ItKY9XZX0OeXd1xUStDHlQObZrHtVEFhdI5NZqNTKC | NULL  |
+-----------+--------------------------------------------------------------+-------+
1 row in set (0.00 sec)

mysql> select id,name,account,pass,email,mobile,status from ri_user;
+----+-----------+---------+--------------------------------------------------------------+-------+--------+--------+
| id | name      | account | pass                                                         | email | mobile | status |
+----+-----------+---------+--------------------------------------------------------------+-------+--------+--------+
|  1 | 管理员    | admin   | $2a$10$Ew.Als4IDP3ItKY9XZX0OeXd1xUStDHlQObZrHtVEFhdI5NZqNTKC | NULL  | NULL   | 启用   |
+----+-----------+---------+--------------------------------------------------------------+-------+--------+--------+
1 row in set (0.00 sec)

mysql> 
mysql> desc log_login;
+------------+--------------+------+-----+-------------------+-------------------+
| Field      | Type         | Null | Key | Default           | Extra             |
+------------+--------------+------+-----+-------------------+-------------------+
| id         | bigint(20)   | NO   | PRI | NULL              | auto_increment    |
| account    | varchar(128) | YES  |     | NULL              |                   |
| status     | varchar(64)  | YES  |     | NULL              |                   |
| operation  | varchar(64)  | YES  |     | NULL              |                   |
| content    | varchar(128) | YES  |     | NULL              |                   |
| login_type | varchar(64)  | YES  |     | NULL              |                   |
| ip         | varchar(64)  | YES  |     | NULL              |                   |
| city       | varchar(128) | YES  |     | NULL              |                   |
| ctime      | datetime     | YES  |     | CURRENT_TIMESTAMP | DEFAULT_GENERATED |
+------------+--------------+------+-----+-------------------+-------------------+
9 rows in set (0.00 sec)

mysql> select id,account,status,city from log_login;
+----+---------+--------+-----------+
| id | account | status | city      |
+----+---------+--------+-----------+
|  1 | admin   | 成功   | 北京市    |
+----+---------+--------+-----------+
1 row in set (0.00 sec)

mysql> 

也许,可以通过修改数据库表的记录,来找回密码?

跟着官方文档的步骤,走到这里,就走不下去了;
我看的官方文档的版本是:2019年7月10日左右的官方文档。

五、二进制安装(自动版本)

获取自动安装脚本:
https://raw.githubusercontent.com/yunweibang/bigops-install/master/newos_install.sh

将脚本上传服务器:

[root@center bigops]# pwd
/software/bigops
[root@center bigops]# 
[root@center bigops]# ls -ltr
total 566972
-rw-r--r-- 1 root root 580577454 Jul 10 21:13 bigops-1.0.0.tar.gz
[root@center bigops]# 
[root@center bigops]# vi bigops_auto_install.sh
[root@center bigops]# 
[root@center bigops]# ls -ltr
total 566980
-rw-r--r-- 1 root root 580577454 Jul 10 21:13 bigops-1.0.0.tar.gz
-rw-r--r-- 1 root root      6142 Jul 12 23:18 bigops_auto_install.sh
[root@center bigops]# 
[root@center bigops]# cat bigops_auto_install.sh 
#!/bin/sh

stty erase '^H'

setenforce 0
if [ -f /etc/sysconfig/selinux ];then
    sed -i 's/SELINUX=.*/SELINUX=disabled/g' /etc/sysconfig/selinux
fi
if [ -f /etc/selinux/config ];then
    sed -i 's/SELINUX=.*/SELINUX=disabled/g' /etc/selinux/config
fi

/bin/sh /opt/bigops/bin/check_env.sh

cp -f /opt/bigops/install/yum.repos.d/* /etc/yum.repos.d/

which "make" > /dev/null
if [ $? != 0 ];then
    yum -y install make
fi

which "gcc" > /dev/null
if [ $? != 0 ];then
    yum -y install gcc
fi

which "g++" > /dev/null
if [ $? != 0 ];then
    yum -y install gcc-c++
fi

medusainst(){
    yum -y install openssl openssl-libs openssl-devel
    cd /opt/bigops/install/soft/
    tar zxvf libssh2-1.8.2.tar.gz
    cd libssh2-1.8.2
    ./configure --prefix=/usr
    make && make install
    cd /opt/bigops/install/soft/
    tar zxvf medusa-2.2.tar.gz
    cd medusa-2.2
    ./configure --prefix=/usr --enable-module-ssh=yes
    make && make install
}

which "/usr/bin/medusa" > /dev/null
if [ $? != 0 ];then
    medusainst
else
    if [ -z "$(/usr/bin/medusa -d|grep ssh.mod)" ];then
        medusainst
    fi
    if [ -z "$(/usr/bin/medusa -V|egrep v2.2)" ];then
        medusainst
    fi
fi


if [ -z "$(nmap -V|egrep 7.70)" ];then
    cd /opt/bigops/install/soft/
    tar zxvf nmap-7.70.tgz
    cd nmap-7.70
    ./configure --prefix=/usr
    make && make install
fi

which "ansible" > /dev/null
if [ $? != 0 ];then
    yum -y install ansible
fi
cp -f /opt/bigops/install/ansible.cfg /root/.ansible.cfg
sed -i 's/^[ ]*StrictHostKeyChecking.*/StrictHostKeyChecking no/g' /etc/ssh/ssh_config

if [ -f /usr/bin/jqbak ];then
    cp -f /opt/bigops/install/soft/jq-linux64 /usr/bin/jq
else
    cp  /usr/bin/jq /usr/bin/jqbak
    cp -f /opt/bigops/install/soft/jq-linux64 /usr/bin/jq
fi
chmod 777 /usr/bin/jq

which "nginx" > /dev/null
if [ $? != 0 ];then
    yum -y install nginx
fi

if [ ! -d /opt/ngxlog/ ];then
    mkdir /opt/ngxlog
fi

cp -f /opt/bigops/config/bigops.properties.example /opt/bigops/config/bigops.properties

echo
echo
echo ----------------------------------
echo -e "please input sso url, default sso.bigops.com"
echo -e ">\c"
read ssourl
ssourl=`echo "${ssourl}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`
if [ -z "${ssourl}" ];then
    ssourl='sso.bigops.com'
fi

echo -e "please input home url, default work.bigops.com"
echo -e ">\c"
read homeurl
homeurl=`echo "${homeurl}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`
if [ -z "${homeurl}" ];then
    homeurl='work.bigops.com'
fi

cp -f /opt/bigops/install/lnmp_conf/nginx.conf /etc/nginx/nginx.conf
cp -f /opt/bigops/install/lnmp_conf/conf.d/default.conf /etc/nginx/conf.d/default.conf
cp -f /opt/bigops/install/lnmp_conf/conf.d/sso.conf /etc/nginx/conf.d/sso.conf
cp -f /opt/bigops/install/lnmp_conf/conf.d/work.conf /etc/nginx/conf.d/work.conf
cp -f /opt/bigops/install/lnmp_conf/conf.d/zabbix.conf /etc/nginx/conf.d/zabbix.conf

sed -i "s#^[ \t]*server_name.*#    server_name ${ssourl};#g" /etc/nginx/conf.d/sso.conf
sed -i "s#^[ \t]*server_name.*#    server_name ${homeurl};#g" /etc/nginx/conf.d/work.conf

sed -i "s#^[ \t]*access_log.*#    access_log  /opt/ngxlog/${ssourl}.access.log main;#g" /etc/nginx/conf.d/sso.conf
sed -i "s#^[ \t]*access_log.*#    access_log  /opt/ngxlog/${homeurl}.access.log main;#g" /etc/nginx/conf.d/work.conf

sed -i "s#^[ \t]*error_log.*#    error_log  /opt/ngxlog/${ssourl}.error.log;#g" /etc/nginx/conf.d/sso.conf
sed -i "s#^[ \t]*error_log.*#    error_log  /opt/ngxlog/${homeurl}.error.log;#g" /etc/nginx/conf.d/work.conf

sed -i "s#^sso.url=.*#sso.url=http://${ssourl}#g" /opt/bigops/config/bigops.properties
sed -i "s#^home.url=.*#home.url=http://${homeurl}#g" /opt/bigops/config/bigops.properties

echo -e "please input db host, default 127.0.0.1"
echo -e ">\c"
read dbhost

echo -e "please input db port, default 3306"
echo -e ">\c"
read dbport

echo -e "please input db name, default bigops"
echo -e ">\c"
read dbname

echo -e "please input db user, default root"
echo -e ">\c"
read dbuser

echo -e "please input db pass"
echo -e ">\c"
read dbpass

if [ -z "${dbhost}" ];then
    dbhost='127.0.0.1'
fi
if [ -z "${dbport}" ];then
    dbport='3306'
fi
if [ -z "${dbname}" ];then
    dbname='bigops'
fi
if [ -z "${dbuser}" ];then
    dbuser='root'
fi
if [ -z "${dbpass}" ];then
    echo 'please input db pass'
    exit
fi

dbhost=`echo "${dbhost}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`
dbport=`echo "${dbport}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`
dbname=`echo "${dbname}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`
dbuser=`echo "${dbuser}"|sed 's/^[ ]*//g'|sed 's/[ ]*$//g'`

sed -i "s#^spring.datasource.url=.*#spring.datasource.url=jdbc:mysql://${dbhost}:${dbport}/${dbname}\
\?useSSL=false\&useUnicode=true\&autoReconnect=true\&characterEncoding=UTF-8#g" /opt/bigops/config/bigops.properties
sed -i "s#^spring.datasource.username=.*#spring.datasource.username=${dbuser}#g" /opt/bigops/config/bigops.properties
sed -i "s#^spring.datasource.password=.*#spring.datasource.password=${dbpass}#g" /opt/bigops/config/bigops.properties

echo
echo ----------------------------------
mysqladmin -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport} drop ${dbname} 2>/dev/null
if [ $? != 0 ];then echo "installation failed.code 1 exit";fi

echo
echo ----------------------------------
echo 'test command'
echo mysql -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport}
echo
echo ----------------------------------

mysql -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport} -e "create database ${dbname}" 2>/dev/null
if [ $? != 0 ];then echo "installation failed. code 2 exit";exit;fi

mysql -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport} ${dbname} </opt/bigops/install/mysql/bigops-1.0.0.sql 2>/dev/null
if [ $? != 0 ];then echo "installation failed. code 3 exit";exit;fi

echo 'Display installed database'
mysql -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport} -e "show databases like '${dbname}'" 2>/dev/null
mysql -u${dbuser} -p${dbpass} -h${dbhost} -P${dbport} -e "use ${dbname};show tables like '%egistered%'" 2>/dev/null
if [ $? == 0 ];then
    echo
    echo ----------------------------------
    /bin/sh /opt/bigops/bin/restart.sh
else
    echo "installation failed. code 4 exit"
fi
[root@center bigops]# 

执行:

[root@center bigops]# ps -ef | grep yum
root      4639  1325 10 23:16 ?        00:00:19 /usr/bin/python /usr/share/PackageKit/helpers/yum/yumBackend.py get-updates none
root      4952  4707  0 23:19 pts/3    00:00:00 grep --color=auto yum
[root@center bigops]# 
[root@center bigops]# kill -9 4639
[root@center bigops]# 
[root@center bigops]# ps -ef | grep yum
root      4966  4707  0 23:20 pts/3    00:00:00 grep --color=auto yum
[root@center bigops]# 
[root@center bigops]# cd /etc/yum.repos.d/
[root@center yum.repos.d]# 
[root@center yum.repos.d]# mv mysql* /backup/
[root@center yum.repos.d]# 
[root@center yum.repos.d]# ls -ltr
total 20
-rw-r--r-- 1 root root 2018 Jul 12 23:24 CentOS-Base.repo
-rw-r--r-- 1 root root 2492 Jul 12 23:24 tsinghua.repo
-rw-r--r-- 1 root root  756 Jul 12 23:24 remi.repo
-rw-r--r-- 1 root root  110 Jul 12 23:24 nginx.repo
-rw-r--r-- 1 root root  514 Jul 12 23:24 epel.repo
[root@center yum.repos.d]# 
[root@center yum.repos.d]# sed -i 's/\$releasever/7/g' *
[root@center yum.repos.d]# 
[root@center yum.repos.d]# sed -i '/gpgcheck/s/1/0/g' *
[root@center yum.repos.d]# 
[root@center yum.repos.d]# yum repolist
Loaded plugins: langpacks, ulninfo
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository epel is listed more than once in the configuration
Repository epel-debuginfo is listed more than once in the configuration
Repository epel-source is listed more than once in the configuration
repo id                          repo name                                                        status
base/x86_64                      CentOS-7 - Base - mirrors.aliyun.com                             10,019
epel/x86_64                      Extra Packages for Enterprise Linux 7 - x86_64                   13,297
extras/x86_64                    CentOS-7 - Extras - mirrors.aliyun.com                              419
nginx/x86_64                     nginx repo                                                          152
updates/x86_64                   CentOS-7 - Updates - mirrors.aliyun.com                           2,233
repolist: 26,120
[root@center yum.repos.d]# 
[root@center yum.repos.d]# cd /software/bigops/
[root@center bigops]# 
[root@center bigops]# ls -ltr 
total 566980
-rw-r--r-- 1 root root 580577454 Jul 10 21:13 bigops-1.0.0.tar.gz
-rw-r--r-- 1 root root      6143 Jul 13 11:15 bigops_auto_install.sh
[root@center bigops]# 
[root@center bigops]# cat bigops_auto_install.sh | grep "\/etc\/yum.repos.d"
#cp -f /opt/bigops/install/yum.repos.d/* /etc/yum.repos.d/
[root@center bigops]# 
[root@center bigops]# sh bigops_auto_install.sh 

(过多的输出,...)

Installed:
  ansible.noarch 0:2.8.1-1.el7                                                                          

Dependency Installed:
  PyYAML.x86_64 0:3.10-11.el7                      libyaml.x86_64 0:0.1.4-11.el7_0                     
  python-babel.noarch 0:0.9.6-8.el7                python-cffi.x86_64 0:1.6.0-5.el7                    
  python-enum34.noarch 0:1.0.4-1.el7               python-httplib2.noarch 0:0.9.2-1.el7                
  python-idna.noarch 0:2.4-1.el7                   python-ipaddress.noarch 0:1.0.16-2.el7              
  python-jinja2.noarch 0:2.7.2-3.el7_6             python-markupsafe.x86_64 0:0.11-10.el7              
  python-paramiko.noarch 0:2.1.1-9.el7             python-ply.noarch 0:3.4-11.el7                      
  python-pycparser.noarch 0:2.14-1.el7             python2-cryptography.x86_64 0:1.7.2-2.el7           
  python2-jmespath.noarch 0:0.9.0-3.el7            python2-pyasn1.noarch 0:0.1.9-7.el7                 
  sshpass.x86_64 0:1.06-2.el7                     

Complete!


----------------------------------
please input sso url, default sso.bigops.com
>sso.adamhuan.com
please input home url, default work.bigops.com
>work.adamhuan.com
please input db host, default 127.0.0.1
>127.0.0.1
please input db port, default 3306
>3306
please input db name, default bigops
>bigops                       
please input db user, default root
>root
please input db pass
>******

----------------------------------
Dropping the database is potentially a very bad thing to do.
Any data stored in the database will be destroyed.

Do you really want to drop the 'bigops' database [y/N] y
installation failed.code 1 exit

----------------------------------
test command
mysql -uroot -p**** -h127.0.0.1 -P3306

----------------------------------
Display installed database
+-------------------+
| Database (bigops) |
+-------------------+
| bigops            |
+-------------------+
+--------------------------------+
| Tables_in_bigops (%egistered%) |
+--------------------------------+
| regexregisteredservice         |
| regexregisteredserviceproperty |
| registeredservice_contacts     |
| registeredserviceimpl_props    |
| registeredserviceimplcontact   |
+--------------------------------+

----------------------------------
Using CATALINA_BASE:   /opt/bigops/sso
Using CATALINA_HOME:   /opt/bigops/sso
Using CATALINA_TMPDIR: /opt/bigops/sso/temp
Using JRE_HOME:        /opt/bigops/java
Using CLASSPATH:       /opt/bigops/sso/bin/bootstrap.jar:/opt/bigops/sso/bin/tomcat-juli.jar
Using CATALINA_PID:    /opt/bigops/sso/logs/tomcat.pid
PID file found but either no matching process was found or the current user does not have permission to stop the process. Stop aborted.
Using CATALINA_BASE:   /opt/bigops/workbe
Using CATALINA_HOME:   /opt/bigops/workbe
Using CATALINA_TMPDIR: /opt/bigops/workbe/temp
Using JRE_HOME:        /opt/bigops/java
Using CLASSPATH:       /opt/bigops/workbe/bin/bootstrap.jar:/opt/bigops/workbe/bin/tomcat-juli.jar
Using CATALINA_PID:    /opt/bigops/workbe/logs/tomcat.pid
PID file found but either no matching process was found or the current user does not have permission to stop the process. Stop aborted.
Using CATALINA_BASE:   /opt/bigops/sso
Using CATALINA_HOME:   /opt/bigops/sso
Using CATALINA_TMPDIR: /opt/bigops/sso/temp
Using JRE_HOME:        /opt/bigops/java
Using CLASSPATH:       /opt/bigops/sso/bin/bootstrap.jar:/opt/bigops/sso/bin/tomcat-juli.jar
Using CATALINA_PID:    /opt/bigops/sso/logs/tomcat.pid
Existing PID file found during start.
Removing/clearing stale PID file.
Tomcat started.
Using CATALINA_BASE:   /opt/bigops/workbe
Using CATALINA_HOME:   /opt/bigops/workbe
Using CATALINA_TMPDIR: /opt/bigops/workbe/temp
Using JRE_HOME:        /opt/bigops/java
Using CLASSPATH:       /opt/bigops/workbe/bin/bootstrap.jar:/opt/bigops/workbe/bin/tomcat-juli.jar
Using CATALINA_PID:    /opt/bigops/workbe/logs/tomcat.pid
Existing PID file found during start.
Removing/clearing stale PID file.
Tomcat started.
start bigserver ......
stop bigserver ......
start bigserver ......
[root@center bigops]# 

请注意,上面在启动脚本前,我注释了原版官方的自动安装脚本中关于YUM的配置。
因为,发现官方配置的YUM包有问题,所以,YUM的部分,是按照【清华大学YUM】去自己填写的。

[root@center bigops]# cat bigops_auto_install.sh | grep "\/etc\/yum.repos.d"
#cp -f /opt/bigops/install/yum.repos.d/* /etc/yum.repos.d/
[root@center bigops]# 

但是,不幸的是,最后还是有和前面手动安装一样的报错:

先暂时忽略这些【不幸】,继续往下走。

在上面自动执行最后,我们看到,官方的脚本实际上帮我们启动了BigOps的服务;
那么,现在,我们来看看这些服务的运行状态:

[root@center bigops]# ps -ef | grep bigserver
root      3751     1  0 11:26 pts/4    00:00:02 java -jar -Xms1G -Xmx1G bigserver.jar
[root@center bigops]# 
[root@center bigops]# netstat -tupln | grep java
tcp6       0      0 127.0.0.1:30000         :::*                    LISTEN      3715/java           
tcp6       0      0 127.0.0.1:30001         :::*                    LISTEN      3715/java           
tcp6       0      0 127.0.0.1:30002         :::*                    LISTEN      3731/java           
tcp6       0      0 127.0.0.1:30003         :::*                    LISTEN      3731/java           
tcp6       0      0 127.0.0.1:60001         :::*                    LISTEN      3751/java           
[root@center bigops]# 

启动了对很多端口的监听,这在上面我们根据官方文档手动安装的时候,似乎不一样:手动安装的时候,并没有这么多端口被监听。

验证一下SSO与WORK服务是否正常:

[root@center bigops]# curl 127.0.0.1:30001/signin/login
[root@center bigops]# curl 127.0.0.1:30003/api/common/ssourl/
{"code":0,"message":"ok","data":{"url":"http://sso.adamhuan.com"}}[root@center bigops]# 
[root@center bigops]# 

重启Nginx服务:

[root@center bigops]# service nginx status
Redirecting to /bin/systemctl status nginx.service
● nginx.service - nginx - high performance web server
   Loaded: loaded (/usr/lib/systemd/system/nginx.service; disabled; vendor preset: disabled)
   Active: inactive (dead)
     Docs: http://nginx.org/en/docs/
[root@center bigops]# 
[root@center bigops]# service nginx restart
Redirecting to /bin/systemctl restart nginx.service
[root@center bigops]# 
[root@center bigops]# service nginx status 
Redirecting to /bin/systemctl status nginx.service
● nginx.service - nginx - high performance web server
   Loaded: loaded (/usr/lib/systemd/system/nginx.service; disabled; vendor preset: disabled)
   Active: active (running) since Sat 2019-07-13 11:39:29 CST; 3s ago
     Docs: http://nginx.org/en/docs/
  Process: 4107 ExecStart=/usr/sbin/nginx -c /etc/nginx/nginx.conf (code=exited, status=0/SUCCESS)
 Main PID: 4108 (nginx)
   CGroup: /system.slice/nginx.service
           ├─4108 nginx: master process /usr/sbin/nginx -c /etc/nginx/nginx.conf
           ├─4109 nginx: worker process
           ├─4110 nginx: worker process
           ├─4111 nginx: worker process
           ├─4112 nginx: worker process
           ├─4116 nginx: worker process
           ├─4121 nginx: worker process
           ├─4123 nginx: worker process
           └─4125 nginx: worker process

Jul 13 11:39:29 center.adamhuan.com systemd[1]: Starting nginx - high performance web server...
Jul 13 11:39:29 center.adamhuan.com systemd[1]: PID file /var/run/nginx.pid not readable (yet?) af...rt.
Jul 13 11:39:29 center.adamhuan.com systemd[1]: Started nginx - high performance web server.
Hint: Some lines were ellipsized, use -l to show in full.
[root@center bigops]# 

接下来:
在MS Windows中,也就是我的外部电脑(我的实验是在虚拟机里面做的)的HOSTS中,要有到下面的记录:

  1. work.adamhuan.com
  2. sso.adamhuan.com

如下:

然后,访问BigOps的页面:
http://work.adamhuan.com

很遗憾,访问失败:

找不到 sso.adamhuan.com 的网页 找不到与以下网址对应的网页:http://sso.adamhuan.com/signin?service=http://work.adamhuan.com/api/auth/login?locationhref=http://work.adamhuan.com/
HTTP ERROR 404

而前面,手动安装的,没有这个问题。


终了,…

说点什么

avatar

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据

  Subscribe  
提醒