Google Associate Cloud Engineer Question 272
Single answerGoogle Cloud PlatformYour company runs a web application on a Compute Engine instance in Google Cloud. The application requires a stable IP address for DNS records and firewall rules. You need to ensure that the IP address of the instance remains constant even after a reboot or maintenance. What steps should you take to achieve this in Google Cloud Platform?
- A
Assign a static external IP address to the instance.
- B
Assign a static internal IP address to the instance.
- C
Use a dynamic IP address and update DNS records after every reboot.
- D
Reserve a static external IP address in the VPC network settings.
Show answer and explanation
Correct answer: A
Explanation
To ensure the web application has a consistent external IP address, you need to assign a static external IP directly to the instance. This allows the IP to remain unchanged across instance reboots and maintenance events, which is crucial for applications relying on DNS stability and firewall rules.
- A. Correct.
Assigning a static external IP address ensures the IP remains the same across reboots and maintenance, making it suitable for DNS and firewall configurations.
- B. Incorrect.
A static internal IP is useful within a VPC but does not help with external DNS records.
- C. Incorrect.
Using a dynamic IP would require constant updates to DNS records, which is not ideal for stable services.
- D. Incorrect.
You must assign the static external IP directly to the instance, not just reserve it in the VPC settings.