Default Amazon ECS GPU-optimized AMI version is 418.xx. The method of changing the nvidia-driver version of the default image is the following.

  1. Check ami id of Amazon ECS GPU-optimized AMI from url
  2. Create EC2 instance using the ami
  3. Find the NVIDIA driver you want from url
  4. Install driver by using the command in the ec2 console.
     

sudo yum install gcc gcc-c++ sudo yum install kernel-devel wget http://us.download.nvidia.com/tesla/440.33.01/NVIDIA-Linux-x86_64-440.33.01.run sudo sh NVIDIA-Linux-x86_64-440.33.01.run

5. Check the installed driver using `nvidia-smi` and create new AMI