Skip to content

Commit f7a3667

Browse files
committed
#18 dynamic ip addr assignment into config files based on virt provider
1 parent cbd080f commit f7a3667

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+84
-85
lines changed

clusters/vc/cfg/vc1/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server: vcsvc
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%

clusters/vc/cfg/vc2/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.77
1+
%VCDB%

clusters/vc/cfg/vcaltdb/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%

clusters/vc/cfg/vcbuild/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%

clusters/vc/cfg/vcdb/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%

clusters/vc/cfg/vcfs/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
#
2-
/home/vagrant 192.168.56.0/24(rw,no_root_squash,security_label,subtree_check,async)
2+
/home/vagrant %VC-0NET%/24(rw,no_root_squash,security_label,subtree_check,async)
33
#
4-
/home/vagrant/common/home 192.168.56.0/24(rw,no_root_squash,security_label,sync)
4+
/home/vagrant/common/home %VC-0NET%/24(rw,no_root_squash,security_label,sync)
55
#
6-
/home/vagrant/common/repos 192.168.56.0/24(rw,no_root_squash,security_label,async)
7-
/home/vagrant/common/root 192.168.56.0/24(rw,no_root_squash,security_label,async)
8-
/home/vagrant/common/var/log/rsyslog 192.168.56.0/24(rw,no_root_squash,security_label,subtree_check,async)
9-
/home/vagrant/common/var/log/slurm 192.168.56.0/24(rw,no_root_squash,security_label,subtree_check,async)
6+
/home/vagrant/common/repos %VC-0NET%/24(rw,no_root_squash,security_label,async)
7+
/home/vagrant/common/root %VC-0NET%/24(rw,no_root_squash,security_label,async)
8+
/home/vagrant/common/var/log/rsyslog %VC-0NET%/24(rw,no_root_squash,security_label,subtree_check,async)
9+
/home/vagrant/common/var/log/slurm %VC-0NET%/24(rw,no_root_squash,security_label,subtree_check,async)
1010

11-
/home/vx 192.168.56.0/24(rw,no_root_squash,security_label,subtree_check,async)
11+
/home/vx %VC-0NET%/24(rw,no_root_squash,security_label,subtree_check,async)
1212

Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
RPCBIND_ARGS="-h 192.168.56.79 -s"
1+
RPCBIND_ARGS="-h %VCFS% -s"
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.76
1+
%VCALTDB%

clusters/vc/cfg/vcgate/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.64
1+
%VCSCHED%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.77
1+
%VCDB%

clusters/vc/cfg/vclogin/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.64
1+
%VCSCHED%

clusters/vc/cfg/vcsched/rootfs/etc/chrony.conf.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
appendwhere: # Generated by NetworkManager
2-
appendwhat: nameserver 192.168.56.71
2+
appendwhat: nameserver %VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.71
1+
%VCSVC%

clusters/vc/cfg/vcsvc/rootfs/etc/chrony.conf.server.%VCSVC%

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ rtcsync
2323
#minsources 2
2424

2525
# Allow NTP client access from local network.
26-
allow 192.168.56.0/24
26+
allow %VC-0NET%/24
2727
allow 127.0.0.1
28-
bindaddress 192.168.56.71
28+
bindaddress %VCSVC%
2929

3030
# Serve time even if not synchronized to a time source.
3131
#local stratum 10

clusters/vc/cfg/vcsvc/rootfs/etc/dnsmasq.conf.%VCSVC%

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
listen-address=::1,127.0.0.1,192.168.56.71
1+
listen-address=::1,127.0.0.1,%VCSVC%
22
except-interface=eth0
33
no-dhcp-interface=eth1,eth0
44
domain-needed
@@ -9,5 +9,5 @@ user=root
99
group=root
1010
domain=tc
1111
local=/tc/
12-
addn-hosts=/etc/hosts~
12+
addn-hosts=/etc/hosts.vc
1313
read-ethers

clusters/vc/common/etc/chrony.conf.client.%VCSVC%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Use local server
2-
server 192.168.56.71
2+
server %VCSVC%
33

44
# Record the rate at which the system clock gains/losses time.
55
driftfile /var/lib/chrony/drift

clusters/vc/common/etc/chrony.conf.server.%VC-NET%

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ rtcsync
2323
#minsources 2
2424

2525
# Allow NTP client access from local network.
26-
allow 192.168.56/24
26+
allow %VC-0NET%/24
2727
allow 127.0.0.1
28-
bindaddress 192.168.56.71
28+
bindaddress %VCSVC%
2929

3030
# Serve time even if not synchronized to a time source.
3131
#local stratum 10

clusters/vc/common/etc/hosts.%VC-NET%

+15-15
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,24 @@
2323
##
2424

2525
### vx - conjoined virtual minicluster
26-
192.168.56.49 vxsched.tc vxsched vxsched.test-cluster vxsched.testcluster
27-
192.168.56.50 vx1.tc vx1 vx1.test-cluster vx1.testcluster
28-
192.168.56.51 vx2.tc vx2 vx2.test-cluster vx2.testcluster
29-
192.168.56.52 vxlogin.tc vxlogin vxlogin.test-cluster vxlogin.testcluster
26+
%VX-NET%.49 vxsched.tc vxsched vxsched.test-cluster vxsched.testcluster
27+
%VX-NET%.50 vx1.tc vx1 vx1.test-cluster vx1.testcluster
28+
%VX-NET%.51 vx2.tc vx2 vx2.test-cluster vx2.testcluster
29+
%VX-NET%.52 vxlogin.tc vxlogin vxlogin.test-cluster vxlogin.testcluster
3030
### vx
3131

3232
### vc - virtual cluster, fully populated
33-
192.168.56.64 vcsched.tc vcsched vcsched.test-cluster vcsched.testcluster
34-
192.168.56.65 vc1.tc vc1 vc1.test-cluster vc1.testcluster
35-
192.168.56.66 vc2.tc vc2 vc2.test-cluster vc2.testcluster
36-
37-
192.168.56.69 vcgate.tc vcgate vcgate.test-cluster vcgate.testcluster vc-gate.tc vc-gate vc-gate.test-cluster vc-gate.testcluster gate.tc gate.test-cluster gate.testcluster
38-
192.168.56.71 vcsvc.tc vcsvc vcsvc.test-cluster vcsvc.testcluster vcloghost vcloghost.tc vcloghost.test-cluster vcloghost.testcluster
39-
192.168.56.73 vclogin.tc vclogin vclogin.test-cluster vclogin.testcluster
40-
192.168.56.75 vcbuild.tc vcbuild vcbuild.test-cluster vcbuild.testcluster
41-
192.168.56.76 vcaltdb.tc vcaltdb vcaltdb.test-cluster vcaltdb.testcluster
42-
192.168.56.77 vcdb.tc vcdb vcdb.test-cluster vcdb.testcluster
43-
192.168.56.79 vcfs.tc vcfs vcfs.test-cluster vcfs.testcluster
33+
%VC-NET%.64 vcsched.tc vcsched vcsched.test-cluster vcsched.testcluster
34+
%VC-NET%.65 vc1.tc vc1 vc1.test-cluster vc1.testcluster
35+
%VC-NET%.66 vc2.tc vc2 vc2.test-cluster vc2.testcluster
36+
37+
%VC-NET%.73 vclogin.tc vclogin vclogin.test-cluster vclogin.testcluster
38+
%VC-NET%.74 vcgate.tc vcgate vcgate.test-cluster vcgate.testcluster vc-gate.tc vc-gate vc-gate.test-cluster vc-gate.testcluster gate.tc gate.test-cluster gate.testcluster
39+
%VC-NET%.75 vcbuild.tc vcbuild vcbuild.test-cluster vcbuild.testcluster
40+
%VC-NET%.76 vcaltdb.tc vcaltdb vcaltdb.test-cluster vcaltdb.testcluster
41+
%VC-NET%.77 vcdb.tc vcdb vcdb.test-cluster vcdb.testcluster
42+
%VC-NET%.78 vcsvc.tc vcsvc vcsvc.test-cluster vcsvc.testcluster vcloghost vcloghost.tc vcloghost.test-cluster vcloghost.testcluster
43+
%VC-NET%.79 vcfs.tc vcfs vcfs.test-cluster vcfs.testcluster
4444
### vc
4545

4646
# following line is used as a marker for hosts.append; be sure it is unique and terminal
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
default 0.0.0.0
22
loopback 127.0.0.0
33
link-local 169.254.0.0
4-
vc-net 192.168.56 virtual-cluster-net test-cluster-net
4+
vc-net %VC-0NET% virtual-cluster-net virtualcluster-net test-cluster-net vx-net
55
nat-ext-net 10.0.2.0 nat-external

clusters/vc/common/etc/slurm/slurm.conf.template.%VCSCHED%

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
SlurmctldHost=vcsched(192.168.56.64)
1+
SlurmctldHost=vcsched(%VCSCHED%)
22
AuthType=auth/munge
33
CryptoType=crypto/munge
44
DisableRootJobs=NO
@@ -33,7 +33,7 @@ MpiDefault=pmi2
3333
#PrivateData=jobs
3434
ProctrackType=proctrack/cgroup
3535
#ProctrackType=proctrack/pgid
36-
Prolog=/etc/slurm/prolog.d/*
36+
#Prolog=/etc/slurm/prolog.d/*.sh
3737
PrologFlags=Alloc,X11
3838
#CliFilterPlugins=x11
3939
X11Parameters=local_xauthority,use_raw_hostname
@@ -94,7 +94,7 @@ PrologEpilogTimeout=180
9494

9595
#MaxMemPerCPU=0
9696
#SchedulerTimeSlice=30
97-
SchedulerParameters=bf_continue,bf_interval=240,bf_max_job_user_part=10,bf_max_job_test=3000,default_queue_depth=3600,allow_zero_lic
97+
SchedulerParameters=bf_continue,bf_interval=240,bf_max_job_user_part=10,bf_max_job_test=3000,default_queue_depth=3600,allow_zero_lic,nohold_on_prolog_fail
9898
SchedulerType=sched/backfill
9999
SelectType=select/cons_res
100100
SelectTypeParameters=CR_CORE

clusters/vc/common/etc/slurm/slurmdbd.conf.%VCDB%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
DbdAddr=192.168.56.77
1+
DbdAddr=%VCDB%
22
DbdHost=vcdb
33
SlurmUser=root
44
DebugFlags=DB_ASSOC,DB_EVENT,DB_QUERY
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.65
1+
%VC1%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.66
1+
%VC2%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.75
1+
%VCBUILD%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.77
1+
%VCDB%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.79
1+
%VCFS%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.73
1+
%VCLOGIN%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.64
1+
%VCSCHED%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.71
1+
%VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.71
1+
%VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.77
1+
%VCDB%
+6-7
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,31 @@
11
#
22
all: LOCAL : allow
33
all: 127.0.0.1 : allow
4-
all: 192.168.56. : allow
5-
all: 192.168.56. : allow
4+
all: %VC-NET%. : allow
65

76
rpcbind: LOCAL : allow
87
rpcbind: 127.0.0.1 : allow
9-
rpcbind: 192.168.56. : allow
8+
rpcbind: %VC-NET%. : allow
109
rpcbind: ALL : deny
1110

1211
statd: LOCAL : allow
1312
statd: 127.0.0.1 : allow
14-
statd: 192.168.56. : allow
13+
statd: %VC-NET%. : allow
1514
statd: ALL : deny
1615

1716
mountd: LOCAL : allow
1817
mountd: 127.0.0.1 : allow
19-
mountd: 192.168.56. : allow
18+
mountd: %VC-NET%. : allow
2019
mountd: ALL : deny
2120

2221
lockd: LOCAL : allow
2322
lockd: 127.0.0.1 : allow
24-
lockd: 192.168.56. : allow
23+
lockd: %VC-NET%. : allow
2524
lockd: ALL : deny
2625

2726
sshd: LOCAL : allow
2827
sshd: 127.0.0.1 : allow
29-
sshd: 192.168.56. : allow
28+
sshd: %VC-NET%. : allow
3029
sshd: ALL : deny
3130

3231
all: ALL : deny

clusters/vx/common/etc/slurm.vx/slurm.conf.template.%VXSCHED%

+3-3
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ JobRequeue=1
1818
PreemptMode=REQUEUE
1919
PreemptType=preempt/qos
2020
PreemptExemptTime=30:00
21-
JobSubmitPlugins=lua
21+
#JobSubmitPlugins=lua
2222
#KillOnBadExit=0
2323
#LaunchType=launch/slurm
2424
#Licenses=foo*4,bar
@@ -33,7 +33,7 @@ MpiDefault=pmi2
3333
#PrivateData=jobs
3434
ProctrackType=proctrack/cgroup
3535
#ProctrackType=proctrack/pgid
36-
Prolog=/etc/slurm/prolog.d/*
36+
#Prolog=/etc/slurm/prolog.d/*.sh
3737
PrologFlags=Alloc,X11
3838
#CliFilterPlugins=x11
3939
X11Parameters=local_xauthority,use_raw_hostname
@@ -94,7 +94,7 @@ PrologEpilogTimeout=180
9494

9595
#MaxMemPerCPU=0
9696
#SchedulerTimeSlice=30
97-
SchedulerParameters=bf_continue,bf_interval=240,bf_max_job_user_part=10,bf_max_job_test=3000,default_queue_depth=3600,allow_zero_lic
97+
SchedulerParameters=bf_continue,bf_interval=240,bf_max_job_user_part=10,bf_max_job_test=3000,default_queue_depth=3600,allow_zero_lic,nohold_on_prolog_fail
9898
SchedulerType=sched/backfill
9999
SelectType=select/cons_res
100100
SelectTypeParameters=CR_CORE

clusters/vx/common/etc/slurm.vx/slurmdbd.conf.%VCDB%

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
DbdAddr=192.168.56.77
1+
DbdAddr=%VCDB%
22
DbdHost=vcdb
33
SlurmUser=root
44
DebugFlags=DB_ASSOC,DB_EVENT,DB_QUERY
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.75
1+
%VCBUILD%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.77
1+
%VCDB%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.79
1+
%VCFS%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.71
1+
%VCSVC%
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
192.168.56.71
1+
%VCSVC%

0 commit comments

Comments
 (0)