[one-users] RES: Virtual Machine contextualization variables

Nelson Peixoto nelsonpeixoto at fiocruz.br
Fri Sep 13 10:46:01 PDT 2013


Hi Olivier,

Thanks for the reply. Anyway... about those variables, is there such a thing
as a reference guide for them? I see there are several ways to use a
variable inside a VM template but it is not clear which are them and what
values can be applied onto them.

The question about the hosts is mainly because so far I could not manage to
understand the interaction in between OpenNebula virtual networks and each
KVM installation in the hosts, and how to deal with the routes so that each
VM can "see" each other.

Right now, I have two hosts for the VM's, both of them with a KVM
installation. By default, KVM sets up a virbr0 interface with 192.168.122.1
network address. 

I wanted to be able to create a single ranged virtual newtork (with a lease
pool), which could be used by both of the hosts when instantiating a VM, so
that I could have more than 255 IP addresses for VM's at a time.

I need to have, for example, 400 VMs instantiated using a single ranged
virtual network, supported by these two hosts. Is it possible? If so, how
should I proceed? Or if not, does that mean I will have to create several
virtual networks, each one limited to x.x.x.1-x.x.x.255 VM's at a time, and
then create several templates for each different virtual networks?

I do not know if I am being clear in the explanation... thanks for the
comprehension...

Best regards,
Nelson Peixoto.

I later created a virtual network in OpenNebula, ranged type, 192.168.
-----Mensagem original-----
De: Olivier Sallou [mailto:olivier.sallou at irisa.fr] 
Enviada em: sexta-feira, 13 de setembro de 2013 11:27
Para: nelsonpeixoto at fiocruz.br
Cc: users at lists.opennebula.org
Assunto: Re: [one-users] Virtual Machine contextualization variables


On 09/12/2013 05:36 PM, nelsonpeixoto at fiocruz.br wrote:
> Dear friends,
>
> It is my first post in here. I have been trying out OpenNebula 3.2 and 
> I have a doubt on using context variables.
>
> I have two hosts for the VMs and i want to be able to capture, via 
> context variable, for each VM I instantiate, which host is it on (IP or
FQDN).
>
> I managed to find this page
> (http://opennebula.org/documentation:archives:rel3.2:template) with a 
> set of instructions on how to use context variables and a link to some 
> of the possible values, but I could not find any hint on how to catch 
> any information on which host is the VM running on.
>
> I want to be able to capture this information and later on use this 
> data on the VM boot, in order to add some specific network configurations.
>
> So, is there a place with a broader context variable reference guide 
> or is there a way to catch that info?
Hi,
you can't set (yet)  any dynamic context variable. All you can do is to set
some "static" variables in the template of your VM.
Via Hooks, you may be able to catch the information (getting all context
data of the VM), and register it in a db/file/... then your VM, once booted,
could try to access this data.
However, your VM network should not depend on the host running the VM.

Regards

Olivier
>
> Thanks in advance,
> Nelson Peixoto.
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>

--
Olivier Sallou
IRISA / University of Rennes 1
Campus de Beaulieu, 35000 RENNES - FRANCE
Tel: 02.99.84.71.95

gpg key id: 4096R/326D8438  (keyring.debian.org) Key fingerprint = 5FB4 6F83
D3B9 5204 6335  D26D 78DC 68DB 326D 8438




More information about the Users mailing list