Linux Ask!

Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.

Jul 112012
 

How to add a static route using command

Answer:

To add a static route, you can use a simple command like:

# sudo route add 192.168.15.0/24 192.168.1.1

The above command make all request to 192.168.15.0/24 (i.e. 192.168.15.1 to 192.168.15.254) route thru the gateway 192.168.1.1

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>