CentOS 安装 Ansible 以及连接Windows server的办法
1. CentOS机器上面按住那ansible
yum install ansible
2. 安装 pywinrm 如果不安装 这个的话 ansible 会提示 没有 winrm 模块
注意需要先安装epel
yum install epel-release yum install python-pip pip2 install --ignore-installed pywinrm
3. windows 的设置 参照转帖的blog
这里面修改 ansible 的host 文件
vim /etc/ansible/hosts 新增加内容:
[windows]
10.24.196.32 ansible_ssh_user="Administrator" ansible_ssh_pass="Test1127?!" ansible_ssh_port= ansible_connection="winrm" ansible_winrm_server_cert_validation=ignore
4. 进行测试验证
ansible windows -m win_ping
结果为:
[root@centos76 ~]# ansible windows -m win_ping
10.24.196.32 | SUCCESS => {
"changed": false,
"ping": "pong"
}
[root@centos76 ~]#
CentOS 安装 Ansible 以及连接Windows server的办法的更多相关文章
- Ansible 批量管理Windows Server服务器
Ansible批量管理Windows Server Ansible是一款为类Unix系统开发的自由开源的配置和自动化工具, 它用Python写成,类似于saltstack和Puppe ...
- 使用SSH连接Windows Server 2019 Core
更新记录 本文迁移自Panda666原博客,原发布时间:2021年7月7日. 一.说明 Windows Server 2019 Core,是纯命令行的Windows Server版本,没有办法使用GU ...
- 使用 Powershell 远程连接 windows server
使用 Powershell 远程连接 windows server Intro 最近我们的开发环境增加了一个 windows 服务器,没有界面的,不能直接远程桌面连上去管理,需要使用 Powershe ...
- CentOS下通过rdesktop连接Windows远程桌面
众所周知,微软的Windows提供了一种远程桌面系统(Remote Desktop),该服务的默认端口是3389,可使用户远程登录进行系统管理或作为终端服务器运行各种应用软件. 而要连接Windows ...
- Ubuntu 下使用Remmina Remote Desktop client 连接windows server输入法的问题
Ubuntu 自带的Remmina Remote Desktop 用来连接windows,vnc,ssh等非常方便好用, 但我在连接windows 2008 r2 server时遇到一个问题: ...
- centos安装ansible
此次测试总共有三台机,分别如下: ansible服务器:10.0.0.20 client01:10.0.0.21 client02:10.0.0.22 一.安装ansible 方法一. yum ins ...
- Mac上远程桌面连接Windows Server 2012 R2
在将一台服务器的操作系统由Windows Server 2012升级为Windows Server 2012 R2之后,在Mac电脑上用微软的远程桌面软件怎么也连不上服务器,错误信息如下: Remot ...
- Windows XPSP3通过网络级身份验证方式连接Windows Server 2008远程桌面
远程桌面大大方便了大家的日常管理工作,Windows Server 2008同样秉承这一优秀特性,并引入网络级身份验证(NLA)作为远程桌面连接的默认身份验证方式. 网络级身份验证 (NLA) 是一种 ...
- 使用Windows系统远程连接Windows server服务器
点击开始菜单->运行 (或者 windows+R) ,输入"mstsc"命令, 打开远程桌面连接对话框,输入你要连接的Windows server服务器的公网IP. 点击 ...
随机推荐
- 【Android Studio安装部署系列】二十八、Android Studio查看其它APP的布局结构
概述 日常使用别家的APP过程中,会遇到一些比较好看的布局,这时候我们就想学习一下别人的布局结构,以便参考. (1)手机连接电脑.设置手机为USB调试模式 参考<[Android Studio安 ...
- django插入数据库错误:mysql的1267错误
错误信息: django.db.utils.OperationalError: (1267, "Illegal mix of collations (latin1_swedish_ci,IM ...
- 小议 localStorage
前言 什么是 localStorage? 在HTML5中,新加入了一个localStorage特性,这个特性主要是用来作为本地存储来使用的,解决了cookie存储空间不足的问题(cookie中每条co ...
- 红透半边天的VR(虚拟现实)产业
目前在做一些与AR与VR相关的工作,特此把一些个人总结的普及性概念与各位朋友共享. 一: 什么是虚拟现实(VR)技术? 虚拟现实技术是一种可以创建和体验虚拟世界的计算机仿真系统它利用计算机生成一种模拟 ...
- [翻译] EF Core in Action 关于这本书
Entity Framework Core in Action Entityframework Core in action是 Jon P smith 所著的关于Entityframework Cor ...
- Golang: Cobra命令行参数库的使用
将cobra下载到 $GOPATH,用命令: go get -v github.com/spf13/cobra/cobra 然后使用 go install github.com/spf13/cobra ...
- Apache web服务器(LAMP架构)(week3_day4)--技术流ken
apache介绍 1).世界上使用率最高的网站服务器,最高时可达70%:官方网站:apache.org 2).http 超文本协议 HTML 超文本标记语言 3).URL 统一资源定位符 http:/ ...
- asp.net mvc 简单项目框架的搭建过程(一)对Bll层和Dal层进行充分解耦
学习asp.net 已经有近三个月的时间了,在asp.net mvc上花的时间最多,但个人真是有些菜,不得不说,asp.net mvc的水真的还是蛮深的.目前在公司实习,也见过公司几个项目的代码了.对 ...
- C#实现注册表 LocalMachine 目录下CURD工具类
[1]注册表是什么? 百度百科 https://baike.baidu.com/item/%E6%B3%A8%E5%86%8C%E8%A1%A8/101856?fr=aladdin [ ...
- spring boot拦截器中获取request post请求中的参数
最近有一个需要从拦截器中获取post请求的参数的需求,这里记录一下处理过程中出现的问题. 首先想到的就是request.getParameter(String )方法,但是这个方法只能在get请求中取 ...