dsh安装指南
dsh批量管理linux服务器
一,安装dsh
切换到root用户,然后切换到work_home_yourname
wget http://www.netfort.gr.jp/~dancer/software/downloads/libdshconfig-0.20.9.tar.gz
tar zxvf libdshconfig-0.20.9.tar.gz
cd libdshconfig-0.20.9
./configure
出错记得修复(Ubuntu: configure error: C++ preprocessor "/lib/cpp" fails sanity check
apt-get install build-essential)
make && make install
wget http://www.netfort.gr.jp/~dancer/software/downloads/dsh-0.25.9.tar.gz
tar zxvf dsh-0.25.9.tar.gz
cd dsh-0.25.9
./configure
make && make install
ln -s /usr/local/lib/libdshconfig.so.1 /lib/
echo "/usr/local/lib/libdshconfig.so.1">> /etc/ld.so.conf
ldconfig
[root@localhost ~]# which dsh
/usr/local/bin/dsh
二,用法介绍:
切换回需要的用户.
mkdir .dsh
cd .dsh
touch how-to-use,内容如下:
dsh -M -r ssh -f file目录 --命令
dsh --help
-v –verbose Verbose output 详细模式输出
-q –quiet Quiet 安静模式输出
-M –show-machine-names Prepend the host name on output显示被控制主机的hostname
-H –hide-machine-names Do not prepend host name on output 不显示主机名(default)
-i –duplicate-input Duplicate input given to dsh
-b –bufsize Change buffer size used in input duplication
-m –machine [machinename] Execute on machine 主机名
-n –num-topology How to divide the machines
-a –all Execute on all machines 主机列表,默认列表在/root/.dsh/machines.list
-g –group [groupname] Execute on group member 指定主机名组,主机名组在/root/.dsh/group/
-f –file [file] Use the file as list of machines 选择主机列表
-r –remoteshell [shellname] Execute using shell (rsh/ssh) 指定远程工具,默认为rsh
-o –remoteshellopt [option] Option to give to shell
-h –help Give out this message
-w –wait-shell Sequentially execute shell 指定顺序运行,默认是并行
-c –concurrent-shell Execute shell concurrently
-F –forklimit [fork limit] Concurrent with limit on number
-V –version Give out version information
三,应用举例:
dsh -M -r ssh -m ~/a.txt -- hostname
dsh安装指南的更多相关文章
- nGrinder安装指南
NGrinder 由两个模块组成,其运行环境为 Oracle JDK 1.6 nGrinder controller web 应用程序,部署在Tomcat 6.x 或更高的版本 nGrinder A ...
- postgresql pgsql最新版安装指南及数据存储路径更改及主从配置
postgresql pgsql最新版安装指南及数据存储路径更改及主从配置 安装指南 首先在apt的list添加你当前系统版本对应的apt列表 目前官网有16.04,14.04,12.04 分别对应下 ...
- 全新 Mac 安装指南(编程篇)(环境变量、Shell 终端、SSH 远程连接)
注:本文专门用于指导对计算机编程与设计(尤其是互联网产品开发与设计)感兴趣的 Mac 新用户,如何在 Mac OS X 系统上配置开发与上网环境,另有<全新 Mac 安装指南(通用篇)>作 ...
- 全新 Mac 安装指南(通用篇)(推荐设置、软件安装、推荐软件)
注:本文将会不定期维护与更新,有需要的朋友请在 Github 上订阅该条 Issues:<全新 Mac 安装指南(通用篇)>. 在 Mac 电脑上只用 Windows 操作系统的同学请看到 ...
- ArchLinux安装指南
将ArchLinux作为进阶Linux发行版,主要看重滚动更新和深入理解Linux的安装过程. 由于是新手,所以先选择在公司电脑上用VMware来安装.然后渐进到借助U盘在win10笔记本上安装双系统 ...
- Linux环境中Openfire安装指南
Linux环境中Openfire安装指南 安装环境: 安装软件:Openfire 4_1_0 http://download.igniterealtime.org/openfire/openfire_ ...
- scrapy3_ 安装指南
安装指南 安装Scrapy 注解 请先阅读 平台安装指南. 下列的安装步骤假定您已经安装好下列程序: Python 2.7 Python Package: pip and setuptools. 现在 ...
- storm 原理简介及单机版安装指南——详细版【转】
storm 原理简介及单机版安装指南 本文翻译自: https://github.com/nathanmarz/storm/wiki/Tutorial 原文链接自:http://www.open-op ...
- mac osx 系统 brew install hadoop 安装指南
mac osx 系统 brew install hadoop 安装指南 brew install hadoop 配置 core-site.xml:配置hdfs文件地址(记得chmod 对应文件夹 ...
随机推荐
- HDU 6197 array array array 2017沈阳网络赛 LIS
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=6197 题意:给你n个数,问让你从中删掉k个数后(k<=n),是否能使剩下的序列为非递减或者非递增 ...
- ubuntu查看mysql版本的几种方法
ubuntu查看mysql版本的几种方法 mysql 1:在终端下:mysql -V(大写) //代码 $ mysql -V mysql Ver 14.14 Distrib 5.5.46, for d ...
- /proc/mounts介绍
现在的 Linux 系统里一般都有这么三个文件:/etc/fstab,/etc/mtab,和 /proc/mounts,比较容易让人迷惑.简单解释一下. /etc/fstab 是只读不写的,它提供的是 ...
- java通过jdbc插入中文到mysql显示异常(问号或者乱码)
转自:https://blog.csdn.net/lsr40/article/details/78736855 首先本人菜鸡一个,如果有说错的地方,还请大家指出予批评 对于很多初学者来说,中文字符编码 ...
- 构建最基础的Spring项目及所需要的jar包
1.Spring 框架由6个模块组成 上图是spring4的结构图,不同版本结构略有差异,但模块都是相同的. 2.Core Container 核心容器 容器是Spring的核心部分,Core Con ...
- 深度揭秘阿里移动端高性能动态化方案Weex
2016年Qcon大会首日,阿里巴巴资深总监.淘宝移动平台.阿里百川负责人庄卓然宣布移动端高性能动态化方案Weex即时内测,并将于6月开源.此消息一出,群情汹涌,在座的程序猿.攻城狮们纷纷拿起手机扫码 ...
- 如何将svg图标快速转换成字体图标?
今天遇到一个客户需要我将页面的图标做成字体图标,想想哎可能整的麻烦,不过想想这也是对项目的一个优化 ( 1.字体图标直接用color自由控制颜色:2.整合在一起,减少http请求等 PS:平时 ...
- Qt 下载列表地址
每次下载Qt总是找好长时间,收藏一下地址 Qt 下载列表地址 https://www.qt.io/download-open-source/#section-9 教育网镜像下载 http://mirr ...
- 开源IDS系列--snorby 进程正常,但是worker无法启动 The Snorby worker is not currently running
设置页面报错: The Snorby worker is not currently running. It's imperative you start the worker immediate ...
- Vuex总结
Vuex官网链接:https://vuex.vuejs.org/zh-cn/strict.html Vuex 是一个专为 Vue.js 应用程序开发的状态管理模式. 它采用集中式存储管理应用的所有组件 ...