In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)06/01 Report--
1.Rancid function:
Rancid is a tool for backing up the configuration of network devices. It can also be used as an alarm tool for configuration changes.
two。 How it works:
Log in remotely (telnet,ssh... Log in to the device, then automatically execute the show command to collect the software and hardware information of the network device, download configuration file, use the CVS plug-in to check the configuration changes, diff a change comparison, so as to know the change process of the network configuration.
And can be sent to the relevant managers through email
3.rancid deployment:
Let me tell you a short story before deployment. In fact, I have never heard of rancid before. Before, network equipment configuration backups were done through professional manufacturers, but when you enter the Internet or companies similar to the Internet, you will find that a lot of the work of operation and maintenance is considered from the perspective of saving money, that is to say, if you can spend nothing, you will never find a manufacturer to solve what can be done with open source software. But after I came to the company, the company had such a need that I had to meet, so I began to build rancid. There are too few relevant materials about rancid in the network (the link to the website I have referenced later in the article), and this rancid still can not support domestic devices (I heard that a plug-in can support Huawei's products now). Fortunately, our company does not have domestic equipment. Hundreds of switches throughout the network are owned by cisco. There are also several versions of rancid, and the configuration file will change greatly with different versions. At that time, I also referred to a lot of documents on the Internet and found that they could not be implemented. It is because of the problem of the version that sometimes you will find that there is a big difference. No, no, no. All right, let's get started.
The yum varies from device to device. First, take a look at how to update yum:
Wget http://mirrors.163.com/.help/CentOS6-Base-163.repo
two。 Back up and replace the repo file of the system
[root@localhost ~] # cd / etc/yum.repos.d/
[root@localhost ~] # mv CentOS-Base.repo CentOS-Base.repo.bak
[root@localhost ~] # mv CentOS6-Base-163.repo CentOS-Base.repo
3. Perform yum source updates
[root@localhost ~] # yum clean all
[root@localhost ~] # yum makecache
[root@localhost ~] # yum update
[root@CentOs etc] # yum install rancid cvs
Vim / etc/rancid/rancid.conf
LIST_OF_GROUPS= "routers switches"
!
#
[rancid@CentOs /] $vi / etc/aliases
Rancid-routers: xxxx@11.com
Rancid-admin-routers: xxxx@11.com
Rancid-switches: xxxx@11.com
Rancid-admin-switches: xxxx@11.com
!
/ / the mailbox needs to be defined according to the requirements. Here I use xxxx@11.com instead.
[root@CentOs] # sudo-I-u rancid
[rancid@CentOs ~] $/ usr/bin/rancid-cvs
/ / if you have previously installed to reinstall this place, you may encounter problems. It is recommended to reboot and reinstall after uninstalling.
/ / create a directory for each group:
[rancid@CentOs ~] $cd / var/rancid/
[rancid@CentOs rancid] $ls
CVS logs routers switches
[rancid@CentOs rancid] $
/ / add hosts to router.db
[rancid@CentOs /] $vim / var/rancid/routers/router.db
192.168.200.103There is ciscoterup
!
[rancid@CentOs /] $vim / var/rancid/switches/router.db
192.168.200.99th ciscoterup
!
[rancid@CentOs /] $cd / var/rancid/
[rancid@CentOs rancid] $ls
CVS logs routers switches
[rancid@CentOs rancid] $touch .cloginrc
!
[rancid@CentOs rancid] $vim .cloginrc
Add autoenable * 1
Add method * ssh
Add user * cisco
Add password * cisco
!
[rancid@CentOs rancid] $chmod 600.cloginrc
/ / execute. / clogin in this directory
[rancid@CentOs rancid] $cd / usr/libexec/rancid/
/ var/log/rancid this is a log document
Note: to go directly to # mode when logging in, I'll go!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.