LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-21-2011, 08:09 PM   #1
enyawix
Member
 
Registered: Sep 2003
Location: ky
Distribution: gentoo
Posts: 409

Rep: Reputation: 32
unable to get vhost working on centos 6


I have tried building the config by hand and building with webmin.



My config is on pastbin

http://pastebin.com/2skp7aEv
 
Old 08-22-2011, 12:28 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

What is the errors you get? And what gives:
Code:
httpd -S
BTW better use:
Code:
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin webmaster@host.foo.com
DocumentRoot /home/wiki
ServerName wiki.waynesdata.com
ErrorLog /var/log/httpd/wiki-error_log
TransferLog /var/log/httpd/wiki-access_log
</VirtualHost>
Regards
 
1 members found this post helpful.
Old 08-22-2011, 11:56 AM   #3
enyawix
Member
 
Registered: Sep 2003
Location: ky
Distribution: gentoo
Posts: 409

Original Poster
Rep: Reputation: 32
[root@localhost ~]# httpd -S
VirtualHost configuration:
wildcard NameVirtualHosts and _default_ servers:
*:80 is a NameVirtualHost
default server wiki.waynesdata.com (/etc/httpd/conf/httpd.conf:1013)
port 80 namevhost wiki.waynesdata.com (/etc/httpd/conf/httpd.conf:1013)
Syntax OK


Nothing works I get the 404 page
 
Old 08-22-2011, 12:20 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Hi,

Your vhosts configuration is fine. Check the error log (/var/log/httpd/wiki-error_log) to see where is apache looking for the requested page and you get the 404 error.

Regards
 
1 members found this post helpful.
Old 08-22-2011, 12:47 PM   #5
enyawix
Member
 
Registered: Sep 2003
Location: ky
Distribution: gentoo
Posts: 409

Original Poster
Rep: Reputation: 32
[Mon Aug 22 07:43:45 2011] [error] [client 192.168.0.1] (13)Permission denied: access to /index.php denied


This is after chmod -R ugoa+rw /home/wiki
 
Old 08-22-2011, 01:08 PM   #6
enyawix
Member
 
Registered: Sep 2003
Location: ky
Distribution: gentoo
Posts: 409

Original Poster
Rep: Reputation: 32
this is a SELinux problem

Thanks bathory. I got things working for now by disabling SElinux. This would have been harder to track down without your help.

Last edited by enyawix; 08-22-2011 at 07:32 PM.
 
  


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
[SOLVED] Apache2 Multiple SSL vhost in different vhost files, does not work LBM Linux - Software 2 09-24-2010 06:06 AM
vhost with ProxyHTMLInterp On/Off correct definition of vhost needed tkmsr Linux - Server 0 07-18-2010 02:12 PM
Unable to get ntfs-3g working on CentOS 5.2 Nightfighter89 Linux - Software 14 03-26-2009 12:26 PM
Unable to Run sudo due to getresuid() Not Working on CentOS 3.1 Xyrael Linux - Security 14 02-06-2008 08:29 PM
Apache: Alias is working on ssl vhost but not on mass vhost jonavogt Linux - Software 0 06-07-2005 02:05 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 06:31 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