This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Manual Network Route
Hey Guys,

Is it possible top add a Network Route manually?
os.execute('route add ...')
For routes to persist between reboots add your code to the init script.
Thanks Admin,

But not working yet.

I try:
os.execute('ip route add via')
os.execute('ip route add netmask gw eth0')

No script errors loged.
If the Route is added will it be shown in the Route window?

Im Using Schneider Spacelynk maybe this is the reason?
Try this:
res = io.readproc('route add -net gw eth0 2>&1')
You might also need to disable "Block unsafe functions in scripts" in Utilities > General configuration.
It works! Big Grin 


Forum Jump: