LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-04-2014, 03:32 AM   #1
j-ray
Senior Member
 
Registered: Jan 2002
Location: germany
Distribution: ubuntu, mint, suse
Posts: 1,591

Rep: Reputation: 145Reputation: 145
run sudo cmd as wwwrun


Hi,

I want to run a program -from within a php script- as user wwwrun using sudo but there is no tty assigned. Looking around I found this entry for the sudoers file as a possible solution:


Defaults:wwwrun !requiretty

Unfortunately this seems to be ignored as I still get the same error.

"som13 sudo: wwwrun : TTY=unknown ; PWD=/DATEN/www/vhosts/some ; USER=root ; COMMAND=/usr/bin/somecmd"

(This is happening on SUSe with sudo version 1.7.6p2)

Can you shed some light on this?


EDIT
The setting was not ignored. But there were additional mistakes in the program I had to correct...

Last edited by j-ray; 09-04-2014 at 04:57 AM. Reason: detail added
 
Old 09-06-2014, 03:38 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Quote:
Originally Posted by j-ray View Post
The setting was not ignored. But there were additional mistakes in the program I had to correct...
Thanks for clarifying. Off of the 0-reply list now.
 
  


Reply

Tags
requiretty, sudo, visudo



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Issue sg_modes cmd at cmd line, want to see the cmd in binary form NuUser Linux - Newbie 1 03-28-2012 08:08 AM
[SOLVED] "sudo: Can't mkdir /var/run/sudo/%user%: File exists" CNBarnes Linux - Server 7 01-10-2011 04:11 PM
(Sudo) command can't run by sudo rahilmaknojia Linux - Server 8 06-25-2010 09:30 AM
wwwrun user cronjobs don't run tristaoh SUSE / openSUSE 1 06-15-2007 05:13 PM
sudo command not working startproc cmd not found Imajica21 Linux - General 2 04-14-2005 01:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:32 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration