Монтирование kvm-файла (disk.img)
# kpartx -av /xens/vm03/disk-vm03.img
add map loop1p1 (253:2): 0 9687132 linear /dev/loop1 63
add map loop1p2 (253:3): 0 546210 linear /dev/loop1 9687195
add map loop1p5 : 0 546147 linear 253:3 63
# mount /dev/mapper/loop1p1 /mnt
# ls /mnt
bin boot cdrom dev etc home initrd.img lib
lost+found media mnt opt proc root sbin selinux srv sys
tmp usr var vmlinuz
# umount /mnt
# kpartx -dv /xens/vm03/disk-vm03.img
del devmap : loop1p5
del devmap : loop1p2
del devmap : loop1p1
loop deleted : /dev/loop1
Теги: .img, kpartx, KVM, mount