Skip to content

Instantly share code, notes, and snippets.

@stephanschubert
Created January 21, 2014 13:36
Show Gist options
  • Save stephanschubert/8540144 to your computer and use it in GitHub Desktop.
Save stephanschubert/8540144 to your computer and use it in GitHub Desktop.
Move MySQL db into 1GB ramdisk on OSX
diskutil erasevolume HFS+ "ramdisk" `hdiutil attach -nomount ram://2048000`
/usr/local/Cellar/mysql/5.6.15/scripts/mysql_install_db \
--basedir=/usr/local/Cellar/mysql/5.6.15 \
--datadir=/Volumes/ramdisk
/usr/local/Cellar/mysql/5.6.15/bin/mysqld \
--basedir=/usr/local/Cellar/mysql/5.6.15 \
--datadir=/Volumes/ramdisk \
--plugin-dir=/usr/local/Cellar/mysql/5.6.15/lib/plugin \
--bind-address=127.0.0.1 \
--log-error=/usr/local/var/mysql/imac.err \
--pid-file=/usr/local/var/mysql/imac.pid
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment