Google Associate Cloud Engineer Practice Test 18

Question 170

A support engineer needs to connect to a Linux VM through OS Login but must not receive sudo privilege. What should the administrator do?

  1. Grant the Compute OS Login role without OS Admin Login
  2. Enable OS Login and assign appropriate OS Login IAM roles
  3. Manage the engineer's OS Login identity and IAM permissions instead
  4. Grant the appropriate OS Admin Login role and other required access

Explanation

Correct Answer

A:

The OS Login role supports login without administrative sudo access. The OS Admin Login role provides additional elevated capability.

Incorrect Answers

B:

It can use IAM-based SSH authorization; however, it does not provide the specific operation to provide Linux login without sudo. The two controls serve different purposes.

C:

This mechanism is intended to troubleshoot metadata keys ignored under OS Login. It does not implement the required action to provide Linux login without sudo, even though both are relevant to the same general service.

D:

The tool can authorize OS Login with sudo access, but it cannot be substituted for the capability needed to provide Linux login without sudo. Its operational effect is not equivalent.

Question 171

A system administrator must use sudo on a Linux VM configured for OS Login. Which choice provides the required behavior?

  1. Grant the appropriate OS Admin Login role and other required access
  2. Manage the engineer's OS Login identity and IAM permissions instead
  3. Enable OS Login and assign appropriate OS Login IAM roles
  4. Create a VM Manager patch deployment
  5. Grant the Compute OS Login role without OS Admin Login

Explanation

Correct Answer

A:

OS Admin Login gives administrative OS Login capability on supported instances. Network reachability and any IAP or service-account requirements remain separate.

Incorrect Answers

B:

Using this action would troubleshoot metadata keys ignored under OS Login, not allow privileged VM guest administration. Its function is different from the specific change described in the scenario.

C:

This setting would use IAM-based SSH authorization. That behavior does not establish the requested ability to allow privileged VM guest administration; it addresses an adjacent concern instead.

D:

The technical effect is to schedule OS patch installation, not to allow privileged VM guest administration; That distinction matters here because the first operation serves automate patching for an enrolled VM fleet, rather than the scenario's required result.

E:

Its purpose is to authorize nonadministrative OS Login access. That distinction matters: the scenario calls for an action to allow privileged VM guest administration, not this separate configuration task.

Question 172

A VM has OS Login enabled but an engineer keeps adding SSH keys to project metadata. Which approach should be selected?

  1. Grant the Compute OS Login role without OS Admin Login
  2. Enable OS Login and assign appropriate OS Login IAM roles
  3. Manage the engineer's OS Login identity and IAM permissions instead
  4. Grant the appropriate OS Admin Login role and other required access
  5. Evaluate VM Manager OS policy assignments for the targeted VMs

Explanation

Correct Answer

C:

With OS Login enabled, guest access is not authorized through the ordinary project and instance metadata SSH-key mechanism. The remedy is to check OS Login roles and identity setup.

Incorrect Answers

A:

This mechanism is intended to authorize nonadministrative OS Login access. It does not implement the required action to fix SSH access controlled by OS Login, even though both are relevant to the same general service.

B:

Administrators use it to use IAM-based SSH authorization, rather than to fix SSH access controlled by OS Login. Applying it would change the wrong component of this deployment.

D:

The result of this choice would be to authorize OS Login with sudo access. The requested outcome, to fix SSH access controlled by OS Login, is handled at a different layer or through another operation.

E:

Choosing this would apply guest operating system policies, an appropriate action for vm manager and guest administration operations; It cannot take the place of the separate step needed to fix SSH access controlled by OS Login in this specific situation.

Question 173

A fleet operator needs supported guest OS inventory and patch management for Compute Engine instances. What is the most direct solution?

  1. Evaluate VM Manager OS policy assignments for the targeted VMs
  2. Use VM Manager on supported instances
  3. Enable VM Manager OS inventory collection
  4. Create a VM Manager patch deployment

Explanation

Correct Answer

B:

VM Manager offers guest policies, inventory and patch management capabilities. It complements VM platform controls with OS-level fleet operations.

Incorrect Answers

A:

Using this action would apply guest operating system policies, not coordinate operating-system updates across VMs. Its function is different from the specific change described in the scenario.

C:

This choice is useful to collect guest package inventory. The stated task is to coordinate operating-system updates across VMs, which requires a different mechanism or permission scope.

D:

This setting would schedule OS patch installation. That behavior does not establish the requested ability to coordinate operating-system updates across VMs; it addresses an adjacent concern instead.

Question 174

Security needs to know which packages are installed on enrolled Compute Engine Linux instances. Which implementation matches this requirement?

  1. Evaluate VM Manager OS policy assignments for the targeted VMs
  2. Enable VM Manager OS inventory collection
  3. Enable OS Login and assign appropriate OS Login IAM roles
  4. Use VM Manager on supported instances
  5. Create a VM Manager patch deployment

Explanation

Correct Answer

B:

OS inventory reports supported guest software information. Instance listing alone identifies machines but not all installed packages.

Incorrect Answers

A:

Administrators use it to apply guest operating system policies, rather than to inspect installed software on VMs. Applying it would change the wrong component of this deployment.

C:

The technical effect is to use IAM-based SSH authorization, not to inspect installed software on VMs; That distinction matters here because the first operation serves centralize Linux VM SSH access, rather than the scenario's required result.

D:

While this can manage VM guest patching and inventory, the present task requires an action to inspect installed software on VMs. This operation does not supply the behavior described in the requirements.

E:

The result of this choice would be to schedule OS patch installation. The requested outcome, to inspect installed software on VMs, is handled at a different layer or through another operation.

Question 175

A fleet of eligible VMs must apply approved OS patches on a defined schedule. What should the administrator do?

  1. Enable VM Manager OS inventory collection
  2. Create a VM Manager patch deployment
  3. Evaluate VM Manager OS policy assignments for the targeted VMs
  4. Grant the Compute OS Login role without OS Admin Login
  5. Use VM Manager on supported instances

Explanation

Correct Answer

B:

Patch deployments select instances and coordinate OS patching according to configured settings. A disk snapshot preserves data but does not install updates.

Incorrect Answers

A:

The tool can collect guest package inventory, but it cannot be substituted for the capability needed to automate patching for an enrolled VM fleet. Its operational effect is not equivalent.

C:

This choice is useful to apply guest operating system policies. The stated task is to automate patching for an enrolled VM fleet, which requires a different mechanism or permission scope.

D:

Choosing this would authorize nonadministrative OS Login access, an appropriate action for os login configuration operations; It cannot take the place of the separate step needed to automate patching for an enrolled VM fleet in this specific situation.

E:

It can manage VM guest patching and inventory; however, it does not provide the specific operation to automate patching for an enrolled VM fleet. The two controls serve different purposes.

Question 176

An engineer wants to enforce supported guest configuration consistently across many instances. Which choice provides the required behavior?

  1. Provide a startup script or supported instance initialization mechanism
  2. Evaluate VM Manager OS policy assignments for the targeted VMs
  3. Create a VM Manager patch deployment
  4. Use VM Manager on supported instances
  5. Enable VM Manager OS inventory collection

Explanation

Correct Answer

B:

OS policies define desired guest configurations on supported instances. They target OS state rather than resource hierarchy access rules.

Incorrect Answers

A:

This proposal can run initialization commands during VM boot, but the failure or goal described here calls for a way to maintain consistent guest settings; It changes the wrong control or scope for the requested outcome.

C:

This approach can schedule OS patch installation. The requirement is to maintain consistent guest settings, so it controls a different part of the workflow and leaves that result unaddressed.

D:

While this can manage VM guest patching and inventory, the present task requires an action to maintain consistent guest settings. This operation does not supply the behavior described in the requirements.

E:

This setting would collect guest package inventory. That behavior does not establish the requested ability to maintain consistent guest settings; it addresses an adjacent concern instead.

Question 177

A developer has kubectl installed but needs credentials and an endpoint for a particular GKE cluster. How should the team proceed?

  1. Use kubectl describe pod and inspect scheduling events
  2. Inspect kubectl config current-context and relevant context settings
  3. Run gcloud container clusters get-credentials for that cluster
  4. Deploy Compute Engine virtual machines
  5. Run kubectl apply -f against the manifest

Explanation

Correct Answer

C:

The command updates kubeconfig to use the chosen cluster context and authentication plugin. It does not itself create Kubernetes resources.

Incorrect Answers

A:

Select this when the goal is to inspect Pod scheduling events. Here the decisive requirement is to connect kubectl to a GKE cluster, and that outcome is not achieved by this action.

B:

This mechanism is intended to inspect the active kubectl context. It does not implement the required action to connect kubectl to a GKE cluster, even though both are relevant to the same general service.

D:

The tool can run and administer virtual machine operating systems, but it cannot be substituted for the capability needed to connect kubectl to a GKE cluster. Its operational effect is not equivalent.

E:

It can apply a Kubernetes declarative manifest; however, it does not provide the specific operation to connect kubectl to a GKE cluster. The two controls serve different purposes.

Question 178

An operator must verify the currently selected kubectl cluster and namespace before making changes. What is the most direct solution?

  1. Run kubectl apply -f against the manifest
  2. Inspect kubectl config current-context and relevant context settings
  3. Use kubectl describe pod and inspect scheduling events
  4. Run gcloud container clusters get-credentials for that cluster

Explanation

Correct Answer

B:

kubectl commands act against the selected context unless overridden. Checking it reduces the chance of modifying the wrong cluster.

Incorrect Answers

A:

This setting would apply a Kubernetes declarative manifest. That behavior does not establish the requested ability to confirm Kubernetes target before applying manifests; it addresses an adjacent concern instead.

C:

This approach can inspect Pod scheduling events. The requirement is to confirm Kubernetes target before applying manifests, so it controls a different part of the workflow and leaves that result unaddressed.

D:

Using this action would populate kubeconfig with GKE cluster access, not confirm Kubernetes target before applying manifests. Its function is different from the specific change described in the scenario.

Question 179

A new deployment is described in YAML and must be created or updated in the selected Kubernetes namespace. Which implementation matches this requirement?

  1. Use kubectl describe pod and inspect scheduling events
  2. Run kubectl apply -f against the manifest
  3. Run gcloud container clusters get-credentials for that cluster
  4. Create a GKE Autopilot cluster
  5. Inspect kubectl config current-context and relevant context settings

Explanation

Correct Answer

B:

kubectl apply reconciles the declared Kubernetes resource specification. The active context and namespace determine where the API request goes.

Incorrect Answers

A:

This mechanism is intended to inspect Pod scheduling events. It does not implement the required action to deploy Kubernetes resources from YAML, even though both are relevant to the same general service.

C:

Administrators use it to populate kubeconfig with GKE cluster access, rather than to deploy Kubernetes resources from YAML. Applying it would change the wrong component of this deployment.

D:

This proposal can use managed GKE workload infrastructure, but the failure or goal described here calls for a way to deploy Kubernetes resources from YAML; It changes the wrong control or scope for the requested outcome.

E:

While this can inspect the active kubectl context, the present task requires an action to deploy Kubernetes resources from YAML. This operation does not supply the behavior described in the requirements.

Question 180

An engineer wants to see why a newly created Kubernetes Pod remains Pending. What should the administrator do?

  1. Run kubectl apply -f against the manifest
  2. Create a GKE Standard cluster
  3. Run gcloud container clusters get-credentials for that cluster
  4. Use kubectl describe pod and inspect scheduling events
  5. Inspect kubectl config current-context and relevant context settings

Explanation

Correct Answer

D:

Pod descriptions include status conditions and events such as insufficient resources or unsatisfied node constraints. A service URL alone does not reveal scheduler decisions.

Incorrect Answers

A:

The tool can apply a Kubernetes declarative manifest, but it cannot be substituted for the capability needed to diagnose a Pending Pod. Its operational effect is not equivalent.

B:

An operator would use this action to configure Kubernetes node infrastructure directly, chiefly when trying to choose detailed cluster node control; The current requirement is to diagnose a Pending Pod, which remains unresolved by that operation.

C:

It can populate kubeconfig with GKE cluster access; however, it does not provide the specific operation to diagnose a Pending Pod. The two controls serve different purposes.

E:

This choice is useful to inspect the active kubectl context. The stated task is to diagnose a Pending Pod, which requires a different mechanism or permission scope.

Associate Cloud Engineer Practice Tests