Files
xen/tools/domain_builder/vifinit
T
iap10@labyrinth.cl.cam.ac.uk f0568abaa3 bitkeeper revision 1.76.1.1 (3e54fc23zcQZlR65KsPYjjBI9M-6Hg)
modifications to newdom scripts. Example invocations:

newdom <size> <image> <ip> <root details>  

really ./newdom 16000 ../../../xenolinux-2.4.16-kdb/arch/xeno/boot/image 128.232.35.xxx root=/dev/nfs nfsroot=/usr/groups/srgboot/hhh/roots/root1

really ./newdom 16000 ../../../xenolinux-2.4.16-kdb/arch/xeno/boot/image 128.232.35.xxx root=/dev/xhdaNNN

[fill in hhh, xxx and NNN as appropriate]
2003-02-20 16:02:43 +00:00

26 lines
596 B
Bash
Executable File

#!/bin/bash
#
# vifinit
#
# This is a silly little script to dump a couple of simple rules down to
# the hypervisor to assign a full static IP to a given virtual interface.
#
# Usage is:
#
# vifinit [vif id] [dotted decimal ip address]
#
if [ $# -ne 2 ] ;
then
echo "usage: vifinit [vif id] [dotted decimal ip address]"
exit
fi
#outbound rule:
echo "ADD ACCEPT srcaddr=$2 srcaddrmask=255.255.255.255 srcint=$1 dstint=-1 proto=any" > /proc/vfr
#inbound rule:
echo "ADD ACCEPT dstaddr=$2 dstaddrmask=255.255.255.255 srcint=-4 dstint=$1 proto=any" > /proc/vfr
#----] done.