首页 > 解决方案 > GCE VM 在启用 Shield VM 后关闭并且无法启动

问题描述

我们最近在一个节点上启用了 Shield VM。之后节点重新启动正常,但此后已关闭并且无法启动。我们在日志中看到任何启动顺序都因屏蔽 VM 而关闭:

{
 insertId: "3"  
 jsonPayload: {
  @type: "type.googleapis.com/cloud_integrity.IntegrityEvent"   
  bootCounter: "4"   
  shutdownEvent: {
  }
 }
 logName: "projects/project_name/logs/compute.googleapis.com%2Fshielded_vm_integrity"  
 receiveTimestamp: "2021-03-26T09:30:41.307564027Z"  
 resource: {
  labels: {…}   
  type: "gce_instance"   
 }
 severity: "NOTICE"  
 timestamp: "2021-03-26T09:30:39.300465584Z"  
}

但是,似乎没有违反完整性。我们已尝试禁用 Shield VM,但仍然遇到错误。关闭之前的事件是延迟启动事件:

insertId: "2"
jsonPayload: {
lateBootReportEvent: {
actualMeasurements: [4]
policyEvaluationPassed: true

有没有办法绕过嵌入在引导序列中的 Shield VM 检查以启动节点?

标签: google-compute-engine

解决方案


我建议通过 Cloud Shell 或 VM 的 Shielded VM 选项卡禁用应用于节点的所有 shielded-vm 标签,包括完整性监控,然后尝试再次启动节点。您可以使用以下命令:

gcloud beta compute instances update YOUR_NODE_NAME --no-shielded-integrity-monitoring --no-shielded-secure-boot] --no-shielded-vtpm 

您可以在此处找到有关命令和标签的更多信息。


推荐阅读