Ignore:
Timestamp:
Jul 27, 2008, 11:35:58 PM (16 years ago)
Author:
ecprice
Message:

New guest-based autoinstaller

Location:
trunk/packages/sipb-xen-guest-installer/domU
Files:
3 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/sipb-xen-guest-installer/domU/usr/sbin/sipb-xen-install

    r641 r741  
    33TARGET=/dev/hda
    44
    5 #For some strange reason, . $TARGET doesn't work reliably.
     5# Read in the environment variables
     6# For some strange reason, . $TARGET doesn't work reliably.
    67eval `grep -a -m1 -B 100 ^return$ $TARGET | grep -v return`
    7 
    8 
    9 #HOSTNAME=foobar
    10 #DIST=etch
    11 #MIRROR=http://debian.lcs.mit.edu/debian
    12 #IMAGESIZE=3800
    138
    149ARCH=amd64
    1510
    16 #LVSIZE=`lvs --noheadings --units M --nosuffix -o Size /dev/xenvg/d_foobar_hda | sed 's/\..*//'`
     11echo ,${IMAGESIZE}$',L,*\n,,S\n;\n;' | sfdisk -uM -H 255 -S 63 $TARGET
    1712
    18 # If this script is interrupted, it may not clean up after itself.
    19 # In particular, it may leave ${VOLUME}1 mounted somewhere in tmp.
    20 # Unmount it, then kpartx -d $VOLUME to clean up.
    21 
    22 ###
    23 ###  Create the device for SIPB-Xen purposes
    24 ###
    25 echo ,${IMAGESIZE}$',L,*\n,,S\n;\n;' | sfdisk -uM -H 255 -S 63 $TARGET
    26 #kpartx -a $TARGET
    27 
    28 xen-create-image --image-dev ${TARGET}1 --swap-dev ${TARGET}2 --fs ext3 --ide --arch $ARCH --dist $DIST --hostname $HOSTNAME --mirror $MIRROR --dhcp --cache=yes
    29 
    30 #kpartx -d $TARGET
     13xen-create-image --image-dev ${TARGET}1 --swap-dev ${TARGET}2 --fs ext3 --ide --arch $ARCH --dist $DIST --hostname $HOSTNAME --mirror $MIRROR --ip=$IP --netmask=255.255.0.0 --gateway=18.181.0.1 --cache=yes
Note: See TracChangeset for help on using the changeset viewer.