Results 1 to 3 of 3
If I wanted to implement the equivalent of the system call
'sysctl -w net.ipv4.ip_forward=1'
in code, any pointers on how I can do that?
I can make a system call ...
- 06-22-2009 #1Just Joined!
- Join Date
- May 2009
- Posts
- 6
Equivalent of sysctl
If I wanted to implement the equivalent of the system call
'sysctl -w net.ipv4.ip_forward=1'
in code, any pointers on how I can do that?
I can make a system call but i wanted to know if there is an alternative..
TIA
- 06-22-2009 #2Just Joined!
- Join Date
- May 2009
- Posts
- 6
to clarify, i want to avoid the 'syscall'..
- 06-22-2009 #3Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 8,974
I suspect not since these are kernel settings and you need to use a system call in order to communicate with the kernel, AFAIK.
So, why are you trying to avoid the use of syscall or the command sysctl?Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!


Reply With Quote