Open Ethernet Networking (OpEN) API Guide and Reference Manual
3.6.0.3
|
This document provides a brief description of the OSPF OpEN APIs. The OSPF OpEN APIs allow processes outside of the ICOS main process (switchdrvr) access to OSPF and its routing management services.
In addition to providing the ability to create and delete an OSPF router with its router id, the global OpEN_API's available are;
In addition to providing the ability to create and delete OSPF routes and areas, the following OpEN API's are available for managing OSPF on specific interfaces;
All 'Set' operations would affect the Switch behavior and configuration.
In the main function, the sample application initializes the OpEN API RPC service by calling openapiClientRegister() and waits for the RPC service in switchdrvr to start. A Client Handle is returned by openapiClientRegister() which is used while invoking the OpEN APIs. The application then exercises the associated OpEN APIs and logs informational and/or error messages on the console. The example application runs to its completion and exits.
ospf_example.c is a sample application that demonstrates the use of the OSPF OpEN API. ospf_example is started from the command line. The example first establishes a OSPF entry with a Router Id of 9.0.0.3. The example continues to test the ability to set and get the available global attributes. The following is a list and sequence of these tests;
CLI Command | OpEN API Reference |
---|---|
(Config)# router <id> | openapiOspfMapRouterIdGet() openapiOspfMapRouterIdSet() |
(Config-router)# [no] 1583compatability | openapiOspfMapRfc1583CompatibilityGet() openapiOspfMapRfc1583CompatibilitySet() |
(Config-router)# [no] auto-cost <reference-bandwidth> <bandwidth> | openapiOspfMapAutoCostRefBwGet() openapiOspfMapAutoCostRefBwSet() |
(Config-router)# [no] timers spf <delay-time> <hold-time> | openapiOspfMapSpfDelayTimeGet() openapiOspfMapSpfDelayTimeSet() openapiOspfMapSpfHoldTimeGet() openapiOspfMapSpfHoldTimeSet() |
(Config-router)# [no] log-adjacency-changes [detail] | openapiOspfMapLogAdjChngGet() openapiOspfMapLogAdjChngSet() |
(Config-router)# [no] max-metric router-lsa [summary-lsa <lsa>] [on-startup <startup>] | openapiOspfMapStubRtrModeSet() openapiOspfMapStubRtrSumLsaMetricOverride() openapiOspfMapStubRtrModeGet() |
(Config-router)# [no] distance ospf external <distance> [no] distance ospf inter-area <distance> [no] distance ospf intra-area <distance> | openapiIpRouterPreferenceGet() openapiIpRouterPreferenceSet() |
(Config-router)# [no] maximum-paths <paths> | openapiOspfMapMaxPathsGet() openapiOspfMapMaxPathsSet() |
(Config-router)# [no] redistribute bgp [metric <metric>] [metric-type <type>] [tag <tag>] [subnets] [no] redistribute connected [metric <metric>] [metric-type <type>] [tag <tag>] [subnets] [no] redistribute rip [metric <metric>] [metric-type <type>] [tag <tag>] [subnets] [no] redistribute static [metric <metric>] [metric-type <type>] [tag <tag>] [subnets] | openapiOspfMapRedistributionSet() |
(Config-router)# [no] trapflags <all|errors|lsa|overflow|retransmit|state-change> | openapiOspfTrapModeGet() openapiOspfTrapModeSet() |
(Config-router)# [no] area <id> nssa|stub [no-summary] | openapiOspfMapImportAsExternGet() openapiOspfMapImportAsExternSet() |
(Config-router)# [no] passive-interface <slot/port>|default|vlan | openapiOspfMapIntfPassiveModeGet() openapiOspfMapIntfPassiveModeSet() |
(Routing) (Interface)# [no] ip ospf area <id> | openapiOspfMapIntfAreaIdGet() openapiOspfMapIntfAreaIdSet() |
(Routing) (Interface)# [no] ip ospf area <id> secondaries | openapiOspfMapIntfSecondariesFlagGet() openapiOspfMapIntfSecondariesFlagSet() |
(Routing) (Interface)# [no] ip ospf cost <cost> | openapiOspfMapIntfMetricValueGet() openapiOspfMapIntfMetricValueSet() |
(Routing) (Interface)# [no] ip ospf network broadcast|point-to-point | openapiOspfMapIntfTypeGet() openapiOspfMapIntfTypeSet() |
(Routing) (Interface)# [no] ip ospf dead-interval <interval> | openapiOspfMapIntfDeadIntervalGet() openapiOspfMapIntfDeadIntervalSet() |
(Routing) (Interface)# [no] ip ospf hello-interval <interval> | openapiOspfMapIntfHelloIntervalGet() openapiOspfMapIntfHelloIntervalSet() |
(Routing) (Interface)# [no] ip ospf | openapiOspfMapIntfPassiveModeGet() openapiOspfMapIntfPassiveModeSet() |