Changeset 2779

Show
Ignore:
Timestamp:
02/12/10 13:52:55
Author:
douglm
Message:

--

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/build/quickstart/linux/startjboss

    r2735 r2779  
    66 
    77BASE_DIR=`pwd` 
     8 
     9PRG="$0" 
     10 
     11usage() { 
     12  echo "  $PRG [-heap size] [-newsize size] " 
     13  echo "" 
     14  echo " where:" 
     15  echo "" 
     16  echo " -heap sets the heap size and should be n for bytes" 
     17  echo "                                        nK for kilo-bytes" 
     18  echo "                                        nM for mega-bytes" 
     19  echo "                                        nG for giga-bytes" 
     20  echo "" 
     21  echo " -newsize sets the new generation size and has the same form as -heap" 
     22  echo "  the value should be around one third of the heap" 
     23  echo "" 
     24  echo "  -permsize sets the permgen size and has the same form as -heap" 
     25  echo "   The value should probably not be less than 256M" 
     26  echo "" 
     27} 
     28 
     29heap="1G" 
     30newsize="330M" 
     31permsize="256M" 
     32 
     33while [ "$1" != "" ] 
     34do 
     35  # Process the next arg 
     36  case $1       # Look at $1 
     37  in 
     38    -usage | -help | -? | ?) 
     39      usage 
     40      exit 
     41      shift 
     42      ;; 
     43    -heap)         # Heap size bytes or nK, nM, nG 
     44      shift 
     45      heap="$1" 
     46      shift 
     47      ;; 
     48    -newsize) 
     49      shift 
     50      newsize="$1" 
     51      shift 
     52      ;; 
     53    -permsize) 
     54      shift 
     55      permsize="$1" 
     56      shift 
     57      ;; 
     58    *) 
     59      usage 
     60      exit 1 
     61      ;; 
     62  esac 
     63done 
    864 
    965JBOSS_VERSION="jboss-5.1.0.GA" 
     
    3389BW_DATA_DIR_DEF=-Dorg.bedework.data.dir=$BW_DATA_DIR/ 
    3490 
     91JAVA_OPTS="$JAVA_OPTS -Xms$heap -Xmx$heap" 
     92JAVA_OPTS="$JAVA_OPTS -XX:NewSize=$newsize -XX:MaxNewSize=$newsize" 
     93export JAVA_OPTS="$JAVA_OPTS -XX:PermSize=$permsize -XX:MaxPermSize=$permsize" 
     94 
    3595RUN_CMD="./$JBOSS_VERSION/bin/run.sh -c $JBOSS_CONFIG $JBOSS_BIND $JBOSS_PORTS $LOG_THRESHOLD $ACTIVEMQ_DIRPREFIX $BW_DATA_DIR_DEF" 
    3696