zno2

《大迁徙》 linux

1. ECS

云服务器(Elastic Compute Service,简称 ECS)

https://cn.aliyun.com/product/ecs

2.确认linux版本

[root@iZ255m2u8usZ ~]# cat /proc/version
Linux version 2.6.32-573.22.1.el6.x86_64 (mockbuild@c6b8.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC) ) #1 SMP Wed Mar 23 03:35:39 UTC 2016

[root@iZ255m2u8usZ ~]# cat /etc/issue
CentOS release 6.5 (Final)
Kernel \r on an \m

3. 系统盘和数据盘

可以在阿里云服务器管理控制台(本实例磁盘-磁盘列表)中查看磁盘类型和使用状态

目前一块系统盘40G,一块数据盘200G ,均为普通云盘,均为使用中

问:看不到数据盘

答:在没有分区和格式化数据盘之前,使用 df -h 命令是无法看到数据盘

问:如何分区和格式化

答:云服务器 ECS > 快速入门(Linux) > 步骤 4:格式化和挂载数据盘

问:fdisk 和 df 

答:fdisk is used to delete and create partitions on the hard drive in earlier versions of MS-DOS and Windows(configure the computers fixed disk drives). df displays the amount of disk space available on the file system containing each file name argument.

[root@iZ255m2u8usZ dev]# fdisk -h

Usage:
 fdisk [options] <disk>    change partition table
 fdisk [options] -l <disk> list partition table(s)
 fdisk -s <partition>      give partition size(s) in blocks

Options:
 -b <size>                 sector size (512, 1024, 2048 or 4096)
 -c                        switch off DOS-compatible mode
 -h                        print help
 -u <size>                 give sizes in sectors instead of cylinders
 -v                        print version
 -C <number>               specify the number of cylinders
 -H <number>               specify the number of heads
 -S <number>               specify the number of sectors per track
fdisk -h
[root@iZ255m2u8usZ dev]# df --help
Usage: df [OPTION]... [FILE]...
Show information about the file system on which each FILE resides,
or all file systems by default.

Mandatory arguments to long options are mandatory for short options too.
  -a, --all             include dummy file systems
  -B, --block-size=SIZE  use SIZE-byte blocks
      --direct          show statistics for a file instead of mount point
      --total           produce a grand total
  -h, --human-readable  print sizes in human readable format (e.g., 1K 234M 2G)
  -H, --si              likewise, but use powers of 1000 not 1024
  -i, --inodes          list inode information instead of block usage
  -k                    like --block-size=1K
  -l, --local           limit listing to local file systems
      --no-sync         do not invoke sync before getting usage info (default)
  -P, --portability     use the POSIX output format
      --sync            invoke sync before getting usage info
  -t, --type=TYPE       limit listing to file systems of type TYPE
  -T, --print-type      print file system type
  -x, --exclude-type=TYPE   limit listing to file systems not of type TYPE
  -v                    (ignored)
      --help     display this help and exit
      --version  output version information and exit

Display values are in units of the first available SIZE from --block-size,
and the DF_BLOCK_SIZE, BLOCK_SIZE and BLOCKSIZE environment variables.
Otherwise, units default to 1024 bytes (or 512 if POSIXLY_CORRECT is set).

SIZE may be (or may be an integer optionally followed by) one of following:
KB 1000, K 1024, MB 1000*1000, M 1024*1024, and so on for G, T, P, E, Z, Y.

Report df bugs to bug-coreutils@gnu.org
GNU coreutils home page: <http://www.gnu.org/software/coreutils/>
General help using GNU software: <http://www.gnu.org/gethelp/>
For complete documentation, run: info coreutils 'df invocation'
df --help

参考文档:

http://www.computerhope.com/unix/fdisk.htm

http://www.computerhope.com/unix/udf.htm

也就是说,fdisk 可以对磁盘分区管理,而df 只能查看已经分区好了的使用情况

问:能演示一下吗

答:

1) 查看磁盘情况

说明:有两块磁盘(/dev/xvda 和 /dev/xvdb),其中a 已分区,b未分区 。这两个名字为设备(Device)名,见下图

开阔视野举例:

Disk /dev/sda: 250.0 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device     Boot  Start  End    Blocks      Id  System
/dev/sda1  *     1      191    1534176     83  Linux
/dev/sda2        192    2231   16386300    83  Linux
/dev/sda3        2232   3506   10241437+   83  Linux
/dev/sda4        3507   30401  216034087+  5   Extended
/dev/sda5        3507   3767   2096451     82  Linux swap / Solaris
/dev/sda6        3768   3832   522081      83  Linux
/dev/sda7        3833   30401  213415461   83  Linux Disk

/dev/sdb: 250.0 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device     Boot  Start  End    Blocks      Id  System
/dev/sdb1  *     1      30401  244196001   83  Linux
fdisk -l 例子

2) 运行 fdisk /dev/xvdb,对数据盘进行分区。根据提示,依次输入 n,p,1,两次回车,wq,分区就开始了。

n 是创建新分区

p 私有分区

1 是分区数为一个

两次回车使用了两个默认值设置磁道(cylinder)

3) 检查结果

4) 上面分区已经创建完毕,还需要进行格式化(运行 mkfs.ext3 /dev/xvdb1)

5)运行 echo /dev/xvdb1 /home ext3 defaults 0 0 >> /etc/fstab 写入新分区信息。完成后,可以使用 cat /etc/fstab 命令查看。

这句是往 /etc/fstab 写入这句配置,其中ext3 要跟前面保持一致 /home 视情况修改成自己的目录。也可以用 vi 编辑

延伸阅读:

Short for file systems tablefstab is a system configuration file found most commonly on Unix systems. The file contains information about available hard disks and disk partitions as well as instructions on how they are to be initialized and integrated into the file system.

The fstab file is usually used for basic configuration settings relating to the primary hard disk and startup file system. Settings for other and partitions are now handled by automatic mounting. The system administrator is responsible for creating and maintaining this file.

6)挂载 (运行 mount /dev/xvdb1 /home 挂载新分区)

df -h 验证

挂载之后重启也不会有影响

 

4.卸载软件

1) 查询

rpm -qa | grep mysql

2)卸载

rpm -e -nodeps mysql....

3) 删除残留文件夹 (find / -name mysql)

/usr/share/mysql
/var/lib/mysql
/var/lib/mysql/mysql

5.安装软件

1) mysql

https://dev.mysql.com/doc/mysql-yum-repo-quick-guide/en/

① Adding the MySQL Yum Repository

下载 安装

[root@iZ255m2u8usZ rpmpackages]# sudo rpm -Uvh mysql57-community-release-el6-9.noarch.rpm 
warning: mysql57-community-release-el6-9.noarch.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing...                ########################################### [100%]
   1:mysql57-community-relea########################################### [100%]

查询可用项

[root@iZ255m2u8usZ rpmpackages]# yum repolist enabled | grep mysql
mysql-connectors-community MySQL Connectors Community                         30
mysql-tools-community      MySQL Tools Community                              43
mysql57-community          MySQL 5.7 Community Server                        164

② install MySQL

sudo yum install mysql-community-server

 

[root@iZ255m2u8usZ rpmpackages]# sudo yum install mysql57-community
Loaded plugins: security
Setting up Install Process
No package mysql57-community available.
Error: Nothing to do
[root@iZ255m2u8usZ rpmpackages]# sudo yum install mysql-community-server
Loaded plugins: security
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package mysql-community-server.x86_64 0:5.7.17-1.el6 will be installed
--> Processing Dependency: mysql-community-common(x86-64) = 5.7.17-1.el6 for package: mysql-community-server-5.7.17-1.el6.x86_64
--> Processing Dependency: mysql-community-client(x86-64) >= 5.7.9 for package: mysql-community-server-5.7.17-1.el6.x86_64
--> Running transaction check
---> Package mysql-community-client.x86_64 0:5.7.17-1.el6 will be installed
--> Processing Dependency: mysql-community-libs(x86-64) >= 5.7.9 for package: mysql-community-client-5.7.17-1.el6.x86_64
---> Package mysql-community-common.x86_64 0:5.7.17-1.el6 will be installed
--> Running transaction check
---> Package mysql-community-libs.x86_64 0:5.7.17-1.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

=====================================================================================================================================================================================
 Package                                            Arch                               Version                                   Repository                                     Size
=====================================================================================================================================================================================
Installing:
 mysql-community-server                             x86_64                             5.7.17-1.el6                              mysql57-community                             151 M
Installing for dependencies:
 mysql-community-client                             x86_64                             5.7.17-1.el6                              mysql57-community                              23 M
 mysql-community-common                             x86_64                             5.7.17-1.el6                              mysql57-community                             328 k
 mysql-community-libs                               x86_64                             5.7.17-1.el6                              mysql57-community                             2.1 M

Transaction Summary
=====================================================================================================================================================================================
Install       4 Package(s)

Total download size: 177 M
Installed size: 879 M
Is this ok [y/N]: y
Downloading Packages:
(1/4): mysql-community-client-5.7.17-1.el6.x86_64.rpm                                                                                                         |  23 MB     03:36     
(2/4): mysql-community-common-5.7.17-1.el6.x86_64.rpm                                                                                                         | 328 kB     00:01     
(3/4): mysql-community-libs-5.7.17-1.el6.x86_64.rpm                                                                                                           | 2.1 MB     00:17     
(4/4): mysql-community-server-5.7.17-1.el6.x86_64.rpm                                                                                                         | 151 MB     20:23     
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                124 kB/s | 177 MB     24:20     
warning: rpmts_HdrFromFdno: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Importing GPG key 0x5072E1F5:
 Userid : MySQL Release Engineering <mysql-build@oss.oracle.com>
 Package: mysql57-community-release-el6-9.noarch (installed)
 From   : /etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Is this ok [y/N]: y
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Warning: RPMDB altered outside of yum.
** Found 5 pre-existing rpmdb problem(s), 'yum check' output follows:
perl-DBD-MySQL-4.013-3.el6.x86_64 has missing requires of libmysqlclient.so.16()(64bit)
perl-DBD-MySQL-4.013-3.el6.x86_64 has missing requires of libmysqlclient.so.16(libmysqlclient_16)(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of libmysqlclient.so.16()(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of libmysqlclient.so.16(libmysqlclient_16)(64bit)
2:postfix-2.6.6-6.el6_5.x86_64 has missing requires of mysql-libs
  Installing : mysql-community-common-5.7.17-1.el6.x86_64                                                                                                                        1/4 
  Installing : mysql-community-libs-5.7.17-1.el6.x86_64                                                                                                                          2/4 
  Installing : mysql-community-client-5.7.17-1.el6.x86_64                                                                                                                        3/4 
  Installing : mysql-community-server-5.7.17-1.el6.x86_64                                                                                                                        4/4 
  Verifying  : mysql-community-server-5.7.17-1.el6.x86_64                                                                                                                        1/4 
  Verifying  : mysql-community-client-5.7.17-1.el6.x86_64                                                                                                                        2/4 
  Verifying  : mysql-community-common-5.7.17-1.el6.x86_64                                                                                                                        3/4 
  Verifying  : mysql-community-libs-5.7.17-1.el6.x86_64                                                                                                                          4/4 

Installed:
  mysql-community-server.x86_64 0:5.7.17-1.el6                                                                                                                                       

Dependency Installed:
  mysql-community-client.x86_64 0:5.7.17-1.el6                mysql-community-common.x86_64 0:5.7.17-1.el6                mysql-community-libs.x86_64 0:5.7.17-1.el6               

Complete!
[root@iZ255m2u8usZ rpmpackages]# 
执行过程

③ Starting the MySQL Server (如果启动失败,需查看日志 /var/log/mysqld.log)

[root@iZ255m2u8usZ rpmpackages]# sudo service mysqld start
Initializing MySQL database:                               [  OK  ]
Installing validate password plugin:                       [  OK  ]
Starting mysqld:                                           [  OK  ]
[root@iZ255m2u8usZ rpmpackages]# sudo service mysqld status
mysqld (pid  2771) is running...

④ 日志文件

2017-02-18T07:39:18.500053Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-02-18T07:39:18.501515Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.17) starting as process 1896 ...
2017-02-18T07:39:18.506708Z 0 [Note] InnoDB: PUNCH HOLE support available
2017-02-18T07:39:18.506734Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-02-18T07:39:18.506742Z 0 [Note] InnoDB: Uses event mutexes
2017-02-18T07:39:18.506870Z 0 [Note] InnoDB: GCC builtin __sync_synchronize() is used for memory barrier
2017-02-18T07:39:18.506883Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-02-18T07:39:18.506892Z 0 [Note] InnoDB: Using Linux native AIO
2017-02-18T07:39:18.507195Z 0 [Note] InnoDB: Number of pools: 1
2017-02-18T07:39:18.507330Z 0 [Note] InnoDB: Using CPU crc32 instructions
2017-02-18T07:39:18.508948Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-02-18T07:39:18.518642Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-02-18T07:39:18.521314Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2017-02-18T07:39:18.533757Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2017-02-18T07:39:18.537383Z 0 [Note] InnoDB: Creating tablespace and datafile system tables.
2017-02-18T07:39:18.584404Z 0 [Note] InnoDB: Tablespace and datafile system tables created.
2017-02-18T07:39:18.600228Z 0 [Warning] InnoDB: Upgrading redo log: 2*3072 pages, LSN=43461825
2017-02-18T07:39:18.722498Z 0 [Warning] InnoDB: Starting to delete and rewrite log files.
2017-02-18T07:39:18.723005Z 0 [Note] InnoDB: Setting log file ./ib_logfile101 size to 48 MB
2017-02-18T07:39:19.858513Z 0 [Note] InnoDB: Setting log file ./ib_logfile1 size to 48 MB
2017-02-18T07:39:21.264529Z 0 [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0
2017-02-18T07:39:21.264654Z 0 [Warning] InnoDB: New log files created, LSN=43461825
2017-02-18T07:39:21.265583Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2017-02-18T07:39:21.265687Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2017-02-18T07:39:21.609908Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2017-02-18T07:39:21.685036Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2017-02-18T07:39:21.685089Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2017-02-18T07:39:21.685693Z 0 [Note] InnoDB: Creating sys_virtual system tables.
2017-02-18T07:39:21.726925Z 0 [Note] InnoDB: sys_virtual table created
2017-02-18T07:39:21.727810Z 0 [Note] InnoDB: Waiting for purge to start
2017-02-18T07:39:21.777941Z 0 [Note] InnoDB: 5.7.17 started; log sequence number 0
2017-02-18T07:39:21.778719Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2017-02-18T07:39:21.778792Z 0 [ERROR] InnoDB: Cannot open '/var/lib/mysql/ib_buffer_pool' for reading: No such file or directory
2017-02-18T07:39:21.778896Z 0 [Note] Plugin 'FEDERATED' is disabled.
2017-02-18T07:39:21.782529Z 0 [Warning] System table 'plugin' is expected to be transactional.
2017-02-18T07:39:21.783128Z 0 [Note] Salting uuid generator variables, current_pid: 1896, server_start_time: 1487403558, bytes_sent: 0, 
2017-02-18T07:39:21.783192Z 0 [Note] Generated uuid: '5ce1dbc0-f5ad-11e6-885a-00163e001b41', server_start_time: 533676557330809230, bytes_sent: 38601536
2017-02-18T07:39:21.783209Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 5ce1dbc0-f5ad-11e6-885a-00163e001b41.
2017-02-18T07:39:21.789704Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2017-02-18T07:39:21.789811Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
2017-02-18T07:39:21.790260Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2017-02-18T07:39:21.791262Z 0 [Note] IPv6 is not available.
2017-02-18T07:39:21.791309Z 0 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
2017-02-18T07:39:21.791338Z 0 [Note] Server socket created on IP: '0.0.0.0'.
2017-02-18T07:39:21.797702Z 0 [Warning] Failed to open optimizer cost constant tables

2017-02-18T07:39:21.798138Z 0 [ERROR] Fatal error: mysql.user table is damaged. Please run mysql_upgrade.
2017-02-18T07:39:21.798220Z 0 [ERROR] Aborting

2017-02-18T07:39:21.798262Z 0 [Note] Binlog end
2017-02-18T07:39:21.798357Z 0 [Note] Shutting down plugin 'ngram'
2017-02-18T07:39:21.798370Z 0 [Note] Shutting down plugin 'partition'
2017-02-18T07:39:21.798375Z 0 [Note] Shutting down plugin 'BLACKHOLE'
2017-02-18T07:39:21.798380Z 0 [Note] Shutting down plugin 'ARCHIVE'
2017-02-18T07:39:21.798384Z 0 [Note] Shutting down plugin 'MRG_MYISAM'
2017-02-18T07:39:21.798390Z 0 [Note] Shutting down plugin 'MEMORY'
2017-02-18T07:39:21.798397Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL'
2017-02-18T07:39:21.798402Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2017-02-18T07:39:21.798406Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2017-02-18T07:39:21.798410Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2017-02-18T07:39:21.798414Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2017-02-18T07:39:21.798418Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2017-02-18T07:39:21.798422Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2017-02-18T07:39:21.798426Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2017-02-18T07:39:21.798430Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2017-02-18T07:39:21.798434Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2017-02-18T07:39:21.798438Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2017-02-18T07:39:21.798442Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2017-02-18T07:39:21.798446Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2017-02-18T07:39:21.798450Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2017-02-18T07:39:21.798454Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2017-02-18T07:39:21.798458Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2017-02-18T07:39:21.798461Z 0 [Note] Shutting down plugin 'INNODB_METRICS'
2017-02-18T07:39:21.798465Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO'
2017-02-18T07:39:21.798469Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2017-02-18T07:39:21.798473Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2017-02-18T07:39:21.798477Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2017-02-18T07:39:21.798482Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2017-02-18T07:39:21.798485Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2017-02-18T07:39:21.798489Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2017-02-18T07:39:21.798493Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM'
2017-02-18T07:39:21.798497Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2017-02-18T07:39:21.798501Z 0 [Note] Shutting down plugin 'INNODB_CMP'
2017-02-18T07:39:21.798505Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2017-02-18T07:39:21.798509Z 0 [Note] Shutting down plugin 'INNODB_LOCKS'
2017-02-18T07:39:21.798515Z 0 [Note] Shutting down plugin 'INNODB_TRX'
2017-02-18T07:39:21.798519Z 0 [Note] Shutting down plugin 'InnoDB'
2017-02-18T07:39:21.798591Z 0 [Note] InnoDB: FTS optimize thread exiting.
2017-02-18T07:39:21.798702Z 0 [Note] InnoDB: Starting shutdown...
2017-02-18T07:39:21.898894Z 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool
2017-02-18T07:39:21.899194Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 170218 15:39:21
2017-02-18T07:39:23.636555Z 0 [Note] InnoDB: Shutdown completed; log sequence number 44637055
2017-02-18T07:39:23.639250Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2017-02-18T07:39:23.639270Z 0 [Note] Shutting down plugin 'MyISAM'
2017-02-18T07:39:23.639294Z 0 [Note] Shutting down plugin 'CSV'
2017-02-18T07:39:23.639312Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2017-02-18T07:39:23.639398Z 0 [Note] Shutting down plugin 'sha256_password'
2017-02-18T07:39:23.639404Z 0 [Note] Shutting down plugin 'mysql_native_password'
2017-02-18T07:39:23.639569Z 0 [Note] Shutting down plugin 'binlog'
2017-02-18T07:39:23.639846Z 0 [Note] /usr/sbin/mysqld: Shutdown complete

2017-02-18T07:40:24.552172Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-02-18T07:40:24.554116Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.17) starting as process 2248 ...
2017-02-18T07:40:24.559210Z 0 [Note] InnoDB: PUNCH HOLE support available
2017-02-18T07:40:24.559239Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-02-18T07:40:24.559248Z 0 [Note] InnoDB: Uses event mutexes
2017-02-18T07:40:24.559255Z 0 [Note] InnoDB: GCC builtin __sync_synchronize() is used for memory barrier
2017-02-18T07:40:24.559262Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-02-18T07:40:24.559271Z 0 [Note] InnoDB: Using Linux native AIO
2017-02-18T07:40:24.559574Z 0 [Note] InnoDB: Number of pools: 1
2017-02-18T07:40:24.559726Z 0 [Note] InnoDB: Using CPU crc32 instructions
2017-02-18T07:40:24.561369Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-02-18T07:40:24.572814Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-02-18T07:40:24.575529Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2017-02-18T07:40:24.587626Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2017-02-18T07:40:24.605030Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2017-02-18T07:40:24.605130Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2017-02-18T07:40:24.914752Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2017-02-18T07:40:24.915869Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2017-02-18T07:40:24.915888Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2017-02-18T07:40:24.917116Z 0 [Note] InnoDB: Waiting for purge to start
2017-02-18T07:40:24.967343Z 0 [Note] InnoDB: 5.7.17 started; log sequence number 44637055
2017-02-18T07:40:24.968117Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2017-02-18T07:40:24.968346Z 0 [Note] Plugin 'FEDERATED' is disabled.
2017-02-18T07:40:24.968671Z 0 [Note] InnoDB: Buffer pool(s) load completed at 170218 15:40:24
2017-02-18T07:40:24.972077Z 0 [Warning] System table 'plugin' is expected to be transactional.
2017-02-18T07:40:24.972787Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2017-02-18T07:40:24.972877Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
2017-02-18T07:40:24.973385Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2017-02-18T07:40:24.974416Z 0 [Note] IPv6 is not available.
2017-02-18T07:40:24.974464Z 0 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
2017-02-18T07:40:24.974495Z 0 [Note] Server socket created on IP: '0.0.0.0'.
2017-02-18T07:40:24.983127Z 0 [Warning] Failed to open optimizer cost constant tables

2017-02-18T07:40:24.983595Z 0 [ERROR] Fatal error: mysql.user table is damaged. Please run mysql_upgrade.
2017-02-18T07:40:24.983701Z 0 [ERROR] Aborting

2017-02-18T07:40:24.983747Z 0 [Note] Binlog end
2017-02-18T07:40:24.983824Z 0 [Note] Shutting down plugin 'ngram'
2017-02-18T07:40:24.983837Z 0 [Note] Shutting down plugin 'partition'
2017-02-18T07:40:24.983842Z 0 [Note] Shutting down plugin 'BLACKHOLE'
2017-02-18T07:40:24.983848Z 0 [Note] Shutting down plugin 'ARCHIVE'
2017-02-18T07:40:24.983853Z 0 [Note] Shutting down plugin 'MRG_MYISAM'
2017-02-18T07:40:24.983861Z 0 [Note] Shutting down plugin 'MEMORY'
2017-02-18T07:40:24.983876Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL'
2017-02-18T07:40:24.983882Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2017-02-18T07:40:24.983886Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2017-02-18T07:40:24.983890Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2017-02-18T07:40:24.983894Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2017-02-18T07:40:24.983899Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2017-02-18T07:40:24.983902Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2017-02-18T07:40:24.983906Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2017-02-18T07:40:24.983910Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2017-02-18T07:40:24.983914Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2017-02-18T07:40:24.983918Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2017-02-18T07:40:24.983921Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2017-02-18T07:40:24.983925Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2017-02-18T07:40:24.983929Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2017-02-18T07:40:24.983933Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2017-02-18T07:40:24.983937Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2017-02-18T07:40:24.983940Z 0 [Note] Shutting down plugin 'INNODB_METRICS'
2017-02-18T07:40:24.983944Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO'
2017-02-18T07:40:24.983948Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2017-02-18T07:40:24.983952Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2017-02-18T07:40:24.983956Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2017-02-18T07:40:24.983960Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2017-02-18T07:40:24.983964Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2017-02-18T07:40:24.983968Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2017-02-18T07:40:24.983971Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM'
2017-02-18T07:40:24.983975Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2017-02-18T07:40:24.983979Z 0 [Note] Shutting down plugin 'INNODB_CMP'
2017-02-18T07:40:24.983983Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2017-02-18T07:40:24.983987Z 0 [Note] Shutting down plugin 'INNODB_LOCKS'
2017-02-18T07:40:24.983991Z 0 [Note] Shutting down plugin 'INNODB_TRX'
2017-02-18T07:40:24.983995Z 0 [Note] Shutting down plugin 'InnoDB'
2017-02-18T07:40:24.984075Z 0 [Note] InnoDB: FTS optimize thread exiting.
2017-02-18T07:40:24.984449Z 0 [Note] InnoDB: Starting shutdown...
2017-02-18T07:40:25.084661Z 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool
2017-02-18T07:40:25.085041Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 170218 15:40:25
2017-02-18T07:40:26.797826Z 0 [Note] InnoDB: Shutdown completed; log sequence number 44637074
2017-02-18T07:40:26.800327Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2017-02-18T07:40:26.800345Z 0 [Note] Shutting down plugin 'MyISAM'
2017-02-18T07:40:26.800371Z 0 [Note] Shutting down plugin 'CSV'
2017-02-18T07:40:26.800379Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2017-02-18T07:40:26.800464Z 0 [Note] Shutting down plugin 'sha256_password'
2017-02-18T07:40:26.800470Z 0 [Note] Shutting down plugin 'mysql_native_password'
2017-02-18T07:40:26.800651Z 0 [Note] Shutting down plugin 'binlog'
2017-02-18T07:40:26.800921Z 0 [Note] /usr/sbin/mysqld: Shutdown complete

2017-02-18T09:13:11.399761Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-02-18T09:13:14.006110Z 0 [Warning] InnoDB: New log files created, LSN=45790
2017-02-18T09:13:14.447694Z 0 [Warning] InnoDB: Creating foreign key constraint system tables.
2017-02-18T09:13:14.548779Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 7a45ad0d-f5ba-11e6-a8d5-00163e001b41.
2017-02-18T09:13:14.557361Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2017-02-18T09:13:14.558169Z 1 [Note] A temporary password is generated for root@localhost: 0.fbtCs)VJi-
2017-02-18T09:13:21.199811Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-02-18T09:13:21.201619Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.17) starting as process 2513 ...
2017-02-18T09:13:21.206497Z 0 [Note] InnoDB: PUNCH HOLE support available
2017-02-18T09:13:21.206523Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-02-18T09:13:21.206531Z 0 [Note] InnoDB: Uses event mutexes
2017-02-18T09:13:21.206541Z 0 [Note] InnoDB: GCC builtin __sync_synchronize() is used for memory barrier
2017-02-18T09:13:21.206547Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-02-18T09:13:21.206556Z 0 [Note] InnoDB: Using Linux native AIO
2017-02-18T09:13:21.206876Z 0 [Note] InnoDB: Number of pools: 1
2017-02-18T09:13:21.207008Z 0 [Note] InnoDB: Using CPU crc32 instructions
2017-02-18T09:13:21.208612Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-02-18T09:13:21.218728Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-02-18T09:13:21.221346Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2017-02-18T09:13:21.233464Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2017-02-18T09:13:21.250327Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2017-02-18T09:13:21.250423Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2017-02-18T09:13:21.603057Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2017-02-18T09:13:21.604096Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2017-02-18T09:13:21.604113Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2017-02-18T09:13:21.605271Z 0 [Note] InnoDB: Waiting for purge to start
2017-02-18T09:13:21.655448Z 0 [Note] InnoDB: 5.7.17 started; log sequence number 2534561
2017-02-18T09:13:21.656223Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2017-02-18T09:13:21.656487Z 0 [Note] Plugin 'FEDERATED' is disabled.
2017-02-18T09:13:21.657961Z 0 [Note] InnoDB: Buffer pool(s) load completed at 170218 17:13:21
2017-02-18T09:13:21.661939Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
2017-02-18T09:13:21.662437Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2017-02-18T09:13:21.663469Z 0 [Note] IPv6 is not available.
2017-02-18T09:13:21.663511Z 0 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
2017-02-18T09:13:21.663538Z 0 [Note] Server socket created on IP: '0.0.0.0'.
2017-02-18T09:13:21.683312Z 0 [Note] Event Scheduler: Loaded 0 events
2017-02-18T09:13:21.683436Z 0 [Note] Executing 'SELECT * FROM INFORMATION_SCHEMA.TABLES;' to get a list of tables using the deprecated partition engine. You may use the startup option '--disable-partition-engine-check' to skip this check. 
2017-02-18T09:13:21.683456Z 0 [Note] Beginning of list of non-natively partitioned tables
2017-02-18T09:13:21.697448Z 0 [Note] End of list of non-natively partitioned tables
2017-02-18T09:13:21.697470Z 0 [Note] Execution of init_file '/var/lib/mysql/install-validate-password-plugin.xuIY3W.sql' started.
2017-02-18T09:13:21.708185Z 0 [Note] Execution of init_file '/var/lib/mysql/install-validate-password-plugin.xuIY3W.sql' ended.
2017-02-18T09:13:21.708274Z 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.7.17'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  MySQL Community Server (GPL)
2017-02-18T09:13:21.708574Z 0 [Note] Giving 0 client threads a chance to die gracefully
2017-02-18T09:13:21.708596Z 0 [Note] Shutting down slave threads
2017-02-18T09:13:21.708605Z 0 [Note] Forcefully disconnecting 0 remaining clients
2017-02-18T09:13:21.708621Z 0 [Note] Event Scheduler: Purging the queue. 0 events
2017-02-18T09:13:21.708702Z 0 [Note] Binlog end
2017-02-18T09:13:21.709428Z 0 [Note] Shutting down plugin 'ngram'
2017-02-18T09:13:21.709446Z 0 [Note] Shutting down plugin 'partition'
2017-02-18T09:13:21.709454Z 0 [Note] Shutting down plugin 'BLACKHOLE'
2017-02-18T09:13:21.709460Z 0 [Note] Shutting down plugin 'ARCHIVE'
2017-02-18T09:13:21.709465Z 0 [Note] Shutting down plugin 'MRG_MYISAM'
2017-02-18T09:13:21.709472Z 0 [Note] Shutting down plugin 'MEMORY'
2017-02-18T09:13:21.709478Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL'
2017-02-18T09:13:21.709485Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES'
2017-02-18T09:13:21.709489Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES'
2017-02-18T09:13:21.709494Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS'
2017-02-18T09:13:21.709498Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN'
2017-02-18T09:13:21.709502Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS'
2017-02-18T09:13:21.709506Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS'
2017-02-18T09:13:21.709510Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES'
2017-02-18T09:13:21.709514Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS'
2017-02-18T09:13:21.709518Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES'
2017-02-18T09:13:21.709522Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE'
2017-02-18T09:13:21.709526Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE'
2017-02-18T09:13:21.709530Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG'
2017-02-18T09:13:21.709534Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED'
2017-02-18T09:13:21.709538Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED'
2017-02-18T09:13:21.709542Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD'
2017-02-18T09:13:21.709545Z 0 [Note] Shutting down plugin 'INNODB_METRICS'
2017-02-18T09:13:21.709549Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO'
2017-02-18T09:13:21.709553Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS'
2017-02-18T09:13:21.709557Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU'
2017-02-18T09:13:21.709561Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE'
2017-02-18T09:13:21.709565Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET'
2017-02-18T09:13:21.709569Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX'
2017-02-18T09:13:21.709572Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET'
2017-02-18T09:13:21.709576Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM'
2017-02-18T09:13:21.709580Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET'
2017-02-18T09:13:21.709584Z 0 [Note] Shutting down plugin 'INNODB_CMP'
2017-02-18T09:13:21.709587Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS'
2017-02-18T09:13:21.709591Z 0 [Note] Shutting down plugin 'INNODB_LOCKS'
2017-02-18T09:13:21.709595Z 0 [Note] Shutting down plugin 'INNODB_TRX'
2017-02-18T09:13:21.709599Z 0 [Note] Shutting down plugin 'InnoDB'
2017-02-18T09:13:21.709694Z 0 [Note] InnoDB: FTS optimize thread exiting.
2017-02-18T09:13:21.709782Z 0 [Note] InnoDB: Starting shutdown...
2017-02-18T09:13:21.810025Z 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool
2017-02-18T09:13:21.810673Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 170218 17:13:21
2017-02-18T09:13:23.537321Z 0 [Note] InnoDB: Shutdown completed; log sequence number 2534784
2017-02-18T09:13:23.539950Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2017-02-18T09:13:23.539969Z 0 [Note] Shutting down plugin 'MyISAM'
2017-02-18T09:13:23.539984Z 0 [Note] Shutting down plugin 'CSV'
2017-02-18T09:13:23.539991Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA'
2017-02-18T09:13:23.540025Z 0 [Note] Shutting down plugin 'sha256_password'
2017-02-18T09:13:23.540031Z 0 [Note] Shutting down plugin 'mysql_native_password'
2017-02-18T09:13:23.540197Z 0 [Note] Shutting down plugin 'binlog'
2017-02-18T09:13:23.540692Z 0 [Note] /usr/sbin/mysqld: Shutdown complete

2017-02-18T09:13:24.701085Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-02-18T09:13:24.702486Z 0 [Note] /usr/sbin/mysqld (mysqld 5.7.17) starting as process 2771 ...
2017-02-18T09:13:24.708150Z 0 [Note] InnoDB: PUNCH HOLE support available
2017-02-18T09:13:24.708183Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-02-18T09:13:24.708193Z 0 [Note] InnoDB: Uses event mutexes
2017-02-18T09:13:24.708199Z 0 [Note] InnoDB: GCC builtin __sync_synchronize() is used for memory barrier
2017-02-18T09:13:24.708206Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-02-18T09:13:24.708214Z 0 [Note] InnoDB: Using Linux native AIO
2017-02-18T09:13:24.708542Z 0 [Note] InnoDB: Number of pools: 1
2017-02-18T09:13:24.708691Z 0 [Note] InnoDB: Using CPU crc32 instructions
2017-02-18T09:13:24.710365Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-02-18T09:13:24.721367Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-02-18T09:13:24.724051Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2017-02-18T09:13:24.736395Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2017-02-18T09:13:24.760218Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2017-02-18T09:13:24.760329Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2017-02-18T09:13:25.093865Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2017-02-18T09:13:25.095053Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2017-02-18T09:13:25.095071Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2017-02-18T09:13:25.096195Z 0 [Note] InnoDB: 5.7.17 started; log sequence number 2534784
2017-02-18T09:13:25.097414Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2017-02-18T09:13:25.097722Z 0 [Note] Plugin 'FEDERATED' is disabled.
2017-02-18T09:13:25.099438Z 0 [Note] InnoDB: Buffer pool(s) load completed at 170218 17:13:25
2017-02-18T09:13:25.104721Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.
2017-02-18T09:13:25.104983Z 0 [Warning] CA certificate ca.pem is self signed.
2017-02-18T09:13:25.107298Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2017-02-18T09:13:25.108310Z 0 [Note] IPv6 is not available.
2017-02-18T09:13:25.108358Z 0 [Note]   - '0.0.0.0' resolves to '0.0.0.0';
2017-02-18T09:13:25.108389Z 0 [Note] Server socket created on IP: '0.0.0.0'.
2017-02-18T09:13:25.127135Z 0 [Note] Event Scheduler: Loaded 0 events
2017-02-18T09:13:25.127274Z 0 [Note] Executing 'SELECT * FROM INFORMATION_SCHEMA.TABLES;' to get a list of tables using the deprecated partition engine. You may use the startup option '--disable-partition-engine-check' to skip this check. 
2017-02-18T09:13:25.127291Z 0 [Note] Beginning of list of non-natively partitioned tables
2017-02-18T09:13:25.141518Z 0 [Note] End of list of non-natively partitioned tables
2017-02-18T09:13:25.141628Z 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.7.17'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  MySQL Community Server (GPL)
2017-02-18T09:13:25.406503Z 3 [Note] Access denied for user 'UNKNOWN_MYSQL_USER'@'localhost' (using password: NO)
[root@iZ255m2u8usZ log]# 
mysqld.log

获取临时的超级用户临时密码(从文件中过滤信息)

sudo grep 'temporary password' /var/log/mysqld.log

修改成自己的密码

[root@iZ255m2u8usZ log]# mysql -uroot -p
Enter password: 

进入mysql 控制台,执行语句:

ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass4!';

⑤ 开启远程连接

mysql> use mysql;
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> update user set host ='%' where user ='root';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

 

2)jdk

3)tomcat

4)nginx

5) 大量图片转移

scp -r /home/target user@host2:/home

执行这个命令的机器赠出

-r 是递归,将全部文件赠出

意思是将host1 的home下target文件整个复制到 host2的home下

需要知道两个用户名密码

 

rsync -avzutP /home/target root@host1:/home

-u 不覆盖原有,可以增量

rsync  version 3.0.6  protocol version 30
Copyright (C) 1996-2009 by Andrew Tridgell, Wayne Davison, and others.
Web site: http://rsync.samba.org/
Capabilities:
    64-bit files, 64-bit inums, 64-bit timestamps, 64-bit long ints,
    socketpairs, hardlinks, symlinks, IPv6, batchfiles, inplace,
    append, ACLs, xattrs, iconv, symtimes

rsync comes with ABSOLUTELY NO WARRANTY.  This is free software, and you
are welcome to redistribute it under certain conditions.  See the GNU
General Public Licence for details.

rsync is a file transfer program capable of efficient remote update
via a fast differencing algorithm.

Usage: rsync [OPTION]... SRC [SRC]... DEST
  or   rsync [OPTION]... SRC [SRC]... [USER@]HOST:DEST
  or   rsync [OPTION]... SRC [SRC]... [USER@]HOST::DEST
  or   rsync [OPTION]... SRC [SRC]... rsync://[USER@]HOST[:PORT]/DEST
  or   rsync [OPTION]... [USER@]HOST:SRC [DEST]
  or   rsync [OPTION]... [USER@]HOST::SRC [DEST]
  or   rsync [OPTION]... rsync://[USER@]HOST[:PORT]/SRC [DEST]
The ':' usages connect via remote shell, while '::' & 'rsync://' usages connect
to an rsync daemon, and require SRC or DEST to start with a module name.

Options
 -v, --verbose               increase verbosity
 -q, --quiet                 suppress non-error messages
     --no-motd               suppress daemon-mode MOTD (see manpage caveat)
 -c, --checksum              skip based on checksum, not mod-time & size
 -a, --archive               archive mode; equals -rlptgoD (no -H,-A,-X)
     --no-OPTION             turn off an implied OPTION (e.g. --no-D)
 -r, --recursive             recurse into directories
 -R, --relative              use relative path names
     --no-implied-dirs       don't send implied dirs with --relative
 -b, --backup                make backups (see --suffix & --backup-dir)
     --backup-dir=DIR        make backups into hierarchy based in DIR
     --suffix=SUFFIX         set backup suffix (default ~ w/o --backup-dir)
 -u, --update                skip files that are newer on the receiver
     --inplace               update destination files in-place (SEE MAN PAGE)
     --append                append data onto shorter files
     --append-verify         like --append, but with old data in file checksum
 -d, --dirs                  transfer directories without recursing
 -l, --links                 copy symlinks as symlinks
 -L, --copy-links            transform symlink into referent file/dir
     --copy-unsafe-links     only "unsafe" symlinks are transformed
     --safe-links            ignore symlinks that point outside the source tree
 -k, --copy-dirlinks         transform symlink to a dir into referent dir
 -K, --keep-dirlinks         treat symlinked dir on receiver as dir
 -H, --hard-links            preserve hard links
 -p, --perms                 preserve permissions
 -E, --executability         preserve the file's executability
     --chmod=CHMOD           affect file and/or directory permissions
 -A, --acls                  preserve ACLs (implies --perms)
 -X, --xattrs                preserve extended attributes
 -o, --owner                 preserve owner (super-user only)
 -g, --group                 preserve group
     --devices               preserve device files (super-user only)
     --copy-devices          copy device contents as regular file
     --specials              preserve special files
 -D                          same as --devices --specials
 -t, --times                 preserve modification times
 -O, --omit-dir-times        omit directories from --times
     --super                 receiver attempts super-user activities
     --fake-super            store/recover privileged attrs using xattrs
 -S, --sparse                handle sparse files efficiently
 -n, --dry-run               perform a trial run with no changes made
 -W, --whole-file            copy files whole (without delta-xfer algorithm)
 -x, --one-file-system       don't cross filesystem boundaries
 -B, --block-size=SIZE       force a fixed checksum block-size
 -e, --rsh=COMMAND           specify the remote shell to use
     --rsync-path=PROGRAM    specify the rsync to run on the remote machine
     --existing              skip creating new files on receiver
     --ignore-existing       skip updating files that already exist on receiver
     --remove-source-files   sender removes synchronized files (non-dirs)
     --del                   an alias for --delete-during
     --delete                delete extraneous files from destination dirs
     --delete-before         receiver deletes before transfer, not during
     --delete-during         receiver deletes during transfer (default)
     --delete-delay          find deletions during, delete after
     --delete-after          receiver deletes after transfer, not during
     --delete-excluded       also delete excluded files from destination dirs
     --ignore-errors         delete even if there are I/O errors
     --force                 force deletion of directories even if not empty
     --max-delete=NUM        don't delete more than NUM files
     --max-size=SIZE         don't transfer any file larger than SIZE
     --min-size=SIZE         don't transfer any file smaller than SIZE
     --partial               keep partially transferred files
     --partial-dir=DIR       put a partially transferred file into DIR
     --delay-updates         put all updated files into place at transfer's end
 -m, --prune-empty-dirs      prune empty directory chains from the file-list
     --numeric-ids           don't map uid/gid values by user/group name
     --timeout=SECONDS       set I/O timeout in seconds
     --contimeout=SECONDS    set daemon connection timeout in seconds
 -I, --ignore-times          don't skip files that match in size and mod-time
     --size-only             skip files that match in size
     --modify-window=NUM     compare mod-times with reduced accuracy
 -T, --temp-dir=DIR          create temporary files in directory DIR
 -y, --fuzzy                 find similar file for basis if no dest file
     --compare-dest=DIR      also compare destination files relative to DIR
     --copy-dest=DIR         ... and include copies of unchanged files
     --link-dest=DIR         hardlink to files in DIR when unchanged
 -z, --compress              compress file data during the transfer
     --compress-level=NUM    explicitly set compression level
     --skip-compress=LIST    skip compressing files with a suffix in LIST
 -C, --cvs-exclude           auto-ignore files the same way CVS does
 -f, --filter=RULE           add a file-filtering RULE
 -F                          same as --filter='dir-merge /.rsync-filter'
                             repeated: --filter='- .rsync-filter'
     --exclude=PATTERN       exclude files matching PATTERN
     --exclude-from=FILE     read exclude patterns from FILE
     --include=PATTERN       don't exclude files matching PATTERN
     --include-from=FILE     read include patterns from FILE
     --files-from=FILE       read list of source-file names from FILE
 -0, --from0                 all *-from/filter files are delimited by 0s
 -s, --protect-args          no space-splitting; only wildcard special-chars
     --address=ADDRESS       bind address for outgoing socket to daemon
     --port=PORT             specify double-colon alternate port number
     --sockopts=OPTIONS      specify custom TCP options
     --blocking-io           use blocking I/O for the remote shell
     --stats                 give some file-transfer stats
 -8, --8-bit-output          leave high-bit chars unescaped in output
 -h, --human-readable        output numbers in a human-readable format
     --progress              show progress during transfer
 -P                          same as --partial --progress
 -i, --itemize-changes       output a change-summary for all updates
     --out-format=FORMAT     output updates using the specified FORMAT
     --log-file=FILE         log what we're doing to the specified FILE
     --log-file-format=FMT   log updates using the specified FMT
     --password-file=FILE    read daemon-access password from FILE
     --list-only             list the files instead of copying them
     --bwlimit=KBPS          limit I/O bandwidth; KBytes per second
     --write-batch=FILE      write a batched update to FILE
     --only-write-batch=FILE like --write-batch but w/o updating destination
     --read-batch=FILE       read a batched update from FILE
     --protocol=NUM          force an older protocol version to be used
     --iconv=CONVERT_SPEC    request charset conversion of filenames
 -4, --ipv4                  prefer IPv4
 -6, --ipv6                  prefer IPv6
     --version               print version number
(-h) --help                  show this help (-h works with no other options)

Use "rsync --daemon --help" to see the daemon-mode command-line options.
Please see the rsync(1) and rsyncd.conf(5) man pages for full documentation.
See http://rsync.samba.org/ for updates, bug reports, and answers
rsync --help

 6. 同步mysql数据库

使用 navicat for mysql 的同步工具

源 -> 目标   英文是 source -> target (被修改的一方,最终会和源一致)

一定要查看日志信息,因为有些数据可能failed 

posted on 2023-06-06 13:15  zno2  阅读(13)  评论(0编辑  收藏  举报

导航