我正在尝试导入虚拟设备。结果失败。我可能犯了什么错误?

我正在尝试导入虚拟设备。结果失败。我可能犯了什么错误?

我将一个 ova 文件上传到我的存储桶。我打开 Cloud Shell 在线终端。我成功设置了区域和区域。然后我运行以下命令开始导入。

gcloud compute instances import adv-odi --source-uri=gs://memoconq/Win2012_64bit_DB_12c_ODI_12cVM.ova

终端输出如下。

starting build "fa0e53a4-c211-4210-b35d-999c1499f65e"
[import-ovf] 2020-05-12T01:45:49Z Starting OVF import workflow.
[import-ovf] 2020-05-12T01:45:49Z Creating scratch bucket `advanced-odi-training-ovf-import-bkt-us-east1` in us-east1 region
[import-ovf] 2020-05-12T01:45:50Z Extracting gs://memoconq/Win2012_64bit_DB_12c_ODI_12cVM.ova OVA archive to gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf
[import-ovf] 2020-05-12T01:45:50Z Extracting: Win2012_64bit_DB_12c_ODI_12cVM.ovf to gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM.ovf
[import-ovf] 2020-05-12T01:45:50Z Extracting: Win2012_64bit_DB_12c_ODI_12cVM-disk001.vmdk to gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM-disk001.vmdk
[import-ovf] 2020-05-12T01:53:30Z Extracting: Win2012_64bit_DB_12c_ODI_12cVM.mf to gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM.mf
[import-ovf] 2020-05-12T01:53:30Z Found gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM.ovf
[import-ovf] 2020-05-12T01:53:31Z Found gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM-disk001.vmdk
[import-ovf] 2020-05-12T01:53:31Z Cleaning up.
[import-ovf] 2020/05/12 01:53:31 Deleting content of: gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/
[import-ovf] 2020-05-12T01:53:31Z Deleting gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM-disk001.vmdk
[import-ovf] 2020-05-12T01:53:31Z Deleting gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM.mf
[import-ovf] 2020-05-12T01:53:31Z Deleting gs://advanced-odi-training-ovf-import-bkt-us-east1/ovf-import-4xzzt/ovf/Win2012_64bit_DB_12c_ODI_12cVM.ovf
ERROR
ERROR: build step 0 "gcr.io/compute-image-tools/gce_ovf_import:release" failed: step exited with non-zero status: 2
ERROR: (gcloud.compute.instances.import) build fa0e53a4-c211-4210-b35d-999c1499f65e completed with status "FAILURE"

日志中添加了以下几行。

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x12b4f56]

goroutine 1 [running]:
github.com/GoogleCloudPlatform/compute-image-tools/cli_tools/gce_ovf_import/ovf_utils.GetOSId(0xc000130230, 0xc00017aa60, 0xc000708050, 0x48, 0xc000130230)
    /workspace/cli_tools/gce_ovf_import/ovf_utils/ovf_utils.go:261 +0xe6
github.com/GoogleCloudPlatform/compute-image-tools/cli_tools/gce_ovf_import/ovf_importer.(*OVFImporter).setUpImportWorkflow(0xc0001d6000, 0x193fc1e, 0x1d, 0x5)
    /workspace/cli_tools/gce_ovf_import/ovf_importer/ovf_importer.go:431 +0x395
github.com/GoogleCloudPlatform/compute-image-tools/cli_tools/gce_ovf_import/ovf_importer.(*OVFImporter).Import(0xc0001d6000, 0xc0001d6000, 0x0, 0x0)
    /workspace/cli_tools/gce_ovf_import/ovf_importer/ovf_importer.go:474 +0x6f
main.runImport(0x0, 0x0, 0x0)
    /workspace/cli_tools/gce_ovf_import/main.go:115 +0xbf
github.com/GoogleCloudPlatform/compute-image-tools/cli_tools/common/utils/logging/service.(*Logger).runWithServerLogging(0xc0000e6f50, 0x197b1f8, 0xc000549240, 0x0, 0xc00011a900, 0x0)
    /workspace/cli_tools/common/utils/logging/service/logger.go:220 +0xa0
github.com/GoogleCloudPlatform/compute-image-tools/cli_tools/common/utils/logging/service.RunWithServerLogging(0x191e66b, 0xe, 0x0, 0x0, 0xc00011a900, 0x0, 0xc000549240, 0x197b1f8, 0x1, 0xc000076058)
    /workspace/cli_tools/common/utils/logging/service/logger.go:257 +0x86
main.main()
    /workspace/cli_tools/gce_ovf_import/main.go:133 +0xe4
ERROR
ERROR: build step 0 "gcr.io/compute-image-tools/gce_ovf_import:release" failed: step exited with non-zero status: 2

有办法解决这个错误吗?或者有其他方法可以导入 ova 文件吗?

答案1

我看到你正在使用 Windows Server 2012(仔细检查支持的Windows 版本)。您可以尝试指定命令中的 -os 参数。此外,检查是否满足要求以便导入它。您可以运行预检工具

相关内容