Solved

CentOS Apache Permissions Problem

Posted on 2006-11-15
9
658 Views
Last Modified: 2008-02-20
I've copied one of my gaming league sites over to a test server in my network where i can develop additional content for it.

I installed CentOS 4.4 and my problem is this version of Linux/Apache's behavior isn't allowing writing to any file in the /var/www/cgi-bin directory .... how can I fix this?

You can view the site here: http://24.39.162.71 , and if you browse around you'll notice the permission errors pop up, especially with regards to the ikonboard forums section (under comms, forums).

Any help would be greatly appreciated!
0
Comment
Question by:newimagent
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
9 Comments
 
LVL 1

Author Comment

by:newimagent
ID: 17950456
Thing is, on my web server, it uses a completely different model for setup and permissions, since it's running under Plesk, and for whatever reason, the permissions are happy there. I mimiced them exactly, and they don't work on my local server that is not running plesk.
0
 
LVL 57

Expert Comment

by:giltjr
ID: 17953202
What is the userid that Apache runs under?

Does that userid, or the group it is in, have read access to all of the files and directories.
0
 
LVL 1

Author Comment

by:newimagent
ID: 17953239
i'm kinda a n00b to the administration side of linux ... i'm an mcse so i'm kinda like a fish out of water here setting up my own server as i usually just rent linux boxes when i need one. i got the forums to display, looks like the permission issue was related SELinux ... the enhanced security configuration. after disabling that the forums now show up, but i can't view posts. more errors, that are probably permission related. take a look at any post in the forums .. maybe you can give me some extra feedback.

apache has read and execute permissions
0
Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

 
LVL 57

Expert Comment

by:giltjr
ID: 17953287
If this is a forum type setup wouldn't Apache need write access to something?

Where are you seeing the errors?  Apache's log?  What are the errors?
0
 
LVL 1

Author Comment

by:newimagent
ID: 17953307
http://24.39.162.71/cgi-bin/comms/forums/ikonboard.cgi?s=455be32e146c91ea;act=ST;f=1;t=496

there is an example of the forums error. you should be able to browse most sections of the site without being registered.

as far as write access the entire site is database driven. there is not one static page of html anywhere on the site. i would think write access would be required at the database level and not on the actual site.
0
 
LVL 57

Accepted Solution

by:
giltjr earned 500 total points
ID: 17953404
I didn't say what Apache may need write access to.  Unless you are spawing processes with the user's userid, then Apache would need authorization to update the database.

In the script TopicView.pm  at line 62 there was an error.  Yes, I know that is obvious.  What it looks like is that this script is doing a prepare in getting ready to query the  DB and one of the variable/parameters that is needed for the prepare statment is not set or is set wrong (out of range).

For example.  If I change t=496 to t=50 I get a totaly different  error, but a more "valid" error stating I need to be logged on.  I have no clue what "t=" is supposed to represent.  I would assume a topic number or a post number.

I need to go get some sleep.  I check in the morning to see if you have made any headway.


0
 
LVL 1

Author Comment

by:newimagent
ID: 17953470
yes t is the topic number. t=50 is a topic in a section of the forums that you need to be logged in to view.

my brain is fried for today, hopefully i'll come up with some new info tomorrow. I know how to chmod files through and ftp proggy, but haven't done it in command line or gui so that might be where i need to look next.
0
 
LVL 1

Author Comment

by:newimagent
ID: 17958614
well the majority of the problem was the SELinux configuration. With that out of the way it looks like all i was missing was the Time::Zone Perl module.

thanks for trying to help me out giltjr
0
 
LVL 57

Expert Comment

by:giltjr
ID: 17959358
SELinux can get you, its bit me more often than I care to admit.
0

Featured Post

Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

Question has a verified solution.

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

As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
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…
In this video, viewers will be given step by step instructions on adjusting mouse, pointer and cursor visibility in Microsoft Windows 10. The video seeks to educate those who are struggling with the new Windows 10 Graphical User Interface. Change Cu…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

631 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