Bug 51220 - impossible to run apache with non-root permissions
impossible to run apache with non-root permissions
Status: CLOSED DUPLICATE of bug 37233
Product: Red Hat Linux
Classification: Retired
Component: apache (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Joe Orton
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-08-08 11:44 EDT by Fernando J. Martinez
Modified: 2007-04-18 12:35 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-21 13:48:05 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Fernando J. Martinez 2001-08-08 11:44:31 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)

Description of problem:
It's impossible to run apache with non-root permissions, because it tries 
to write a semaphore in /var/run:

>>>>>>>>>>>>>>>>>>>>>>>>>
Ouch! ap_mm_create(1048576, "/var/run/httpd.mm.12420") failed
Error: MM: mm:core: failed to open semaphore file (Permission denied): OS: 
No such file or directory

>>>>>>>>>>>>>>>>>>>>>>>>>

Mandrake 8 seems to have it solved in its package:

  apache-common-1.3.19-3mdk RPM for i586

See their changelog:

>>>>>>>>>>>>>>>>>>>>>>
- Changed MM_CORE_PATH to /var/apache-mm/mm instead of /var/run/mm 
    because only root can write to /var/run and we have to be able to run 
    Apache as a non-root user! 

>>>>>>>>>>>>>>>>>>>>>>


How reproducible:
Always

Steps to Reproduce:
1.Log in with non root permissions
2.Try to launch apache
3.
	

Actual Results:  The apacha is not started because it tries to access some 
files or directories not permitted to a non root user

Additional info:
Comment 1 Alexandre Oliva 2002-02-24 13:54:42 EST
I'd go ahead and suggest to make this pathname configurable in the httpd.conf
file, like all other pathnames that default to /var/run.

Meanwhile, here's a quick work-around: copy /usr/sbin/httpd elsewhere, then
change occurrences of /var/run in it to say /tmp/run (make sure it retains the
same length).  Then, create /tmp/run as the user who runs httpd and you're done.
Comment 2 Ville Skyttä 2002-06-13 14:47:02 EDT
Applies to Red Hat 7.3 too, and is pretty damn annoying.  What's the status of 
this? 
Comment 3 Joe Orton 2004-09-21 06:06:47 EDT

*** This bug has been marked as a duplicate of 37233 ***
Comment 4 Red Hat Bugzilla 2006-02-21 13:48:05 EST
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.

Note You need to log in before you can comment on or make changes to this bug.