I want to run command line program such as,
# ifconfig eth0 up/down
# route add default gw

from a Java program using the Runtime.exec() command. But when I run the program, no message is showing and silently discarded and have no impact on the system.
Plz tell me, how is can be done.
From other commands, such as, ifconfig, route, I can capture the output.

And how can a program be run in privileged mode without any user interaction?

Thanks in advance.