HP-UX Routing Services Administrator’s Guide HP-UX 11i v2 Edition 1 Manufacturing Part Number: B2355-90777 August 2003 U.S.A. © Copyright 2003 Hewlett-Packard Development Company L.P. All Rights Reserved.
Legal Notices The information in this document is subject to change without notice. Hewlett-Packard makes no warranty of any kind with regard to this manual, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose. Hewlett-Packard shall not be held liable for errors contained herein or direct, indirect, special, incidental or consequential damages in connection with the furnishing, performance, or use of this material.
© Copyright 1989-93 The Open Software Foundation, Inc. © Copyright 1986 Digital Equipment Corporation. © Copyright 1990 Motorola, Inc. © Copyright 1990, 1991, 1992 Cornell University © Copyright 1989-1991 The University of Maryland © Copyright 1988 Carnegie Mellon University Trademark Notices UNIX is a registered trademark in the United States and other countries, licensed exclusively through The Open Group. Intel Itanium Processor Family is a trademark of Intel Corporation in the U.S.
Contents About This Document 1. Overview The mrouted Routing Daemon . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Multicasting Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . DVMRP Protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . IP Multicast Addresses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Contents D: Major Router. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 E: Major Router . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 Controlling RIP Traffic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 Configuring the OSPF Protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Contents Tracing gated Activity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Operational User Interface for gated – gdc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . The gated Routing Table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . The ripquery Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . The ospf_monitor Tool . . . . . . . . .
Contents 8
About This Document This manual describes the various routing daemons supported in the HP-UX 11i v2 operating system.It is one of the five new manuals documenting the Internet Services suite of products. See “Related Documentation” on page 11 for a list of the other new Internet Services manuals. These manuals replace the manual Installing and Administering Internet Services (B2355-90685), which was shipped with previous releases of the operating system.
Publishing History Table 2 provides, for a particular document, the manufacturing part number, the respective operating systems, and the publication date. Table 2 Publishing History Details Document Manufacturing Part Number Operating System Supported Publication Date B2355-90110 10.x June 1996 B2355-90147 11.0 October 1997 B2355-90685 11.11 11.20 11.22 December 2000 B5969-4360 11.
Related Documentation For more information about the Internet Services suite of products, see the following books: • HP-UX Internet Services Administrator’s Guide Provides an overview of the Internet Services products and describes how to install and configure them on your HP-UX 11i v2 operating system. You can access this manual at the following URL: http://www.docs.hp.com/hpux/netcom/index.
Many sections of this manual refer to RFCs for more information about certain networking topics. These documents publicize Internet standards, new research concepts, and status memos about the Internet. You can access the full range of RFC documents and more information about the Internet Engineering Task Force (IETF) at the following URL: http://www.ietf.org/rfc.
a hot link to the manpage itself. From the HP-UX command line, you can enter “man audit” or “man 5 audit” to view the manpage. See man (1). Book Title The title of a book. On the Web and on the Instant Information CD, it may be a hot link to the book itself. ComputerOut Text displayed by the computer. Command A command name, qualified command phrase, daemon, file, or option name. $ The system prompt for the Bourne, Korn, and POSIX shells. # The superuser prompt.
• 14 The version of HP-UX that you are using.
1 Overview A router is a device that has multiple network interfaces and that transfers Internet Protocol (IP) packets from one network or subnet to another within an internetwork. In many IP-related documents, this device is also referred to as a gateway.
Overview manual. The router stores all the routing information in the form of a routing table. Routing tables contain the routes to reach a particular network, and also identify the router to which the datagram packet can be passed for this purpose. The routing tables must contain the latest routing information. Routing protocols perform the task of updating the routing tables with the latest routing information.
Overview The mrouted Routing Daemon The mrouted Routing Daemon mrouted (pronounced “M route D”) is a routing daemon that forwards IP multicast datagrams, within an autonomous network, through routers that support IP multicast addressing. mrouted implements the Distance-Vector Multicast Routing Protocol (DVMRP). The ultimate destination of multicast datagrams are host systems that are members of one or more multicast groups.
Overview The mrouted Routing Daemon of the multicast datagrams. You can achieve this by using topological knowledge of the network to implement a multicast forwarding algorithm called Truncated Reverse Path Broadcasting (TRPB). mrouted structures routing information in the form of a pruned broadcast delivery tree that contains routing information. mrouted structures routing information only to those subnets that have members of the destination multicast group.
Overview The mrouted Routing Daemon In this figure, the mrouted router R1 receives a multicast packet from node M. Because R1 is configured as one end of a tunnel, R1 encapsulates the IP multicast packet in a standard unicast IP packet addressed to the mrouted router R2. The packet, now treated as a normal IP packet, is sent through the intervening nonmulticast network to R2. R2 receives the packet and removes the outer IP header, thereby restoring the original multicast packet.
Overview The mrouted Routing Daemon Normally, IP multicast addresses are mapped to 802.3 or Ethernet multicast addresses. The IP multicasting addressing scheme, similar to Ethernet’s scheme, uses the datagram’s destination address to indicate multicast delivery. When an IP multicast address is mapped to an Ethernet multicast address, the low-order 23 bits of the IP multicast address are placed into the low-order 23 bits of the special Ethernet multicast address.
Overview The mrouted Routing Daemon also defines IGMP message types that enable hosts to join and leave multicast groups, and that allow multicast routers to query one another for routing information.
Overview The gated Routing Daemon The gated Routing Daemon gated (pronounced “gate D”) is a routing daemon that updates routing tables in internetwork routers. Developed at Cornell University, gated handles the Routing Information Protocol (RIP), External Gateway Protocol (EGP), Border Gateway Protocol (BGP), Open Shortest Path First (OSPF) routing protocol, and the Router Discovery Protocol (RDP), or any combination of these protocols. Routing protocols are designed to find a path between network nodes.
Overview The gated Routing Daemon • gated translates among several protocols, passing information within or between IP routing domains or autonomous systems. Autonomous system (AS) is used here to refer to a group of connected nodes and routers in the same administrative domain that exchange routing information via a common routing protocol. • gated provides the system administrator flexibility in setting up and controlling network routing.
Overview The gated Routing Daemon Routing Protocols For routing purposes, networks and gateways are logically grouped into autonomous system (AS). Companies and organizations that want to connect to the Internet and form an AS must obtain a unique AS number from the Internet Assigned Numbers Authority (IANA). An interior gateway protocol distributes routing information within the autonomous system.
Overview The gated Routing Daemon • NOTE HELLO is designed to work with routers called Fuzzballs. Most installations use RIP or OSPF instead of HELLO. The HELLO protocol is no longer supported on HP-UX. You can use RIP or OSPF instead, because they are internal routing protocols. Do not mix RIP and OSPF protocols within a single network, because the routing information may conflict. Table 1-1 compares the advantages and disadvantages of the RIP and OSPF protocols.
Overview The gated Routing Daemon Table 1-1 Comparison of RIP and OSPF Protocols (Continued) RIP OSPF Disadvantage: RIP generates more protocol traffic than OSPF, because it propagates routing information by periodically transmitting the entire routing table to neighbor routers.
Overview The gated Routing Daemon packets. It is used instead of, or in addition to, a statically configured default router. Router discovery consists of two parts: a server part that runs on routers, and a client part that runs on hosts.
Overview The gated Routing Daemon 28 Chapter 1
2 Configuring mrouted This chapter describes how to configure mrouted and the various configuration commands in mrouted. It also provides information on starting and verifying the mrouted installation.
Configuring mrouted routing support tools.
Configuring mrouted How to Configure mrouted How to Configure mrouted When the mrouted daemon starts, it automatically reads the default configuration file /etc/mrouted.conf. You can override the default configuration file by specifying an alternate file while invoking mrouted. See “Starting mrouted” on page 36 for more information. If you change the /etc/mrouted.
Configuring mrouted How to Configure mrouted You can use the phyint command to disable multicast routing on the physical interface identified by the local IP address, local-addr (see Figure 2-1), or to associate a nondefault metric or threshold with the specified physical interface. Alternatively, you can replace the local IP address, local-addr, with the interface name, such as lan0.
Configuring mrouted How to Configure mrouted NOTE A phyint command must precede a tunnel command. All the phyint and tunnel command options must be placed on a single line except for the boundary and altnet options, which can begin on a separate line. Figure 2-1 Multicast Network Example Configuration mrouted Router Node 193.3.3.3 mrouted Router Node Node mrouted Router 195.5.5.5 mrouted Router 193.3.4.5 195.5.6.7 Node Nonmulticast phyint 193.3.3.3 Tunnel 193.3.4.5 195.5.5.5 Boundary 193.3.3.
Configuring mrouted How to Configure mrouted The TTL value of forwarded packets is only compared with the threshold value; it is not decremented by the threshold. An application that initiates the IP multicast datagram sets the TTL, and typically represents the number of subnets, or hops, the datagram has to traverse to reach its destination. Every time a multicast datagram passes through a multicast router, the TTL value is decremented by 1.
Configuring mrouted How to Configure mrouted those leaf subnets do not contain members of the multicast destination group. Use only nonpruning mode for testing. The default mode for pruning is on. You can use the name command to assign a name (boundary-name) to a boundary (a scoped-addr/mask-len pair) to simplify the configuration task. mrouted terminates if it has less than two enabled virtual interfaces (VIFs), where a VIF is either a physical multicast-capable interface or a tunnel.
Configuring mrouted Starting mrouted Starting mrouted You can start mrouted from the HP-UX prompt or from within a shell script by issuing the following command: /etc/mrouted [-p] [-c config_file] [-d debug_level] The -p option disables pruning by overriding the pruning on statement within the /etc/mrouted.conf configuration file. You must use this option for testing purposes only. The -c option overrides the default configuration file /etc/mrouted.conf.
Configuring mrouted Verifying mrouted Operation Verifying mrouted Operation You can use one or more of the following methods to verify mrouted operation: • Retrieve the virtual interface table and the multicast routing table to verify if appropriate virtual interfaces (vifs) are configured. See “Displaying mrouted Routing Tables” on page 38 for information on retrieving these tables.
Configuring mrouted Displaying mrouted Routing Tables Displaying mrouted Routing Tables mrouted contains three routing tables: the virtual interface table, the multicast routing table, and the multicast routing cache table. The virtual interface table displays the following topological information for each virtual interface: • Physical and tunnel interfaces. • The number of incoming and outgoing packets at each interface. • The value of specific configuration parameters, such as metric and threshold.
Configuring mrouted Displaying mrouted Routing Tables peers: 36.8.0.77 boundaries: 239.0.1 (2.2) 239.1.2 pkts in: 34545433 The multicast routing table displays connectivity information for each subnet from which a multicast datagram can originate. The multicast routing cache table is a duplicate copy of the kernel forwarding cache table. It contains the status information for multicast destination group-origin subnet pairs.
Configuring mrouted Displaying mrouted Routing Tables For more information on signals, type man 1M mrouted at the HP-UX command prompt, and see the Signals section.
Configuring mrouted Multicast Routing Support Tools Multicast Routing Support Tools This section describes various multicast routing support tools. The mrinfo Tool mrinfo is a multicast routing tool that requests configuration information from mrouted and prints the information to the standard output. By default, mrouted prints configuration information for its local instance. You can override the default request (the local instance of mrouted) by specifying an alternate router IP address or system name.
Configuring mrouted Multicast Routing Support Tools 42 Chapter 2
3 Configuring gated gated handles multiple routing protocols. You can configure the gated daemon to perform all or any combination of the supported protocols.
Configuring gated The HP-UX 11i v2 operating system supports gated 3.5.9. This chapter contains information about how to configure gated on various routing protocols. It also describes how to specify the tracing options and route preference in gated, and discusses certain troubleshooting measures.
Configuring gated Configuration Overview Configuration Overview Upon startup, gated reads the configuration file to decide how each protocol must be used to manage routing. By default, it uses the configuration file named/etc/gated.conf. Creating the configuration file is usually the responsibility of the system administrator. The configuration file can include up to eight sections (called classes) of configuration statements. You can define the statements further with optional clauses.
Configuring gated Configuration Overview If you do not want to use any of the gated 3.5.9 features added at HP-UX 10.30, and do not have any tracing configured in your gated 3.0 /etc/gated.conf configuration file, you can continue to use your 3.0 configuration file with gated 3.5.9. If you do have tracing configured in your gated 3.0 file, you must run the conv_config conversion tool on the file so that it follows the 3.5.9 syntax (see “Converting the Configuration File from 3.0 to 3.5.9” on page 48).
Configuring gated Configuration Overview 3. Add statements for any additional configuration information. See “Customizing Routes” on page 90, “Specifying Tracing Options” on page 92, and “Specifying Route Preference” on page 94 for other configuration options. In particular, you may want to prevent gated from deleting interfaces from the routing table when gated does not receive routing protocol information from that interface. To do this, insert passive interface definitions in the interfaces statements.
Configuring gated Configuration Overview NOTE You can also use the command gdc checkconf to parse the /etc/gated.conf file for syntax errors. gdc issues a message to indicate the parsing errors. If there are any errors, the error output is saved to a file for further inspection. For more details, type man 1M gdc at the HP-UX prompt. 6. Set the environment variable GATED to 1 in the file /etc/rc.config.d/netconf to invoke gated automatically when the system is started. 7.
Configuring gated Configuration Overview 1. Retain a copy of the gated 3.0 configuration file, because you cannot specify the same file for input and output while running the conv_config conversion tool. For example, if you are using /etc/gated.conf for 3.0, type the following command: cp /etc/gated.conf /etc/gated.conf.30 2. Issue the following command at the HP-UX prompt: conv_config < input_config_file_name > output_config_file where input_config_file_name is the name of the gated 3.
Configuring gated Configuring the RIP Protocol Configuring the RIP Protocol RIP uses hopcount to determine the shortest path to a destination. Hopcount is the number of routers a packet must pass through to reach its destination. If a path is directly connected, it has the lowest hopcount of 1. If the path passes through a single router, the hopcount increases to 2. Hopcount can increase to a maximum value of 16, which is RIP’s infinity metric, an indication that a network or node cannot be reached.
Configuring gated Configuring the RIP Protocol trustedgateways router_list ; sourcegateways router_list ; traceoptions traceoptions ; } ] ; Curly braces ({}) are part of the syntax for the RIP protocol statement. Square brackets ([]) are not part of the syntax; they are used here to indicate optional parameters. yes (or on) informs gated to enable the RIP protocol at this node and to process RIP packets coming in from other nodes. no (or off) informs gated to disable the RIP protocol at this node.
Configuring gated Configuring the RIP Protocol Range: 1 – 16 • query authentication [none|[[simple|md5] password]] specifies the authentication, if any, that is required for query packets that do not originate from routers. If authentication consisting of only a password is required, specify simple password or password. If the required authentication consists of a key that was created with the MD5 algorithm, specify md5. Default: none.
Configuring gated Configuring the RIP Protocol • [secondary] authentication [none|[simple|md5] password] specifies the type of authentication for RIP Version 2 packets (it is ignored for Version 1 packets). secondary indicates that the secondary authentication is defined; otherwise, the primary authentication is defined. If authentication consisting of only a password is required, specify simple password or password (where password is a quoted string of 0 – 16 characters).
Configuring gated Configuring the RIP Protocol Simple RIP Configuration A simple RIP configuration consists of RIP routers and end nodes that listen to information exchanged by the RIP routers, as shown in Figure 3-1. Figure 3-1 and the accompanying text describe configuration of a single end system (node A) and a RIP router (node B). The configuration is the same for multiple end systems and RIP routers (only node B’s configuration is shown here).
Configuring gated Configuring the RIP Protocol With one interface, A can listen to RIP traffic on the network but does not forward routing information. Routers must be multicasting RIP packets on this network for A to learn about them and update its routing table. The first syntax statement enables RIP on node A’s interface (121.1.0.10) to multicast routing information. The second statement specifies a static local default route to prevent gated from deleting it. B: RIP Router Set up /etc/gated.
Configuring gated Configuring the RIP Protocol Figure 3-2 Example of Large RIP Network D: Major Router A: Cluster Node or Isolated Node 134.5.0.1 A 121.1.0.2 130.15.0.5 D 133.4.0.1 130.15.0.0 (network number) B 130.15.0.6 132.5.0.1 121.1.0.92 B: Root Server 121.1.0.0 (network number) F: Single Node 121.1.0.10 C: Single Node E: Major Router 121.1.0.15 136.5.0.1 C F 136.5.0.0 (network number) E 132.6.0.1 131.5.0.
Configuring gated Configuring the RIP Protocol B: Cluster (or Root) Server Node Run gated to get routing information about the 121.0.0.0 network. Set up /etc/gated.conf as follows: interfaces { interface 130.15.0.6 121.1.0.92 passive ; }; rip yes { interface 130.15.0.6 noripout ; interface 121.1.0.92 version 2 multicast; }; static { default gateway 121.1.0.2 preference 255 ; }; In the previous example, setting rip to yes is similar to setting rip to broadcast.
Configuring gated Configuring the RIP Protocol rip yes { interface 121.1.0.10 version 2 multicast; }; static { default interface 121.1.0.10 preference 255 ; }; With one interface, C can listen to RIP traffic on the network but does not forward routing information. Routers must be multicasting RIP packets on this network for C to learn about them and to update its routing table. D: Major Router Set up /etc/gated.
Configuring gated Configuring the RIP Protocol The options for limiting RIP routing information imported by gated in the RIP protocol definition in the /etc/gated.conf file are as follows: • The noripin clause in the interface definition informs gated not to process RIP information received through the listed interfaces. • The trustedgateways clause informs gated to listen to RIP information received only from the specified routers.
Configuring gated Configuring the OSPF Protocol Configuring the OSPF Protocol Open Shortest Path First (OSPF) is a link-state routing protocol that distributes routing information between routers in a single autonomous system (AS). Each OSPF router transmits a packet with a description of its local links to all other OSPF routers. The distributed database is built from the collected descriptions.
Configuring gated Configuring the OSPF Protocol Figure 3-3 Areas Defined in an Autonomous System Area 1 C 1 A B 2 3 Other AS D E Legend: Network F Router I Area 2 Area Area 3 4 G 5 H 6 Backbone Internal routers have all their directly connected networks in the same area. In Figure 3-3, routers A, B, and H are internal routers. Routers that are connected to multiple areas are called area border routers. In Figure 3-3, routers F and G are area border routers.
Configuring gated Configuring the OSPF Protocol Multi-access networks (networks that can be accessed through two or more neighbor routers) must have one of the routers identified as a designated router. Designated routers initiate OSPF protocol functions on behalf of the network. In Figure 3-3, you can access network 1 through the neighbor routers A, B, or C; one of these routers is elected to become the designated router for network 1.
Configuring gated Configuring the OSPF Protocol it is not required that an AS boundary router be a backbone router. An AS boundary router learns about routes other than its attached AS through exchanges with other routing protocols or through configuration information. Each AS boundary router calculates paths to destinations outside of its attached AS. It then advertises these paths to all routers in its AS.
Configuring gated Configuring the OSPF Protocol 6. For multi-access networks, identify a designated router. For NBMA networks, several routers can be designated router candidates. Designated routers are specified in the interface definitions (see “The interface Statement” on page 67). 7. You must decide if you want to assign a cost to each interface. See “Cost” on page 79 for more information about costs. 8. Designate stub areas.
Configuring gated Configuring the OSPF Protocol The following sections explain other statements defined for the OSPF protocol configuration. Defining Areas Each OSPF router is associated with one or more areas. The area statement identifies an OSPF area. The value is in the form of a dotted quad, or a number between 1 and 4294967295. To define an area, you must specify the following: • The addresses of the networks that make up the area. • The router interfaces used to communicate with the area.
Configuring gated Configuring the OSPF Protocol You can define various characteristics for an area and interfaces. The following sections describe the configuration statements that you can use in defining an area. The networks Statement The networks statement defines the address ranges that forms an OSPF area. This definition applies only to area border routers, where multiple areas are specified, and is required only if you need to compress a number of subnets using a network mask.
Configuring gated Configuring the OSPF Protocol The following is an example of the network definition in the Router A’s /etc/gated.conf file: ospf yes area 0.0.0.1 networks { 193.2.1.16 mask 0xfffffff0 ; 193.2.1.32 mask 0xfffffff0 ; } ; interface 193.2.1.33 { ... } ; } ; ... The interface Statement The interface statement in the OSPF protocol definition specifies the interface to use while communicating with the specified networks. You can specify the interface with an address (for example, 193.2.1.
Configuring gated Configuring the OSPF Protocol • A point-to-point network is a network that joins a single pair of routers. An example of a point-to-point network is a 56-KB serial line. The following sections describe each type of interface. Multicast Interfaces On multicast networks, an OSPF router dynamically detects its neighbor routers through the OSPF Hello message.
Configuring gated Configuring the OSPF Protocol Default: None (you must specify a value) Range: Integer between 0 – 255 NOTE The hellointerval value must be the same for all OSPF routers. • routerdeadinterval specifies the time interval (in seconds) for which the Hello packets are not received from a router before it is considered down or inactive by its neighbors. This value must be a multiple of the hellointerval value.
Configuring gated Configuring the OSPF Protocol Figure 3-6 shows an example of a router that is connected to a multicast network through the interface 193.2.1.35. Figure 3-6 Multicast Router Interface Example Router 193.2.1.35 Network Network Network Router The following is an example of the multicast interface definition in the router’s /etc/gated.conf file: interface 193.2.1.
Configuring gated Configuring the OSPF Protocol specified by the routerdeadinterval definition). The value of pollinterval must be larger than the value of hellointerval. A sample value for an X.25 network is 2 minutes. Default: None (you must specify a value) Range: 0 – 255 • routers specify the list of routers attached to the non-broadcast network. Routers are defined by their IP interface addresses. You must define the routers that are eligible to be designated routers as eligible.
Configuring gated Configuring the OSPF Protocol interface 193.2.1.35 nonbroadcast cost 5 { routers { 193.2.1.33 eligible ; 193.2.1.46 eligible ; } ; priority 15 ; hellointerval 5 ; routerdeadinterval 20 ; retransmitinterval 10 ; pollinterval 20 ; } ; Point-to-Point Interfaces On point-to-point networks, an OSPF router dynamically detects its neighbor router by sending OSPF Hello packets.
Configuring gated Configuring the OSPF Protocol • routerdeadinterval specifies the time interval (in seconds) for which the Hello packets are not received from a router before it is considered down or inactive by its neighbors. This value must be a multiple of the hellointerval value. Default: None (you must specify a value) Range: 0 – 65535 NOTE The routerdeadinterval value must be the same for all OSPF routers. You can define a point-to-point interface with or without a nonbroadcast clause.
Configuring gated Configuring the OSPF Protocol Figure 3-8 shows an example of a router (A) that is connected to a non-broadcast, point-to-point network through interface 193.2.1.1. Figure 3-8 Point-to-Point Router Interface Example Router A 193.2.1.1 193.2.1.2 Router B The following is an example of the interface definition in router A’s /etc/gated.conf file: interface 193.2.1.
Configuring gated Configuring the OSPF Protocol Figure 3-9 shows an example of an area border router that is connected to area 0.0.0.2 through interface 193.2.1.20. Because all traffic in and out of the area 0.0.0.2 must pass through router A, it is not necessary for the area’s internal routers, such as router B, to receive inter-area routing information. Figure 3-9 Area Border Router Configuration Example Area 0.0.0.1 Area 0.0.0.2 193.2.1.16 mask 0xfffffff0 193.2.1.17 Router A Router B 193.2.1.
Configuring gated Configuring the OSPF Protocol Defining Backbones The OSPF backbone distributes routing information between areas. You can define backbones with the same statements and clauses as areas. You need not define the stub statement for a backbone. The backbone statement is used to define a router as a backbone router. If an OSPF internal or area boarder router is also a backbone router, the backbone statement must follow the area statements in the /etc/gated.conf file.
Configuring gated Configuring the OSPF Protocol backbone { interface 15.13.115.156 { enable ; transitdelay 20 ; priority 20 ; hellointerval 30 ; routerdeadinterval 120 ; retransmitinterval 60 ; } ; } ; If the router is directly attached via a point-to-point interface to a host that is not running OSPF, you can prevent sending OSPF Hello packets to the host. Do this by specifying the subhost statement with the host’s address. You can optionally define the cost.
Configuring gated Configuring the OSPF Protocol configured on a per-interface basis. If a router has interfaces to more than one network, different passwords can be configured. This is illustrated in Figure 3-11.
Configuring gated Configuring the OSPF Protocol retransmitinterval 10 ; pollinterval 20 ; authkey " travis " ; } ; } ; Cost The outbound side of each router interface is associated with a configurable cost. Lower cost interfaces are more likely to be used in forwarding data traffic. Cost values are assigned at the discretion of the network or system administrator.
Configuring gated Configuring the OSPF Protocol In Figure 3-12, there are two possible packet routes between nodes A and D: one route goes through node B and the other route goes through node C. The cost of each route is calculated as follows: Node A to node B and node B to node D: 5+5 = 10 Node A to node C and node C to node D: 5+10 = 15 The lowest cost OSPF path between nodes A and D is therefore through node B.
Configuring gated Configuring the OSPF Protocol gated supports the use of route information from other autonomous systems that use other routing protocols, such as EGP. AS boundary routers send AS external link advertisements and flood the AS with advertisements (with the exception of configured stub areas). A single AS external link advertisement is sent for each external route that the AS boundary router has learned about.
Configuring gated Configuring the OSPF Protocol value can be an unsigned 31-bit number. You can also specify tag as as_tag, where as_tag is an unsigned 12-bit number that is automatically assigned. • type determines how ASE routes imported into OSPF are treated. Type 1 routes must be routes from internal gateway protocols with external metrics that are directly comparable to OSPF metrics.
Configuring gated Configuring the OSPF Protocol Sample OSPF Configuration Figure 3-13 shows an example of two areas. Area 1 is a non-stub area, while area 2 is configured as a stub area. Node B is an area border router between the two areas. Figure 3-13 OSPF Sample Configuration Area 1 (Non-Stub) A 193.2.1.35 LAN 1 193.2.1.32 193.2.1.33 B 15.13.115.156 193.2.1.17 LAN 2 193.2.1.16 193.2.1.20 C Area 2 (Stub) A: Internal Router (Non-Stub Area) Set up /etc/gated.
Configuring gated Configuring the OSPF Protocol # Router A Configuration OSPF yes { area 0.0.0.1 { interface 193.2.1.35 priority 5 ; enable ; hellointerval 5 ; routerdeadinterval retransmitinterval } ; } ; } ; (non-stub area) cost 5 { 20 ; 10 ; The configuration for the internal router A is for a multicast interface. For an NBMA interface, you can set the configuration in /etc/gated.conf as follows: # Router A Configuration (non-stub area) OSPF yes { area 0.0.0.1 { interface 193.2.1.
Configuring gated Configuring the OSPF Protocol } ; area 0.0.0.1 { interface 193.2.1.33 cost 5 { priority 15 ; enable ; hellointerval 5 ; routerdeadinterval 20 ; retransmitinterval 10 ; } ; } ; area 0.0.0.2 { interface 193.2.1.17 cost 5 { priority 15 ; enable ; hellointerval 5 ; routerdeadinterval 20 ; retransmitinterval 10 ; } ; } ; backbone { interface 15.13.115.
Configuring gated Configuring the OSPF Protocol The routing table on node A contains routes to 193.2.1.32 and 193.2.1.16. The routing table on node C in the stub area contains routes only to LAN 1 and a default router. Accessing the OSPF MIB HP’s gated also provides ospfagt, an OSPF Simple Management Network Protocol (SNMP) subagent that supports the OSPF MIB (Management Information Base) (see RFC 1253). The ospfagt subagent works with the HP SNMP Agent, snmpdm.
Configuring gated Configuring RDP Configuring RDP You can use Router Discovery Protocol (RDP), a standard protocol, to inform hosts of the presence of routers to which they can send packets. You can also use RDP instead of host wiretapping routing protocols (for example, RIP). It is used instead of, or in addition to, having statically configured default routes in hosts. RDP consists of two portions: the server portion, which runs on routers, and the client portion, which runs on hosts.
Configuring gated Configuring RDP configured on the physical interface. If advertisements are sent to a net or subnet broadcast, only that network’s or subnet’s address is included in the advertisement. An example of the routerdiscovery server statement is as follows: routerdiscovery server yes { interface lan1 lan2 maxadvinterval 5 ; address 193.2.1.17 193.2.1.33 193.2.1.
Configuring gated Configuring RDP The host also deletes any routes learned from ICMP redirects pointing to the invalid addresses. Also, if a router advertisement is not received before the addresses listed by the host becomes invalid (that is, before its lifetime expires), the routes learned from that router are deleted by the host.
Configuring gated Customizing Routes Customizing Routes gated maintains the routing table in user space, and synchronizes this table with the kernel routing table. This section describes statements for setting up customized routes in the Static class of the gated configuration file, /etc/gated.conf. You can use these statements to specify default routers, static routes, passive interfaces, and routing metrics for interfaces.
Configuring gated Customizing Routes Setting Interface States gated times out routes that pass through interfaces not receiving any RIP, OSPF, or BGP packets. The passive clause in the interface statement of the Static class prevents gated from changing the preference of a route to the interface if routing information is not received for the interface. HP recommends that you use the passive clause for all interfaces.
Configuring gated Specifying Tracing Options Specifying Tracing Options Trace options specify the desired level of tracing output from gated. Tracing output provides useful system information for setting up a node on the network. Use trace options to set up a node and to send a certain type of tracing to a log file. You can specify tracing in the following ways: • In a protocol statement in the /etc/gated.conf configuration file. • In the Trace class of the /etc/gated.conf configuration file.
Configuring gated Specifying Tracing Options Table 3-2 Protocol-Related Global Trace Options for gated Configuration Files (Continued) Option Effect timer Traces the timer usage by this protocol or peer. route Traces all routing table changes for routes installed by this protocol or peer. general A combination of normal and route. all Enables all tracing options. Some of the options specified in Table 3-2 do not apply to all of the protocols.
Configuring gated Specifying Route Preference Specifying Route Preference gated maintains a routing table that consists of the route information learned from OSPF and from other active routing protocols, such as RIP or EGP. You can also configure static routes in the /etc/gated.conf file with one or more static clauses (see “Installing Static Routes” on page 90 for more information). The gated routing pool can therefore contain multiple routes to a single destination.
Configuring gated Specifying Route Preference Table 3-3 Default Preference Values of Routes (Continued) Route Type Preference /etc/gated.config Configuration Static routes 60 Can be changed in static statement in Static class. RIP 100 Can be changed with import statement in Control class. Point-to-point interface 110 Can be changed with interface statement in Interface class. “Down” interface 120 Can be changed with interface statement in Interface class.
Configuring gated Specifying Route Preference 96 • In a defaults statement in the OSPF protocol configuration. This preference definition specifies the preference value of ASE routes that are imported into OSPF. See “AS External Routes (AS Boundary Routers Only)” on page 80 for more information. ASE routes are imported into OSPF with a default preference of 150. • In an import statement in the Control class of the /etc/gated.conf file.
Configuring gated Importing and Exporting Routes Importing and Exporting Routes You can propagate routes from one routing protocol to another using the import and export control statements. Routes are imported into a gated forwarding table and exported out to the routing protocols. For more information on import and export statements, type man 4 gated.conf at the HP-UX prompt. The import Statement import statements restrict or control routes that are imported to the gated forwarding table.
Configuring gated Importing and Exporting Routes Examples of import and export Statements The following import statement imports a BGP route for network 195.1.1 to the gated forwarding table with a preference of 15: import proto bgp as 1 { 195.1.1 mask 0xffffff00 preference 15; }; The following export statement exports to OSPF the ASE route that was imported to the gated forwarding table in the previous example. The route was originally built by BGP and the destination of the route is network 195.1.1.
Configuring gated Starting gated Starting gated To start gated, complete the following steps: 1. Set the environment variable GATED to 1 in the file /etc/rc.config.d/netconf to start gated automatically upon system startup. 2. Reboot your system, or issue the following command to run the gated startup script: /sbin/init.d/gated start You can also start gated by running the command gdc start.
Configuring gated Starting gated Table 3-4 Command Line Options for gated (Continued) Flag Effect -n Specifies that gated will not modify the kernel’s routing tables. For more information about the command-line options, type man 1M gated at the HP-UX prompt. Verifying That gated Is Running Issue the following command to determine if gated is running: /usr/bin/ps -ef | /usr/bin/grep gated This command reports the process identification (PID), current time, and the command invoked (gated).
Configuring gated Troubleshooting gated Troubleshooting gated This section describes the following techniques for troubleshooting gated and some common problems encountered with gated operation: • “Checking for Syntax Errors in the Configuration File” on page 101 • “Tracing gated Activity” on page 101 • “Operational User Interface for gated – gdc” on page 102 • “The gated Routing Table” on page 103 • “The ripquery Tool” on page 103 • “The ospf_monitor Tool” on page 103 • “Common Problems” on p
Configuring gated Troubleshooting gated NOTE In gated 3.5.9, the two statements in the Trace class (tracefile and traceoptions) are combined into one traceoptions statement. Therefore, the tracefile statement is eliminated. For details about the new syntax, type man 4 gated.conf at the HP-UX prompt. After tracing is started to a file, you can rotate the trace file. Receipt of a SIGUSR1 signal stops gated from tracing and closes the trace file. The trace file can then be moved out of the way.
Configuring gated Troubleshooting gated gdc determines the state of gated and produces a reliable exit status during errors, which is useful in shell scripts that manipulate gated. The syslogd facility is used to log all the commands and error messages generated during gdc operation. gated uses these log messages to provide an audit trail of operations performed on the daemon. For more information, type man 1M gated at the HP-UX prompt.
Configuring gated Troubleshooting gated Common Problems This section discusses the common problems experienced during gated operation. Problem 1: gated does not act as expected. First, check the syslogd output for any syntax errors that may have been flagged. To detect incorrect configuration commands, use gated tracing. Following are two sample configurations, along with the trace files generated by gated. The node used has three interfaces: lan0, lan1, and lan2.
Configuring gated Troubleshooting gated Interface Configuration Without strictintfs Option Specified The following configuration references a non-existent interface, but does not include the strictintfs option: traceoptions "tt" general; interfaces { interface lan0 lan1 lan3 passive ; } ; rip yes ; The following is the tracing output that is produced when gated is started with this configuration: trace_on: Tracing to "/tt" started Tracing flags enabled: general inet_routerid_notify: Router ID: 15.13.119.
Configuring gated Troubleshooting gated lan2 Index 3 Address 802.2 8:0:9:3d:2c:b1 State: <> Refcount: 2 Up-down transitions: 0 198.1.1.17 Metric: 0 Refcount: 4 Change: <> Change: <> MTU: 1436 Preference: 0 Down: 120 State: Broadcast Address: 198.1.1.255 Subnet Number: 198.1.1 Subnet Mask: 2 55.255.255 lan1 Index 4 Address 802.2 8:0:9:3d:3c:69 State: <> Refcount: 2 Up-down transitions: 0 198.2.1.
Configuring gated Troubleshooting gated Normally, gated deletes the route configured in the /etc/rc.config.d/netconf file. To solve this problem, configure a static default route as described in the section “Installing Static Routes” on page 90. Another common scenario occurs in networks where all the gateways do not implement the gated routing protocols.
Configuring gated Troubleshooting gated You may have to repeat this process several times to track down the original source of the route. If you expect the route to go through a different router, turn on gated tracing. The tracing tells you which routers are advertising this route and the values attached to those routes. Problem 4: gated does not add routes that you think it must. Tracking down this problem is similar to the previous problem (“Problem 3: gated adds routes that appear to be incorrect.
Index A all hosts group, 19 area border router, 61 configuration example, 75 area statement in /etc/gated.conf file, 65 areas, OSPF, 63 example configuration, 65 AS, 23 See autonomous system Assigned Numbers Authority, 63 authentication in OSPF, 77 authkey statement in /etc/gated.conf file, 69, 78 authtype statement in /etc/gated.
Index priority statement, 68 query authentication clause, 52 retain clause, 90 retransmitinterval statement, 68, 72 rip statement, 50 ripin clause, 52 ripout clause, 52 routerdeadinterval statement, 69, 73 routers statement, 71 secondary authentication clause, 53 sourcegateways clause, 51, 53, 58 static statement, 90 stub statement, 74 stubhosts statement, 73, 80 tag value, 82 traceoptions statement, 53 transmitdelay statement, 68 trustedgateways clause, 53, 59 type value, 82 version clause, 52 /etc/mrouted
Index IP type of service routing feature, 24 K kernel routing table, 22, 100 L link state advertisement, 62 M management information base See MIB metricin clause in /etc/gated.conf file, 52 metricout clause in /etc/gated.conf file, 52 MIB, 24 mixing protocols, 25 mrouted configuration command phyint command, 31 tunnel command, 32 logging, 36 routing tables, 38 starting, 36 support tools, 41 verifying operation, 37 mrouted.cache file, 38 multicast clause in /etc/gated.
Index password authentication in OSPF, 78 configuration example, 78 phyint command in mrouted, 32 point-to-point network interface, 68, 72 configuration example, 74 pollinterval statement in /etc/gated.conf file, 71, 73 preference clause in /etc/gated.conf file, 51, 81, 94 priority statement in /etc/gated.conf file, 68 pruned broadcast delivery tree, 18 pruning command in mrouted, 35 Q query authentication clause in /etc/gated.
Index TOS routing feature, 24 traceoptions statement in /etc/gated.conf file, 53 tracing gated, 92, 99, 101 transmitdelay statement in /etc/gated.conf file, 68 TRPB, 18 Truncated Reverse Path Broadcasting, 18 See TRPB trustedgateways clause in /etc/gated.conf file, 53, 59 TTL in mrouted, 33 tunnel command in mrouted, 32 tunnelling in mrouted, 18 type of service See TOS type value in /etc/gated.conf file, 82 U /usr/tmp/mrouted.dump file, 38 V /var/adm/syslog/syslog.log file, 36 /var/tmp/mrouted.