Changeset 31233 for other-projects

Show
Ignore:
Timestamp:
14.12.2016 11:12:29 (2 years ago)
Author:
davidb
Message:

Changes to operate on nema as well as gsliscluster1 and gc0-9

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • other-projects/hathitrust/wcsa/extracted-features-solr/trunk/gslis-cluster/SETUP.bash

    r31103 r31233  
    88export SPARK_SLAVE_HOSTS="gc0 gc1 gc2 gc3 gc4 gc5 gc6 gc7 gc8 gc9" 
    99 
    10 export ZOOKEEPER_SERVER=gchead:8181 
    11 export SOLR_NODES="gc0:8983 gc1:8983 gc2:8983 gc3:8983 gc4:8983 gc5:8983 gc6:8983 gc7:8983 gc8:8983 gc9:8983" 
    12 #export SOLR_NODES="$SOLR_NODES gc0:8984 gc1:8984 gc2:8984 gc3:8984 gc4:8984 gc5:8984 gc6:8984 gc7:8984 gc8:8984 gc9:8984" 
     10if [ "$short_hostname" = "nema" ] ; then 
     11  export ZOOKEEPER_SERVER=localhost:8181 
     12  export SOLR_NODES="localhost:8983 localhost:8984 localhost:8985 localhost:8986 localhost:8987 localhost:8988 localhost:8989 localhost:8990 localhost:8991 localhost:8992" 
     13else  
     14  export ZOOKEEPER_SERVER=gchead:8181 
     15  export SOLR_NODES="gc0:8983 gc1:8983 gc2:8983 gc3:8983 gc4:8983 gc5:8983 gc6:8983 gc7:8983 gc8:8983 gc9:8983" 
     16  #export SOLR_NODES="$SOLR_NODES gc0:8984 gc1:8984 gc2:8984 gc3:8984 gc4:8984 gc5:8984 gc6:8984 gc7:8984 gc8:8984 gc9:8984" 
     17fi 
     18 
     19 
    1320 
    1421export HTRC_EF_PACKAGE_HOME=`pwd` 
     
    3138fi 
    3239 
    33 source SETUP/setup-spark.bash 
     40if [ "$short_hostname" != "nema" ] ; then 
     41  source SETUP/setup-spark.bash 
     42fi 
    3443 
    3544source SETUP/setup-zookeeper.bash  
     
    4251fi 
    4352 
    44 spark_conf_slaves="$SPARK_HOME/conf/slaves"  
    45 if [ ! -f "$spark_conf_slaves" ] ; then 
    46   echo "****" 
    47   echo "* Populatig $spark_conf_slaves"  
    48   echo "* With: $SPARK_SLAVE_HOSTS" 
    49   echo "****" 
    50   for s in $SPARK_SLAVE_HOSTS ; do 
    51     echo $s >> "$spark_conf_slaves" 
    52   done 
    53 else 
    54   slaves=`cat "$spark_conf_slaves" | tr '\n' ' '` 
    55   if [ "$short_hostname" = "gsliscluster1" ] ; then 
     53if [ "$short_hostname" != "nema" ] ; then 
     54  spark_conf_slaves="$SPARK_HOME/conf/slaves"  
     55  if [ ! -f "$spark_conf_slaves" ] ; then 
    5656    echo "****" 
    57     echo "* Spark slaves: $slaves" 
     57    echo "* Populatig $spark_conf_slaves"  
     58    echo "* With: $SPARK_SLAVE_HOSTS" 
    5859    echo "****" 
     60    for s in $SPARK_SLAVE_HOSTS ; do 
     61      echo $s >> "$spark_conf_slaves" 
     62    done 
     63  else 
     64    slaves=`cat "$spark_conf_slaves" | tr '\n' ' '` 
     65    if [ "$short_hostname" = "gsliscluster1" ] ; then 
     66      echo "****" 
     67      echo "* Spark slaves: $slaves" 
     68      echo "****" 
     69    fi 
    5970  fi 
    6071fi