Solved

Need assistance running PHP EXEC as local user on Ubuntu

Posted on 2013-12-05
5
485 Views
Last Modified: 2013-12-11
I know there are a number of ways to do this, but looking for something very simple to do.

I need to launch the following vlc script via PHP & EXEC, as a local user. I currently can run it as www-data, but I need to launch it with a user that has a home directory.

vlc -I dummy dvb:// :dvb-adapter=0 --sout '#standard{access=http,mux=ogg,dst=10.10.1.83:8181}'
0
Comment
Question by:tamray_tech
  • 3
  • 2
5 Comments
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 500 total points
ID: 39700052
That requires 'suEXEC' except that I think that only works when you are using 'per user' sites in 'public_html'.  That places the files you want to run in a web directory in that user's home directory.  More info here: http://httpd.apache.org/docs/2.2/suexec.html
0
 

Author Comment

by:tamray_tech
ID: 39701027
I spotted this in my research. From what I see, I would need to recompile Apache for this. Is that correct? if so, i would rather find a different option.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39701589
I don't believe there is another option.  Apache runs under a very limited user on purpose.  suEXEC is the way to change that.
0
 

Author Closing Comment

by:tamray_tech
ID: 39712229
I implemented Suexec-common on Ubuntu and achieved the results I was looking for. No need to recompile, just configure and activate.

Thanks
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39712240
You're welcome, glad to help, and thanks for the points.
0

Featured Post

The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question