SSH批量部署服务

SSH批量部署服务

1.1在NFS上作为中心分发服务器将私钥分发到其他服务器上

1.1.1NFS部署

  .ssh/authorized_keys

to make sure we haven't added extra keys that you weren't expecting.

1.1.2 web-lnmp02客户端分发部署

  .ssh/authorized_keys

to make sure we haven't added extra keys that you weren't expecting.

1.1.3 rsync-backup客户端分发部署

  .ssh/authorized_keys

to make sure we haven't added extra keys that you weren't expecting.

2.1在NFS上测试

2.1.1 通过ssh命令在当前机器上查看web-lamp01的IP地址

批量管理脚本:

~

批量分发脚本:

#!/bin/sh
. /etc/init.d/functions

~

利用分发脚本分发hosts文件

优化后的分发脚本

下面关于SSH相关的文章您也可能喜欢,不妨参考下:

猜你喜欢

转载自www.linuxidc.com/Linux/2016-03/128978.htm
今日推荐