当前位置:网站首页>Shell 集群免密关机
Shell 集群免密关机
2022-04-22 00:58:00 【AdamShyly】
准备两个shell脚本:shut、shutall,并且配置好集群的ssh免密
[hadoop@hadoop102 bin]$ pwd
/home/hadoop/bin
[hadoop@hadoop102 bin]$ cat shut
#!/bin/bash
PASSWORD=你定义的密码
echo $PASSWORD | sudo -S halt -p
[hadoop@hadoop102 bin]$ cat shutall
#!/bin/bash
for host in hadoop103 hadoop104
do
ssh $host /home/hadoop/bin/shut
done
shut
然后将这两个脚本分发到集群中,需要注意的是shutall脚本中的for循环遍历的是除了本机以外的其他集群主机
版权声明
本文为[AdamShyly]所创,转载请带上原文链接,感谢
https://blog.csdn.net/Adam_captain/article/details/124319497
边栏推荐
- [observation] purple light cloud: homogeneous hybrid cloud is upgraded to distributed cloud, making cloud and intelligence everywhere
- Huawei cloud hosting experience: your software storage expert
- 作文以记之 ~ 二叉树的中序遍历
- No more simple intention lock
- Cloud native enthusiast weekly: looking for open source alternatives to netlify
- Finally, wechat scanning code login is completed. It's really fragrant..
- Draw2d custom dashboard
- 05 Lua 控制结构
- Introduction notes to PHP zero Foundation (11): String
- Five tips for novices to do cross-border e-commerce in 2022
猜你喜欢

Observe cloud landing in Alibaba cloud computing nest and build a new ISV ecosystem

Cloud native enthusiast weekly: looking for open source alternatives to netlify

Addition, deletion, modification and query of advanced MySQL data (DML)

观测云登陆阿里云计算巢,共建ISV新生态

Probe architecture of open source project kindling based on ebpf Technology

精彩回顾 | DEEPNOVA x Iceberg Meetup Online《基于Iceberg打造实时数据湖》

Mysql database common sense storage engine

Matlab: simulate the control system and use ode45 to solve the LC circuit

. net core enterprise wechat web page authorization login

2022年4月21日,第14天
随机推荐
The video course "vite Learning Guide - webify deployment project based on Tencent cloud" was launched "cloud + community"
Filter the eloquent model using multiple optional filters
Redis个人笔记:Redis应用场景,Redis常见命令,Reids缓存击穿穿透,Redis分布式锁实现方案,秒杀设计思路,Redis消息队列,Reids持久化,Redis主从哨兵分片集群
精彩回顾 | DEEPNOVA x Iceberg Meetup Online《基于Iceberg打造实时数据湖》
JS find array subscript
腾讯团队实力打造flutter入门教程,1-3年Android开发工程师面试经验分享
Cloud native enthusiast weekly: looking for open source alternatives to netlify
Cookie & session learning
The AOV function of R language is used for one-way ANOVA, the normality of the dependent variable of ANOVA is evaluated by Q-Q diagram, the equality (homogeneity) of Bartlett's verification variance,
Several schemes of single USB to multi serial port
OTS parsing error: invalid version tag solution
draw2d自定义仪表盘
Introduction notes to PHP zero Foundation (11): String
Shallow comparison between oceanbase and tidb - implementation plan
【Pranet】论文及代码解读(ResNet部分)——jialiang nie
Qipengyuan vision breaks the conventional social model and constructs a diversified scene community
Public testing, exclusive, penetration testing, picking up ragged tips
How can devices of different brands be compatible and interconnected? Yiwen teaches you to understand
简单理解变量的结构赋值
括号匹配检测 (20 分) C语言