IP CLI Commands
2/1553-ZAT 759 94 Uen B – December 2005
303
12.44
ip set route gateway
12.44.1 Syntax
ip set route {<name>|<number>} gateway <gateway>
12.44.2 Description
This command sets the gateway address of a route previously created using
the
ip add route
command. If you want the route to go directly to its
destination and not via a gateway, specify 0.0.0.0 as the gateway.
12.44.3 Options
The following table gives the range of values for each option which can be
specified with this command and a default value (if applicable).
Option Description
Default
value
name
A name that identifies an existing
route. To display route names, use the
ip list routes
command.
N/A
number
A number that identifies an existing
route. To display route numbers, use
the
ip list routes
command. The
number appears in the first column
under the heading ID.
N/A
gateway
The IP address of the gateway that the
IP routes through, displayed in the
following format:
192.168.102.3
If you added a route directly to an
interface, the gateway address is set
by default to 0.0.0.0 so that no
gateway is specified.
N/A
12.44.4 Example
-->
ip set route route1 gateway 192.168.102.3