9.2. 日志和自定义资源
您可以下载日志和自定义资源(CR)信息以进行故障排除。如需更多信息,请参阅 详细的迁移工作流。
9.2.1. 收集日志和自定义资源信息
您可以使用 MTV web 控制台或命令行界面(CLI)为以下目标下载日志和自定义资源(CR) yaml 文件:
- 迁移计划:Web 控制台或 CLI。
- 虚拟机:Web 控制台或 CLI.
- namespace:仅限 CLI。
must-gather 工具会在存档文件中收集以下日志和 CR 文件:
CR:
-
DataVolumeCR:代表在迁移的虚拟机中挂载的磁盘。 -
VirtualMachineCR:代表一个迁移的虚拟机。 -
计划CR:定义 VM 和存储和网络映射。
-
日志:
-
Importerpod: Disk-to-data-volume 转换日志。importerpod 命名规则是importer-<migration_plan>-<vm_id><5_char_id>,例如importer-mig-plan-pig-plan-90dfc6-9a17-4a8btnfh,其中ed90dfc6-9a17-4a8是经过截断的 RHV VM ID,btnfh是 5 个字符生成的 ID。 -
转换pod:虚拟机转换日志.转换pod 运行virt-v2v,它会在虚拟机的 PVC 中安装和配置设备驱动程序。转换pod 命名约定是 <migration_plan>-<vm_id><5_char_id>。 -
virt-launcherpod:VM launcher 日志.当迁移的虚拟机被开启后,virt-launcherPod 运行QEMU-KVM,并附加了作为虚拟机磁盘的 PVC。 -
forklift-controllerpod:针对must-gather命令指定的迁移计划、虚拟机或命名空间过滤日志。 forklift-must-gather-apipod:日志针对must-gather命令指定的迁移计划、虚拟机或命名空间过滤。注意must-gather归档文件中不包含空的或排除的日志文件。
-
VMware 迁移计划的 must-gather 归档结构示例
must-gather
└── namespaces
├── target-vm-ns
│ ├── crs
│ │ ├── datavolume
│ │ │ ├── mig-plan-vm-7595-tkhdz.yaml
│ │ │ ├── mig-plan-vm-7595-5qvqp.yaml
│ │ │ └── mig-plan-vm-8325-xccfw.yaml
│ │ └── virtualmachine
│ │ ├── test-test-rhel8-2disks2nics.yaml
│ │ └── test-x2019.yaml
│ └── logs
│ ├── importer-mig-plan-vm-7595-tkhdz
│ │ └── current.log
│ ├── importer-mig-plan-vm-7595-5qvqp
│ │ └── current.log
│ ├── importer-mig-plan-vm-8325-xccfw
│ │ └── current.log
│ ├── mig-plan-vm-7595-4glzd
│ │ └── current.log
│ └── mig-plan-vm-8325-4zw49
│ └── current.log
└── openshift-mtv
├── crs
│ └── plan
│ └── mig-plan-cold.yaml
└── logs
├── forklift-controller-67656d574-w74md
│ └── current.log
└── forklift-must-gather-api-89fc7f4b6-hlwb6
└── current.log