[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Re: Communicating with VM before Network is configured.



On Tue, 18 Jul 2006, Ligesh wrote:

>  I have a specific requirement to assign static ips to a VM. My question
> is: is there a way to accomplish this. In Vmware you can do it by
> defining a variable machine.id in the config file variable, which can be
> accessed from inside VM using the the vmware-guestd on linux or
> vmwareservice.exe on linux. This is generally a good idea, and I want to
> know if Xen supports something like this, or what I should do to get
> this implemented etc etc.

I expect vmware does this by controlling both the MAC address and the DHCP
server, that certainly seems like the simplest way ... you could impliment
the same functionality yourself.

Failing that, you can pass info to the domU kernel "command line" the
same way the root device is passed in. I use this method with my
initrd to pass in nbd boot parameters:

   extra="NBDHOST=65.39.183.43 NBDPORT=8001
      ip=192.168.2.254:1.1.1.1:192.168.2.86:255.255.255.0"

for an init script it's really simple, as those NBD* parms are already
loaded into environment variables :) ... but in the more general
case you would need to parse them out of /proc/cmdline

I don't believe xen has any specific methods for passing config
parameters to the domU, but I'm no expert.

Oh, and looking back at the subject line... those ip config parameters
might be of use to you... ip=192...

You'll need a kernel with autoconfig enabled.

-Tom



_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.