[one-users] managing images

Daniel.MOLDOVAN at cs.utcluj.ro Daniel.MOLDOVAN at cs.utcluj.ro
Tue Feb 1 04:40:27 PST 2011


Hy,
The target is the virtual target for the virtual disk. I have no used the
images repository until now and i am using KVM so i'm not entirely sure
what DISK types XEN supports . However, this might be useful so : using an
already existing virtual machine virtual disk i declare

DISK   = [
   type = disk,
   clone=no,
   size =4096,
   format = ext3,
   source= "virtualDiskFilePath",
   target   = hda,
   readonly = "no"
   ]
. Then, i have in the OS section
OS     = [
   boot = hd,
   ROOT = hda
  ]
Note that hda is just the target inside the virtual machine.

And for booting a XEN kernel located on the Host computer, NOT in the
virtual machine, use
OS     = [
   boot = hd,
   ROOT = hda,
   kernel = "/boot/vmlinuz-2.6.35-22-server",
   initrd = "/boot/initrd.img-2.6.35-22-server",
  ]
where "boot/vmlinuz-2.6.35-22-server" should be replaced by the path to
your kernel and its name,
as shown in http://opennebula.org/documentation:rel2.0:template OS section.

Hope this helps.

Regards

În Mar, Februarie 1, 2011 1:16 pm, anoop Lekshmanan a scris:
> Thanks Daniel.
>
>
> I have Xen installed and XenDom0 running on a node and I have
> successfully connected to the Node.
>
> ID NAME              CLUSTER  RVM   TCPU   FCPU   ACPU    TMEM    FMEM
> STAT
> 0 node-0                 default        0        400      395 400
> 7.9G      1024K  off
> 1 node1                  default        0        400      398     400
> 7.9G      7.2G   on
>
>
> I have created an image template of CentOS DVD ISO:
> NAME          = "CentOS 5.5 Base"
> PATH          = /opt/cloud/one/images/CentOS-5.5-x86_64-bin-DVD-1of2.iso
> PUBLIC        = YES
> DESCRIPTION   = "CentOS 5.5 for testing"
>
>
> Then registered the template and oneimage lsited it:
>
>
> oneimage list ID     USER                 NAME TYPE              REGTIME
> PUB PER STAT
> #VMS
> 1 oneadmin      CentOS 5.5 Base   OS   Jan 31, 2011 11:14 Yes  No
> rdy     0
>
> I have created vnet using onevnet with name LAN2.
>
>
> Now I am trying to start a VM on the node using this image.
>
>
> I have created the vm template as:
>
>
> CPU    = 1
> MEMORY = 2056
>
>
> DISK = [ image  = "CentOS 5.5 Base" ]
>
>
> DISK = [ type   = swap,
> size   = 3072 ]
>
> #swap of 3 GB
> DISK = [ type   = swap,
> size   = 3072 ] #/ root file system of 10 GB
>
>
> DISK = [ TYPE   = fs,
> SIZE   = 10240,
> FORMAT = ext3,
> SAVE   = yes,
> TARGET = ? ]
> NIC    = [ NETWORK = "LAN2" ]
>
>
> GRAPHICS = [type="vnc",listen="0.0.0.0",port="1"]
>
>
> What could be the Target, I have /vm on hda3 ( not a separate partition
> but / of my Xen Host)
> I am trying to have a 10 GB / mount and 3 GB swap space. How can I set the
>  rest  like kernel etc....
>
> I have no idea how to create the disk,  I have no separate partitions for
>  Xen guest, partitions I have are / /boot and swap. I have a /vm
> directory for keeping Guests.  Should I re-instal the machine with
> separate /vm partition?
>
> I am stuck on this for some time. It would be great if some one can help
> me.
>
> Thanks,
> Anoop
>
>
>
>
> On Tue, Feb 1, 2011 at 12:42 PM, <Daniel.MOLDOVAN at cs.utcluj.ro> wrote:
>
>
>> Hello,
>> Look at http://www.opennebula.org/documentation:rel2.0:template . And
>> depending on your needs you can create both swap partitions and disk and
>>  so on. You need at least one boot partition which is the root for the
>> OS
>> in the case you are using KVM. For XEN you can use a kernel located on
>> the host to boot the VM. Regarding the disk concepts,think at each disk
>> as a separate storage drive, depending on the storage type(cdrom, disk,
>> swap, etc).
>>
>> P.S. Is ONE not ON :P
>>
>>
>>
>> În Lun, Ianuarie 31, 2011 10:27 pm, anoop Lekshmanan a scris:
>>
>>> Thanks Nikolay.
>>>
>>>
>>>
>>> One more question, on deploying like this how can I choose/customize
>>> disk for thus deployed VMs like /, swap, boot etc. I had gone through
>>> ON
>>> docs, but I dont understand the disk concepts, should we create
>> partitions
>>> /,swap,
>>> boot on the node for VM. What does Target means, should we create
>>> target partitions before running the deploy commands.
>>>
>>> Sorry for bothering you, I am totally confused on this part.
>>>
>>>
>>>
>>> Thanks,
>>> Anoop
>>>
>>>
>>>
>>> On Tue, Feb 1, 2011 at 1:42 AM, <knawnd at gmail.com> wrote:
>>>
>>>
>>>
>>>> anoop Lekshmanan wrote on 31/01/11 23:04:
>>>>
>>>> Hi Nikolay,
>>>>
>>>>
>>>>>
>>>>> Thanks!
>>>>>
>>>>>
>>>>>
>>>>> I have used the registered image with VM template but on onevm
>>>>> create template-name the vm state continues be on pending.
>>>>>
>>>> To run VM it needs to be deployed apart from creating VM
>>>> $ onevm deploy <VM_id> <Host_id>
>>>>
>>>>
>>>>
>>>> VM_id is virtual machine id  (specified in first column on 'onevm
>>>> list') Host_id is registered in ON host id ('onehost list') E.g.
>>>> $ onevm deploy 9 3
>>>>
>>>>
>>>>
>>>> Hope it helps,
>>>> Nikolay.
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> Users mailing list
>>>> Users at lists.opennebula.org
>>>> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>>>>
>>>>
>>>>
>>> _______________________________________________
>>> Users mailing list
>>> Users at lists.opennebula.org
>>> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>>>
>>>
>>>
>>
>>
>>
>





More information about the Users mailing list