LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Use pthread scheduling policy without root user (https://www.linuxquestions.org/questions/programming-9/use-pthread-scheduling-policy-without-root-user-855947/)

papaLou 01-12-2011 05:15 PM

Use pthread scheduling policy without root user
 
I am working on a large program in C to run on Puppy Linux. I have multiple pthreads running. I want to be able to set the pthread SCHED_POLICY and priority in my program but I want a user to be able to run the program without root privilege.
Using a sticky bit and root ownership gives the user too much power because they will be able to write and compile their own scripts.
Is there a way to use 'sudo' when I set the thread parameters from my program or something like this?

Thank you.
lou

P42 01-20-2011 09:21 AM

system(sudo --args command);


All times are GMT -5. The time now is 06:27 AM.