[File] qemu disk file format

Steve Grubb sgrubb at redhat.com
Mon Jan 17 18:23:44 UTC 2022


Hello,

I run across something that I'd like to report. On linux systems, libvirt is 
the main way of running virtualized operating systems. It uses the qemu copy 
on write file format (qcow2). If I point file at one of these images, I get 
this:

# file /var/lib/libvirt/images/rhel8.2-s390x.qcow2
/var/lib/libvirt/images/rhel8.2-s390x.qcow2: QEMU QCOW2 Image (v3), 
21474836480 bytes

Good. It understands what it's looking at. But checking the mime-type:

# file --mime-type /var/lib/libvirt/images/rhel8.2-s390x.qcow2
/var/lib/libvirt/images/rhel8.2-s390x.qcow2: application/octet-stream

It doesn't know what it's looking at. The text in magic/Magdir/virtual is 
kind of complicated or I would take a stab at patching this. The shared-mime-
info package seems to think it should be application/x-qemu-disk.

Best Regards,
-Steve




More information about the File mailing list