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 对应文件夹 ...
随机推荐
- Android: 在onCreate()中获得对象尺寸
onCreate() 中 View 尚未绘制完成 很多时候,我们需要在某个界面刚刚加载的时候,执行一些对 View 进行操作的代码,通常我们把这些代码放在 Activity 的 onCreate() ...
- plsql实例精讲部分笔记
转换sql: create or replace view v_sale(year,month1,month2,month3,month4,month5,month6,month7,month8,mo ...
- Effective STL 笔记: Item 6--Be alert for C++'s most vexing parse
假设有个文件里面记录的一系列的 int 值,现在我们想把这些数值存到一个 List 里面,结合 Item 5, 我们可能会写出下面的代码: ifstream dataFile("ints.d ...
- MySql学习笔记——触发器
今天又学习了一下mysql触发器的相关知识,对此做了一些笔记和总结. 定义及作用 触发器是一个被指定关联到一个表的数据对象,触发器不需要调用,当对一个表的特别事件出现时,它就会被激活.触发器的代码也是 ...
- Jmeter----5.1 设置中文
注意:JMeter5需要Java8 以上,本文环境是Win7 64位 设置永久默认汉化:在Jmeter的安装目录下的bin目录中找到 jmeter.properties这个文件,用文本编辑器打开.在# ...
- 响应式之像素和viewport
引言 按照pc尺寸做好的网页,在手机端打开,看起来像是pc的缩小版,东西都在只是字太小都看不清了,有什么办法放大呢? 于是去google一下,发现,贴了这么一行代码就轻松解决了: <meta n ...
- 小甲鱼C++笔记(上)1-24
一 OO思想:每个对象都是一个完整的独立的个体,由相关的属性和行为组合与外界分隔 OO思想的特点:1封装 把对象的属性和方法结合成一个独立的系统单位,并尽可能隐藏内部细节 2抽象 对一类公共问题进行统 ...
- C# 6.0 新特性 (四)
原文: 1.http://www.cnblogs.com/BoyceYang/p/3711343.html 2.http://www.cnblogs.com/lhking/p/3660182.html ...
- CentOS 7 kibana安装配置
Kibana 是为Elasticsearch设计的开源分析和可视化平台,你可以使用 Kibana 来搜索,查看存储在 Elasticsearch 索引中的数据并与之交互.你可以很容易实现高级的数据分析 ...
- 转:[译]CSV 注入:被人低估的巨大风险
转:https://yq.aliyun.com/articles/225847 原文地址:The Absurdly Underestimated Dangers of CSV Injection 原文 ...