wiki:adherelinux/drbl_mpi/20110701

drbl-mpi

利用前人的code,作修改如下

#!/bin/bash

# Program: # Install drbl-mpich2 # Author: # adherelinux # Version: # 1.0 # History: # 2011/07/01

# [Path]

Work_Home="/opt/drbl-mpich2"
Work_Path="/opt/drbl-mpich2/sbin"
Now_Path="$(dirname $0)"
PATH=${PATH}:$Work_Path:${Now_Path}/sbin

# Source]

source $Now_Path/sbin/functions_drbl_mpich2

# [Main]

check_root

jude="no"
if [ -e $Work_Home ]; then

echo -e "\nThis system already has drbl-mpich2."
read -p "Do you want to install, again (yes/no): " jude

if [ $jude == "yes" ]; then

rm -fr $Work_Home

else

echo "Exit" exit

fi

fi

# = 1. Create /opt/drbl-mpich2 and copy file =

mkdir -p $Work_Home
mkdir $Work_Home/etc
mkdir $Work_Home/.tmp
cp -fr $Now_Path/sbin $Work_Home/
cp -fr $Now_Path/conf $Work_Home/
cp -fr $Now_Path/uninstall.sh $Work_Home/

# = 2. Move war =
#mv drbl-mpich2.war $Work_Home/

# = 4. Install completion =

echo ""
echo "[drbl-mpich2 install completion]"
echo "Please go to /opt/drbl-mpich2/ to check !!!"

Last modified 13 years ago Last modified on Jul 1, 2011, 4:01:26 PM