[one-users] Need information on getting VM's IP address

Tino Vazquez tinova79 at gmail.com
Thu Feb 5 07:07:26 PST 2009


Hi Lalithamba,

comments below,

On Mon, Feb 2, 2009 at 4:05 PM,  <lalithamba.vishwanathaiah at wipro.com> wrote:
> Hi Ruben,
>
> Following are the templates for VNet and VM which I have submitted.
>
> The VNet template is as shown below :
>
> NAME="Public VLAN"
> TYPE=FIXED
> BRIDGE=eth0
> LEASES=[IP=10.101.102.100]
>
>
> Output : onevnet show 0
>
> NID               : 0
> UID               : 0
> Network Name      : Public VLAN
> Type              : Fixed
> Bridge            : eth0
> ....: Template :....
>         BRIDGE=eth0
>         HOSTNAME=10.101.102.100
>         LEASES=IP=10.101.102.100
>         NAME=Public VLAN
>         TYPE=FIXED
> ....: Leases :....
> IP = 10.101.102.100 MAC = 00:03:0a:65:66:64  USED = 1 VID = 0
>
> In this case, the MAC address what formed as a combination of
>
> MAC_ADDRESS = MAC_PREFFIX:IP_IN_HEXADECIMAL
>
> where MAC_PREFIX=00:03 in oned.conf
>
> ----------------------------------------------------------------------------------
> The VM Template is :
>
> NAME    = nodev1m
> CPU      = 0.5
> MEMORY   = 256
> bootargs = "--entry=xvda2:/boot/vmlinuz-xen,/boot/initrd-xen"
> OS       = [bootloader = "/usr/lib/xen/boot/domUloader.py"]
> DISK     = [source="/home/cloud/vm-image/disk0",target="xvda", BOOT="true",
> read
> only="no"]
> NIC     = [network="Public VLAN"]
> GRAPHICS = [
>   type    = "vnc",
>   listen  = "127.0.0.1",
>   port    = "9999"]
> ----------------------------------------------------------------------------------
>
> When xen creates the VM and boots it, DHCP assigns the IP address
> dynamically to Guest VM.
> In this case, how do we get the IP address of Guest VM using Open Nebula ?

These two approaches for giving an IP to the VM are mutually
exclusive. you can use DHCP, in which case you don't need OpenNebula's
network management capabilities, or you can use the built in virtual
network manager, as you did with the VM template and the "onevnet"
command.

If you chose the latter, you will need to configure your VM to be able
to be contextualized upon booting. For more information, take a look
here: http://opennebula.org/doku.php?id=documentation:rel1.2:nm#network_context_for_the_vm-

> Thanks and Regards,
> Lalithamba.

Hope it helps,

-Tino

>
> ________________________________
> From: Ruben S. Montero [mailto:rubensm at dacya.ucm.es]
> Sent: Mon 02-Feb-09 6:05 PM
> To: users at lists.opennebula.org
> Cc: Lalithamba Vishwanathaiah (WT01 - Innovation Group)
> Subject: Re: [one-users] Need information on getting VM's IP address
>
> Hi,
>         onevm show <VMID> should do the job. The command output, under the
> Template,
> in the NIC attribute should show you the IP
>
> Best
>
> Ruben
>
> On Monday 02 February 2009 12:36:59 lalithamba.vishwanathaiah at wipro.com
> wrote:
>> Hi,
>>
>> I am new to OpenNebula.
>>
>> Once a VM is deployed using "onevm create" command, its starting up VM
>> with
>> a specific IP address & MAC. Is there any way to get hold of this ip
>> address ?
>>
>> Is there any method /command in Opennebula to get the IP address of the VM
>> ?
>>
>> Many Thanks.
>>
>> Thanks and Regards,
>> Lalithamba.
>>
>>
>>
>> Please do not print this email unless it is absolutely necessary.
>>
>> The information contained in this electronic message and any attachments
>> to
>> this message are intended for the exclusive use of the addressee(s) and
>> may
>> contain proprietary, confidential or privileged information. If you are
>> not
>> the intended recipient, you should not disseminate, distribute or copy
>> this
>> e-mail. Please notify the sender immediately and destroy all copies of
>> this
>> message and any attachments.
>>
>> WARNING: Computer viruses can be transmitted via email. The recipient
>> should check this email and any attachments for the presence of viruses.
>> The company accepts no liability for any damage caused by any virus
>> transmitted by this email.
>>
>> www.wipro.com
>
> --
> +---------------------------------------------------------------+
>  Dr. Ruben Santiago Montero
>  Associate Professor
>  Distributed System Architecture Group (http://dsa-research.org)
>
>  URL:    http://dsa-research.org/doku.php?id=people:ruben
>  Weblog: http://blog.dsa-research.org/?author=7
>
>  GridWay, http://www.gridway.org
>  OpenNEbula, http://www.opennebula.org
> +---------------------------------------------------------------+
>
> Please do not print this email unless it is absolutely necessary.
>
> The information contained in this electronic message and any attachments to
> this message are intended for the exclusive use of the addressee(s) and may
> contain proprietary, confidential or privileged information. If you are not
> the intended recipient, you should not disseminate, distribute or copy this
> e-mail. Please notify the sender immediately and destroy all copies of this
> message and any attachments.
>
> WARNING: Computer viruses can be transmitted via email. The recipient should
> check this email and any attachments for the presence of viruses. The
> company accepts no liability for any damage caused by any virus transmitted
> by this email.
>
> www.wipro.com
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>



-- 
Constantino Vázquez, Grid Technology Engineer/Researcher:
http://www.dsa-research.org/tinova
DSA Research Group: http://dsa-research.org
Globus GridWay Metascheduler: http://www.GridWay.org
OpenNebula Virtual Infrastructure Engine: http://www.OpenNebula.org


More information about the Users mailing list