| 用法 | virt-sysprep -d vm1(域)/ -a disk.qcow2(文件) |
|---|---|
| 查看步骤 | virt-sysprep --list-operations |
| 选择操作 | --operations machine-id,ssh-hostkeys,logfiles |
| 前提 | 目标域已关机,磁盘未被占用 |
查看并执行标准清理
查看并执行标准清理
virt-sysprep --list-operations | head -20
sudo virt-sysprep -a /data/images/base.qcow2
sudo virt-sysprep -d vm-template --operations machine-id,ssh-hostkeys,logfiles