TCP/IP Configuration  «Prev   Next»

Solaris Routing Command Configuration

How do I configure Routing command in Solaris?

  1. You are logged on with normal user permissions, and you are in the /home/user1 directory.
    Your systems administrator has updated the system PATH value to allow you to use the netstat and route commands.
    You are going to work with the routing table in order to further understand the significance of a properly configured routing table.
    Your IP address is 192.168.199.34. You are therefore on the 192.168.199.0 network. Issue the proper command to inspect your routing table.
    Solution: netstat -nr
  2. According to the readout, your default gateway is 192.168.199.1. You can see this by viewing the entry that says “default”. Then, look for the entry beneath “Gateway”. The default gateway is listed here (192.168.199.1). Send some ping packets to your default gateway.
    Solution: ping 192.168.199.1
  3. You now know that you can access your default gateway. Assert root privileges so that you can work with your routing table. Use rootpass as your password.
    Solution: su
  4. Now that you have root privileges, you can experiment with the routing table to further understand the consequences of a misconfigured routing table. Assume that the route command is in the execute path for the root shell. Delete the default gateway entry. Hint: Your command will involve the use of the word “default.”
    Solution: route delete default 192.168.199.1
  5. One of the many systems on your subnet has the IP address 192.168.199.129. Issue some ping packets to see if you can still reach this system.
    Solution: ping 192.168.199.129
  6. Notice that you can still connect to this system, even though you have deleted the default gateway from your system's routing table. This is because the system exists on the same subnet, and does not require a default gateway. Now, check to see if you can ping another host on another subnet. For example, the Acme Web server is on another subnet. Ping the host at www.acmecorp.com.
    Solution: ping www.acmecorp.com
  7. You receive error messages from ping indicating that there is no valid route to this host—this is because the Acme Web server exists on a different subnet. In order to send messages to this Web server, you require a router to intercede for you. Issue a command that creates a new default entry for your default gateway.
    Solution: route add default 192.168.199.1 Text for all other entries: Use the route command, then use add and specify the gateway address.
  8. Your interface has a default gateway, again. Test your connectivity by pinging the Acme Web server again.
    Solution: ping www.acmecorp.com