Dear Valentine, Yes I can boot the VM in my local machine using qemu.
Right now I have installed win7 in my virtualbox & converted .vdi to .qcow2 format using qemu-utils after that shall try to import the qcow2 file at /var/lib/libvirt/images/ folder and try again. Sudeep On Thu, Jul 10, 2014 at 10:58 AM, Valentin Bud <valentin....@gmail.com> wrote: > Hello Sudeep, > > I have never used virt-install but I doubt it install the VirtIO drivers > [1] > by itself inside the Windows 7 image. > > Without those drivers the virtio doesn't work inside the machine, in the > sense > that Windows Installer doesn't see any HDD present. > > Can you boot the VM on your local machine using qemu? > > [1]: http://www.linux-kvm.org/page/WindowsGuestDrivers/Download_Drivers > > Best, > Valentin > > > On Wed, Jul 9, 2014 at 10:15 PM, Sudeep Narayan Banerjee < > snbaner...@iitgn.ac.in> wrote: > >> Hello Valentine, >> >> I followed the steps in and could install Win7 using virt-install >> command. Win7 OS gets installed in 7GB HDD and I could see Win7 desktop >> using virt-manager. >> >> Then I power-off the machine and create the image, template & VM >> successfully from oneadmin prompt. >> >> But, from vncviewer in OpenNebula GUI, it says, "Booting from Hard-Disk". >> Inside the VM, I am not able to see the desktop! >> >> ------------------------------------------------------------------------- >> >> Following steps I did: >> >> 1. [oneadmin@front ~]$ cd /var/lib/libvirt/images/ >> >> [oneadmin@front images]$ qemu-img create -f qcow2 -o >> preallocation=metadata /storage/local/images/win7.qcow2 8G >> >> >> Formatting '/var/lib/libvirt/images/win7.qow2', fmt=qcow2 size=8589934592 >> encryption=off cluster_size=65536 preallocation='metadata' >> >> >> [oneadmin@front images]$ qemu-img info win7.qcow2 >> >> image: win7.qcow2 >> >> file format: raw >> virtual size: 8.0G (8589934592 bytes) >> disk size: 392K >> cluster_size: 65536 >> >> [oneadmin@front images]$ qemu-img convert -f raw -O qcow2 win7.qcow2 >> win7.qcow2 >> >> [oneadmin@front images]$ qemu-img info win7.qcow2 >> >> image: win7.qcow2 >> file format: qcow2 >> >> virtual size: 8.0G (8589934592 bytes) >> disk size: 392K >> cluster_size: 65536 >> >> [oneadmin@front images]$ chown qemu.qemu win7.qcow2 >> >> [oneadmin@front images]$ virt-install --connect qemu:///system --name >> win7 --ram 1024 --vcpus 2 --disk >> path=/var/lib/libvirt/images/win7.qcow2,size=8,format=qcow2,bus=virtio,cache=none >> --cdrom /home/Windows-7-x86.iso --vnc --os-type=windows --os-variant=win7 >> -noautoconsole --accelerate --noapic --keymap=en-us >> >> >> Finally, >> >> >> [oneadmin@front ~]$ onevm list >> ID USER GROUP NAME STAT UCPU UMEM >> HOST TIME >> 25 oneadmin oneadmin myvm1 runn 0 512M nc1 >> 11d 16h14 >> >> >> Regards, >> Sudeep >> >> >> On Tue, Jul 8, 2014 at 9:13 PM, Valentin Bud <valentin....@gmail.com> >> wrote: >> >>> Hello Sudeep, >>> >>> Note that virt-install doesn't care that your image is already created, >>> it >>> overwrites it and changes the format to raw. >>> >>> Take a look over this article [1], on how to pass the format of the >>> image to virt-install. >>> >>> Or just qemu-img convert your raw image to qcow2. >>> >>> [1]: >>> http://opennodecloud.com/documentation/howtos/kvm-guests-virt-install-examples/ >>> >>> Best, >>> Valentin >>> >>> >>> On Tue, Jul 8, 2014 at 6:24 PM, Sudeep Narayan Banerjee < >>> snbaner...@iitgn.ac.in> wrote: >>> >>>> Dear Javier, >>>> >>>> You are true. It is raw indeed. But I made it like qcow2! Below is the >>>> command I executed for qcow2. >>>> >>>> >>>> [oneadmin@front images]$ qemu-img create -f qcow2 -o >>>> preallocation=metadata /storage/local/images/ >>>> winserv1.qcow2 8G >>>> Formatting '/var/lib/libvirt/images/win7.qow2', fmt=qcow2 >>>> size=8589934592 encryption=off cluster_size=65536 preallocation='metadata' >>>> >>>> [oneadmin@front images]$ qemu-img info >>>> /var/lib/libvirt/images/win7.qcow2 >>>> image: /var/lib/libvirt/images/win7.qcow2 >>>> file format: raw >>>> virtual size: 8.0G (8589934592 bytes) >>>> disk size: 4.9G >>>> >>>> So, how to fix it?!? I have been trying to make a VM in windows for >>>> past 10days but still not able to make it! :-( >>>> >>>> Regards, >>>> Sudeep >>>> >>>> >>>> On Tue, Jul 8, 2014 at 8:45 PM, Javier Fontan <jfon...@opennebula.org> >>>> wrote: >>>> >>>>> I believe that the image is not a qcow2 image but raw. You can check >>>>> the format with: >>>>> >>>>> $ qemu-img info /var/lib/libvirt/images/win7.qcow2 >>>>> >>>>> On Tue, Jul 8, 2014 at 4:16 PM, Sudeep Narayan Banerjee >>>>> <snbaner...@iitgn.ac.in> wrote: >>>>> > Dear Sir, >>>>> > >>>>> > I have been trying to install Windows-7 64bit in OpenNebula. Our >>>>> target is >>>>> > to create a VM with Windows as OS. >>>>> > >>>>> > Below are the steps that I followed. But not able to "runn" the VM. >>>>> SeLinux >>>>> > is Disabled in both servers. >>>>> > >>>>> > [root@front ~]# getenforce --> Frontend >>>>> > Disabled >>>>> > >>>>> > [root@nc1 ~]# getenforce --> Worker Node >>>>> > Disabled >>>>> > >>>>> > [oneadmin@front ~]$ cd /var/lib/libvirt/images/ >>>>> > >>>>> > [oneadmin@front images]$ qemu-img create -f qcow2 -o >>>>> preallocation=metadata >>>>> > /storage/local/images/winserv1.qcow2 8G >>>>> > Formatting '/var/lib/libvirt/images/win7.qow2', fmt=qcow2 >>>>> size=8589934592 >>>>> > encryption=off cluster_size=65536 preallocation='metadata' >>>>> > >>>>> > [oneadmin@front images]$ ls -lrth >>>>> > total 5.0G >>>>> > -rw------- 1 oneadmin oneadmin 8.0G Jul 8 18:23 win7.qcow2 >>>>> > [oneadmin@front images]$ exit >>>>> > >>>>> > [root@front ~]# virt-install --prompt >>>>> > What is the name of your virtual machine? >>>>> > myvm7 >>>>> > How much RAM should be allocated (in megabytes)? >>>>> > 1024 >>>>> > What would you like to use as the disk (file path)? >>>>> > /var/lib/libvirt/images/win7.qcow2 >>>>> > How large would you like the disk >>>>> (/var/lib/libvirt/images/win7.qcow2) to be >>>>> > (in gigabytes)? >>>>> > 8 >>>>> > What is the install CD-ROM/ISO or URL? >>>>> > /home/Windows-7-x86.iso >>>>> > >>>>> > Starting install... >>>>> > Allocating 'win7.qcow2' >>>>> > | 8.0 GB 00:00 >>>>> > Creating domain... >>>>> > | 0 B 00:00 >>>>> > (virt-viewer:24972): virt-viewer-DEBUG: Couldn't load configuration: >>>>> File is >>>>> > empty >>>>> > >>>>> > [oneadmin@front ~]$ oneimage create --name "win7-x86_64" --path >>>>> > "/var/lib/libvirt/images/win7.qcow2" --driver qcow2 --datastore >>>>> default >>>>> > ID: 12 >>>>> > >>>>> > [oneadmin@front ~]$ oneimage list >>>>> > ID USER GROUP NAME DATASTORE SIZE TYPE >>>>> PER STAT >>>>> > RVMS >>>>> > 3 oneadmin oneadmin Ubuntu-14.04_x8 default 287M OS >>>>> No used >>>>> > 1 >>>>> > 12 oneadmin oneadmin win7-x86_64 default 8G OS >>>>> No rdy >>>>> > 0 >>>>> > >>>>> > [oneadmin@front ~]$ onetemplate create --name "win7" --cpu 1 --vcpu >>>>> 1 >>>>> > --memory 512 --arch x86_64 --disk "win7-x86_64" --nic "private" >>>>> --vnc --ssh >>>>> > ID: 11 >>>>> > >>>>> > [oneadmin@front ~]$ onetemplate list >>>>> > ID USER GROUP NAME >>>>> > REGTIME >>>>> > 2 oneadmin oneadmin Ubuntu-14.04 >>>>> 06/27 >>>>> > 02:11:28 >>>>> > 11 oneadmin oneadmin win7 >>>>> 07/08 >>>>> > 18:30:39 >>>>> > >>>>> > [oneadmin@front ~]$ onetemplate instantiate win7 --name myvm8 >>>>> > VM ID: 36 >>>>> > >>>>> > [oneadmin@front ~]$ onevm list >>>>> > ID USER GROUP NAME STAT UCPU UMEM HOST >>>>> > TIME >>>>> > 25 oneadmin oneadmin myvm2 runn 0 512M nc1 >>>>> 11d >>>>> > 16h14 >>>>> > 36 oneadmin oneadmin myvm8 fail 0 0K >>>>> 0d >>>>> > 00h00 >>>>> > >>>>> > >>>>> > ERROR from log file. >>>>> > >>>>> > [oneadmin@front ~]$ tail -f /var/log/one/36.log >>>>> > >>>>> > Tue Jul 8 18:31:48 2014 [DiM][I]: New VM state is ACTIVE. >>>>> > Tue Jul 8 18:31:48 2014 [LCM][I]: New VM state is PROLOG. >>>>> > Tue Jul 8 18:35:30 2014 [LCM][I]: New VM state is BOOT >>>>> > Tue Jul 8 18:35:30 2014 [VMM][I]: Generating deployment file: >>>>> > /var/lib/one/vms/36/deployment.0 >>>>> > Tue Jul 8 18:35:31 2014 [VMM][I]: ExitCode: 0 >>>>> > Tue Jul 8 18:35:31 2014 [VMM][I]: Successfully execute network >>>>> driver >>>>> > operation: pre. >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: Command execution fail: cat << >>>>> EOT | >>>>> > /var/tmp/one/vmm/kvm/deploy >>>>> '/var/lib/one/datastores/0/36/deployment.0' >>>>> > 'nc1' 36 nc1 >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: error: Failed to create domain >>>>> from >>>>> > /var/lib/one/datastores/0/36/deployment.0 >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: error: internal error process >>>>> exited >>>>> > while connecting to monitor: qemu-kvm: -drive >>>>> > >>>>> file=/var/lib/one/datastores/0/36/disk.0,if=none,id=drive-ide0-0-0,format=qcow2: >>>>> > could not open disk image /var/lib/one/datastores/0/36/disk.0: >>>>> Invalid >>>>> > argument >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: >>>>> > Tue Jul 8 18:35:32 2014 [VMM][E]: Could not create domain from >>>>> > /var/lib/one/datastores/0/36/deployment.0 >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: ExitCode: 255 >>>>> > Tue Jul 8 18:35:32 2014 [VMM][I]: Failed to execute virtualization >>>>> driver >>>>> > operation: deploy. >>>>> > Tue Jul 8 18:35:32 2014 [VMM][E]: Error deploying virtual machine: >>>>> Could >>>>> > not create domain from /var/lib/one/datastores/0/36/deployment.0 >>>>> > Tue Jul 8 18:35:33 2014 [DiM][I]: New VM state is FAILED >>>>> > >>>>> > -- >>>>> > Thanks & Regards, >>>>> > Sudeep Narayan Banerjee >>>>> > >>>>> > _______________________________________________ >>>>> > Users mailing list >>>>> > Users@lists.opennebula.org >>>>> > http://lists.opennebula.org/listinfo.cgi/users-opennebula.org >>>>> > >>>>> >>>>> >>>>> >>>>> -- >>>>> Javier Fontán Muiños >>>>> Developer >>>>> OpenNebula - Flexible Enterprise Cloud Made Simple >>>>> www.OpenNebula.org | @OpenNebula | github.com/jfontan >>>>> >>>> >>>> >>>> >>>> -- >>>> Thanks & Regards, >>>> Sudeep Narayan Banerjee >>>> >>>> _______________________________________________ >>>> Users mailing list >>>> Users@lists.opennebula.org >>>> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org >>>> >>>> >>> >>> >>> -- >>> Valentin Bud >>> http://databus.pro | valen...@databus.pro >>> >> >> >> >> -- >> Thanks & Regards, >> Sudeep Narayan Banerjee >> > -- Thanks & Regards, Sudeep Narayan Banerjee
_______________________________________________ Users mailing list Users@lists.opennebula.org http://lists.opennebula.org/listinfo.cgi/users-opennebula.org