LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-03-2007, 05:36 PM   #1
plainusdonuticus
LQ Newbie
 
Registered: Jan 2007
Posts: 7

Rep: Reputation: 0
httpd.conf probs when installing php


I have manually compiled php-5.1.4 and tried to start httpd. I get the following error when I type service httpd configtest:

httpd: Syntax error on line 205 of /etc/httpd/conf/httpd.conf: Cannot load /usr/lib/httpd/modules/libphp5.so into server: /usr/lib/httpd/modules/libphp5.so: cannot restore segment prot after reloc: Permission denied

I have looked around and noticed the following solution seems to have helped a lot of people:

1. If selinux enabled? type: setenforce 0
or try
2. set allow all permission chmod 777 libphp5.so
or
3. chcon libphp5.so -t shlib_t

of those 3 solutions, only #1 worked for me and I don't think that is the best solution. Can anyone explain to me why solution #3 would not work in my case? I'm using FC6, Apache 2.2.3, php 5.1.4

Thanks,
PlainD
 
Old 01-05-2007, 04:32 PM   #2
nonfatalexec
Member
 
Registered: May 2006
Location: Toronto, Canada
Distribution: Fedora 17
Posts: 36

Rep: Reputation: 15
On my system, the security context type of libphp5.so is textrel_shlib_t, so the correct command would have been "chcon libphp5.so -t textrel_shlib_t". You could have also tried using "restorecon -vv" which would restore the security context of the file according to the selinux-policy database and the "-vv" option will tell you what security context change was made to the file.
 
Old 01-05-2007, 05:27 PM   #3
plainusdonuticus
LQ Newbie
 
Registered: Jan 2007
Posts: 7

Original Poster
Rep: Reputation: 0
it was worth a shot but that didn't work for me. When i typed restorecon -vv libphp5.so I did not get any feedback as to the security context just another command line. Are there any other ways to tell the security context for a file?
 
Old 01-06-2007, 09:33 AM   #4
nonfatalexec
Member
 
Registered: May 2006
Location: Toronto, Canada
Distribution: Fedora 17
Posts: 36

Rep: Reputation: 15
Did you try "chcon -t textrel_shlib_t libphp5.so"?
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP module not in httpd.conf alkmie Mandriva 2 07-19-2006 07:43 PM
modifying httpd.conf for php Cikotic Linux - Software 6 08-22-2004 12:38 PM
Red Hat 9 server can't write PHP script, problem in httpd.conf file? x_menno_x Linux - Newbie 27 06-29-2004 04:44 PM
PHP - What to add to Apache httpd.conf file? maktos Linux - Software 9 04-17-2004 08:18 PM
PHP and httpd.conf adcripps Linux - Newbie 8 05-18-2002 04:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:43 PM.

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