Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
asapo
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Joao Alvim Oliveira Dias De Almeida
asapo
Commits
8b86cbd9
Commit
8b86cbd9
authored
5 years ago
by
Sergey Yakubov
Browse files
Options
Downloads
Patches
Plain Diff
flag to use ip over ib, flag to set lightweight service nodes
parent
a0e2f188
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
deploy/docker/cluster/orchestr_config.py
+3
-2
3 additions, 2 deletions
deploy/docker/cluster/orchestr_config.py
deploy/docker/cluster/run_maxwell.sh
+21
-6
21 additions, 6 deletions
deploy/docker/cluster/run_maxwell.sh
with
24 additions
and
8 deletions
deploy/docker/cluster/orchestr_config.py
+
3
−
2
View file @
8b86cbd9
...
...
@@ -40,13 +40,14 @@ def set_parameters():
d
[
'
server_adresses
'
]
=
my_get_env
(
'
SERVER_ADRESSES
'
,
'
[
"'
+
socket
.
gethostname
()
+
'"
]
'
)
d
[
'
is_server
'
]
=
is_server
(
d
[
'
advertise_ip
'
],
d
[
'
server_adresses
'
])
if
d
[
'
is_server
'
]
==
"
true
"
:
d
[
'
bootstrap_expect_string
'
]
=
"
bootstrap_expect =
"
+
d
[
'
n_servers
'
]
d
[
'
bootstrap_expect_string
'
]
=
"
bootstrap_expect =
"
+
str
(
d
[
'
n_servers
'
]
)
else
:
d
[
'
bootstrap_expect_string
'
]
=
""
d
[
'
ib_address
'
]
=
my_get_env
(
'
IB_ADDRESS
'
,
"
none
"
)
d
[
'
nomad_alloc_dir
'
]
=
my_get_env
(
'
NOMAD_ALLOC_DIR
'
,
''
)
d
[
'
recursors
'
]
=
my_get_env
(
'
RECURSORS
'
,
'
[
"
8.8.8.8
"
]
'
)
lightweight_service_nodes
=
my_get_env
(
'
ASAPO_LIGHTWEIGHT_SERVICE_NODES
'
,
'
[]
'
)
d
[
'
is_asapo_lightweight_service_node
'
]
=
is_server
(
d
[
'
advertise_ip
'
],
lightweight_service_nodes
)
return
d
def
process_file
(
file_in
,
file_out
):
...
...
This diff is collapsed.
Click to expand it.
deploy/docker/cluster/run_maxwell.sh
+
21
−
6
View file @
8b86cbd9
#!/usr/bin/env bash
#folders
NOMAD_ALLOC_HOST_SHARED
=
/tmp/asapo/container_host_shared/nomad_alloc
SERVICE_DATA_CLUSTER_SHARED
=
/home/yakubov/asapo/asapo_cluster_shared/service_data
DATA_GLOBAL_SHARED
=
/home/yakubov/asapo/global_shared/data
#service distribution
MAX_NOMAD_SERVERS
=
3
# rest are clients
N_ASAPO_LIGHTWEIGHT_SERVICE_NODES
=
1
# where to put influx, elk, ... . Rest are receivers, brokers, mongodb
#DESY stuff
RECURSORS
=[
"
\"
131.169.40.200
\"
"
,
\"
"131.169.194.200
\"
"
]
ASAPO_USER
=
`
id
-u
`
:
`
id
-g
`
USE_IB
=
True
# use ib interface for service discovery (all communications goes thourgh this interface)
# todo: use ib only for communications with receiver (asapo discovery service should return correct ip using node meta IB_ADDRESS)
USE_IP_OVER_IB
=
true
#docker stuff
DOCKER_ENDPOINT
=
"127.0.0.1:2376"
#comment to use unix sockets
DOCKER_TLS_CA
=
/data/netapp/docker/certs/ca.pem
DOCKER_TLS_KEY
=
/data/netapp/docker/certs/
$USER
/key.pem
DOCKER_TLS_CERT
=
/data/netapp/docker/certs/
$USER
/cert.pem
#ADVERTISE_IP=
IB_ADDRESS
=
`
hostname
--short
`
-ib
IB_HOSTNAME
=
`
hostname
--short
`
-ib
IB_ADDRESS
=
`
getent hosts
$IB_HOSTNAME
|
awk
'{ print $1 }'
`
RECURSORS
=[
"
\"
131.169.40.200
\"
"
,
\"
"131.169.194.200
\"
"
]
if
[
"
$USE_IP_OVER_IB
"
==
"true"
]
;
then
ADVERTISE_IP
=
$IB_ADDRESS
fi
#prepare env variables based on the above input
N_SERVERS
=
$((
$SLURM_JOB_NUM_NODES
>
$MAX_NOMAD_SERVERS
?
$MAX_NOMAD_SERVERS
:
$SLURM_JOB_NUM_NODES
))
SERVER_ADRESSES
=
`
scontrol show hostnames
$SLURM_JOB_NODELIST
|
head
-
$N_SERVERS
|
awk
'BEGIN{printf "["} {printf "%s\"%s\"",sep,$0; sep=","} END{print "]"}'
`
ASAPO_LIGHTWEIGHT_SERVICE_NODES
=
`
scontrol show hostnames
$SLURM_JOB_NODELIST
|
head
-
$N_ASAPO_LIGHTWEIGHT_SERVICE_NODES
|
awk
'BEGIN{printf "["} {printf "%s\"%s\"",sep,$0; sep=","} END{print "]"}'
`
# make folders if not exist
mkdir
-p
$NOMAD_ALLOC_HOST_SHARED
$SERVICE_DATA_CLUSTER_SHARED
$DATA_GLOBAL_SHARED
chmod
777
$NOMAD_ALLOC_HOST_SHARED
$SERVICE_DATA_CLUSTER_SHARED
$DATA_GLOBAL_SHARED
cd
$SERVICE_DATA_CLUSTER_SHARED
mkdir
esdatadir fluentd grafana influxdb mongodb
chmod
777
*
#todo: elastic search check
mmc
=
`
cat
/proc/sys/vm/max_map_count
`
if
((
mmc < 262144
))
;
then
echo
consider increasing max_map_count - needed
for
elasticsearch
...
...
@@ -39,7 +55,6 @@ docker rm -f asapo
docker pull yakser/asapo-cluster
dockerrun
--rm
\
-u
$ASAPO_USER
\
-v
/scratch/docker/100000.100000:/scratch/docker/100000.100000
\
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment