I want to create a template from CentOS 6 so that each VM feels like a unique install. I found sys-unconfig which works but I don't like that it asks for a new password on boot. What alternatives are there?
Asked
Active
Viewed 877 times
0
masterq
- 151
- 1
- 1
- 10
-
That doesn't work on centos6 – masterq May 24 '18 at 20:34
-
1“Doesn’t work” ... in what way? – Jeff Schaller May 24 '18 at 22:43
1 Answers
0
This depends on your image format and how you create the image in the first place however I generally use virt-sysprep to unconfigure images, details can be found here: "http://libguestfs.org/virt-sysprep.1.html" The command would look something like this:
# virt-sysprep --operations ssh-hostkeys,udev-persistent-net,machine-id -a disk.img
I would then look at using cloud-init to configure the new VMs on bootup, again this depends on your hypervisor technology on how this would need to be configured. http://cloudinit.readthedocs.io/en/latest/
Tim Brandrick
- 121
- 4