In static routing, the host must rely upon the services of a default router for routing information. Thus, enabling dynamic routing that uses a routing protocol is the easiest way to manage routing on a system.
Sites with multiple routers and networks typically administer their network topology as a single routing domain or an autonomous system (AS). The procedures and examples in this section are based on the figure used in Example 1, Configuring a System as a Router. In that figure, an AS is divided into three local networks: 203.0.113.0, 198.51.100.0, and 192.0.2.0. The network has both routers and client systems. The types of routers that are on a network include the following: border routers, default routers, and packet-forwarding routers. The types of client systems on a network include both multihomed systems and single-interface systems. For more details about each of these components, see IPv4 Autonomous System Topology in Planning for Network Deployment in Oracle Solaris 11.4.
Before You Begin
Ensure that your role has the appropriate rights profile to perform this procedure. See Using Rights Profiles to Perform Network Configuration.
For instructions, see How to Configure an IPv4 Interface in Configuring and Managing Network Components in Oracle Solaris 11.4.
You perform this step because the presence of any statically defined default routes prevents the enabling of dynamic routing during a system boot.
$ route -p show
$ route -p delete -net default -gateway ip-address
$ ipadm set-prop -p forwarding=off ipv4
$ svcadm enable route:default
When you start a routing protocol, the routing daemon /usr/sbin/in.routed automatically updates the routing table. This process is known as dynamic routing.
The following example shows how to configure dynamic routing for hosta, which is a single-interface system on the network 192.0.2.0, as shown in the figure in Example 1, Configuring a System as a Router. The system uses Router 1 as its default router. The example assumes that you have already configured the system's IP interface.
First, you would log into hosta with the appropriate rights. Then, you would remove all of the persistently defined routes from the system.
$ route -p show persistent: route add default 198.51.100.10 $ route -p delete default 198.51.100.10 delete net default: gateway 198.51.100.10 delete persistent net default: gateway 198.51.100.10
Then you would disable packet forwarding as well as enable routing on the system.
$ ipadm set-prop -p forwarding=off ipv4 $ svcadm enable route:default