经过几天折腾,终于搞出来了一个python网络设备配置备份的脚本。基本思路如下:1.定义设备类Device1.1初始化参数dc,zone,hostname,ip,user,passwd(数据中心,网络区域,设备名称,ip,用户名,密码)1.2函数login设备登录1.3函数screenCMD设备测试是否支持分屏命令(目前只有华为的做这个测试)1.4函数get_config支持分屏命令的设备取配置方
分类:
编程语言 时间:
2020-10-22 23:08:20
阅读次数:
30
1. 下载并编译安装torque [root@master ~]# cd /opt/ [root@master opt]#yum install wget -y && wget http://wpfilebase.s3.amazonaws.com/torque/torque-6.1.1.1.tar. ...
分类:
其他好文 时间:
2020-10-22 22:19:40
阅读次数:
18
Centos7使用firewalld查看防火墙状态systemctlstatusfirewalld关闭防火墙临时关闭systemctlstopfirewalld永久关闭需要把开机自启动关闭systemctldisablefirewalld检查服务状态systemctlis-activefirewalld#检查服务是否正常运行systemctlis-enablefirewalld#检查服务是否开机运
分类:
系统相关 时间:
2020-10-21 21:28:47
阅读次数:
39
Existing lock /var/run/yum.pid: another copy is running as pid 19342. Another app is currently holding the yum lock; waiting for it to exit... The oth ...
分类:
其他好文 时间:
2020-10-20 16:35:38
阅读次数:
30
一.前置条件 1.需要安装docker 并运行 2.需要安装docker-compose 二.下载离线安装包 1.tar -zxvf harbor.v1.5.1.tar.gz 2.vim harbor.cfg 编辑配置文件 1.hostname = A.B.C.D # 写你自己的网址或IP,公网访问 ...
分类:
其他好文 时间:
2020-10-19 23:07:01
阅读次数:
31
1,打开网址下载mysql yum源 https://dev.mysql.com/downloads/repo/yum/ 根据linux版本选择不同的rpm包 ,我的是centos7.5,所以我选择第二个 2,点击下载 点击获得地址 二、下载和安装mysql源,wget 加上刚刚复制的地址 如果显示 ...
分类:
数据库 时间:
2020-10-19 22:49:58
阅读次数:
37
1、导入hellodb.sql生成数据库(1)在students表中,查询年龄大于25岁,且为男性的同学的名字和年龄[root@centos7~]$systemctlstartmariadb[root@centos7~]$ss-tnlStateRecv-QSend-QLocalAddress:PortPeerAddress:PortLISTEN0100127.0.0.1:25*:*LISTEN05
分类:
数据库 时间:
2020-10-18 16:55:25
阅读次数:
29
centos7安装zabbix5.0+postgresql详细步骤
分类:
数据库 时间:
2020-10-18 16:35:28
阅读次数:
37