Modérateur: modos Ixus
cd /etc/mrtg
mkdir $1
cd /var/www/html/mrtg/
mkdir $1
cfgmaker \
--global 'WorkDir: /var/www/html/mrtg/'$1 \
--global 'Language: french' \
--global 'Options[_]: bits,growright' \
--ifdesc=descr public@$1 \
--output /etc/mrtg/$1/$1.cfg
cd /etc/cron.d
echo '0-59/5 * * * * root /usr/bin/mrtg /etc/mrtg/'$1'/'$1'.cfg' >> mrtg
####
# First, map the community name "public" into a "security name"
# sec.name source community
com2sec localnet default public
####
# Second, map the security name into a group name:
# groupName securityModel securityName
group public v1 localnet
group notConfigGroup v2c notConfigUser
####
# Third, create a view for us to let the group have rights to:
# Make at least snmpwalk -v 1 localhost -c public system fast again.
# name incl/excl subtree mask(optional)
#view systemview included .1.3.6.1.2.1.1
#view systemview included .1.3.6.1.2.1.25.1.1
view all included .1
####
# Finally, grant the group read-only access to the systemview view.
# group context sec.model sec.level prefix read write notif
access public "" any noauth exact all none none
## context sec.model sec.level prefix read write notif
#access MyROGroup "" any noauth 0 all none none
#access MyRWGroup "" any noauth 0 all all all
syslocation la ou tu veux
syscontact Root <root@localhost>
Retour vers Linux et BSD (forum généraliste)
Utilisateur(s) parcourant actuellement ce forum : Aucun utilisateur inscrit et 0 invité(s)