Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

 

设置SWAP

设置swap
$ mkdir /data
$ dd if=/dev/zero of=/data/swap bs=512 count=8388616
$ mkswap /data/swap
$ vi /etc/sysctl.conf, vm.swappiness设置为60
$ vi /etc/fstab   添加  /data/swap swap swap defaults    0  0
挂载NAS
$ apt-get update
$ apt-get install nfs-common
$ mkdir /app_home
$ mount -t nfs -o vers=4.0,rsize=1048576,wsize=1048576,hard,timeo=600,retrans=2,noresvport file-system-id-xxxx.region.nas.aliyuncs.com:/ /app_home
$ vi /etc/fstab  添加  file-system-id-xxxx.region.nas.aliyuncs.com:/ /app_home  nfs4 vers=4.0,rsize=1048576,wsize=1048576,hard,timeo=600,retrans=2,_netdev,noresvport 0 0
  • No labels