Backup /etc/fstab
cp /etc/fstab /tmp/fstab.`date +%F`
Delete the swap mount item in /etc/fstab
vim /etc/fstab
Delete the line with swap
Close all swap
swapoff -a
Observe the recovery of the process after using swap and swapoff -a. For processes that cannot recover swap, you need to schedule a time to restart
an examination:
free -m # 应该 Swap 这一行显示全是
0