Proxmox setup notes.

master
Jeff Moe 7 years ago
parent bd03bad5dc
commit 58464c59b0

@ -28,72 +28,55 @@ cd /etc ; git add . ; git commit -a -m 'Initial Proxmox configuration'
#
# XXX Set up vmbr0 via web interface.
#
# Netwok
# sf-004 (host) --> System --> Network
# Fix subnet mask, IP in web gui.
# Create --> Linux Bridge:
# vmbr0
# XXX best way for this server? No subnet.
# Network
# Bridges ? XXX
# Set up static IPs on each interface in Proxmox web gui
#
# Set up ethernet ports
# XXX check name Disable enp2s0 (Autostart no)
# set up vmbr0 to the main IP, gateway, etc.
# Create Linux Bridge in web interface
# vmbr0
#XXX THIS ISN'T CORRECT IP
# 174.128.244.192/26
# 255.255.255.192
# Autostart
# VLAN Aware
# Bridge: enp2s0
# Comment Main bridge
#
# Set up 10.3.1.0 and 10.99.1.0 networks statically
# on secondary ethernet interfaces
# Reboot! sf-004 (host) --> Restart
cd /etc ; git add . ; git commit -a -m 'Configure ethernet addresses'
# Reboot!
# Configure Corosync
# Set up hosts
# XXX MAKE SURE NEW NODES GET ADDED TO EXISTING SERVER /etc/hosts
cat > /etc/hosts <<EOF
127.0.0.1 localhost
# The following lines are desirable for IPv6 capable hosts
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
10.22.22.1 sf-001.forksand.com sf-001
10.22.22.2 sf-002.forksand.com sf-002
10.22.22.3 sf-003.forksand.com sf-003
10.22.22.4 sf-004.forksand.com sf-004
10.3.1.1 sf-001-coro1
10.3.1.2 sf-002-coro1
10.3.1.3 sf-003-coro1
10.3.1.4 sf-004-coro1
10.3.2.1 sf-001-coro2
10.3.2.2 sf-002-coro2
10.3.2.3 sf-003-coro2
10.3.2.4 sf-004-coro2
10.22.22.1 sf-001-dmz
10.22.22.2 sf-002-dmz
10.22.22.3 sf-003-dmz
10.22.22.4 sf-004-dmz
10.68.68.1 sf-001-migrate
10.68.68.2 sf-002-migrate
10.68.68.3 sf-003-migrate
10.68.68.4 sf-004-migrate
10.99.1.1 sf-001-file1
10.99.1.2 sf-002-file1
10.99.1.3 sf-003-file1
10.99.1.4 sf-004-file1
10.99.2.1 sf-001-file2
10.99.2.2 sf-002-file2
10.99.2.3 sf-003-file2
10.99.2.4 sf-004-file2
10.254.254.1 sf-001-admin
10.254.254.2 sf-002-admin
10.254.254.3 sf-003-admin
10.254.254.4 sf-004-admin
EOF
cd /etc ; git commit -m 'Add hosts' hosts
# Test cluster ping
echo "Testing coro1 pings"
for i in sf-001-coro1 sf-002-coro1 sf-003-coro1 sf-004-coro1
@ -103,27 +86,21 @@ echo "Testing coro2 pings"
for i in sf-001-coro2 sf-002-coro2 sf-003-coro2 sf-004-coro2
do ping -q -c1 $i
done
echo "Testing file1 pings"
for i in sf-001-file1 sf-002-file1 sf-003-file1 sf-004-file1
do ping -q -c1 $i
done
echo "Testing file2 pings"
for i in sf-001-file2 sf-002-file2 sf-003-file2 sf-004-file2
do ping -q -c1 $i
done
echo "Testing migrate pings"
for i in sf-001-migrate sf-002-migrate sf-003-migrate sf-004-migrate
do ping -q -c1 $i
done
echo "Testing DMZ pings"
for i in sf-001-dmz sf-002-dmz sf-003-dmz sf-004-dmz
do ping -q -c1 $i
done
echo "Testing admin pings"
for i in sf-001-admin sf-002-admin sf-003-admin sf-004-admin
for i in sf-001 sf-002 sf-003 sf-004
do ping -q -c1 $i
done
# XXX set up ssh keys
# Add them to:
cat /root/.ssh/id_rsa.pub
# /etc/pve/priv/authorized_keys
cd /etc ; git commit -m 'Set up ssh keys' /etc/pve/priv/authorized_keys
# Test ssh
echo "Testing coro1 ssh"
for i in sf-001-coro1 sf-002-coro1 sf-003-coro1 sf-004-coro1
@ -133,14 +110,6 @@ echo "Testing coro2 ssh"
for i in sf-001-coro2 sf-002-coro2 sf-003-coro2 sf-004-coro2
do ssh $i hostname
done
echo "Testing file1 ssh"
for i in sf-001-file1 sf-002-file1 sf-003-file1 sf-004-file1
do ssh $i hostname
done
echo "Testing file2 ssh"
for i in sf-001-file2 sf-002-file2 sf-003-file2 sf-004-file2
do ssh $i hostname
done
echo "Testing migrate ssh"
for i in sf-001-migrate sf-002-migrate sf-003-migrate sf-004-migrate
do ssh $i hostname
@ -154,39 +123,24 @@ echo "Testing coro2 ssh by IP"
for i in 10.3.2.1 10.3.2.2 10.3.2.3 10.3.2.4
do ssh $i hostname
done
#echo "Testing file1 ssh by IP"
#for i in 10.99.1.1 10.99.1.2 10.99.1.3 10.99.1.4
#do ssh $i hostname
#done
#echo "Testing file2 ssh by IP"
#for i in 10.99.2.1 10.99.2.2 10.99.2.3 10.99.2.4
#do ssh $i hostname
#done
echo "Testing migrate ssh by IP"
for i in 10.68.68.1 10.68.68.2 10.68.68.3 10.68.68.4
do ssh $i hostname
done
# Note this is needed on at least one of the SharkTech servers or
# you get bad UDP checksums
# Also set to correct ethernet device
# XXX CHECK
# ethtool -K enp3s0 gso off
# ethtool --offload enp3s0 rx off tx off
# ethtool -K enp4s0 gso off
# ethtool --offload enp4s0 rx off tx off
# Run this on JUST ONE NODE, sf-001, to get the cluster started:
# XXX add --ring1 ?
pvecm create sharkfork --bindnet0_addr 10.3.1.1 --ring0_addr sf-001-coro1
pvecm create sharkfork -bindnet0_addr 10.3.1.1 -ring0_addr 10.3.1.1 -bindnet1_addr 10.3.2.1 -ring1_addr 10.3.2.1
# Run this on sf-002 sf-003 sf-004
# XXX add --ring1 ?
# XXX which add IP ?
pvecm add 10.3.1.2 --ring0_addr sf-001-coro1
pvecm add 10.3.1.3 --ring0_addr sf-001-coro1
pvecm add 10.3.1.4 --ring0_addr sf-001-coro1
# Run on sf-002
pvecm add 10.3.1.1 --ring0_addr 10.3.1.2 --ring1_addr 10.3.2.2 --use_ssh
# Run on sf-003
pvecm add 10.3.1.1 --ring0_addr 10.3.1.3 --ring1_addr 10.3.2.3 --use_ssh
# Run on sf-004
pvecm add 10.3.1.1 --ring0_addr 10.3.1.4 --ring1_addr 10.3.2.4 --use_ssh
# Check status
pvecm status
pvecm nodes
@ -212,4 +166,30 @@ pvecm nodes
# Add servers:
# 208.67.222.222 208.67.220.220 37.235.1.174
#
# XXX Ceph
echo "Testing file1 pings"
for i in sf-001-file1 sf-002-file1 sf-003-file1 sf-004-file1
do ping -q -c1 $i
done
echo "Testing file2 pings"
for i in sf-001-file2 sf-002-file2 sf-003-file2 sf-004-file2
do ping -q -c1 $i
done
echo "Testing file1 ssh"
for i in sf-001-file1 sf-002-file1 sf-003-file1 sf-004-file1
do ssh $i hostname
done
echo "Testing file2 ssh"
for i in sf-001-file2 sf-002-file2 sf-003-file2 sf-004-file2
do ssh $i hostname
done
#echo "Testing file1 ssh by IP"
#for i in 10.99.1.1 10.99.1.2 10.99.1.3 10.99.1.4
#do ssh $i hostname
#done
#echo "Testing file2 ssh by IP"
#for i in 10.99.2.1 10.99.2.2 10.99.2.3 10.99.2.4
#do ssh $i hostname
#done

Loading…
Cancel
Save