2 #----------------------------------------------------
3 #shell used to initiate container, this script
4 #is called by the container BEFORE all the
7 #----------------------------------------------------
9 #vzgot.start VE_name VE_pid [base_dir]
10 # VE_name is the container dir name
11 # VE_pid is the container main process ID as seen
13 # base_dir is this application root directory
14 # used for devel only.
15 #----------------------------------------------------
19 #----------------------------------------------------
20 if ! [ -f $BASE/etc/vzgot/vzgot_config ] ; then
21 echo "Missing vzgot config file"
22 exit 1 #trouble trouble
24 . $BASE/etc/vzgot/vzgot_config
26 #specific container configuration override (if needed)
27 if [ -f $BASE/$VZLIB/vzdir/$CONTNAME/vzgot_config ] ; then
28 $BASE/$VZLIB/vzdir/$CONTNAME/vzgot_config
30 #----------------------------------------------------
31 #renaming VETH pair to a standard ETH name
32 ip link set From_$2 name $ETHNAME
34 if [ $ret -ne 0 ]; then
35 echo "vzgot.container.start, unable to rename veth From_$2 to $ETHNAME"
38 #----------------------------------------------------
39 #setting the fastboot flag
40 rm -fr $BASE/$VZLIB/vzdir/$CONTNAME/rootfs/.autofsck
41 touch $BASE/$VZLIB/vzdir/$CONTNAME/rootfs/fastboot
42 #----------------------------------------------------