当前位置: 首页 > news >正文

Linux 73 LAMP4

LAMP

环境配置

hostnamectl
ip
yum install cmake
systemctl stop NetworkManager
firewalld
/etc/selinux/config
SELINUX=disabled
setenforce 0

yum install pcre-devel
yum install ncurses-devel
yum install openssl-devel


[root@localhost ~]# hostname
localhost.localdomain
[root@localhost ~]# hostnamectl set-hostname web
[root@localhost ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00inet 127.0.0.1/8 scope host lovalid_lft forever preferred_lft foreverinet6 ::1/128 scope hostvalid_lft forever preferred_lft forever
2: ens34: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000link/ether 00:0c:29:1d:53:3b brd ff:ff:ff:ff:ff:ffinet 192.168.235.15/24 brd 192.168.235.255 scope global ens34valid_lft forever preferred_lft foreverinet6 fe80::20c:29ff:fe1d:533b/64 scope linkvalid_lft forever preferred_lft forever
3: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default qlen 1000link/ether 52:54:00:2b:f9:1b brd ff:ff:ff:ff:ff:ffinet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0valid_lft forever preferred_lft forever
4: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master virbr0 state DOWN group default qlen 1000link/ether 52:54:00:2b:f9:1b brd ff:ff:ff:ff:ff:ff
[root@localhost ~]# yum repolist
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
源标识                                                           源名称                                                              状态
!local                                                           local yum                                                           4,070
soft                                                             soft yum                                                                1
repolist: 4,071
[root@localhost ~]# cd /etc/repos.yum.d
-bash: cd: /etc/repos.yum.d: 没有那个文件或目录
[root@localhost ~]# cd /etc/yum.repos.d
[root@localhost yum.repos.d]# ls
local.repo  repo.tar.gz  soft.repo
[root@localhost yum.repos.d]# cat local.repo
[local]
name=local yum
baseurl=file:///mnt
enabled=1
gpgcheck=0
[root@localhost yum.repos.d]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /run/media/caozx26/CentOS 7 x86_64
[root@localhost yum.repos.d]# cd /mnt
[root@localhost mnt]# ls
[root@localhost mnt]# mount -o ro /mnt /dev/sr0
mount: /mnt 不是一个块设备
[root@localhost mnt]# mount -o ro /dev/sro /mnt
mount: 特殊设备 /dev/sro 不存在
[root@localhost mnt]# mount -o ro /dev/sr0 /mnt
[root@localhost mnt]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /mnt
[root@localhost mnt]# chmod +x /etc/rc.local
[root@localhost mnt]# ll /etc/rc.local
lrwxrwxrwx. 1 root root 13 59 03:35 /etc/rc.local -> rc.d/rc.local
[root@localhost mnt]# echo 'mount -o ro /dev/sr0 /mnt'>>/etc/rc.local
[root@localhost mnt]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /mnt
[root@localhost mnt]# cd /etc/yum.repos.d
[root@localhost yum.repos.d]# ls
local.repo  repo.tar.gz  soft.repo
[root@localhost yum.repos.d]# yum clean all
已加载插件:fastestmirror, langpacks
正在清理软件源: local soft
Cleaning up list of fastest mirrors
[root@localhost yum.repos.d]# yum makecache
已加载插件:fastestmirror, langpacks
Determining fastest mirrors
local                                                                                                              | 3.6 kB  00:00:00
soft                                                                                                               | 2.9 kB  00:00:00
(1/7): local/group_gz                                                                                              | 153 kB  00:00:00
(2/7): local/filelists_db                                                                                          | 3.3 MB  00:00:00
(3/7): local/primary_db                                                                                            | 3.3 MB  00:00:00
(4/7): soft/filelists_db                                                                                           | 1.1 kB  00:00:00
(5/7): local/other_db                                                                                              | 1.3 MB  00:00:00
(6/7): soft/other_db                                                                                               | 1.2 kB  00:00:00
(7/7): soft/primary_db                                                                                             | 2.4 kB  00:00:00
元数据缓存已建立
[root@localhost yum.repos.d]# yum repolist
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
源标识                                                           源名称                                                              状态
local                                                            local yum                                                           4,070
soft                                                             soft yum                                                                1
repolist: 4,071
[root@localhost yum.repos.d]# sysatemctl status NetworkManager
bash: sysatemctl: 未找到命令...
[root@localhost yum.repos.d]# systemctl status NetworkManager
● NetworkManager.service - Network ManagerLoaded: loaded (/usr/lib/systemd/system/NetworkManager.service; disabled; vendor preset: enabled)Active: inactive (dead)Docs: man:NetworkManager(8)
[root@localhost yum.repos.d]# systemctl status firewalld
● firewalld.service - firewalld - dynamic firewall daemonLoaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)Active: inactive (dead)Docs: man:firewalld(1)
[root@localhost yum.repos.d]# setenforce 0
[root@localhost yum.repos.d]# 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=disable
# SELINUXTYPE= can take one of three values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted[root@localhost yum.repos.d]# vim /etc/selinux/config
[root@localhost yum.repos.d]# 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 values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted[root@localhost yum.repos.d]# yum install cmake
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 cmake.x86_64.0.2.8.12.2-2.el7 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                       架构                           版本                                    源                             大小
==========================================================================================================================================
正在安装:cmake                         x86_64                         2.8.12.2-2.el7                          local                         7.1 M事务概要
==========================================================================================================================================
安装  1 软件包总下载量:7.1 M
安装大小:27 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : cmake-2.8.12.2-2.el7.x86_64                                                                                           1/1验证中      : cmake-2.8.12.2-2.el7.x86_64                                                                                           1/1已安装:cmake.x86_64 0:2.8.12.2-2.el7完毕!
[root@localhost yum.repos.d]# yum install openssl-devel
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 openssl-devel.x86_64.1.1.0.2k-19.el7 将被 安装
--> 正在处理依赖关系 zlib-devel(x86-64),它被软件包 1:openssl-devel-1.0.2k-19.el7.x86_64 需要
--> 正在处理依赖关系 krb5-devel(x86-64),它被软件包 1:openssl-devel-1.0.2k-19.el7.x86_64 需要
--> 正在检查事务
---> 软件包 krb5-devel.x86_64.0.1.15.1-50.el7 将被 安装
--> 正在处理依赖关系 libverto-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 libselinux-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 libcom_err-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 keyutils-libs-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
---> 软件包 zlib-devel.x86_64.0.1.2.7-18.el7 将被 安装
--> 正在检查事务
---> 软件包 keyutils-libs-devel.x86_64.0.1.5.8-3.el7 将被 安装
---> 软件包 libcom_err-devel.x86_64.0.1.42.9-19.el7 将被 安装
---> 软件包 libselinux-devel.x86_64.0.2.5-15.el7 将被 安装
--> 正在处理依赖关系 libsepol-devel(x86-64) >= 2.5-10,它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
--> 正在处理依赖关系 pkgconfig(libsepol),它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
--> 正在处理依赖关系 pkgconfig(libpcre),它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
---> 软件包 libverto-devel.x86_64.0.0.2.5-4.el7 将被 安装
--> 正在检查事务
---> 软件包 libsepol-devel.x86_64.0.2.5-10.el7 将被 安装
---> 软件包 pcre-devel.x86_64.0.8.32-17.el7 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                                 架构                       版本                                  源                         大小
==========================================================================================================================================
正在安装:openssl-devel                           x86_64                     1:1.0.2k-19.el7                       local                     1.5 M
为依赖而安装:keyutils-libs-devel                     x86_64                     1.5.8-3.el7                           local                      37 kkrb5-devel                              x86_64                     1.15.1-50.el7                         local                     273 klibcom_err-devel                        x86_64                     1.42.9-19.el7                         local                      32 klibselinux-devel                        x86_64                     2.5-15.el7                            local                     187 klibsepol-devel                          x86_64                     2.5-10.el7                            local                      77 klibverto-devel                          x86_64                     0.2.5-4.el7                           local                      12 kpcre-devel                              x86_64                     8.32-17.el7                           local                     480 kzlib-devel                              x86_64                     1.2.7-18.el7                          local                      50 k事务概要
==========================================================================================================================================
安装  1 软件包 (+8 依赖软件包)总下载量:2.6 M
安装大小:5.8 M
Is this ok [y/d/N]: y
Downloading packages:
------------------------------------------------------------------------------------------------------------------------------------------
总计                                                                                                      397 kB/s | 2.6 MB  00:00:06
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : libsepol-devel-2.5-10.el7.x86_64                                                                                      1/9正在安装    : libcom_err-devel-1.42.9-19.el7.x86_64                                                                                 2/9正在安装    : pcre-devel-8.32-17.el7.x86_64                                                                                         3/9正在安装    : libselinux-devel-2.5-15.el7.x86_64                                                                                    4/9正在安装    : zlib-devel-1.2.7-18.el7.x86_64                                                                                        5/9正在安装    : libverto-devel-0.2.5-4.el7.x86_64                                                                                     6/9正在安装    : keyutils-libs-devel-1.5.8-3.el7.x86_64                                                                                7/9正在安装    : krb5-devel-1.15.1-50.el7.x86_64                                                                                       8/9正在安装    : 1:openssl-devel-1.0.2k-19.el7.x86_64                                                                                  9/9验证中      : libselinux-devel-2.5-15.el7.x86_64                                                                                    1/9验证中      : keyutils-libs-devel-1.5.8-3.el7.x86_64                                                                                2/9验证中      : libverto-devel-0.2.5-4.el7.x86_64                                                                                     3/9验证中      : zlib-devel-1.2.7-18.el7.x86_64                                                                                        4/9验证中      : pcre-devel-8.32-17.el7.x86_64                                                                                         5/9验证中      : 1:openssl-devel-1.0.2k-19.el7.x86_64                                                                                  6/9验证中      : libcom_err-devel-1.42.9-19.el7.x86_64                                                                                 7/9验证中      : krb5-devel-1.15.1-50.el7.x86_64                                                                                       8/9验证中      : libsepol-devel-2.5-10.el7.x86_64                                                                                      9/9已安装:openssl-devel.x86_64 1:1.0.2k-19.el7作为依赖被安装:keyutils-libs-devel.x86_64 0:1.5.8-3.el7        krb5-devel.x86_64 0:1.15.1-50.el7         libcom_err-devel.x86_64 0:1.42.9-19.el7libselinux-devel.x86_64 0:2.5-15.el7            libsepol-devel.x86_64 0:2.5-10.el7        libverto-devel.x86_64 0:0.2.5-4.el7pcre-devel.x86_64 0:8.32-17.el7                 zlib-devel.x86_64 0:1.2.7-18.el7完毕!
[root@localhost yum.repos.d]# yum install ncurses-devel.x86_64
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 ncurses-devel.x86_64.0.5.9-14.20130511.el7_4 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                           架构                       版本                                        源                         大小
==========================================================================================================================================
正在安装:ncurses-devel                     x86_64                     5.9-14.20130511.el7_4                       local                     712 k事务概要
==========================================================================================================================================
安装  1 软件包总下载量:712 k
安装大小:2.1 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : ncurses-devel-5.9-14.20130511.el7_4.x86_64                                                                            1/1验证中      : ncurses-devel-5.9-14.20130511.el7_4.x86_64                                                                            1/1已安装:ncurses-devel.x86_64 0:5.9-14.20130511.el7_4完毕!
[root@localhost yum.repos.d]#

MYSQL

useradd -r -s /sbin/nologin mysql

tar xf mysql

cd myql

vim cmake.sh

配置Mysql选项
数据目录 /usr/local/mysql/data
安装目录 /usr/local/mysql

-DCMAKE_INSTALL_PREFIX=/usr/local/mysql

chmod +x cmake.sh

./cmake.sh

[root@localhost yum.repos.d]# useradd -s -r /sbin/nologin mysql
useradd:无效的 shell“-r”
[root@localhost yum.repos.d]# useradd -r -s /sbin/nologin mysql
[root@localhost yum.repos.d]# cd /
[root@localhost /]# ls
bin  boot  dev  etc  home  lib  lib64  media  mnt  opt  proc  root  run  sbin  soft  soft1  srv  sys  tmp  usr  var
[root@localhost /]# cd ~
[root@localhost ~]# ls
anaconda-ks.cfg  httpd-2.4.37.tar.bz2  initial-setup-ks.cfg  mysql-5.6.31.tar.gz
[root@localhost ~]# tar xf mysql-5.6.31.tar.gz
[root@localhost ~]# ls
anaconda-ks.cfg  httpd-2.4.37.tar.bz2  initial-setup-ks.cfg  mysql-5.6.31  mysql-5.6.31.tar.gz
[root@localhost ~]# cd mysql-5.6.31/
[root@localhost mysql-5.6.31]# vim cmake.sh
[root@localhost mysql-5.6.31]# cat cmake.sh
cmake . \
-DCMAKE_INSTALL_PREFIX=/usr/local/mysql/ \
-DMYSQL_DATADIR=/usr/local/mysql/data \
-DENABLED_LOCAL_INFILE=1 \
-DWITH_INNOBASE_STORAGE_ENGINE=1 \
-DMYSQL_TCP_PORT=3306 \
-DDEFAULT_CHARSET=utf8mb4 \
-DDEFAULT_COLLATION=utf8mb4_general_ci \
-DWITH_EXTRA_CHARSETS=all \
-DMYSQL_USER=mysql
[root@localhost mysql-5.6.31]# chmod +x cmake.sh
[root@localhost mysql-5.6.31]# ./cmake.sh
-- Running cmake version 2.8.12.2
-- Found Git: /usr/bin/git (found version "1.8.3.1")
-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.8.5
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for SHM_HUGETLB
-- Looking for SHM_HUGETLB - found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found

make && make install

chown -R mysql.mysql /usr/local/mysql

rm -f /etc/my.cnf

cd /usr/local/mysql

./scripts/mysql_install_db --user=mysql
ll data

cp support-files/mysql.server /etc/init.d/mysql

service mysql start

-- Installing: /usr/local/mysql/sql-bench/test-ATIS
-- Installing: /usr/local/mysql/sql-bench/test-alter-table
-- Installing: /usr/local/mysql/sql-bench/test-big-tables
-- Installing: /usr/local/mysql/sql-bench/test-connect
-- Installing: /usr/local/mysql/sql-bench/test-create
-- Installing: /usr/local/mysql/sql-bench/test-insert
-- Installing: /usr/local/mysql/sql-bench/test-select
-- Installing: /usr/local/mysql/sql-bench/test-transactions
-- Installing: /usr/local/mysql/sql-bench/test-wisconsin
[root@localhost mysql-5.6.31]# ll /usr/local/mysql
总用量 48
drwxr-xr-x.  2 root root  4096 73 22:15 bin
-rw-r--r--.  1 root root 17987 517 2016 COPYING
drwxr-xr-x.  3 root root    18 73 22:15 data
drwxr-xr-x.  2 root root    55 73 22:15 docs
drwxr-xr-x.  3 root root  4096 73 22:15 include
drwxr-xr-x.  3 root root  4096 73 22:15 lib
drwxr-xr-x.  4 root root    30 73 22:15 man
drwxr-xr-x. 10 root root  4096 73 22:15 mysql-test
-rw-r--r--.  1 root root  2496 517 2016 README
drwxr-xr-x.  2 root root    30 73 22:15 scripts
drwxr-xr-x. 28 root root  4096 73 22:15 share
drwxr-xr-x.  4 root root  4096 73 22:15 sql-bench
drwxr-xr-x.  2 root root   136 73 22:15 support-files
[root@localhost mysql-5.6.31]# chown -R mysql.mysql /usr/local/mysql
[root@localhost mysql-5.6.31]# ll -d /usr/local/mysql
drwxr-xr-x. 13 mysql mysql 191 73 22:15 /usr/local/mysql
[root@localhost mysql-5.6.31]# rm -f /etc/my.cnf
[root@localhost mysql-5.6.31]# cd /usr/local/mysql
[root@localhost mysql]# ./scripts/mysql_install_db --user=mysql
Installing MySQL system tables...2025-07-03 22:32:19 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2025-07-03 22:32:19 0 [Note] ./bin/mysqld (mysqld 5.6.31) starting as process 34642 ...
2025-07-03 22:32:19 34642 [Note] InnoDB: Using atomics to ref count buffer pool pages
2025-07-03 22:32:19 34642 [Note] InnoDB: The InnoDB memory heap is disabled
2025-07-03 22:32:19 34642 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2025-07-03 22:32:19 34642 [Note] InnoDB: Memory barrier is not used
2025-07-03 22:32:19 34642 [Note] InnoDB: Compressed tables use zlib 1.2.3
2025-07-03 22:32:19 34642 [Note] InnoDB: Using CPU crc32 instructions
2025-07-03 22:32:19 34642 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2025-07-03 22:32:19 34642 [Note] InnoDB: Completed initialization of buffer pool
2025-07-03 22:32:19 34642 [Note] InnoDB: The first specified data file ./ibdata1 did not exist: a new database to be created!
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting file ./ibdata1 size to 12 MB
2025-07-03 22:32:19 34642 [Note] InnoDB: Database physically writes the file full: wait...
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting log file ./ib_logfile101 size to 48 MB
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting log file ./ib_logfile1 size to 48 MB
2025-07-03 22:32:20 34642 [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0
2025-07-03 22:32:20 34642 [Warning] InnoDB: New log files created, LSN=45781
2025-07-03 22:32:20 34642 [Note] InnoDB: Doublewrite buffer not found: creating new
2025-07-03 22:32:20 34642 [Note] InnoDB: Doublewrite buffer created
2025-07-03 22:32:20 34642 [Note] InnoDB: 128 rollback segment(s) are active.
2025-07-03 22:32:20 34642 [Warning] InnoDB: Creating foreign key constraint system tables.
2025-07-03 22:32:20 34642 [Note] InnoDB: Foreign key constraint system tables created
2025-07-03 22:32:20 34642 [Note] InnoDB: Creating tablespace and datafile system tables.
2025-07-03 22:32:20 34642 [Note] InnoDB: Tablespace and datafile system tables created.
2025-07-03 22:32:20 34642 [Note] InnoDB: Waiting for purge to start
2025-07-03 22:32:20 34642 [Note] InnoDB: 5.6.31 started; log sequence number 0
2025-07-03 22:32:20 34642 [Note] Binlog end
2025-07-03 22:32:20 34642 [Note] InnoDB: FTS optimize thread exiting.
2025-07-03 22:32:20 34642 [Note] InnoDB: Starting shutdown...
2025-07-03 22:32:21 34642 [Note] InnoDB: Shutdown completed; log sequence number 1625977
OKFilling help tables...2025-07-03 22:32:21 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2025-07-03 22:32:21 0 [Note] ./bin/mysqld (mysqld 5.6.31) starting as process 34676 ...
2025-07-03 22:32:21 34676 [Note] InnoDB: Using atomics to ref count buffer pool pages
2025-07-03 22:32:21 34676 [Note] InnoDB: The InnoDB memory heap is disabled
2025-07-03 22:32:21 34676 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2025-07-03 22:32:21 34676 [Note] InnoDB: Memory barrier is not used
2025-07-03 22:32:21 34676 [Note] InnoDB: Compressed tables use zlib 1.2.3
2025-07-03 22:32:21 34676 [Note] InnoDB: Using CPU crc32 instructions
2025-07-03 22:32:21 34676 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2025-07-03 22:32:21 34676 [Note] InnoDB: Completed initialization of buffer pool
2025-07-03 22:32:21 34676 [Note] InnoDB: Highest supported file format is Barracuda.
2025-07-03 22:32:21 34676 [Note] InnoDB: 128 rollback segment(s) are active.
2025-07-03 22:32:21 34676 [Note] InnoDB: Waiting for purge to start
2025-07-03 22:32:21 34676 [Note] InnoDB: 5.6.31 started; log sequence number 1625977
2025-07-03 22:32:21 34676 [Note] Binlog end
2025-07-03 22:32:21 34676 [Note] InnoDB: FTS optimize thread exiting.
2025-07-03 22:32:21 34676 [Note] InnoDB: Starting shutdown...
2025-07-03 22:32:23 34676 [Note] InnoDB: Shutdown completed; log sequence number 1625987
OKTo start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your systemPLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:./bin/mysqladmin -u root password 'new-password'./bin/mysqladmin -u root -h web password 'new-password'Alternatively you can run:./bin/mysql_secure_installationwhich will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.See the manual for more instructions.You can start the MySQL daemon with:cd . ; ./bin/mysqld_safe &You can test the MySQL daemon with mysql-test-run.plcd mysql-test ; perl mysql-test-run.plPlease report any problems at http://bugs.mysql.com/The latest information about MySQL is available on the web athttp://www.mysql.comSupport MySQL by buying support/licenses at http://shop.mysql.comNew default config file was created as ./my.cnf and
will be used by default by the server when you start it.
You may edit this file to change server settings[root@localhost mysql]# ll data
总用量 110600
-rw-rw----. 1 mysql mysql 12582912 73 22:32 ibdata1
-rw-rw----. 1 mysql mysql 50331648 73 22:32 ib_logfile0
-rw-rw----. 1 mysql mysql 50331648 73 22:32 ib_logfile1
drwx------. 2 mysql mysql     4096 73 22:32 mysql
drwx------. 2 mysql mysql     4096 73 22:32 performance_schema
drwxr-xr-x. 2 mysql mysql       20 73 22:15 test
[root@localhost mysql]# cp supports-files/mysql /etc/init.d/mysql
cp: 无法获取"supports-files/mysql" 的文件状态(stat): 没有那个文件或目录
[root@localhost mysql]# ls
bin  COPYING  data  docs  include  lib  man  my.cnf  mysql-test  README  scripts  share  sql-bench  support-files
[root@localhost mysql]# cp support-files/mysql /etc/init.d/mysql
cp: 无法获取"support-files/mysql" 的文件状态(stat): 没有那个文件或目录
[root@localhost mysql]# ls support-files/
binary-configure  magic  my-default.cnf  mysqld_multi.server  mysql-log-rotate  mysql.server
[root@localhost mysql]# cp support-files/mysql.server /etc/init.d/mysql
[root@localhost mysql]# service mysql start
Starting MySQL. SUCCESS!

cd /usr/local/mysql

bin/mysqladmin -u root password ‘123’

echo ‘export PATH=$PATH:/usr/local/mysql/bin’>/etc/profile

source /etc/profile

//The /etc/profile file is a ​​system-wide configuration file​​ in Linux and Unix-like systems that initializes environment variables and shell settings for all users during login sessions. Here’s a comprehensive breakdown:
​​Global Environment Variables​​: Sets variables like PATH, JAVA_HOME, and LANG for all users. For example:
​​2. Execution Scope & Order​​
​​Applies Only to Login Shells​​: Executes when users log in via SSH, terminal, or su - (not for non-login shells like new terminal tabs)

​​5. Common Issues & Fixes​​
​​Changes Not Applied​​:
Confirm login shell usage (e.g., su - user, not su user).
Check syntax errors via bash -n /etc/profile .
​​Login Failures​​:
Boot into recovery mode to restore a backup of /etc/profile
// ​​Critical Problems with This Command​​
​​Overwrites Entire /etc/profile​​
The > operator replaces the entire content of /etc/profile with only export PATH=$PATH:/usr/local/mysql/bin. This erases all existing system-wide configurations (e.g., default PATH, LANG, USER variables, security settings), potentially breaking login functionality for all users .
​​Breaks System-Wide Environment Settings​​
/etc/profile sets global variables (e.g., PATH, PS1, umask) and loads scripts from /etc/profile.d/. Overwriting it could:
Prevent users from logging in.
Disable critical system commands (e.g., sudo, ls) if their paths are removed .
​​Syntax Errors in PATH Handling​​
The command appends /usr/local/mysql/bin but uses $PATH without quotes. If PATH contains spaces, this may cause parsing errors. Safer syntax:

mysql -uroot -p

[root@localhost mysql]# cd /usr/local/mysql
[root@localhost mysql]# bin/mysqladmin -u root password '123'
Warning: Using a password on the command line interface can be insecure.
[root@localhost mysql]# echo 'export PATH=$PATH:/usr/local/mysql/bin'>>/etc/profile
[root@localhost mysql]# source /etc/profile
[root@localhost mysql]# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.6.31 Source distributionCopyright (c) 2000, 2016, 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>

apache

apr apr-util

tar apr
cd apr
./configure
make && make install

apr-util

tar apr-util
cd apr-util
./configure --with-apr=/usr/local/apr/bin-1-config
make && make install

tar xf httpd

cd httpd

vim apache.sh

./configure \

–with-apr=/usr/local/apr/bin/apr-1-config
–with-apr-util=/usr/local/apr/bin/apu-1-config

chmod +x apache.sh

./apache.sh

make && make install

cd /usr/local/apache2

bin/apachectl

php

tar xf php

cd php

vim php.sh

./configure \

chmod +x php.sh

./php.sh

yum install libxml-devel

yum install libjpeg-devel
yum install libpng
yum install freetype

./php.sh

make && make install\

ls /usr/local/apache2/modules/libphp7.so

配置Apache与PHP

vim /usr/local/apache2/conf/httpd.conf

209 ServerName localhost:80

159 LoadModule negotiation

483 Include conf/extra/httpd-languages.conf

166 LoadMo

AddHandler php7-script.php
AddType text/html.php

270 Direc index.php index.html

vim /usr/local/apache2/conf/extra/httpd-languages.conf

19 DefaultLanguage zh-CN
78 language zh-CN en…

cd /usr/local/apache2

bin/apachectl -k restart

cd /usr/local/apache2/htdocs

rm -f index.html

vim index.sh

<?php phpinfo(); ?>

LAMP

tar xf wordpress

mkdir /www

mv wordpress /www/blog

chown -R deamon.daemon /www/blog/

ll /www/blog

配虚拟主机

/usr/local/apache2/htdocs

vim /usr/local/apache2/conf/httpd.conff

494 Include conf/extra

vim /usr/local/apache2/conf/extra/httpd-vhosts.conf

<VirtualHost *:80>
DocumentRoor “/www/blog”
ServerName www.blog.com
Errorlog “logs/blog_error_log”
Customlog “logs/blog_access_log” common

mysql -uroot -p

create database blog default charset utf8;

Windows

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

启动

root@192.168.235.15's password:┌────────────────────────────────────────────────────────────────────┐│                        • MobaXterm 20.0 •                          ││            (SSH client, X-server and networking tools)             ││                                                                    ││ ➤ SSH session to root@192.168.235.15                               ││   • SSH compression : ✘                                            ││   • SSH-browser     : ✔                                            ││   • X11-forwarding  : ✔  (remote display is forwarded through SSH) ││   • DISPLAY         : ✔  (automatically set on remote server)      ││                                                                    ││ ➤ For more info, ctrl+click on help or visit our website           │└────────────────────────────────────────────────────────────────────┘Last login: Sat Jun 28 12:40:12 2025 from 192.168.235.1
[root@localhost ~]# hostname
localhost.localdomain
[root@localhost ~]# hostnamectl set-hostname web
[root@localhost ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00inet 127.0.0.1/8 scope host lovalid_lft forever preferred_lft foreverinet6 ::1/128 scope hostvalid_lft forever preferred_lft forever
2: ens34: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000link/ether 00:0c:29:1d:53:3b brd ff:ff:ff:ff:ff:ffinet 192.168.235.15/24 brd 192.168.235.255 scope global ens34valid_lft forever preferred_lft foreverinet6 fe80::20c:29ff:fe1d:533b/64 scope linkvalid_lft forever preferred_lft forever
3: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default qlen 1000link/ether 52:54:00:2b:f9:1b brd ff:ff:ff:ff:ff:ffinet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0valid_lft forever preferred_lft forever
4: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master virbr0 state DOWN group default qlen 1000link/ether 52:54:00:2b:f9:1b brd ff:ff:ff:ff:ff:ff
[root@localhost ~]# yum repolist
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
源标识                                                           源名称                                                              状态
!local                                                           local yum                                                           4,070
soft                                                             soft yum                                                                1
repolist: 4,071
[root@localhost ~]# cd /etc/repos.yum.d
-bash: cd: /etc/repos.yum.d: 没有那个文件或目录
[root@localhost ~]# cd /etc/yum.repos.d
[root@localhost yum.repos.d]# ls
local.repo  repo.tar.gz  soft.repo
[root@localhost yum.repos.d]# cat local.repo
[local]
name=local yum
baseurl=file:///mnt
enabled=1
gpgcheck=0
[root@localhost yum.repos.d]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /run/media/caozx26/CentOS 7 x86_64
[root@localhost yum.repos.d]# cd /mnt
[root@localhost mnt]# ls
[root@localhost mnt]# mount -o ro /mnt /dev/sr0
mount: /mnt 不是一个块设备
[root@localhost mnt]# mount -o ro /dev/sro /mnt
mount: 特殊设备 /dev/sro 不存在
[root@localhost mnt]# mount -o ro /dev/sr0 /mnt
[root@localhost mnt]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /mnt
[root@localhost mnt]# chmod +x /etc/rc.local
[root@localhost mnt]# ll /etc/rc.local
lrwxrwxrwx. 1 root root 13 5月   9 03:35 /etc/rc.local -> rc.d/rc.local
[root@localhost mnt]# echo 'mount -o ro /dev/sr0 /mnt'>>/etc/rc.local
[root@localhost mnt]# lsblk
NAME            MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda               8:0    0   20G  0 disk
├─sda1            8:1    0    1G  0 part /boot
└─sda2            8:2    0   19G  0 part├─centos-root 253:0    0   17G  0 lvm  /└─centos-swap 253:1    0    2G  0 lvm  [SWAP]
sr0              11:0    1  4.4G  0 rom  /mnt
[root@localhost mnt]# cd /etc/yum.repos.d
[root@localhost yum.repos.d]# ls
local.repo  repo.tar.gz  soft.repo
[root@localhost yum.repos.d]# yum clean all
已加载插件:fastestmirror, langpacks
正在清理软件源: local soft
Cleaning up list of fastest mirrors
[root@localhost yum.repos.d]# yum makecache
已加载插件:fastestmirror, langpacks
Determining fastest mirrors
local                                                                                                              | 3.6 kB  00:00:00
soft                                                                                                               | 2.9 kB  00:00:00
(1/7): local/group_gz                                                                                              | 153 kB  00:00:00
(2/7): local/filelists_db                                                                                          | 3.3 MB  00:00:00
(3/7): local/primary_db                                                                                            | 3.3 MB  00:00:00
(4/7): soft/filelists_db                                                                                           | 1.1 kB  00:00:00
(5/7): local/other_db                                                                                              | 1.3 MB  00:00:00
(6/7): soft/other_db                                                                                               | 1.2 kB  00:00:00
(7/7): soft/primary_db                                                                                             | 2.4 kB  00:00:00
元数据缓存已建立
[root@localhost yum.repos.d]# yum repolist
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
源标识                                                           源名称                                                              状态
local                                                            local yum                                                           4,070
soft                                                             soft yum                                                                1
repolist: 4,071
[root@localhost yum.repos.d]# sysatemctl status NetworkManager
bash: sysatemctl: 未找到命令...
[root@localhost yum.repos.d]# systemctl status NetworkManager
● NetworkManager.service - Network ManagerLoaded: loaded (/usr/lib/systemd/system/NetworkManager.service; disabled; vendor preset: enabled)Active: inactive (dead)Docs: man:NetworkManager(8)
[root@localhost yum.repos.d]# systemctl status firewalld
● firewalld.service - firewalld - dynamic firewall daemonLoaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)Active: inactive (dead)Docs: man:firewalld(1)
[root@localhost yum.repos.d]# setenforce 0
[root@localhost yum.repos.d]# 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=disable
# SELINUXTYPE= can take one of three values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted[root@localhost yum.repos.d]# vim /etc/selinux/config
[root@localhost yum.repos.d]# 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 values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted[root@localhost yum.repos.d]# yum install cmake
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 cmake.x86_64.0.2.8.12.2-2.el7 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                       架构                           版本                                    源                             大小
==========================================================================================================================================
正在安装:cmake                         x86_64                         2.8.12.2-2.el7                          local                         7.1 M事务概要
==========================================================================================================================================
安装  1 软件包总下载量:7.1 M
安装大小:27 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : cmake-2.8.12.2-2.el7.x86_64                                                                                           1/1验证中      : cmake-2.8.12.2-2.el7.x86_64                                                                                           1/1已安装:cmake.x86_64 0:2.8.12.2-2.el7完毕!
[root@localhost yum.repos.d]# yum install openssl-devel
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 openssl-devel.x86_64.1.1.0.2k-19.el7 将被 安装
--> 正在处理依赖关系 zlib-devel(x86-64),它被软件包 1:openssl-devel-1.0.2k-19.el7.x86_64 需要
--> 正在处理依赖关系 krb5-devel(x86-64),它被软件包 1:openssl-devel-1.0.2k-19.el7.x86_64 需要
--> 正在检查事务
---> 软件包 krb5-devel.x86_64.0.1.15.1-50.el7 将被 安装
--> 正在处理依赖关系 libverto-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 libselinux-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 libcom_err-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
--> 正在处理依赖关系 keyutils-libs-devel,它被软件包 krb5-devel-1.15.1-50.el7.x86_64 需要
---> 软件包 zlib-devel.x86_64.0.1.2.7-18.el7 将被 安装
--> 正在检查事务
---> 软件包 keyutils-libs-devel.x86_64.0.1.5.8-3.el7 将被 安装
---> 软件包 libcom_err-devel.x86_64.0.1.42.9-19.el7 将被 安装
---> 软件包 libselinux-devel.x86_64.0.2.5-15.el7 将被 安装
--> 正在处理依赖关系 libsepol-devel(x86-64) >= 2.5-10,它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
--> 正在处理依赖关系 pkgconfig(libsepol),它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
--> 正在处理依赖关系 pkgconfig(libpcre),它被软件包 libselinux-devel-2.5-15.el7.x86_64 需要
---> 软件包 libverto-devel.x86_64.0.0.2.5-4.el7 将被 安装
--> 正在检查事务
---> 软件包 libsepol-devel.x86_64.0.2.5-10.el7 将被 安装
---> 软件包 pcre-devel.x86_64.0.8.32-17.el7 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                                 架构                       版本                                  源                         大小
==========================================================================================================================================
正在安装:openssl-devel                           x86_64                     1:1.0.2k-19.el7                       local                     1.5 M
为依赖而安装:keyutils-libs-devel                     x86_64                     1.5.8-3.el7                           local                      37 kkrb5-devel                              x86_64                     1.15.1-50.el7                         local                     273 klibcom_err-devel                        x86_64                     1.42.9-19.el7                         local                      32 klibselinux-devel                        x86_64                     2.5-15.el7                            local                     187 klibsepol-devel                          x86_64                     2.5-10.el7                            local                      77 klibverto-devel                          x86_64                     0.2.5-4.el7                           local                      12 kpcre-devel                              x86_64                     8.32-17.el7                           local                     480 kzlib-devel                              x86_64                     1.2.7-18.el7                          local                      50 k事务概要
==========================================================================================================================================
安装  1 软件包 (+8 依赖软件包)总下载量:2.6 M
安装大小:5.8 M
Is this ok [y/d/N]: y
Downloading packages:
------------------------------------------------------------------------------------------------------------------------------------------
总计                                                                                                      397 kB/s | 2.6 MB  00:00:06
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : libsepol-devel-2.5-10.el7.x86_64                                                                                      1/9正在安装    : libcom_err-devel-1.42.9-19.el7.x86_64                                                                                 2/9正在安装    : pcre-devel-8.32-17.el7.x86_64                                                                                         3/9正在安装    : libselinux-devel-2.5-15.el7.x86_64                                                                                    4/9正在安装    : zlib-devel-1.2.7-18.el7.x86_64                                                                                        5/9正在安装    : libverto-devel-0.2.5-4.el7.x86_64                                                                                     6/9正在安装    : keyutils-libs-devel-1.5.8-3.el7.x86_64                                                                                7/9正在安装    : krb5-devel-1.15.1-50.el7.x86_64                                                                                       8/9正在安装    : 1:openssl-devel-1.0.2k-19.el7.x86_64                                                                                  9/9验证中      : libselinux-devel-2.5-15.el7.x86_64                                                                                    1/9验证中      : keyutils-libs-devel-1.5.8-3.el7.x86_64                                                                                2/9验证中      : libverto-devel-0.2.5-4.el7.x86_64                                                                                     3/9验证中      : zlib-devel-1.2.7-18.el7.x86_64                                                                                        4/9验证中      : pcre-devel-8.32-17.el7.x86_64                                                                                         5/9验证中      : 1:openssl-devel-1.0.2k-19.el7.x86_64                                                                                  6/9验证中      : libcom_err-devel-1.42.9-19.el7.x86_64                                                                                 7/9验证中      : krb5-devel-1.15.1-50.el7.x86_64                                                                                       8/9验证中      : libsepol-devel-2.5-10.el7.x86_64                                                                                      9/9已安装:openssl-devel.x86_64 1:1.0.2k-19.el7作为依赖被安装:keyutils-libs-devel.x86_64 0:1.5.8-3.el7        krb5-devel.x86_64 0:1.15.1-50.el7         libcom_err-devel.x86_64 0:1.42.9-19.el7libselinux-devel.x86_64 0:2.5-15.el7            libsepol-devel.x86_64 0:2.5-10.el7        libverto-devel.x86_64 0:0.2.5-4.el7pcre-devel.x86_64 0:8.32-17.el7                 zlib-devel.x86_64 0:1.2.7-18.el7完毕!
[root@localhost yum.repos.d]# yum install ncurses-devel.x86_64
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
--> 正在检查事务
---> 软件包 ncurses-devel.x86_64.0.5.9-14.20130511.el7_4 将被 安装
--> 解决依赖关系完成依赖关系解决==========================================================================================================================================Package                           架构                       版本                                        源                         大小
==========================================================================================================================================
正在安装:ncurses-devel                     x86_64                     5.9-14.20130511.el7_4                       local                     712 k事务概要
==========================================================================================================================================
安装  1 软件包总下载量:712 k
安装大小:2.1 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction正在安装    : ncurses-devel-5.9-14.20130511.el7_4.x86_64                                                                            1/1验证中      : ncurses-devel-5.9-14.20130511.el7_4.x86_64                                                                            1/1已安装:ncurses-devel.x86_64 0:5.9-14.20130511.el7_4完毕!
[root@localhost yum.repos.d]# useradd -s -r /sbin/nologin mysql
useradd:无效的 shell“-r”
[root@localhost yum.repos.d]# useradd -r -s /sbin/nologin mysql
[root@localhost yum.repos.d]# cd /
[root@localhost /]# ls
bin  boot  dev  etc  home  lib  lib64  media  mnt  opt  proc  root  run  sbin  soft  soft1  srv  sys  tmp  usr  var
[root@localhost /]# cd ~
[root@localhost ~]# ls
anaconda-ks.cfg  httpd-2.4.37.tar.bz2  initial-setup-ks.cfg  mysql-5.6.31.tar.gz
[root@localhost ~]# tar xf mysql-5.6.31.tar.gz
[root@localhost ~]# ls
anaconda-ks.cfg  httpd-2.4.37.tar.bz2  initial-setup-ks.cfg  mysql-5.6.31  mysql-5.6.31.tar.gz
[root@localhost ~]# cd mysql-5.6.31/
[root@localhost mysql-5.6.31]# vim cmake.sh
[root@localhost mysql-5.6.31]# cat cmake.sh
cmake . \
-DCMAKE_INSTALL_PREFIX=/usr/local/mysql/ \
-DMYSQL_DATADIR=/usr/local/mysql/data \
-DENABLED_LOCAL_INFILE=1 \
-DWITH_INNOBASE_STORAGE_ENGINE=1 \
-DMYSQL_TCP_PORT=3306 \
-DDEFAULT_CHARSET=utf8mb4 \
-DDEFAULT_COLLATION=utf8mb4_general_ci \
-DWITH_EXTRA_CHARSETS=all \
-DMYSQL_USER=mysql
[root@localhost mysql-5.6.31]# chmod +x cmake.sh
[root@localhost mysql-5.6.31]# ./cmake.sh
-- Running cmake version 2.8.12.2
-- Found Git: /usr/bin/git (found version "1.8.3.1")
-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.8.5
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for SHM_HUGETLB
-- Looking for SHM_HUGETLB - found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of void *
-- Check size of void * - done
-- MySQL 5.6.31
-- Packaging as: mysql-5.6.31-Linux-x86_64
-- Performing Test HAVE_LLVM_LIBCPP
-- Performing Test HAVE_LLVM_LIBCPP - Failed
-- Looking for floor
-- Looking for floor - not found
-- Looking for floor in m
-- Looking for floor in m - found
-- Looking for gethostbyname_r
-- Looking for gethostbyname_r - found
-- Looking for bind
-- Looking for bind - found
-- Looking for crypt
-- Looking for crypt - not found
-- Looking for crypt in crypt
-- Looking for crypt in crypt - found
-- Looking for setsockopt
-- Looking for setsockopt - found
-- Looking for dlopen
-- Looking for dlopen - not found
-- Looking for dlopen in dl
-- Looking for dlopen in dl - found
-- Looking for sched_yield
-- Looking for sched_yield - found
-- Looking for clock_gettime
-- Looking for clock_gettime - found
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Looking for 4 include files stdlib.h, ..., float.h
-- Looking for 4 include files stdlib.h, ..., float.h - found
-- Looking for include file alloca.h
-- Looking for include file alloca.h - found
-- Looking for include file aio.h
-- Looking for include file aio.h - found
-- Looking for include file arpa/inet.h
-- Looking for include file arpa/inet.h - found
-- Looking for include file crypt.h
-- Looking for include file crypt.h - found
-- Looking for include file cxxabi.h
-- Looking for include file cxxabi.h - not found
-- Looking for include file dirent.h
-- Looking for include file dirent.h - found
-- Looking for include file dlfcn.h
-- Looking for include file dlfcn.h - found
-- Looking for include file execinfo.h
-- Looking for include file execinfo.h - found
-- Looking for include file fcntl.h
-- Looking for include file fcntl.h - found
-- Looking for include file fenv.h
-- Looking for include file fenv.h - found
-- Looking for include file float.h
-- Looking for include file float.h - found
-- Looking for include file floatingpoint.h
-- Looking for include file floatingpoint.h - not found
-- Looking for include file fpu_control.h
-- Looking for include file fpu_control.h - found
-- Looking for include file grp.h
-- Looking for include file grp.h - found
-- Looking for include file ieeefp.h
-- Looking for include file ieeefp.h - not found
-- Looking for include file inttypes.h
-- Looking for include file inttypes.h - found
-- Looking for include file langinfo.h
-- Looking for include file langinfo.h - found
-- Looking for include file limits.h
-- Looking for include file limits.h - found
-- Looking for include file locale.h
-- Looking for include file locale.h - found
-- Looking for include file malloc.h
-- Looking for include file malloc.h - found
-- Looking for include file memory.h
-- Looking for include file memory.h - found
-- Looking for include file ndir.h
-- Looking for include file ndir.h - not found
-- Looking for include file netinet/in.h
-- Looking for include file netinet/in.h - found
-- Looking for include file paths.h
-- Looking for include file paths.h - found
-- Looking for include file port.h
-- Looking for include file port.h - not found
-- Looking for include file poll.h
-- Looking for include file poll.h - found
-- Looking for include file pwd.h
-- Looking for include file pwd.h - found
-- Looking for include file sched.h
-- Looking for include file sched.h - found
-- Looking for include file select.h
-- Looking for include file select.h - not found
-- Looking for include file semaphore.h
-- Looking for include file semaphore.h - found
-- Looking for include files sys/types.h, sys/dir.h
-- Looking for include files sys/types.h, sys/dir.h - found
-- Looking for include file sys/ndir.h
-- Looking for include file sys/ndir.h - not found
-- Looking for include file sys/pte.h
-- Looking for include file sys/pte.h - not found
-- Looking for include file stdlib.h
-- Looking for include file stdlib.h - found
-- Looking for include file strings.h
-- Looking for include file strings.h - found
-- Looking for include file string.h
-- Looking for include file string.h - found
-- Looking for include file synch.h
-- Looking for include file synch.h - not found
-- Looking for include file sysent.h
-- Looking for include file sysent.h - not found
-- Looking for include file sys/cdefs.h
-- Looking for include file sys/cdefs.h - found
-- Looking for include file sys/file.h
-- Looking for include file sys/file.h - found
-- Looking for include file sys/fpu.h
-- Looking for include file sys/fpu.h - not found
-- Looking for include file sys/ioctl.h
-- Looking for include file sys/ioctl.h - found
-- Looking for include file sys/ipc.h
-- Looking for include file sys/ipc.h - found
-- Looking for include file sys/malloc.h
-- Looking for include file sys/malloc.h - not found
-- Looking for include file sys/mman.h
-- Looking for include file sys/mman.h - found
-- Looking for include file sys/prctl.h
-- Looking for include file sys/prctl.h - found
-- Looking for include file sys/resource.h
-- Looking for include file sys/resource.h - found
-- Looking for include file sys/select.h
-- Looking for include file sys/select.h - found
-- Looking for include file sys/shm.h
-- Looking for include file sys/shm.h - found
-- Looking for include file sys/socket.h
-- Looking for include file sys/socket.h - found
-- Looking for include file sys/stat.h
-- Looking for include file sys/stat.h - found
-- Looking for include file sys/stream.h
-- Looking for include file sys/stream.h - not found
-- Looking for include file sys/termcap.h
-- Looking for include file sys/termcap.h - not found
-- Looking for include files time.h, sys/timeb.h
-- Looking for include files time.h, sys/timeb.h - found
-- Looking for include files curses.h, term.h
-- Looking for include files curses.h, term.h - found
-- Looking for include file asm/termbits.h
-- Looking for include file asm/termbits.h - found
-- Looking for include file termbits.h
-- Looking for include file termbits.h - not found
-- Looking for include file termios.h
-- Looking for include file termios.h - found
-- Looking for include file termio.h
-- Looking for include file termio.h - found
-- Looking for include file termcap.h
-- Looking for include file termcap.h - found
-- Looking for include file unistd.h
-- Looking for include file unistd.h - found
-- Looking for include file utime.h
-- Looking for include file utime.h - found
-- Looking for include file varargs.h
-- Looking for include file varargs.h - not found
-- Looking for include file sys/time.h
-- Looking for include file sys/time.h - found
-- Looking for include file sys/utime.h
-- Looking for include file sys/utime.h - not found
-- Looking for include file sys/wait.h
-- Looking for include file sys/wait.h - found
-- Looking for include file sys/param.h
-- Looking for include file sys/param.h - found
-- Looking for include file sys/vadvise.h
-- Looking for include file sys/vadvise.h - not found
-- Looking for include file fnmatch.h
-- Looking for include file fnmatch.h - found
-- Looking for include file stdarg.h
-- Looking for include file stdarg.h - found
-- Looking for include files stdlib.h, sys/un.h
-- Looking for include files stdlib.h, sys/un.h - found
-- Looking for include file vis.h
-- Looking for include file vis.h - not found
-- Looking for include file wchar.h
-- Looking for include file wchar.h - found
-- Looking for include file wctype.h
-- Looking for include file wctype.h - found
-- Looking for include file sasl/sasl.h
-- Looking for include file sasl/sasl.h - not found
-- Looking for include file sys/devpoll.h
-- Looking for include file sys/devpoll.h - not found
-- Looking for include file signal.h
-- Looking for include file signal.h - found
-- Looking for include file sys/devpoll.h
-- Looking for include file sys/devpoll.h - not found
-- Looking for include file sys/epoll.h
-- Looking for include file sys/epoll.h - found
-- Looking for include file sys/event.h
-- Looking for include file sys/event.h - not found
-- Looking for include file sys/queue.h
-- Looking for include file sys/queue.h - found
-- Looking for TAILQ_FOREACH
-- Looking for TAILQ_FOREACH - found
-- Looking for include file sys/ptem.h
-- Looking for include file sys/ptem.h - not found
-- Performing Test HAVE_WERROR_FLAG
-- Performing Test HAVE_WERROR_FLAG - Success
-- Performing Test HAVE_PTHREAD_ONCE_INIT
-- Performing Test HAVE_PTHREAD_ONCE_INIT - Success
-- Looking for _aligned_malloc
-- Looking for _aligned_malloc - not found
-- Looking for _aligned_free
-- Looking for _aligned_free - not found
-- Looking for aio_read
-- Looking for aio_read - not found
-- Looking for alarm
-- Looking for alarm - found
-- Looking for backtrace
-- Looking for backtrace - found
-- Looking for backtrace_symbols
-- Looking for backtrace_symbols - found
-- Looking for backtrace_symbols_fd
-- Looking for backtrace_symbols_fd - found
-- Looking for printstack
-- Looking for printstack - not found
-- Looking for bmove
-- Looking for bmove - not found
-- Looking for bsearch
-- Looking for bsearch - found
-- Looking for index
-- Looking for index - found
-- Looking for clock_gettime
-- Looking for clock_gettime - found
-- Looking for cuserid
-- Looking for cuserid - found
-- Looking for directio
-- Looking for directio - not found
-- Looking for _doprnt
-- Looking for _doprnt - not found
-- Looking for flockfile
-- Looking for flockfile - found
-- Looking for ftruncate
-- Looking for ftruncate - found
-- Looking for getline
-- Looking for getline - found
-- Looking for compress
-- Looking for compress - not found
-- Looking for crypt
-- Looking for crypt - found
-- Looking for dlerror
-- Looking for dlerror - found
-- Looking for dlopen
-- Looking for dlopen - found
-- Looking for fchmod
-- Looking for fchmod - found
-- Looking for fcntl
-- Looking for fcntl - found
-- Looking for fconvert
-- Looking for fconvert - not found
-- Looking for fdatasync
-- Looking for fdatasync - found
-- Looking for fdatasync
-- Looking for fdatasync - found
-- Looking for fedisableexcept
-- Looking for fedisableexcept - found
-- Looking for fpsetmask
-- Looking for fpsetmask - not found
-- Looking for fseeko
-- Looking for fseeko - found
-- Looking for fsync
-- Looking for fsync - found
-- Looking for getcwd
-- Looking for getcwd - found
-- Looking for gethostbyaddr_r
-- Looking for gethostbyaddr_r - found
-- Looking for gethrtime
-- Looking for gethrtime - not found
-- Looking for getnameinfo
-- Looking for getnameinfo - found
-- Looking for getpass
-- Looking for getpass - found
-- Looking for getpassphrase
-- Looking for getpassphrase - not found
-- Looking for getpwnam
-- Looking for getpwnam - found
-- Looking for getpwuid
-- Looking for getpwuid - found
-- Looking for getrlimit
-- Looking for getrlimit - found
-- Looking for getrusage
-- Looking for getrusage - found
-- Looking for getwd
-- Looking for getwd - found
-- Looking for gmtime_r
-- Looking for gmtime_r - found
-- Looking for initgroups
-- Looking for initgroups - found
-- Looking for issetugid
-- Looking for issetugid - not found
-- Looking for getuid
-- Looking for getuid - found
-- Looking for geteuid
-- Looking for geteuid - found
-- Looking for getgid
-- Looking for getgid - found
-- Looking for getegid
-- Looking for getegid - found
-- Looking for ldiv
-- Looking for ldiv - found
-- Looking for localtime_r
-- Looking for localtime_r - found
-- Looking for longjmp
-- Looking for longjmp - found
-- Looking for lstat
-- Looking for lstat - found
-- Looking for madvise
-- Looking for madvise - found
-- Looking for malloc_info
-- Looking for malloc_info - found
-- Looking for memcpy
-- Looking for memcpy - found
-- Looking for memmove
-- Looking for memmove - found
-- Looking for mkstemp
-- Looking for mkstemp - found
-- Looking for mlock
-- Looking for mlock - found
-- Looking for mlockall
-- Looking for mlockall - found
-- Looking for mmap
-- Looking for mmap - found
-- Looking for mmap64
-- Looking for mmap64 - found
-- Looking for perror
-- Looking for perror - found
-- Looking for poll
-- Looking for poll - found
-- Looking for port_create
-- Looking for port_create - not found
-- Looking for posix_fallocate
-- Looking for posix_fallocate - found
-- Looking for posix_memalign
-- Looking for posix_memalign - found
-- Looking for pread
-- Looking for pread - found
-- Looking for pthread_attr_create
-- Looking for pthread_attr_create - not found
-- Looking for pthread_attr_getguardsize
-- Looking for pthread_attr_getguardsize - found
-- Looking for pthread_attr_getstacksize
-- Looking for pthread_attr_getstacksize - found
-- Looking for pthread_attr_setscope
-- Looking for pthread_attr_setscope - found
-- Looking for pthread_attr_setstacksize
-- Looking for pthread_attr_setstacksize - found
-- Looking for pthread_condattr_create
-- Looking for pthread_condattr_create - not found
-- Looking for pthread_condattr_setclock
-- Looking for pthread_condattr_setclock - found
-- Looking for pthread_key_delete
-- Looking for pthread_key_delete - found
-- Looking for pthread_rwlock_rdlock
-- Looking for pthread_rwlock_rdlock - found
-- Looking for pthread_sigmask
-- Looking for pthread_sigmask - found
-- Looking for pthread_threadmask
-- Looking for pthread_threadmask - not found
-- Looking for pthread_yield_np
-- Looking for pthread_yield_np - not found
-- Looking for putenv
-- Looking for putenv - found
-- Looking for readdir_r
-- Looking for readdir_r - found
-- Looking for readlink
-- Looking for readlink - found
-- Looking for re_comp
-- Looking for re_comp - found
-- Looking for regcomp
-- Looking for regcomp - found
-- Looking for realpath
-- Looking for realpath - found
-- Looking for rename
-- Looking for rename - found
-- Looking for rwlock_init
-- Looking for rwlock_init - not found
-- Looking for sched_yield
-- Looking for sched_yield - found
-- Looking for setenv
-- Looking for setenv - found
-- Looking for setlocale
-- Looking for setlocale - found
-- Looking for setfd
-- Looking for setfd - not found
-- Looking for sigaction
-- Looking for sigaction - found
-- Looking for sigthreadmask
-- Looking for sigthreadmask - not found
-- Looking for sigwait
-- Looking for sigwait - found
-- Looking for sigaddset
-- Looking for sigaddset - found
-- Looking for sigemptyset
-- Looking for sigemptyset - found
-- Looking for sighold
-- Looking for sighold - found
-- Looking for sigset
-- Looking for sigset - found
-- Looking for sleep
-- Looking for sleep - found
-- Looking for snprintf
-- Looking for snprintf - found
-- Looking for stpcpy
-- Looking for stpcpy - found
-- Looking for strcoll
-- Looking for strcoll - found
-- Looking for strerror
-- Looking for strerror - found
-- Looking for strlcpy
-- Looking for strlcpy - not found
-- Looking for strnlen
-- Looking for strnlen - found
-- Looking for strlcat
-- Looking for strlcat - not found
-- Looking for strsignal
-- Looking for strsignal - found
-- Looking for fgetln
-- Looking for fgetln - not found
-- Looking for strpbrk
-- Looking for strpbrk - found
-- Looking for strsep
-- Looking for strsep - found
-- Looking for strstr
-- Looking for strstr - found
-- Looking for strtok_r
-- Looking for strtok_r - found
-- Looking for strtol
-- Looking for strtol - found
-- Looking for strtoll
-- Looking for strtoll - found
-- Looking for strtoul
-- Looking for strtoul - found
-- Looking for strtoull
-- Looking for strtoull - found
-- Looking for strcasecmp
-- Looking for strcasecmp - found
-- Looking for strncasecmp
-- Looking for strncasecmp - found
-- Looking for strdup
-- Looking for strdup - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for shmctl
-- Looking for shmctl - found
-- Looking for shmdt
-- Looking for shmdt - found
-- Looking for shmget
-- Looking for shmget - found
-- Looking for tell
-- Looking for tell - not found
-- Looking for tempnam
-- Looking for tempnam - found
-- Looking for thr_setconcurrency
-- Looking for thr_setconcurrency - not found
-- Looking for thr_yield
-- Looking for thr_yield - not found
-- Looking for vasprintf
-- Looking for vasprintf - found
-- Looking for vsnprintf
-- Looking for vsnprintf - found
-- Looking for vprintf
-- Looking for vprintf - found
-- Looking for valloc
-- Looking for valloc - found
-- Looking for memalign
-- Looking for memalign - found
-- Looking for chown
-- Looking for chown - found
-- Looking for nl_langinfo
-- Looking for nl_langinfo - found
-- Looking for ntohll
-- Looking for ntohll - not found
-- Looking for clock_gettime
-- Looking for clock_gettime - found
-- Looking for epoll_create
-- Looking for epoll_create - found
-- Looking for epoll_ctl
-- Looking for epoll_ctl - found
-- Looking for inet_ntop
-- Looking for inet_ntop - found
-- Looking for kqueue
-- Looking for kqueue - not found
-- Looking for kqueue
-- Looking for kqueue - not found
-- Looking for signal
-- Looking for signal - found
-- Looking for timeradd
-- Looking for timeradd - found
-- Looking for timerclear
-- Looking for timerclear - found
-- Looking for timercmp
-- Looking for timercmp - found
-- Looking for timerisset
-- Looking for timerisset - found
-- Looking for include file time.h
-- Looking for include file time.h - found
-- Looking for include file sys/times.h
-- Looking for include file sys/times.h - found
-- Looking for include file asm/msr.h
-- Looking for include file asm/msr.h - found
-- Looking for include file ia64intrin.h
-- Looking for include file ia64intrin.h - not found
-- Looking for times
-- Looking for times - found
-- Looking for gettimeofday
-- Looking for gettimeofday - found
-- Looking for read_real_time
-- Looking for read_real_time - not found
-- Looking for ftime
-- Looking for ftime - found
-- Looking for time
-- Looking for time - found
-- Looking for rdtscll
-- Looking for rdtscll - not found
-- Looking for madvise
-- Looking for madvise - found
-- Looking for tzname
-- Looking for tzname - found
-- Looking for lrand48
-- Looking for lrand48 - found
-- Looking for getpagesize
-- Looking for getpagesize - found
-- Looking for TIOCGWINSZ
-- Looking for TIOCGWINSZ - found
-- Looking for FIONREAD
-- Looking for FIONREAD - found
-- Looking for TIOCSTAT
-- Looking for TIOCSTAT - not found
-- Looking for FIONREAD
-- Looking for FIONREAD - not found
-- Looking for finite
-- Looking for finite - found
-- Looking for log2
-- Looking for log2 - found
-- Looking for isnan
-- Looking for isnan - found
-- Looking for rint
-- Looking for rint - found
-- Performing Test HAVE_ISINF
-- Performing Test HAVE_ISINF - Success
-- Performing Test HAVE_FESETROUND
-- Performing Test HAVE_FESETROUND - Success
-- Check if the system is big endian
-- Searching 16 bit integer
-- Check size of unsigned short
-- Check size of unsigned short - done
-- Using unsigned short
-- Check if the system is big endian - little endian
-- Check size of sigset_t
-- Check size of sigset_t - done
-- Check size of mode_t
-- Check size of mode_t - done
-- Check size of char *
-- Check size of char * - done
-- Check size of long
-- Check size of long - done
-- Check size of size_t
-- Check size of size_t - done
-- Check size of char
-- Check size of char - done
-- Check size of short
-- Check size of short - done
-- Check size of int
-- Check size of int - done
-- Check size of long long
-- Check size of long long - done
-- Check size of off_t
-- Check size of off_t - done
-- Check size of uchar
-- Check size of uchar - failed
-- Check size of uint
-- Check size of uint - done
-- Check size of ulong
-- Check size of ulong - done
-- Check size of int8
-- Check size of int8 - failed
-- Check size of uint8
-- Check size of uint8 - failed
-- Check size of int16
-- Check size of int16 - failed
-- Check size of uint16
-- Check size of uint16 - failed
-- Check size of int32
-- Check size of int32 - failed
-- Check size of uint32
-- Check size of uint32 - failed
-- Check size of u_int32_t
-- Check size of u_int32_t - done
-- Check size of int64
-- Check size of int64 - failed
-- Check size of uint64
-- Check size of uint64 - failed
-- Check size of time_t
-- Check size of time_t - done
-- Check size of struct timespec
-- Check size of struct timespec - done
-- Check size of bool
-- Check size of bool - failed
-- Check size of socklen_t
-- Check size of socklen_t - done
-- Performing Test TIME_T_UNSIGNED
-- Performing Test TIME_T_UNSIGNED - Failed
-- Performing Test HAVE_GETADDRINFO
-- Performing Test HAVE_GETADDRINFO - Success
-- Performing Test HAVE_SELECT
-- Performing Test HAVE_SELECT - Success
-- Performing Test HAVE_TIMESPEC_TS_SEC
-- Performing Test HAVE_TIMESPEC_TS_SEC - Failed
-- Performing Test QSORT_TYPE_IS_VOID
-- Performing Test QSORT_TYPE_IS_VOID - Success
-- Performing Test HAVE_SOCKET_SIZE_T_AS_socklen_t
-- Performing Test HAVE_SOCKET_SIZE_T_AS_socklen_t - Success
-- Performing Test HAVE_PTHREAD_YIELD_ZERO_ARG
-- Performing Test HAVE_PTHREAD_YIELD_ZERO_ARG - Success
-- Checking stack direction : -1
-- Performing Test SIGNAL_RETURN_TYPE_IS_VOID
-- Performing Test SIGNAL_RETURN_TYPE_IS_VOID - Success
-- Looking for include files time.h, sys/time.h
-- Looking for include files time.h, sys/time.h - found
-- Looking for O_NONBLOCK
-- Looking for O_NONBLOCK - found
-- Performing Test C_HAS_inline
-- Performing Test C_HAS_inline - Success
-- Performing Test HAVE_PAUSE_INSTRUCTION
-- Performing Test HAVE_PAUSE_INSTRUCTION - Success
-- Looking for tcgetattr
-- Looking for tcgetattr - found
-- Performing Test HAVE_POSIX_SIGNALS
-- Performing Test HAVE_POSIX_SIGNALS - Success
-- Performing Test HAVE_BSS_START
-- Performing Test HAVE_BSS_START - Success
-- Performing Test HAVE_WEAK_SYMBOL
-- Performing Test HAVE_WEAK_SYMBOL - Success
-- Performing Test HAVE_SOLARIS_STYLE_GETHOST
-- Performing Test HAVE_SOLARIS_STYLE_GETHOST - Failed
-- Performing Test HAVE_GCC_ATOMIC_BUILTINS
-- Performing Test HAVE_GCC_ATOMIC_BUILTINS - Success
-- Looking for netinet/in6.h
-- Looking for netinet/in6.h - not found
-- Check size of struct sockaddr_in6
-- Check size of struct sockaddr_in6 - done
-- Check size of struct in6_addr
-- Check size of struct in6_addr - done
-- Performing Test HAVE_SOCKADDR_STORAGE_SS_FAMILY
-- Performing Test HAVE_SOCKADDR_STORAGE_SS_FAMILY - Success
-- Performing Test HAVE_SOCKADDR_IN_SIN_LEN
-- Performing Test HAVE_SOCKADDR_IN_SIN_LEN - Failed
-- Performing Test HAVE_SOCKADDR_IN6_SIN6_LEN
-- Performing Test HAVE_SOCKADDR_IN6_SIN6_LEN - Failed
-- Performing Test STRUCT_DIRENT_HAS_D_INO
-- Performing Test STRUCT_DIRENT_HAS_D_INO - Success
-- Performing Test STRUCT_DIRENT_HAS_D_NAMLEN
-- Performing Test STRUCT_DIRENT_HAS_D_NAMLEN - Failed
-- Looking for include file numaif.h
-- Looking for include file numaif.h - not found
-- Performing Test HAVE_VISIBILITY_HIDDEN
-- Performing Test HAVE_VISIBILITY_HIDDEN - Success
-- HAVE_VISIBILITY_HIDDEN
-- HAVE_VISIBILITY_HIDDEN
-- HAVE_VISIBILITY_HIDDEN
-- Check size of mbstate_t
-- Check size of mbstate_t - done
-- Performing Test HAVE_LANGINFO_CODESET
-- Performing Test HAVE_LANGINFO_CODESET - Success
-- Looking for mbrlen
-- Looking for mbrlen - found
-- Looking for mbscmp
-- Looking for mbscmp - not found
-- Looking for mbsrtowcs
-- Looking for mbsrtowcs - found
-- Looking for wcrtomb
-- Looking for wcrtomb - found
-- Looking for mbrtowc
-- Looking for mbrtowc - found
-- Looking for wcscoll
-- Looking for wcscoll - found
-- Looking for wcsdup
-- Looking for wcsdup - found
-- Looking for wcwidth
-- Looking for wcwidth - found
-- Looking for wctype
-- Looking for wctype - found
-- Looking for iswlower
-- Looking for iswlower - found
-- Looking for iswupper
-- Looking for iswupper - found
-- Looking for towlower
-- Looking for towlower - found
-- Looking for towupper
-- Looking for towupper - found
-- Looking for iswctype
-- Looking for iswctype - found
-- Check size of wchar_t
-- Check size of wchar_t - done
-- Check size of wctype_t
-- Check size of wctype_t - done
-- Check size of wint_t
-- Check size of wint_t - done
-- Found Curses: /usr/lib64/libcurses.so
-- Looking for tputs in /usr/lib64/libcurses.so
-- Looking for tputs in /usr/lib64/libcurses.so - found
-- Performing Test HAVE_DECL_TGOTO
-- Performing Test HAVE_DECL_TGOTO - Success
-- Looking for strvis
-- Looking for strvis - not found
-- Looking for strunvis
-- Looking for strunvis - not found
-- Performing Test HAVE_WVLA
-- Performing Test HAVE_WVLA - Success
-- Looking for include file libaio.h
-- Looking for include file libaio.h - not found
-- Looking for io_queue_init in aio
-- Looking for io_queue_init in aio - not found
-- Looking for sched_getcpu
-- Looking for sched_getcpu - found
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS - Success
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS_BYTE
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS_BYTE - Success
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS_64
-- Performing Test HAVE_IB_GCC_ATOMIC_BUILTINS_64 - Success
-- Performing Test HAVE_IB_GCC_SYNC_SYNCHRONISE
-- Performing Test HAVE_IB_GCC_SYNC_SYNCHRONISE - Success
-- Performing Test HAVE_IB_GCC_ATOMIC_THREAD_FENCE
-- Performing Test HAVE_IB_GCC_ATOMIC_THREAD_FENCE - Success
-- Performing Test HAVE_IB_GCC_ATOMIC_TEST_AND_SET
-- Performing Test HAVE_IB_GCC_ATOMIC_TEST_AND_SET - Success
-- Performing Test HAVE_IB_ATOMIC_PTHREAD_T_GCC
-- Performing Test HAVE_IB_ATOMIC_PTHREAD_T_GCC - Success
-- Looking for asprintf
-- Looking for asprintf - found
-- Check size of pthread_t
-- Check size of pthread_t - done
-- Using cmake version 2.8.12.2
-- Not building NDB
-- Performing Test HAVE_PEERCRED
-- Performing Test HAVE_PEERCRED - Success
-- Library mysqlclient depends on OSLIBS -lpthread;m;dl
-- Googlemock was not found. gtest-based unit tests will be disabled. You can run cmake . -DENABLE_DOWNLOADS=1 to automatically download and build required components from source.
-- If you are inside a firewall, you may need to use an http proxy: export http_proxy=http://example.com:80
-- Library mysqlserver depends on OSLIBS -lpthread;m;crypt;dl
-- CMAKE_BUILD_TYPE: RelWithDebInfo
-- COMPILE_DEFINITIONS: HAVE_CONFIG_H
-- CMAKE_C_FLAGS:  -Wall -Wextra -Wformat-security -Wvla -Wwrite-strings -Wdeclaration-after-statement
-- CMAKE_CXX_FLAGS:  -Wall -Wextra -Wformat-security -Wvla -Woverloaded-virtual -Wno-unused-parameter
-- CMAKE_C_FLAGS_RELWITHDEBINFO: -O3 -g -fabi-version=2 -fno-omit-frame-pointer -fno-strict-aliasing -DDBUG_OFF
-- CMAKE_CXX_FLAGS_RELWITHDEBINFO: -O3 -g -fabi-version=2 -fno-omit-frame-pointer -fno-strict-aliasing -DDBUG_OFF
-- Configuring done
-- Generating done
CMake Warning:Manually-specified variables were not used by the project:MYSQL_USER-- Build files have been written to: /root/mysql-5.6.31
[root@localhost mysql-5.6.31]# make && make install
Scanning dependencies of target INFO_BIN
[  0%] Built target INFO_BIN
Scanning dependencies of target INFO_SRC
[  0%] Built target INFO_SRC
Scanning dependencies of target abi_check
-- Installing: /usr/local/mysql/sql-bench/limits/sybase.cfg
-- Installing: /usr/local/mysql/sql-bench/README
-- Installing: /usr/local/mysql/sql-bench/bench-count-distinct
-- Installing: /usr/local/mysql/sql-bench/bench-init.pl
-- Installing: /usr/local/mysql/sql-bench/compare-results
-- Installing: /usr/local/mysql/sql-bench/copy-db
-- Installing: /usr/local/mysql/sql-bench/crash-me
-- Installing: /usr/local/mysql/sql-bench/graph-compare-results
-- Installing: /usr/local/mysql/sql-bench/innotest1
-- Installing: /usr/local/mysql/sql-bench/innotest1a
-- Installing: /usr/local/mysql/sql-bench/innotest1b
-- Installing: /usr/local/mysql/sql-bench/innotest2
-- Installing: /usr/local/mysql/sql-bench/innotest2a
-- Installing: /usr/local/mysql/sql-bench/innotest2b
-- Installing: /usr/local/mysql/sql-bench/run-all-tests
-- Installing: /usr/local/mysql/sql-bench/server-cfg
-- Installing: /usr/local/mysql/sql-bench/test-ATIS
-- Installing: /usr/local/mysql/sql-bench/test-alter-table
-- Installing: /usr/local/mysql/sql-bench/test-big-tables
-- Installing: /usr/local/mysql/sql-bench/test-connect
-- Installing: /usr/local/mysql/sql-bench/test-create
-- Installing: /usr/local/mysql/sql-bench/test-insert
-- Installing: /usr/local/mysql/sql-bench/test-select
-- Installing: /usr/local/mysql/sql-bench/test-transactions
-- Installing: /usr/local/mysql/sql-bench/test-wisconsin
[root@localhost mysql-5.6.31]# ll /usr/local/mysql
总用量 48
drwxr-xr-x.  2 root root  4096 73 22:15 bin
-rw-r--r--.  1 root root 17987 517 2016 COPYING
drwxr-xr-x.  3 root root    18 73 22:15 data
drwxr-xr-x.  2 root root    55 73 22:15 docs
drwxr-xr-x.  3 root root  4096 73 22:15 include
drwxr-xr-x.  3 root root  4096 73 22:15 lib
drwxr-xr-x.  4 root root    30 73 22:15 man
drwxr-xr-x. 10 root root  4096 73 22:15 mysql-test
-rw-r--r--.  1 root root  2496 517 2016 README
drwxr-xr-x.  2 root root    30 73 22:15 scripts
drwxr-xr-x. 28 root root  4096 73 22:15 share
drwxr-xr-x.  4 root root  4096 73 22:15 sql-bench
drwxr-xr-x.  2 root root   136 73 22:15 support-files
[root@localhost mysql-5.6.31]# chown -R mysql.mysql /usr/local/mysql
[root@localhost mysql-5.6.31]# ll -d /usr/local/mysql
drwxr-xr-x. 13 mysql mysql 191 73 22:15 /usr/local/mysql
[root@localhost mysql-5.6.31]# rm -f /etc/my.cnf
[root@localhost mysql-5.6.31]# cd /usr/local/mysql
[root@localhost mysql]# ./scripts/mysql_install_db --user=mysql
Installing MySQL system tables...2025-07-03 22:32:19 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2025-07-03 22:32:19 0 [Note] ./bin/mysqld (mysqld 5.6.31) starting as process 34642 ...
2025-07-03 22:32:19 34642 [Note] InnoDB: Using atomics to ref count buffer pool pages
2025-07-03 22:32:19 34642 [Note] InnoDB: The InnoDB memory heap is disabled
2025-07-03 22:32:19 34642 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2025-07-03 22:32:19 34642 [Note] InnoDB: Memory barrier is not used
2025-07-03 22:32:19 34642 [Note] InnoDB: Compressed tables use zlib 1.2.3
2025-07-03 22:32:19 34642 [Note] InnoDB: Using CPU crc32 instructions
2025-07-03 22:32:19 34642 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2025-07-03 22:32:19 34642 [Note] InnoDB: Completed initialization of buffer pool
2025-07-03 22:32:19 34642 [Note] InnoDB: The first specified data file ./ibdata1 did not exist: a new database to be created!
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting file ./ibdata1 size to 12 MB
2025-07-03 22:32:19 34642 [Note] InnoDB: Database physically writes the file full: wait...
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting log file ./ib_logfile101 size to 48 MB
2025-07-03 22:32:19 34642 [Note] InnoDB: Setting log file ./ib_logfile1 size to 48 MB
2025-07-03 22:32:20 34642 [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0
2025-07-03 22:32:20 34642 [Warning] InnoDB: New log files created, LSN=45781
2025-07-03 22:32:20 34642 [Note] InnoDB: Doublewrite buffer not found: creating new
2025-07-03 22:32:20 34642 [Note] InnoDB: Doublewrite buffer created
2025-07-03 22:32:20 34642 [Note] InnoDB: 128 rollback segment(s) are active.
2025-07-03 22:32:20 34642 [Warning] InnoDB: Creating foreign key constraint system tables.
2025-07-03 22:32:20 34642 [Note] InnoDB: Foreign key constraint system tables created
2025-07-03 22:32:20 34642 [Note] InnoDB: Creating tablespace and datafile system tables.
2025-07-03 22:32:20 34642 [Note] InnoDB: Tablespace and datafile system tables created.
2025-07-03 22:32:20 34642 [Note] InnoDB: Waiting for purge to start
2025-07-03 22:32:20 34642 [Note] InnoDB: 5.6.31 started; log sequence number 0
2025-07-03 22:32:20 34642 [Note] Binlog end
2025-07-03 22:32:20 34642 [Note] InnoDB: FTS optimize thread exiting.
2025-07-03 22:32:20 34642 [Note] InnoDB: Starting shutdown...
2025-07-03 22:32:21 34642 [Note] InnoDB: Shutdown completed; log sequence number 1625977
OKFilling help tables...2025-07-03 22:32:21 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2025-07-03 22:32:21 0 [Note] ./bin/mysqld (mysqld 5.6.31) starting as process 34676 ...
2025-07-03 22:32:21 34676 [Note] InnoDB: Using atomics to ref count buffer pool pages
2025-07-03 22:32:21 34676 [Note] InnoDB: The InnoDB memory heap is disabled
2025-07-03 22:32:21 34676 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2025-07-03 22:32:21 34676 [Note] InnoDB: Memory barrier is not used
2025-07-03 22:32:21 34676 [Note] InnoDB: Compressed tables use zlib 1.2.3
2025-07-03 22:32:21 34676 [Note] InnoDB: Using CPU crc32 instructions
2025-07-03 22:32:21 34676 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2025-07-03 22:32:21 34676 [Note] InnoDB: Completed initialization of buffer pool
2025-07-03 22:32:21 34676 [Note] InnoDB: Highest supported file format is Barracuda.
2025-07-03 22:32:21 34676 [Note] InnoDB: 128 rollback segment(s) are active.
2025-07-03 22:32:21 34676 [Note] InnoDB: Waiting for purge to start
2025-07-03 22:32:21 34676 [Note] InnoDB: 5.6.31 started; log sequence number 1625977
2025-07-03 22:32:21 34676 [Note] Binlog end
2025-07-03 22:32:21 34676 [Note] InnoDB: FTS optimize thread exiting.
2025-07-03 22:32:21 34676 [Note] InnoDB: Starting shutdown...
2025-07-03 22:32:23 34676 [Note] InnoDB: Shutdown completed; log sequence number 1625987
OKTo start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your systemPLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:./bin/mysqladmin -u root password 'new-password'./bin/mysqladmin -u root -h web password 'new-password'Alternatively you can run:./bin/mysql_secure_installationwhich will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.See the manual for more instructions.You can start the MySQL daemon with:cd . ; ./bin/mysqld_safe &You can test the MySQL daemon with mysql-test-run.plcd mysql-test ; perl mysql-test-run.plPlease report any problems at http://bugs.mysql.com/The latest information about MySQL is available on the web athttp://www.mysql.comSupport MySQL by buying support/licenses at http://shop.mysql.comNew default config file was created as ./my.cnf and
will be used by default by the server when you start it.
You may edit this file to change server settings[root@localhost mysql]# ll data
总用量 110600
-rw-rw----. 1 mysql mysql 12582912 73 22:32 ibdata1
-rw-rw----. 1 mysql mysql 50331648 73 22:32 ib_logfile0
-rw-rw----. 1 mysql mysql 50331648 73 22:32 ib_logfile1
drwx------. 2 mysql mysql     4096 73 22:32 mysql
drwx------. 2 mysql mysql     4096 73 22:32 performance_schema
drwxr-xr-x. 2 mysql mysql       20 73 22:15 test
[root@localhost mysql]# cp supports-files/mysql /etc/init.d/mysql
cp: 无法获取"supports-files/mysql" 的文件状态(stat): 没有那个文件或目录
[root@localhost mysql]# ls
bin  COPYING  data  docs  include  lib  man  my.cnf  mysql-test  README  scripts  share  sql-bench  support-files
[root@localhost mysql]# cp support-files/mysql /etc/init.d/mysql
cp: 无法获取"support-files/mysql" 的文件状态(stat): 没有那个文件或目录
[root@localhost mysql]# ls support-files/
binary-configure  magic  my-default.cnf  mysqld_multi.server  mysql-log-rotate  mysql.server
[root@localhost mysql]# cp support-files/mysql.server /etc/init.d/mysql
[root@localhost mysql]# service mysql start
Starting MySQL. SUCCESS!
[root@localhost mysql]# cd /usr/local/mysql
[root@localhost mysql]# bin/mysqladmin -u root password '123'
Warning: Using a password on the command line interface can be insecure.
[root@localhost mysql]# echo 'export PATH=$PATH:/usr/local/mysql/bin'>>/etc/profile
[root@localhost mysql]# source /etc/profile
[root@localhost mysql]# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.6.31 Source distributionCopyright (c) 2000, 2016, 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>
http://www.dtcms.com/a/265603.html

相关文章:

  • 渗透测试中 phpinfo() 的信息利用分析
  • Java接口报错:Packet for query is too large - 解决方案与架构思考
  • 从0到1搭建同城O2O外卖平台:外卖系统源码架构解析与实战指南
  • 前置代理重构网络访问的「中转站」
  • YOLOv2 正负样本分配机制详解
  • ollama bge-m3 Embending模型永久加载 does not support generate
  • Spring注解之@Repository
  • 采样点不一致:总线通信的隐形杀手
  • C++之红黑树认识与实现
  • Go应用容器化完全指南:构建最小化安全镜像的终极实践
  • Jenkins的最佳替代方案TeamCity:优势、差异对比及常见问题解答
  • 使用 HiveMQ Broker 写入 TDengine
  • C#,VB.NET从JSON数据里提取数组中的对象节点值
  • 【论】电力-交通融合网协同优化:迎接电动汽车时代的挑战
  • .NET 8.0 Redis 教程
  • Pytorch中expand()和repeat()函数使用详解和实战示例
  • github在线图床
  • 一篇文章掌握Docker
  • Redis 持久化详解、使用及注意事项
  • 关于使用cursor tunnel链接vscode(避免1006 issue的做法)
  • ASP 安装使用教程
  • ubuntu rules 使用规则
  • 什么是VR全景展示?VR展示需要哪些科技?
  • 【React Native原生项目不能运行npx react-native run-android项目】
  • 学习设计模式《十六》——策略模式
  • 安装 Docker Compose!!!
  • 蒙特卡洛方法:随机抽样的艺术与科学
  • SSL Pinning破解实战:企业级移动应用安全测试方案
  • java集合详解
  • 论文阅读笔记——Autoregressive Image Generation without Vector Quantization