-
Notifications
You must be signed in to change notification settings - Fork 0
/
cacti_client.sh
26 lines (19 loc) · 879 Bytes
/
cacti_client.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
# install snmp and tools
##This is actualyy part of the web server and will be added to the end of the scripting
yum -y install net-snmp net-snmp-utils
# create a new snmpd.conf
mv /etc/snmp/snmpd.conf /etc/snmp/snmpd.conf.orig
touch /etc/snmp/snmpd.conf
# edit snmpd.conf file /etc/snmp/snmpd.conf
# for the 10.138.x.x to worl...instance has to be in us-west1-b
echo '# create myuser in mygroup authenticating with 'public' community string and source network 10.138.0.0/24
com2sec myUser 10.138.0.0/24 public
# myUser is added into the group 'myGroup' and the permission of the group is defined
group myGroup v1 myUser
group myGroup v2c myUser
view all included .1
access myGroup "" any noauth exact all all none' >> /etc/snmp/snmpd.conf
# Enable snmp, Start snmp
systemctl enable snmpd
systemctl start snmpd