Skip to content

Instantly share code, notes, and snippets.

@nickwanhere
Created June 24, 2016 08:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nickwanhere/0d0dd66af3f42b3f2f73cc5878c07169 to your computer and use it in GitHub Desktop.
Save nickwanhere/0d0dd66af3f42b3f2f73cc5878c07169 to your computer and use it in GitHub Desktop.
root@myserver:~# dd if=/dev/zero of=/swap.dat bs=1024 count=512k
root@myserver:~# mkswap /swap.dat
root@myserver:~# swapon /swap.dat
root@myserver:~# vim /etc/fstab
vim is started to edit, add the following to the end of /etc/fstab file
/swap.dat none swap sw 0 0
Then, edit the mysql config file
root@myserver:~# vim /etc/mysql/my.cnf
And add this under [mysqld]
innodb_buffer_pool_size=64M
Finally reload mysql
root@myserver:~# service mysqld reload
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment