Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Install CUDA on Amazon EC2 g2.2xlarge instance
sudo apt-get update
sudo apt-get -y dist-upgrade
sudo apt-get install -y gcc g++ gfortran build-essential linux-image-generic libopenblas-dev python-nose python-numpy python-scipy linux-headers-generic-lts-trusty linux-source
sudo rm /boot/grub/menu.lst
sudo update-grub
# if / has only around 8 GB, move that file to /mnt which has lots of space
mv ~/ /mnt
sudo sh /mnt/
# accept eula, answer yes to every question and use default directories
echo 'export PATH=/usr/local/cuda-7.0/bin:$PATH' >> ~/.bashrc
echo 'export LD_LIBRARY_PATH=/usr/local/cuda-7.0/lib64:$LD_LIBRARY_PATH' >> ~/.bashrc
sudo reboot
# verify/test cuda
# check output
cd NVIDIA\_CUDA-7.0\_Samples/1\_Utilities/deviceQuery
# check output
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.