By default MySQL uses the system default location used for temporary file storage, which is usually /tmp, /var/tmp, or /usr/tmp. In Ubuntu its /tmp. It’s good practice to specify separate location for MySQL, if you want to prevent System restart. If tmp location is on separate location then only MySQL restart will needed in case of any disk increase needed in future.

Step 1: Create new EBS Volume by Login to Console and Click on EC2 Dashboard, then click on “Volumes”

Step 2: Fill the details of Volume and click on create and the new Volume will be created within few seconds.

Step 3: Attach the newly created volume to the Instance.

Step 4: Check if the volume is attached or not by going to EC2 dashboard and clicking on that particular instance. You can also check by going to Volume stats as well.

Step 5: Login to machine by your key or password.

Step 6: Format Volume to ext4 and then mount it and make fstab entry as well.