I have an imaged (clonezilla) system image of a Ubuntu setup with a bunch of settings. Now I am wondering, what needs to be changed if I use the clonezilla image to create always new systems from this image.

The things, which I can immediately name are: - host ssh key need to changed - hostname

what commands should I use (preferable also working on centOS) to modify the upper points?

What other things do I have forgot to fix/change?

Under windows I know the sysprep tool..

  • Does Ubuntu not have sys-unconfig? Mar 31, 2018 at 15:22
  • @IgnacioVazquez-Abrams did not find it here: packages.ubuntu.com What OS provides it?
    – cilap
    Mar 31, 2018 at 16:09
  • Solaris and Linux, among others. It's a very old convention. No idea why Ubuntu would have chosen not to include it. Mar 31, 2018 at 16:52

2 Answers 2


Look at http://manpages.ubuntu.com/manpages/precise/man1/virt-sysprep.1.html . It`s a bash script to reset/unconfigure a vm so clones can be made.

  • Welcome to ServerFault. Please try to include a few more information on the actual tool (here virt-sysprep), because the links may not always available after a few years / decades later. Apr 1, 2018 at 3:27

If you intend to deploy the image in the same network you should check if you have a static ip address on /etc/network/interfaces and change, if necessary, the configuration for a another ip address in the new system cloned to avoid conflicts whith the other hosts.

(Copy and paste an example): sudo vi /etc/network/interfaces

To configure a dynamic IP address

auto eth0 iface eth0 inet dhcp

Or configure a static IP

auto eth0 iface eth0 inet static address gateway netmask network broadcast

For these settings to take effect you need to restart your networking services.

sudo /etc/init.d/networking restart

enter link description here

If you intend to change the name of the User for a NewUser you should take in consideration this link: change username


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.