
Answer-first summary for fast verification
Answer: In the Google Cloud Console, increase the size of the persistent disk, and use the resize2fs command to extend the disk.
To avoid downtime while increasing the storage space for a critical production database running on a VM with an ext4-formatted persistent disk, the correct approach is to increase the size of the persistent disk via the Google Cloud Console and then use the resize2fs command to extend the filesystem to utilize the additional space. This method does not require restarting the database service or moving files to a new disk, thus minimizing potential disruptions. Option A is correct because it directly addresses the need for more space without downtime. Option B is incorrect because while increasing the disk size is a step in the right direction, using fdisk to verify the new space is not sufficient to make the additional space available to the filesystem. Option C involves unnecessary steps like creating a snapshot and restarting the database service, which could lead to downtime. Option D suggests adding a new disk and moving files, which is more complex and could also lead to downtime or require significant database reconfiguration.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
How can you expand the storage capacity of an ext4-formatted persistent disk attached to a Compute Engine VM hosting a critical production database without causing downtime?
A
In the Google Cloud Console, increase the size of the persistent disk, and use the resize2fs command to extend the disk.
B
In the Google Cloud Console, increase the size of the persistent disk, and use the fdisk command to verify that the new space is ready to use
C
In the Google Cloud Console, create a snapshot of the persistent disk, restore the snapshot to a new larger disk, unmount the old disk, mount the new disk, and restart the database service.
D
In the Google Cloud Console, create a new persistent disk attached to the VM, and configure the database service to move the files to the new disk.
No comments yet.