Skip to content

Commit 1e343c6

Browse files
committed
updated singularity examples
1 parent f00f377 commit 1e343c6

File tree

3 files changed

+37
-65
lines changed

3 files changed

+37
-65
lines changed
Lines changed: 20 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
Bootstrap: docker
1+
Bootstrap: localimage
22

3-
From: ubuntu
3+
From: ./demo-template.sif
44

55

66
%help
77

8-
Supermagic is a MPI sanity check - https://github.com/hpc/supermagic
8+
Supermagic is a MPI sanity check - https://github.com/hpc/supermagic
99

1010
#%setup
1111

@@ -20,57 +20,24 @@ Supermagic is a MPI sanity check - https://github.com/hpc/supermagic
2020
Version v1.0
2121

2222

23-
#%environment
23+
%environment
24+
25+
LD_LIBRARY_PATH=/usr/lib/libibverbs:$LD_LIBRARY_PATH
2426

2527

2628
%post
2729

28-
echo "Creating required mount points"
29-
mkdir /scratch
30-
mkdir /checkpoint
31-
32-
echo "Installing Development Tools group"
33-
apt-get update && apt-get install -y --no-install-recommends \
34-
apt-utils \
35-
build-essential \
36-
wget \
37-
curl \
38-
git \
39-
libopenblas-dev \
40-
libcurl4-openssl-dev \
41-
libfreetype6-dev \
42-
libpng-dev \
43-
libzmq3-dev \
44-
python-pip \
45-
pkg-config \
46-
python-dev \
47-
python-setuptools \
48-
rsync \
49-
software-properties-common \
50-
unzip \
51-
vim \
52-
zip \
53-
zlib1g-dev
54-
apt-get clean
55-
56-
echo "Installing OpenMPI into container..."
57-
#git clone https://github.com/open-mpi/ompi.git
58-
wget https://download.open-mpi.org/release/open-mpi/v4.0/openmpi-4.0.0.tar.gz
59-
tar -zxf openmpi-4.0.0.tar.gz
60-
cd openmpi-4.0.0
61-
#./autogen.pl
62-
./configure --prefix=/usr/local
63-
make
64-
make install
65-
# /usr/local/bin/mpicc examples/ring_c.c -o /usr/bin/mpi_ring
66-
67-
68-
#%runscript
69-
70-
# echo "Rooooar!"
71-
# echo "Arguments received: $*"
72-
# exec echo "$@"
73-
74-
#%test
75-
76-
# /usr/local/bin/mpirun --allow-run-as-root /usr/bin/mpi_test
30+
echo "Installing Supermagic"
31+
git clone https://github.com/hpc/supermagic.git
32+
cd supermagic
33+
make MPICC=cc
34+
cp -p supermagic /usr/bin/
35+
36+
%runscript
37+
38+
/usr/bin/supermagic
39+
40+
%test
41+
42+
#/usr/local/bin/mpirun --allow-run-as-root /usr/bin/supermagic
43+
/usr/local/bin/mpirun /usr/bin/supermagic

user-training/examples/singularity/demo-03.def

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Bootstrap: localimage
22

3-
From: ./demo-template.simg
3+
From: ./demo-template.sif
44

55

66
%help
@@ -82,5 +82,3 @@ This is a help message for the container
8282
%test
8383

8484
/usr/local/bin/mpirun --allow-run-as-root /usr/bin/mpi_test
85-
86-

user-training/examples/singularity/demo-mpich.def renamed to user-training/examples/singularity/demo-openmpi.def

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
Bootstrap: docker
22

3-
From: ubuntu
3+
From: ubuntu
44

55

66
%help
77

8-
Development Enviroment with OpenMPI support
8+
Development Environment with OpenMPI support
99

1010
#%setup
1111

@@ -23,12 +23,15 @@ Development Enviroment with OpenMPI support
2323

2424
echo "Creating required mount points"
2525
mkdir /scratch
26-
mkdir /checkpoint
26+
mkdir /chk
2727

28-
echo "Installing Development Tools group"
28+
echo "Installing Development Environment"
2929
apt-get update && apt-get install -y --no-install-recommends \
3030
apt-utils \
3131
build-essential \
32+
libtool \
33+
autoconf \
34+
automake \
3235
wget \
3336
curl \
3437
git \
@@ -47,24 +50,28 @@ Development Enviroment with OpenMPI support
4750
vim \
4851
zip \
4952
zlib1g-dev
50-
apt-get clean
5153

5254
# IB MLNX OFED
55+
echo "Installing Infiniband Libraries and Utils"
5356
apt-get install -y dkms infiniband-diags libibverbs* ibacm librdmacm* libmlx4* libmlx5* mstflint libibmad.* libibumad* opensm srptools librdmacm-dev rdmacm-utils ibverbs-utils perftest vlan ibutils
54-
apt-get install -y libtool autoconf automake build-essential ibutils ibverbs-utils rdmacm-utils infiniband-diags perftest librdmacm-dev libibverbs-dev libmlx4-1 numactl libnuma-dev autoconf automake gcc g++ git libtool pkg-config
57+
apt-get install -y ibutils ibverbs-utils rdmacm-utils infiniband-diags perftest librdmacm-dev libibverbs-dev libmlx4-1 numactl libnuma-dev
5558
apt-get install -y libnl-3-200 libnl-route-3-200 libnl-route-3-dev libnl-utils
5659

57-
echo "Installing OpenMPI into container..."
60+
# Installing OpenMPI
61+
echo "Installing OpenMPI"
5862
wget https://download.open-mpi.org/release/open-mpi/v4.0/openmpi-4.0.0.tar.gz
5963
tar -zxf openmpi-4.0.0.tar.gz
6064
cd openmpi-4.0.0
6165
./configure --prefix=/usr/local
6266
make
6367
make install
64-
# /usr/local/bin/mpicc examples/ring_c.c -o /usr/bin/mpi_ring
68+
/usr/local/bin/mpicc examples/ring_c.c -o /usr/bin/mpi_ring
6569

70+
# Cleaning
71+
apt-get clean
72+
rm -fr /openmpi-4.0.0.tar.gz openmpi-4.0.0
6673

67-
%environment
74+
%environment
6875
LD_LIBRARY_PATH=/usr/lib/libibverbs:$LD_LIBRARY_PATH
6976

7077

0 commit comments

Comments
 (0)