36 lines
482 B
Bash
36 lines
482 B
Bash
#!/usr/bin/env bash
|
|
|
|
# 需要在所有的节点执行
|
|
|
|
hostnamectl set-hostname master-node
|
|
|
|
sed -i "/search/ a nameserver 223.5.5.5" /etc/resolv.conf
|
|
|
|
echo "AllowTcpForwarding yes" >> /etc/ssh/sshd_config
|
|
systemctl restart sshd
|
|
|
|
cat >> /etc/hosts << EOF
|
|
10.20.1.135 master-node
|
|
10.20.1.136 worker-1
|
|
10.20.1.137 worker-2
|
|
10.20.1.138 worker-3
|
|
10.20.1.139 storage-1
|
|
10.20.1.140 gpu-1
|
|
EOF
|
|
|
|
ping worker-1
|
|
|
|
yum clean all && yum makecache
|
|
|
|
|
|
36.138.111.244
|
|
|
|
app
|
|
|
|
7NsQTTfUB
|
|
|
|
Zyly2023**
|
|
|
|
|
|
|