日常修改

This commit is contained in:
zeaslity
2024-11-13 09:51:57 +08:00
parent dcbefdead9
commit 8c34f9018c
15 changed files with 1263 additions and 5 deletions

View File

@@ -0,0 +1,43 @@
#!/usr/bin/env bash
# 需要在所有的节点执行
hostnamectl set-hostname service-
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
134.80.124.6 master-1
134.80.124.7 master-2
134.80.124.8 master-3
134.80.124.9 worker-1
134.80.124.10 worker-2
134.80.124.11 worker-3
134.80.124.12 worker-4
134.80.124.13 worker-5
134.80.124.14 worker-6
134.80.124.15 service-1
134.80.124.16 service-2
134.80.124.17 service-3
134.80.124.18 service-4
134.80.124.19 database-1
134.80.124.20 database-2
134.80.124.21 nfs-1
134.80.124.22 nfs-2
EOF
ping worker-1
yum clean all && yum makecache
Pa_r8m#Ij0Io(b