35 votes

Does the "bs" option in "dd" really improve the speed?

What you have done is only a read speed test. if you are actually copying blocks to another device you have pauses in the reading while the other device is accepting the data you want to write, when ...
user avatar
22 votes
Accepted

free up not used space on a qcow2-image-file on kvm/qemu

virt-sparsify can do all this with less hassle on your part: http://libguestfs.org/virt-sparsify.1.html
user avatar
20 votes
Accepted

Which is better image format, raw or qcow2, to use as a baseimage for other VMs?

For your specific use case (base image + qcow2 overlay), the RAW format should be preferred: It's faster: as it has no metadata associated, it is as fast as possible. On the other hand, Qcow2 has two ...
user avatar
  • 43.6k
11 votes

Does the "bs" option in "dd" really improve the speed?

With regards to the internal hard disk, at least -- when you are reading from the device the block layer at least has to retrieve one sector which is 512 bytes. So, when handling a 1 byte read you've ...
user avatar
  • 22.9k
9 votes

How can I copy a VHD image back to a physical disc?

You can use qemu-nbd in Linux to access a disk image as if it were a block device. Here are some examples of operations that can be performed from a live Knoppix terminal. su modprobe nbd ...
user avatar
8 votes

Which is better image format, raw or qcow2, to use as a baseimage for other VMs?

Please be advised....if you are using linux you can use raw and get the same benifits of qcow2 as far as size goes. ...If your file system supports holes (for example in ext2 or ext3 on Linux or ...
user avatar
  • 220
7 votes

Using DD for disk cloning

dd if=/dev/sda of=/dev/sdb bs=4096 conv=sync,noerror This will copy the disk, and skip blocks with errors, which is very important. These are the basic and essential options for using dd to clone or ...
user avatar
7 votes

free up not used space on a qcow2-image-file on kvm/qemu

You can use virt-sparsify for this. It automatically zeros and sparsifies free space on most filesystems it finds within the source disk image (supports ext2/3/4, btrfs, NTFS, etc) . Step-by-step ...
user avatar
  • 1,213
7 votes

OS X equivalents for Ubuntu's genisoimage and qemu-img

I had to this exact same thing for generating a local cloud init setup. mkisofs is a drop in replacement for genisoimage from what I can tell. mkisofs -output init.iso -volid cidata -joliet -rock {...
user avatar
7 votes

OS X equivalents for Ubuntu's genisoimage and qemu-img

$ hdiutil makehybrid -o init.iso -hfs -joliet -iso -default-volume-name cidata config/ Where config/ contains meta-data and user-data. To install qemu, simply run the following from the command-line:...
user avatar
7 votes

Advice on replicating Hyper-V server image

As mentioned, Failover Cluster would be the easiest way to do it. However, I would recommend you to build it with Active Directory available in your infrastructure. As for shared storage you can use ...
user avatar
  • 5,171
6 votes
Accepted

What is the recommended method to prepare Red Hat/CentOS 7 templates?

What we think of as the initial setup is actually in three parts. The first two are: Initial setup, which asks you to accept the license and create a user Firstboot, which asks you to configure kdump ...
user avatar
6 votes
Accepted

Converting Multiple VMware disk image to single disk image

It is certainly doable. Assume you have: vmdk-primary.vmdk vmdk-2.vmdk vmdk-3.vmdk Then do this: vmware-vdiskmanager.exe -r vmdk-primary.vmdk -t 0 combinedImage.vmdk The vmware-vdiskmanager.exe ...
user avatar
  • 1,023
6 votes

How to write a sparse Linux (EXT4) disk image without writing gigabytes of zeros?

dd can handle this. You need to add conv=sparse to the command line. From the man page: try to seek rather than write the output for NUL input blocks
user avatar
6 votes

RAID 1, vs RAID 6 vs RAID 10. What is most secure and reliable for my needs?

The Short Answer is: it depends The Longer Answer is regarding: Would a NAS used for storing backup files be a good idea or an overkill? In Fact, it is a commonly used practice to do so for short-...
user avatar
  • 1,311
5 votes

Prepare a disk to be imaged by Clonezilla for use on smaller disks?

In creating your Master Image, resize the partitions or "total non Free space area" to be smaller than your smallest target drive will be. Use the expert mode instead of beginner in Clonezilla. If ...
user avatar
  • 51
5 votes

free up not used space on a qcow2-image-file on kvm/qemu

In addition to the accepted answer (which describe the more common, general method to shrink a qcow2 file), modern version (ie: RHEL7+) of the libvirt/qemu/qcow2 stack supports the virtio-scsi driver ...
user avatar
  • 43.6k
5 votes
Accepted

Is there a way to relate the mac address of a machine to it's hostname when deploying images over a network?

dhcp protocol can send hostname. It can be set with request host-name option in gnu/linux. https://www.rfc-editor.org/rfc/rfc1533#section-3.14
user avatar
  • 1,230
4 votes
Accepted

Can I run Windows Deployment Services from start to finish without using the network?

If you're interested in capturing an image automatically from your computer(s) to physical media (E.G. CD, DVD, BD, USB, etc...) you can use a tool that Microsoft created called: Microsoft Deployment ...
user avatar
4 votes

Setting up 20 computers with WIN7

What you want is a deployment, not an image. Deployments are the OS plus any apps required for the users. You can deploy windows using the similarly named Microsoft deployment toolkit. Search in your ...
user avatar
  • 23.9k
4 votes
Accepted

ZFS: very big files + compression + snapshots

You should be using ZFS compression (with compression=lz4) by default these days. There's no good reason not to use it, except if you know that your data is not compressible. Snapshots on compressed ...
user avatar
  • 195k
4 votes

KVM direct disk access vs raw files

Is there any impact on performance from a kvm guest if I create ext4 on this large drive directly, mount it up on the host like /mnt/kvms and then create raw kvm disk image on it? Every time, when ...
user avatar
4 votes
Accepted

Create a windows 10 image for use as a docker container

No, this won't work. Windows Containers (this is the same as Docker containers on Linux) basically contain the "user-space" part of windows, but share the single underlying windows server kernel. I ...
user avatar
3 votes

Using DD for disk cloning

The most info was described in previous inserted recipies, but not all was described. Under linux you can clone hard drive or partition by dd command. Attention, when you'll make a mistake, you will ...
user avatar
  • 338
3 votes

How can I copy a VHD image back to a physical disc?

Use HDDGuru Raw Copy Tool Mount the VHD(X) using explorer on Windows 8/10 Plug in the target disk Use the Raw Copy tool to copy the mounted disk to target physical disk This can be used for any of ...
user avatar
  • 274
3 votes

How to shrink size of raw virtual machine disk image (kvm)?

Raw images are not really resize-friendly. You can however try zerofree on (unmounted) filesystem and then compress the resulting image file. Also, check if your target environment supports OVF ...
user avatar
3 votes
Accepted

Is a QEMU installation on a raw disk backward compatible?

Being RAW, the file contain a plain bit-level representation of the data inside it. In other words, RAW disks are always "compatible", because they contain no special structure/headers. What really ...
user avatar
  • 43.6k
3 votes
Accepted

Windows 10 installation on Dell T7600 with PERC H310 Raid Controller

Edit: a new version of Windows 10 Pro for Workstations could maybe help you out this fall too if you can wait. Windows 10 Pro for Workstations is a high-end edition of Windows 10 Pro, comes with ...
user avatar
  • 16.2k
3 votes
Accepted

KVM image format convertion: raw thin provisioning to raw preallocated

To fully preallocate a RAW image, rather than copying/converting the whole image with qemu-img, you can simply issue fallocate <image_file> -l <size_to_preallocate> In your case, you can ...
user avatar
  • 43.6k
3 votes
Accepted

How do I generate a bootable .iso file from a directory?

You need mkisofs to generate the new iso and specify boot information. The args of mkisofs and structure of the directories will vary from one distribution to another, so the best is to look for ...
user avatar
  • 1,017

Only top scored, non community-wiki answers of a minimum length are eligible