troubleshooting Question

setting service to run with lower privs

Avatar of schnibitz
schnibitz asked on
LinuxLinux SecurityLinux Distributions
3 Comments1 Solution602 ViewsLast Modified:
I've successfully set several perl scripts to run as services/daemons in centos5-ish.  I can issue the following:

service [servicename] start


service [servicename] stop

and the scripts will fire up, or shut down accordingly.  Problem: they're running as the root user context.  How do I get them to run as an unprivileged user?  Is setuid the way to go?  Or will that not work, or is there some other/better way?

Chris Sandrini
Senior System Engineer
Join our community to see this answer!
Unlock 1 Answer and 3 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros