public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* How to edit *.qcow2
@ 2010-02-01  3:58 satimis
  2010-02-01  5:04 ` Terry
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: satimis @ 2010-02-01  3:58 UTC (permalink / raw)
  To: kvm

Hi folks,

KVM
host – Debian 5.0

I need to mount kvm/qemu *.qcow2 image amending/reading its content. I  
can't figure out the type of file "-t"

    1. mount -t mke2fs -o loop VM/vm30.qcow2 /mnt
    2. mount -t e2fs -o loop VM/vm30.qcow2 /mnt
    3. mount -o loop VM/vm30.qcow2 /mnt
    4. mount -t ext3 -o loop VM/vm30.qcow2 /mnt
    5. mount -t ext2 -o loop VM/vm30.qcow2 /mnt

None of them can work. Please help TIA  Pointer would be appreciated.


B.R.
Stephen L


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: How to edit *.qcow2
  2010-02-01  3:58 How to edit *.qcow2 satimis
@ 2010-02-01  5:04 ` Terry
  2010-02-03  4:05   ` satimis
  2010-02-03  6:11 ` Asias He
       [not found] ` <229432dd1001312031ud59ffb8s47fd50b615202d5c@mail.gmail.com>
  2 siblings, 1 reply; 6+ messages in thread
From: Terry @ 2010-02-01  5:04 UTC (permalink / raw)
  To: satimis; +Cc: kvm

you need nbd-client and qemu-nbd to access qcow2 file.

satimis@pacific.net.hk wrote:
> Hi folks,
> 
> KVM
> host – Debian 5.0
> 
> I need to mount kvm/qemu *.qcow2 image amending/reading its content. I
> can't figure out the type of file "-t"
> 
>    1. mount -t mke2fs -o loop VM/vm30.qcow2 /mnt
>    2. mount -t e2fs -o loop VM/vm30.qcow2 /mnt
>    3. mount -o loop VM/vm30.qcow2 /mnt
>    4. mount -t ext3 -o loop VM/vm30.qcow2 /mnt
>    5. mount -t ext2 -o loop VM/vm30.qcow2 /mnt
> 
> None of them can work. Please help TIA  Pointer would be appreciated.
> 
> 
> B.R.
> Stephen L
> 
> -- 
> To unsubscribe from this list: send the line "unsubscribe kvm" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: How to edit *.qcow2
  2010-02-01  5:04 ` Terry
@ 2010-02-03  4:05   ` satimis
  0 siblings, 0 replies; 6+ messages in thread
From: satimis @ 2010-02-03  4:05 UTC (permalink / raw)
  To: kvm

Quoting Terry <hanfang@staff.sina.com.cn>:

> you need nbd-client and qemu-nbd to access qcow2 file.


Hi Terry,


Thanks for your advice.

Are qemu-nbd and kvm-nbd the same?

I can't find kvm-nbd on Debian 5.0
$ which qemu-nbd
No printout

I found kvm-nbd
$ which kvm-nbd
/usr/bin/kvm-nbd

Which package provide kvm-ndb?  Linux-tools ?


B.R.
Stephen L


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: How to edit *.qcow2
  2010-02-01  3:58 How to edit *.qcow2 satimis
  2010-02-01  5:04 ` Terry
@ 2010-02-03  6:11 ` Asias He
       [not found] ` <229432dd1001312031ud59ffb8s47fd50b615202d5c@mail.gmail.com>
  2 siblings, 0 replies; 6+ messages in thread
From: Asias He @ 2010-02-03  6:11 UTC (permalink / raw)
  To: satimis; +Cc: kvm

you can try guestfish.

http://libguestfs.org/recipes.html

2010/2/1  <satimis@pacific.net.hk>:
> Hi folks,
>
> KVM
> host – Debian 5.0
>
> I need to mount kvm/qemu *.qcow2 image amending/reading its content. I can't
> figure out the type of file "-t"
>
>   1. mount -t mke2fs -o loop VM/vm30.qcow2 /mnt
>   2. mount -t e2fs -o loop VM/vm30.qcow2 /mnt
>   3. mount -o loop VM/vm30.qcow2 /mnt
>   4. mount -t ext3 -o loop VM/vm30.qcow2 /mnt
>   5. mount -t ext2 -o loop VM/vm30.qcow2 /mnt
>
> None of them can work. Please help TIA  Pointer would be appreciated.
>
>
> B.R.
> Stephen L
>
> --
> To unsubscribe from this list: send the line "unsubscribe kvm" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: How to edit *.qcow2
       [not found] ` <229432dd1001312031ud59ffb8s47fd50b615202d5c@mail.gmail.com>
@ 2010-02-05  6:54   ` satimis
  2010-02-06 16:33     ` Liang Guo
  0 siblings, 1 reply; 6+ messages in thread
From: satimis @ 2010-02-05  6:54 UTC (permalink / raw)
  To: Liang Guo; +Cc: kvm

Hi Liang,


Thanks for your advice and link.

Host - Debian 5.0
KVM
libvirt


> run  kvm-nbd  VM/vm30.qcow2, modprobe nbd
> nbd-client localhost 1024 /dev/nbd0

> then you can use /dev/nbd0 as a block device like /dev/sda

> I've write a little essay on how to install Debian on kvm image, FYI:

> http://blog.chinaunix.net/u/7667/showart_2112267.html


I can't find kvm-nbd and nbd-client.  I have nbd installed already.


$ yum list nbd
Loaded plugins: presto, refresh-packagekit
Available Packages
nbd.x86_64            2.9.13-1.fc12           fedora


$ which kvm-nbd
/usr/bin/which: no kvm-nbd in  
(/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/satimis/bin)


$ which qemu-nbd
/usr/bin/qemu-nbd


$ which nbd-client
/usr/bin/which: no nbd-client in  
(/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/satimis/bin)


I suppose qemu-nbd = kvm-nbd ?  Where is nbd-client ?

Any advice?  TIA


B.R.
Stephen



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: How to edit *.qcow2
  2010-02-05  6:54   ` satimis
@ 2010-02-06 16:33     ` Liang Guo
  0 siblings, 0 replies; 6+ messages in thread
From: Liang Guo @ 2010-02-06 16:33 UTC (permalink / raw)
  To: satimis; +Cc: kvm

在 星期五 05 二月 2010 14:54:57,satimis@pacific.net.hk 写道:
> Hi Liang,
> 
> 
> Thanks for your advice and link.
> 
> Host - Debian 5.0
> KVM
> libvirt
> 
> > run  kvm-nbd  VM/vm30.qcow2, modprobe nbd
> > nbd-client localhost 1024 /dev/nbd0
> >
> > then you can use /dev/nbd0 as a block device like /dev/sda
> >
> > I've write a little essay on how to install Debian on kvm image, FYI:
> >
> > http://blog.chinaunix.net/u/7667/showart_2112267.html
> 
> I can't find kvm-nbd and nbd-client.  I have nbd installed already.
> 
> 
> $ yum list nbd
> Loaded plugins: presto, refresh-packagekit
> Available Packages
> nbd.x86_64            2.9.13-1.fc12           fedora
> 
> 
> $ which kvm-nbd
> /usr/bin/which: no kvm-nbd in
> (/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:
> /usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/satimis/bin)
> 
> 
> $ which qemu-nbd
> /usr/bin/qemu-nbd
> 
> 
> $ which nbd-client
> /usr/bin/which: no nbd-client in
> (/usr/lib64/qt-3.3/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:
> /usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/satimis/bin)
> 
> 
> I suppose qemu-nbd = kvm-nbd ?  Where is nbd-client ?
In debian stable, kvm-nbd command is from pacakge kvm, please see 
http://packages.debian.org/lenny/amd64/kvm/filelist

If you are using Debian SID, you should use qemu-kvm instead of kvm. 

nbd-client command is from package nbd-client, please see:
http://packages.debian.org/lenny/amd64/nbd-client/filelist, It is in /sbin 
directory, so you should use root to run it.

qemu-nbd is from package qemu-utils, I have not use it, but I think it should 
do the same thing as kvm-nbd. 

I don't know fedora exactly, but I think fedora should have relevant package.

Best Wishes. 

-- 
Liang Guo
http://bluestone.cublog.cn

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-02-06 16:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-01  3:58 How to edit *.qcow2 satimis
2010-02-01  5:04 ` Terry
2010-02-03  4:05   ` satimis
2010-02-03  6:11 ` Asias He
     [not found] ` <229432dd1001312031ud59ffb8s47fd50b615202d5c@mail.gmail.com>
2010-02-05  6:54   ` satimis
2010-02-06 16:33     ` Liang Guo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox