You can add a static route to the SMS by utilizing the SMS CLI command "set route.add" or by running the "routes" CLI command.
Note: The syntax for the command would be <destination> <network mask> <gateway>
Sample:
SMS=> routes
Route options allow static routes to be added or deleted for the network management interface.
IPv4 management interface routes
Destination Gateway Genmask Flags Metric Ref Use
192.168.96.0 0.0.0.0 255.255.252.0 U 0 0 0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0
0.0.0.0 192.168.98.2 0.0.0.0 UG 0 0 0
Would you like to: [A]dd or [D]elete an IPv4 route, or [E]xit? <[A],D,E>:
Sample:
SMS=> set route.add
Add IPv4 static route (route.add=[]) = 172.16.0.0 255.255.0.0 192.168.111.111
Result: Success
To view the SMS routing table you can use the "get route" command:
SMS=> get route
IPv4 management interface routes (route.info) =
Destination Gateway Genmask Flags Metric Ref Use
192.168.111.0 0.0.0.0 255.255.255.0 U 0 0 0
172.16.0.0 192.168.111.111 255.255.0.0 UG 0 0 0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0
0.0.0.0 192.168.111.1 0.0.0.0 UG 0 0 0
Result: Success
Note: The Static route added is persistent (The route entry will remain after a system reboot)
How To: Delete a Static Route
To delete a static route you can use the "set route.del" command or the "routes" CLI command.
Sample:
SMS=> set route.del
Delete IPv4 static route (route.del=[]) = 172.16.0.0 255.255.0.0 192.168.111.111
Result: Success
To view the SMS routing table you can use the "get route" command:
Sample:
SMS=> get route
IPv4 management interface routes (route.info) =
Destination Gateway Genmask Flags Metric Ref Use
192.168.111.0 0.0.0.0 255.255.255.0 U 0 0 0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0
0.0.0.0 192.168.111.1 0.0.0.0 UG 0 0 0