-- *****************************************************************
-- QTECH-MPLS-LDP-MIB.mib:  Qtech MPLS LDP MIB file
--
-- MAY 2011, HongPeiYang
--
-- Copyright (c) 2011 by Qtech Networks Co.,Ltd.
-- All rights reserved.
-- 
-- *****************************************************************
--

QTECH-MPLS-LDP-MIB DEFINITIONS ::= BEGIN


IMPORTS
        MODULE-IDENTITY,
        OBJECT-TYPE,
        TimeTicks,
        IpAddress,
        Unsigned32,
        Gauge32,
        Counter32
                FROM SNMPv2-SMI
        TruthValue,
        RowStatus
                FROM SNMPv2-TC
        MODULE-COMPLIANCE,
        OBJECT-GROUP
                FROM SNMPv2-CONF
        ConfigStatus
                FROM QTECH-TC    
        EnabledStatus 
                FROM P-BRIDGE-MIB                
        AreaID,
        Status,
        PositiveInteger,
        DesignatedRouterPriority,
        RouterID,
        HelloRange 
                FROM OSPF-MIB
        InetAddressPrefixLength,
        InetAddressType,
        InetAddress,
        InetPortNumber
             FROM INET-ADDRESS-MIB           --  [RFC3291]
        SnmpAdminString
                FROM SNMP-FRAMEWORK-MIB      --  [RFC3411]
        MplsLdpIdentifier
                FROM MPLS-TC-STD-MIB         --  [RFC3811]
        qtechMgmt
                FROM QTECH-SMI;

qtechMplsLdpMIB MODULE-IDENTITY
        LAST-UPDATED "201105150000Z"
        ORGANIZATION "Qtech Networks Co.,Ltd."
        CONTACT-INFO
                " 
                Tel: 4008-111-000 

                E-mail: service@qtech.com.cn"
        DESCRIPTION
                "This module defines qtech mpls ldp mibs."
        REVISION      "201105150000Z"
        DESCRIPTION
                "Initial version of this MIB module."
        ::= { qtechMgmt 99}

qtechMplsLdpMIBObjects OBJECT IDENTIFIER ::= { qtechMplsLdpMIB 1 }
     --****************************************************************

     qtechMplsLdpObjects       OBJECT IDENTIFIER ::= { qtechMplsLdpMIBObjects 1 }
     qtechMplsLdpConformance   OBJECT IDENTIFIER ::= { qtechMplsLdpMIBObjects 2 }

     --****************************************************************
     -- MPLS LDP Objects
     --****************************************************************

     qtechMplsLdpMplsGernalMibObjects    OBJECT IDENTIFIER ::= { qtechMplsLdpObjects 1 }     
     qtechMplsLdpConfigMibObjects        OBJECT IDENTIFIER ::= { qtechMplsLdpObjects 2 } 

mplsLdpThreadName  OBJECT-TYPE
    SYNTAX      SnmpAdminString
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "LDP Task Name."
    ::= { qtechMplsLdpMplsGernalMibObjects 1 }

mplsLdpSessionUpCount  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Total LDP session Operational count."
    ::= { qtechMplsLdpMplsGernalMibObjects 2 }

mplsLdpSessionCreatCount  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Total active LDP session number."
    ::= { qtechMplsLdpMplsGernalMibObjects 3 }

mplsLdpSessionDownCount  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Total tear down LDP session number."
    ::= { qtechMplsLdpMplsGernalMibObjects 4 }

mplsLdpSessionDownCauseByInf  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "The total count of LDP sessions which are caused down by interface."
    ::= { qtechMplsLdpMplsGernalMibObjects 5 }

qtechMplsLdpFecTable OBJECT-TYPE
     SYNTAX      SEQUENCE OF QtechMplsLdpFecEntry
     MAX-ACCESS  not-accessible
     STATUS      current
     DESCRIPTION
         "This table represents the FEC
         (Forwarding Equivalence Class)
         Information associated with an LSP."
     ::= { qtechMplsLdpMplsGernalMibObjects 6 }

qtechMplsLdpFecEntry OBJECT-TYPE
   SYNTAX      QtechMplsLdpFecEntry
   MAX-ACCESS  not-accessible
   STATUS      current
   DESCRIPTION
       "Each row represents a single FEC Element."
   INDEX       { mplsFecIndex }
   ::= { qtechMplsLdpFecTable 1 }

QtechMplsLdpFecEntry ::= SEQUENCE {
    mplsFecIndex               INTEGER,
    mplsFecType                INTEGER,
    mplsFecAddrType            InetAddressType,
    mplsFecAddr                InetAddress,
    mplsFecAddrPrefixLength    InetAddressPrefixLength,
    mplsFecStatus              INTEGER,
    mplsFecLspActivity         TruthValue,
    mplsFecLspDisconnect       TruthValue,
    mplsFecLspDisconnectType   INTEGER,
    mplsFecSession             MplsLdpIdentifier,
    mplsLdpSessionCloseType    INTEGER,
    mplsFecIngressBytes        INTEGER,
    mplsFecIngressPackets      INTEGER,
    mplsFecTransmitBytes       INTEGER,
    mplsFecTransmitPackets     INTEGER
}

mplsFecIndex OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
        "The index which uniquely identifies this entry."
    ::= { qtechMplsLdpFecEntry 1 }

mplsFecType  OBJECT-TYPE
    SYNTAX      INTEGER {
                   prefix(1),
                   hostAddress(2)
                }
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "The type of the FEC.  If the value of this object
        is 'prefix(1)' then the FEC type described by this
        row is an address prefix.

        If the value of this object is 'hostAddress(2)' then
        the FEC type described by this row is a host address."
    REFERENCE
        "RFC3036, Section 3.4.1. FEC TLV."
    ::= { qtechMplsLdpFecEntry 2 }

mplsFecAddrType  OBJECT-TYPE
    SYNTAX      InetAddressType
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "The value of this object is the type of the
        Internet address.  The value of this object,
        decides how the value of the mplsFecAddr object
        is interpreted."
    REFERENCE
        "RFC3036, Section 3.4.1. FEC TLV."
    ::= { qtechMplsLdpFecEntry 3 }

mplsFecAddr     OBJECT-TYPE
    SYNTAX      InetAddress
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "The value of this object is interpreted based
        on the value of the 'mplsFecAddrType' object.

        This address is then further interpretted as
        an being used with the address prefix,
        or as the host address.  This further interpretation
        is indicated by the 'mplsFecType' object.
        In other words, the FEC element is populated
        according to the Prefix FEC Element value encoding, or
        the Host Address FEC Element encoding."
    REFERENCE
        "RFC3036, Section 3.4.1 FEC TLV."
    ::= { qtechMplsLdpFecEntry 4 }

mplsFecAddrPrefixLength  OBJECT-TYPE
    SYNTAX      InetAddressPrefixLength
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "If the value of the 'mplsFecType' is 'hostAddress(2)'
        then this object is undefined.

        If the value of 'mplsFecType' is 'prefix(1)'
        then the value of this object is the length in
        bits of the address prefix represented by
        'mplsFecAddr', or zero.  If the value of this
        object is zero, this indicates that the
        prefix matches all addresses.  In this case the
        address prefix MUST also be zero (i.e., 'mplsFecAddr'
        should have the value of zero.)"
    REFERENCE
        "RFC3036, Section 3.4.1. FEC TLV."
    DEFVAL { 0 }
    ::= { qtechMplsLdpFecEntry 5 }

mplsFecStatus  OBJECT-TYPE
    SYNTAX      INTEGER {
                   route(1),
                   nonroute(2)
                }
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "The type of the FEC.  If the value of this object
        is 'prefix(1)' then the FEC type described by this
        row is an address prefix.

        If the value of this object is 'hostAddress(2)' then
        the FEC type described by this row is a host address."
    ::= { qtechMplsLdpFecEntry 6 }

mplsFecLspActivity  OBJECT-TYPE
    SYNTAX      TruthValue 
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "LSP activity state."
    ::= { qtechMplsLdpFecEntry 7 }

mplsFecLspDisconnect  OBJECT-TYPE
    SYNTAX      TruthValue
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "LSP disconnection state."
    ::= { qtechMplsLdpFecEntry 8 }

mplsFecLspDisconnectType  OBJECT-TYPE
    SYNTAX      INTEGER {
                   sessionDown(1),
                   nhChng(2),
                   other(3)
                }
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "LSP disconnection reason."
    ::= { qtechMplsLdpFecEntry 9 }
        
mplsFecSession  OBJECT-TYPE
    SYNTAX      MplsLdpIdentifier
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Corresponding LDP session of FEC nexthop"
    ::= { qtechMplsLdpFecEntry 10 }      
        
        
mplsLdpSessionCloseType  OBJECT-TYPE
    SYNTAX      INTEGER {
                   none(0),
                   backoff(1),
                   hello_timer_expired(2),
                   peer_holddown_time_expired(3),
                   keepalive_timer_expired(4),
                   peer_keepalive_time_expired(5),
                   bad_ldp_identifier(6),
                   peer_recv_bad_ldp_identifier(7),
                   bad_protocol_version(8),
                   peer_recv_bad_protocol_version(9),
                   peer_recv_bad_pdu_length(10),
                   peer_recv_bad_message_length(11),
                   peer_recv_bad_tlv_length(12),
                   malformed_tlv_value(13),
                   peer_recv_malformed_tlv_value(14),
                   peer_shutdown(15),
                   session_rejected_no_hello(16),
                   peer_rejected_no_hello(17),
                   session_rejected_parameters_advertisement_mode(18),
                   peer_rejected_advertisement_mode(19),
                   session_rejected_parameters_max_pdu_length(20),
                   peer_rejected_max_pdu_length(21),
                   peer_rejected_parameters_label_range(22),
                   session_rejected_bad_keepalive_time(23),
                   peer_rejected_bad_keepalive_time(24),
                   internal_error(25),
                   peer_internal_error(26),
                   event_unlawful(27),
                   passive_wait_init_or_keepalive_expired(28),
                   peer_unknown_message_type(29),
                   peer_unknown_tlv_type(30),
                   tcp_connection_closed_by_peer(31),
                   no_ip_routing(32),
                   nsr_recover_fail(33),
                   session_has_no_other_adj(34),
                   session_connect_fail(35),
                   session_count_has_reach_max_count(36),
                   session_send_msg_fail(37),
                   session_md5_password_changed(38),
                   fsm_process_fail(39),
                   session_init_fail(40),
                   add_ftn_or_ilm_fail(41),
                   close_instance_close(42),
                   close_msg_proto_version_error(43),
                   close_session_backoff_callback_but_no_active_adj(44),
                   close_recv_bad_msg(45),
                   user_cleared_session_manually(46),
                   ldp_unconfigured_globally(47),
                   ldp_disabled_on_interface(48),
                   no_enough_memory(49),
                   ldp_global_config_change(50),
                   interface_vrf_changed(51),
                   ldp_router_id_changed(52),
                   interface_down(53),
                   recv_bad_length_msg(54),
                   recv_bad_tlv_len(55),
                   recv_malformed_tlv(56),
                   recv_internal_error(57),
                   recv_bad_pdu_length(58),
                   tcp_connect_not_correct(59),
                   nsm_client_close(60),
                   process_label_mapping_fail(61),
                   targeted_session_unconfigured(62),
                   switchover_process_gr(63),
                   local_host_process_gr(64),
                   reload_command(65),
                   te_interface_disabled_targeted_session(66),
                   targeted_hellos_no_longer_accepted(67)
                }
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Corresponding LDP session tear down reason of FEC nexthop."
    ::= { qtechMplsLdpFecEntry 11 }

mplsFecIngressBytes  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Received bytes by LSP,where 0 means does not support"
    ::= { qtechMplsLdpFecEntry 12 }

mplsFecIngressPackets  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Received packets by LSP,where 0 means does not support"
    ::= { qtechMplsLdpFecEntry 13 }

mplsFecTransmitBytes  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Forwarding bytes by LSP,where 0 means does not support"
    ::= { qtechMplsLdpFecEntry 14 }

mplsFecTransmitPackets  OBJECT-TYPE
    SYNTAX      INTEGER
    MAX-ACCESS  read-only
    STATUS      current
    DESCRIPTION
        "Forwarding packets by LSP,where 0 means does not support"
    ::= { qtechMplsLdpFecEntry 15 }
    

END
                
