小时? 发表于 2018-7-28 08:06:58

Juniper设备配置SMNP模板

  (1) 配置 SNMP Agent 代理
  Syntax
  community community-name {
  authorization authorization;
  clients {
  address restrict;
  }
  view view-name;
  }
  Example:
  # set snmp community tester authorization read-only clients 192.168.0.1/24
  # set snmp community tester authorization read-only clients 10.10.10.0/24 restrict
  snmp {
  community tester {
  authorization read-only;
  clients {
  192.168.0.1/24;
  10.10.10.0/24 restrict; //禁止访问的网段
  }
  }
  (2) 配置 SNMP trap-group
  snmp {
  // 路由器名称
  description R1-D-DP-1.CZW;
  // 所在地理位置
  location "DaPing Build 4F";
  // 技术联络人
  contact "xxxx. phone:xxxxx";
  // SNMP Community配置
  community zy-cqdx-snmp {
  // 指定权限为只读
  authorization read-only;
  // 限定以下的地址发送SNMP查询的请求
  clients {
  61.183.1.48/32;
  61.128.186.48/32;
  }
  }
  // 配置主动SNMP讯息回报
  trap-group all {
  // 指定使用SNMP v2
  version v2;
  // 指定发送的事件类别
  // 本文檔所提及的Trap所需的类别如下
  categories {
  authentication;
  chassis;
  link;
  routing;
  startup;
  vrrp-events;
  configuration;
  sonet-alarms;
  }
  // 事件信息的目的主机
  targets {
  61.128.186.48;
  }
  }
  }
  // 于routing-options 下指定SNMP网管主机的静态路由(由管理端口fxp0送出)。
  routing-options {
  static {
  route 61.128.186.48/32 next-hop 61.186.155.89;
  route 61.183.1.48/32 next-hop 61.186.155.89;
  }
  }
  // 要对LSP进行流量、封包数等进行SNMP计数,
  // 必须开启以下的MPLS Statistics Gathering功能
  // 建议使用的更新间隔为300秒(缺省值)
  protocols {
  mpls {
  statistics {
  file lsp.stats;
  interval 300;
  }
  }
  }
  WEB界面配置juniper防火墙:
  一、配置snmp协议
  1、 进入图形化配置界面 通过http://ip地址
  在主菜单中点击configuration,选择Report Settings,然后点击snmp
  2、 在System Contact框中填写系统管理员的联系方式,比如姓名等,在location处填写此设备的使用地点。选择“Enable Authentication Fail Trap”复选框。不改变默认端口。
  点击Apply应用。
  3、 点击new community填加community 字符串
  4、 产品默认为public,建议更改。
  5、同时选择“Write”、“Trap”、“Including Traffic Alarms”三个复选框。在“Hosts IP Address/Netmask”中填加管理主机的ip 地址和子网掩码。
  6、点击ok 按钮。
  二、配置一个接口为SNMP网管接口
  在配置完SNMP协议后,还得给设备配置一个可网管接口IP,网管产品通过该接口IP和设备通信。配置步骤如下:
  1、通过VEB配置方式进入设备WEB配置界面。选择“Network”,然后选择“Interfaces”,打开所有的接口配置。
  2、选择要作为管理的接口,点击“Edit”,打开该接口的属性编辑框。
  3、在“Management Service”中选择“snmp”
  4、点击ok,确定即可。那以后就可以通过该接口的IP 地址管理该设备了
  ---------------------------------------大鹏----------------------------------------------
页: [1]
查看完整版本: Juniper设备配置SMNP模板