[Planetlab-devel] gec8 demo help: Auto-adding a second interface to a slice upon

"S.Çağlar Onur" caglar at cs.princeton.edu
Sun Jul 18 15:50:07 EDT 2010


Hi Rob,

On Jul 18, 2010, at 3:30 PM, Rob Sherwood wrote:

> Hello,
> 
> So, we're using PL nodes with two interfaces ( a control interface and
> an interface on an openflow network).  We dredged out of your mailing
> list this series of magic commands to expose the second interface to a
> slice:
> 
> [as root on the node, run:]
> # ifconfig eth1 $ip netmask 255.255.255.0 up
> # mkdir /etc/vservers/<slice name>/interfaces/2
> # echo $ip > /etc/vservers/<slice name>/interfaces/2/ip
> # touch /etc/vservers/<slice name>/interfaces/2/nodev
> # vserver <slice name> restart
> 
> Now, the trick is that I would like to do this at slice creation, so
> that it happens automatically for all slices.  I'm hoping that someone
> can point me to the right "slice creation script"  where I can just
> tack these commands on to it (or even provide a patch if you're
> feeling particular generous, a patch).

/usr/sbin/vuseradd is the correct one. It's a bash script so you can easily add required post-install steps or modify slice creation parameters to add other interfaces [1].

> Given this is for the gec8 demo (two days!), any help would be greatly
> appreciated.
> 
> Thanks in advance,
> 
> - Rob
> .
> 
> _______________________________________________
> Devel mailing list
> Devel at lists.planet-lab.org
> https://lists.planet-lab.org/mailman/listinfo/devel


[1] http://git.planet-lab.org/?p=util-vserver-pl.git;a=blob;f=scripts/vuseradd;h=f77d58b3bb7f32f2f0165762493956c8367e17d4;hb=refs/heads/0.3#l80

Best regards,
--
S.Çağlar Onur <caglar at cs.princeton.edu>




More information about the Devel mailing list