Reference: https://www.jb51.net/article/136432.htm
First, view memory
free -h
free -m
Second, the solution:
1, increase swap swap space to solve the problem:
dd if=/dev/zero of=/swapfile bs=1M count=1024
mkswap /swapfile
swapon /swapfile
2, increase automatically mount:
Join / swapfile swap swap defaults 0 0 in the file / etc / fstab in
service mysql start a successful start
3, notes
Generates an empty file
dd if = / dev / zero of = 1.txt bs = 1M count = 2 generates an empty file specified size
if = file name: the file name
of = filename: Output file name
bs = byte size
count = number