[9fans] Networking problem with Plan 9 + Xen - Plan9

This is a discussion on [9fans] Networking problem with Plan 9 + Xen - Plan9 ; I am having problem configuring Plan 9 so that it can access both dom0 and the internet. At the moment I am trying to configure Plan 9 with Xen; I have set up a CPU/file server and an authentication server. ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: [9fans] Networking problem with Plan 9 + Xen

  1. [9fans] Networking problem with Plan 9 + Xen

    I am having problem configuring Plan 9 so that it can access both dom0
    and the internet.

    At the moment I am trying to configure Plan 9 with Xen; I have set up
    a CPU/file server and an authentication server. I am able to access
    the internet on dom0 through eth0 with the IP address of 192.168.0.1.
    But I am having trouble configuring the networking of Plan 9.

    What IP address should I give to Plan 9 and how do I configure it?

    Thank you for your time.

    -eric

  2. Re: [9fans] Networking problem with Plan 9 + Xen

    > At the moment I am trying to configure Plan 9 with Xen; I have set up
    > a CPU/file server and an authentication server. I am able to access
    > the internet on dom0 through eth0 with the IP address of 192.168.0.1.
    > But I am having trouble configuring the networking of Plan 9.
    >
    > What IP address should I give to Plan 9 and how do I configure it?


    If your xen configuration bridges the virtual network interfaces
    onto the physical ethernet, it's easy. You just give Plan 9 another
    address on the same subnet. If you have a DHCP server on the local
    network, the Plan 9 command
    ip/ipconfig
    should pick up the configuration information from dhcp and do everything
    needed. Otherwise, suppose you want to give Plan 9 address 192.168.0.42
    and your router is at 192.168.0.99; then use the command
    ip/ipconfig -g 192.168.0.99 ether /net/ether0 add 192.168.0.42


  3. Re: [9fans] Networking problem with Plan 9 + Xen

    I prefer the nat way we do things. Aki and I set things up so when you
    create the domain, it "just happens".

    I can put my /etc/xen directory on sources if that will help

    ron

  4. Re: [9fans] Networking problem with Plan 9 + Xen

    On 5/12/07, ron minnich wrote:
    > I can put my /etc/xen directory on sources if that will help


    Yes please, that will be very helpful.

    -eric

  5. Re: [9fans] Networking problem with Plan 9 + Xen

    On 5/11/07, Eric Boston wrote:
    > On 5/12/07, ron minnich wrote:
    > > I can put my /etc/xen directory on sources if that will help

    >
    > Yes please, that will be very helpful.


    OK, on sources I have this:
    cpu% pwd
    /n/sources/xen/xen3/ronslaptop
    cpu% ls -l
    --rw-r--r-- M 65 rminnich xen 1844108 May 11 22:18 9xenpccpuf
    --rw-r--r-- M 65 rminnich xen 76945 May 11 22:16 etcxen.tgz
    cpu%

    I dropped my current kernel on there just for reference.

    The xen scripts were hacked on by Aki and me so that, when you do
    xm create -c plan9test
    you see this nice stuff appear in /etc/hosts and /etc/dhcpd.conf:
    10.0.1.1 plan9

    host plan9 { hardware ethernet 00:16:3e:4a:2d:78; fixed-address
    10.0.1.1; option routers 10.0.1.128; option host-name "plan9"; option
    domain-name-servers 192.168.0.1;}

    This is useful because the way xen works, it gives you a different
    veth every time, so you can't easily stick with a fixed IP/MAC.

    BTW Aki and I talked today and we've given up on fbdev -- THX is going
    to include X11. Such is life. The fbdev stuff is nowhere close to
    solid enough to depend on.

    Opera has kindly agreed to let us distribute opera on the THX, but --
    there's a legal agreement I have to sign. Yuck. I am afraid to sign
    it.

    Somebody pointed out at the BAP9UG meeting that I should just bundle
    inferno (and hence Charon) onto THX instead. So, that is what we will
    do.

    ron

  6. Re: [9fans] Networking problem with Plan 9 + Xen

    Ron says -

    > I prefer the nat way we do things. Aki and I set things up so when you
    > create the domain, it "just happens".


    Not to start a xen configuration war here, but bridging and nat each
    have different advantages. If xen puts your virtual Plan 9 server
    behind a nat, how do you access it from other machines on your network
    or from the outside internet?

    Without hacking on the standard xen scripts at all, my bridged
    configuration also "just happens".

    > This is useful because the way xen works, it gives you a different
    > veth every time, so you can't easily stick with a fixed IP/MAC.


    You can define a fixed ethernet address in the guest domain config
    file. As the example /n/sources/xen/xen3/etc-xen-plan9 shows:

    name = "plan9"
    vif = [ 'mac=aa:00:10:00:00:10' ]
    disk = ...

    You can then configure your DHCP server to assign a fixed IP
    address to this MAC.

    If you don't use DHCP, then you don't need a fixed MAC, and
    you can define all the IP address information in the guest
    domain config file. Just edit the Plan 9 /rc/bin/cpurc script
    to contain the command
    eval ip/ipconfig $ipconfig
    and set up the domain config file something like this:

    name = "p9cpu"
    vif = [ '' ]
    disk = [ 'file:/usr/xen9/plan9.img,sda,w' ]
    extra="""
    bootargs=local!/dev/sd00/fossil
    venti=/dev/sd00/arenas
    ipconfig=-g 192.168.0.1 192.168.0.42
    DNSSERVER=192.168.0.1 192.168.0.2
    """

    If you configure the Plan 9 guest as a file and auth server, you could
    use a second domain config file to define a diskless client, by
    omitting the 'disk=' line, and defining the 'extra=' section something
    like this:

    extra="""
    bootargs=tcp -g 192.168.0.1 192.168.0.100
    fs=192.168.0.42
    auth=192.168.0.42
    DNSSERVER=192.168.0.1 192.168.0.2
    """


+ Reply to Thread