Skip to content

Commit

Permalink
corrections to mpi mca params file, spot market use for AWS demo
Browse files Browse the repository at this point in the history
  • Loading branch information
exby committed Jun 16, 2017
1 parent 11ecb1e commit 40436f1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
9 changes: 8 additions & 1 deletion 3.7.1/demos/aws/spinup-new-ec2.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
#
# instead of paying a whopping $1.59 per hour for a c4.8large virtual machine, let's save money by using Spot instances!
# aws ec2 describe-spot-price-history --instance-types c4.8xlarge --availability-zone us-west-2b --start-time 2017-05-30T16:00:00 --end-time 2017-05-30T18:00:00
#
docker-machine -D create --driver amazonec2 \
--amazonec2-access-key $AWS_ACCESS_KEY_ID \
--amazonec2-secret-key $AWS_SECRET_ACCESS_KEY \
--amazonec2-vpc-id $AWS_VPC_ID \
--amazonec2-region us-west-2 \
--amazonec2-instance-type c4.8xlarge \
--amazonec2-root-size 60 \
--amazonec2-zone b wrf-LargeEC2
--amazonec2-request-spot-instance \
--amazonec2-spot-price 0.625 \
--amazonec2-zone b \
wrf-LargeEC2
2 changes: 1 addition & 1 deletion 3.7.1/ncar-wrf/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ RUN chmod +x /wrf/run-wrf \
# set up ssh configuration
COPY ssh_config /root/.ssh/config
RUN mkdir -p /root/.openmpi
COPY default-mca-params.conf /root/.openmpi
COPY default-mca-params.conf /root/.openmpi/mca-params.conf
RUN yum clean all \
&& /wrf/docker-clean \
&& mkdir -p /var/run/sshd \
Expand Down
1 change: 1 addition & 0 deletions 3.7.1/ncar-wrf/default-mca-params.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
btl=tcp,self
plm_rsh_no_tree_spawn=1
btl_base_warn_component_unused=0
pml=ob1
7 changes: 3 additions & 4 deletions 3.7.1/ncar-wrf/run-wrf
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ echo "doing real"
fi

# Command for real
./real.exe
./real.exe

# Check success
ls -ls wrfinput_d01
Expand Down Expand Up @@ -290,10 +290,9 @@ for key in "${!ary[@]}"; do echo "${ary[$key]} slots=${process_per_host}" >> /wr
# Command for openmpi wrf in Docker world
cp namelist.nocolons namelist.input
#
# see /root/.openmpi/default-mca-params.conf
# see /root/.openmpi/mca-params.conf
# time mpirun --allow-run-as-root -hostfile /wrf/hosts --mca pml ob1 -np $num_procs --mca btl self,tcp --mca btl_tcp_if_include $iface ./wrf.exe
# time mpirun --allow-run-as-root -hostfile /wrf/hosts --mca pml ob1 -np $num_procs --mca btl_tcp_if_include $iface ./wrf.exe
time mpirun --allow-run-as-root -hostfile /wrf/hosts --mca pml ob1 --mca btl_base_warn_component_unused 0 -np $num_procs --mca btl_tcp_if_include $iface ./wrf.exe
time mpirun --allow-run-as-root -hostfile /wrf/hosts -np $num_procs --mca btl_tcp_if_include $iface ./wrf.exe

# Check success
ls -ls /$OUTPUT_DIR/wrfo*
Expand Down

0 comments on commit 40436f1

Please sign in to comment.