Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
openstack-build-ubuntu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
David Johnson
openstack-build-ubuntu
Commits
4f5ccc6c
Commit
4f5ccc6c
authored
May 03, 2016
by
David Johnson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use pssh in a few key places to scale much more effectively.
parent
1709fd35
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
59 additions
and
6 deletions
+59
-6
setup-controller.sh
setup-controller.sh
+40
-3
setup-ovs.sh
setup-ovs.sh
+10
-2
setup-vpn.sh
setup-vpn.sh
+9
-1
No files found.
setup-controller.sh
View file @
4f5ccc6c
...
@@ -49,6 +49,9 @@ __openstack() {
...
@@ -49,6 +49,9 @@ __openstack() {
done
done
}
}
maybe_install_packages pssh
PSSH
=
'/usr/bin/parallel-ssh -t 0 -O StrictHostKeyChecking=no '
# Make sure our repos are setup.
# Make sure our repos are setup.
#apt-get install ubuntu-cloud-keyring
#apt-get install ubuntu-cloud-keyring
#echo "deb http://ubuntu-cloud.archive.canonical.com/ubuntu" \
#echo "deb http://ubuntu-cloud.archive.canonical.com/ubuntu" \
...
@@ -880,6 +883,9 @@ fi
...
@@ -880,6 +883,9 @@ fi
#
#
# Install the Compute service on the compute nodes
# Install the Compute service on the compute nodes
#
#
PHOSTS
=
""
mkdir
-p
$OURDIR
/pssh.setup-compute.stdout
$OURDIR
/pssh.setup-compute.stderr
if
[
-z
"
${
NOVA_COMPUTENODES_DONE
}
"
]
;
then
if
[
-z
"
${
NOVA_COMPUTENODES_DONE
}
"
]
;
then
NOVA_COMPUTENODES_DONE
=
1
NOVA_COMPUTENODES_DONE
=
1
...
@@ -890,8 +896,15 @@ if [ -z "${NOVA_COMPUTENODES_DONE}" ]; then
...
@@ -890,8 +896,15 @@ if [ -z "${NOVA_COMPUTENODES_DONE}" ]; then
# Copy the latest settings (passwords, endpoints, whatever) over
# Copy the latest settings (passwords, endpoints, whatever) over
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
admin-openrc.sh
$fqdn
:
$OURDIR
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
admin-openrc.sh
$fqdn
:
$OURDIR
$SSH
$fqdn
$DIRNAME
/setup-compute.sh
PHOSTS
=
"
$PHOSTS
-H
$fqdn
"
done
echo
"*** Setting up Cmopute service on nodes:
$PHOSTS
"
$PSSH
$PHOSTS
-o
$OURDIR
/pssh.setup-compute.stdout
\
-e
$OURDIR
/pssh.setup-compute.stderr
$DIRNAME
/setup-compute.sh
for
node
in
$COMPUTENODES
do
touch
$OURDIR
/compute-done-
${
node
}
touch
$OURDIR
/compute-done-
${
node
}
done
done
...
@@ -1148,6 +1161,10 @@ fi
...
@@ -1148,6 +1161,10 @@ fi
if
[
-z
"
${
NEUTRON_COMPUTENODES_DONE
}
"
]
;
then
if
[
-z
"
${
NEUTRON_COMPUTENODES_DONE
}
"
]
;
then
NEUTRON_COMPUTENODES_DONE
=
1
NEUTRON_COMPUTENODES_DONE
=
1
PHOSTS
=
""
mkdir
-p
$OURDIR
/pssh.setup-compute-network.stdout
\
$OURDIR
/pssh.setup-compute-network.stderr
for
node
in
$COMPUTENODES
for
node
in
$COMPUTENODES
do
do
fqdn
=
`
getfqdn
$node
`
fqdn
=
`
getfqdn
$node
`
...
@@ -1155,8 +1172,16 @@ if [ -z "${NEUTRON_COMPUTENODES_DONE}" ]; then
...
@@ -1155,8 +1172,16 @@ if [ -z "${NEUTRON_COMPUTENODES_DONE}" ]; then
# Copy the latest settings (passwords, endpoints, whatever) over
# Copy the latest settings (passwords, endpoints, whatever) over
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
$fqdn
:
$SETTINGS
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
$fqdn
:
$SETTINGS
ssh
-o
StrictHostKeyChecking
=
no
$fqdn
$DIRNAME
/setup-compute-network.sh
PHOSTS
=
"
$PHOSTS
-H
$fqdn
"
done
echo
"*** Setting up Compute network on nodes:
$PHOSTS
"
$PSSH
$PHOSTS
-o
$OURDIR
/pssh.setup-compute-network.stdout
\
-e
$OURDIR
/pssh.setup-compute-network.stderr
\
$DIRNAME
/setup-compute-network.sh
for
node
in
$COMPUTENODES
do
touch
$OURDIR
/compute-network-done-
${
node
}
touch
$OURDIR
/compute-network-done-
${
node
}
done
done
...
@@ -2092,6 +2117,10 @@ fi
...
@@ -2092,6 +2117,10 @@ fi
if
[
-z
"
${
TELEMETRY_COMPUTENODES_DONE
}
"
]
;
then
if
[
-z
"
${
TELEMETRY_COMPUTENODES_DONE
}
"
]
;
then
TELEMETRY_COMPUTENODES_DONE
=
1
TELEMETRY_COMPUTENODES_DONE
=
1
PHOSTS
=
""
mkdir
-p
$OURDIR
/pssh.setup-compute-telemetry.stdout
\
$OURDIR
/pssh.setup-compute-telemetry.stderr
for
node
in
$COMPUTENODES
for
node
in
$COMPUTENODES
do
do
fqdn
=
`
getfqdn
$node
`
fqdn
=
`
getfqdn
$node
`
...
@@ -2099,8 +2128,16 @@ if [ -z "${TELEMETRY_COMPUTENODES_DONE}" ]; then
...
@@ -2099,8 +2128,16 @@ if [ -z "${TELEMETRY_COMPUTENODES_DONE}" ]; then
# Copy the latest settings (passwords, endpoints, whatever) over
# Copy the latest settings (passwords, endpoints, whatever) over
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
$fqdn
:
$SETTINGS
scp
-o
StrictHostKeyChecking
=
no
$SETTINGS
$fqdn
:
$SETTINGS
ssh
-o
StrictHostKeyChecking
=
no
$fqdn
$DIRNAME
/setup-compute-telemetry.sh
PHOSTS
=
"
$PHOSTS
-H
$fqdn
"
done
echo
"*** Setting up Compute telemetry on nodes:
$PHOSTS
"
$PSSH
$PHOSTS
-o
$OURDIR
/pssh.setup-compute-telemetry.stdout
\
-e
$OURDIR
/pssh.setup-compute-telemetry.stderr
\
$DIRNAME
/setup-compute-telemetry.sh
for
node
in
$COMPUTENODES
do
touch
$OURDIR
/compute-telemetry-done-
${
node
}
touch
$OURDIR
/compute-telemetry-done-
${
node
}
done
done
...
...
setup-ovs.sh
View file @
4f5ccc6c
...
@@ -24,6 +24,11 @@ if [ "$HOSTNAME" != "$NETWORKMANAGER" ]; then
...
@@ -24,6 +24,11 @@ if [ "$HOSTNAME" != "$NETWORKMANAGER" ]; then
exit
0
;
exit
0
;
fi
fi
maybe_install_packages pssh
PSSH
=
'/usr/bin/parallel-ssh -t 0 -O StrictHostKeyChecking=no '
PHOSTS
=
""
mkdir
-p
$OURDIR
/pssh.setup-ovs-node.stdout
$OURDIR
/pssh.setup-ovs-node.stderr
# Do the network manager node first, no ssh
# Do the network manager node first, no ssh
echo
"*** Setting up OpenVSwitch on
$HOSTNAME
"
echo
"*** Setting up OpenVSwitch on
$HOSTNAME
"
$DIRNAME
/setup-ovs-node.sh
$DIRNAME
/setup-ovs-node.sh
...
@@ -32,9 +37,12 @@ for node in $NODES
...
@@ -32,9 +37,12 @@ for node in $NODES
do
do
[
"
$node
"
=
"
$NETWORKMANAGER
"
]
&&
continue
[
"
$node
"
=
"
$NETWORKMANAGER
"
]
&&
continue
echo
"*** Setting up OpenVSwitch on
$node
"
fqdn
=
`
getfqdn
$node
`
fqdn
=
`
getfqdn
$node
`
$SSH
$fqdn
$DIRNAME
/setup-ovs-node.sh
PHOSTS
=
"
$PHOSTS
-H
$fqdn
"
done
done
echo
"*** Setting up OpenVSwitch via pssh:
$PHOSTS
"
$PSSH
-o
$OURDIR
/pssh.setup-ovs-node.stdout
-e
$OURDIR
/pssh.setup-ovs-node.stderr
\
$PHOSTS
$DIRNAME
/setup-ovs-node.sh
exit
0
exit
0
setup-vpn.sh
View file @
4f5ccc6c
...
@@ -180,6 +180,11 @@ unset KEY_EXPIRE
...
@@ -180,6 +180,11 @@ unset KEY_EXPIRE
# Get the hosts files setup to point to the new management network
# Get the hosts files setup to point to the new management network
# and setup the VPN on the clients.
# and setup the VPN on the clients.
#
#
maybe_install_packages pssh
PSSH
=
'/usr/bin/parallel-ssh -t 0 -O StrictHostKeyChecking=no '
PHOSTS
=
""
mkdir
-p
$OURDIR
/pssh.setup-vpn.stdout
$OURDIR
/pssh.setup-vpn.stderr
for
node
in
$NEWVPNNODES
for
node
in
$NEWVPNNODES
do
do
[
"
$node
"
=
"
$NETWORKMANAGER
"
]
&&
continue
[
"
$node
"
=
"
$NETWORKMANAGER
"
]
&&
continue
...
@@ -189,7 +194,10 @@ do
...
@@ -189,7 +194,10 @@ do
scp
-p
-o
StrictHostKeyChecking
=
no
\
scp
-p
-o
StrictHostKeyChecking
=
no
\
/etc/openvpn/ca.crt
$KEY_DIR
/
$node
.crt
$KEY_DIR
/
$node
.key
\
/etc/openvpn/ca.crt
$KEY_DIR
/
$node
.crt
$KEY_DIR
/
$node
.key
\
$fqdn
:
$OURDIR
$fqdn
:
$OURDIR
$SSH
$fqdn
$DIRNAME
/setup-vpn-client.sh
PHOSTS
=
"
$PHOSTS
-H
$fqdn
"
done
done
$PSSH
-o
$OURDIR
/pssh.setup-vpn.stdout
-e
$OURDIR
/pssh.setup-vpn.stderr
\
$PHOSTS
$DIRNAME
/setup-vpn-client.sh
exit
0
exit
0
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment