In GCP, you need to select the Boot disc with respect to the operating system version, If you are looking to update the machine with the latest package, you can use.
sudo yum update
sudo apt-get update
These commands will help you to update the system.
For more information, refer to the below Linux training