LinuxQuestions.org
Review your favorite Linux distribution.
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 05-26-2009, 04:14 AM   #1
lgp171188
LQ Newbie
 
Registered: Apr 2009
Posts: 16

Rep: Reputation: 0
Question Unexplainable 404 error in apache2


Hi all,
I am in the process of writing a web-application using apache,mod-python and cheetah. I installed apache2, mod-python and cheetah and also enabled the userdir module in apache2 so that i can host the webpages inside my public_html folder.

The public_html folder has a folder named 'site' which gets displayed when I type "http://localhost/~myusername/" in the browser. There are subfolders inside this 'site' folder and the site folder also has an index.html page inside it.

But when I click on the site folder in the browser, I get a 'Requested url /~myusername/site/ not found'. There are files inside the folder with 777 permissions and still I get this error.

I use Ubuntu Jaunty with the following configuration - 'Apache/2.2.11 (Ubuntu) PHP/5.2.6-3ubuntu4.1 with Suhosin-Patch mod_python/3.3.1 Python/2.6.2 Server at localhost Port 80'.

Please help me regarding this issue.

These are the lines I have added to the /etc/apache2/sites-available/default file


Code:

<Directory "/home/myusername/public_html/site/">
SetHandler mod_python
PythonHandler mod_python.publisher
PythonDebug On
PythonAutoReload On
PythonPath "sys.path+['/home/myusername/public_html/site/py']"

</Directory>

Thanks in advance.
 
Old 05-26-2009, 04:52 PM   #2
twantrd
Senior Member
 
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440

Rep: Reputation: 52
Work on the problem one step at a time. Don't load any of the Python stuff until you can configure apache to serve out the html files. I would also look in your apache error logs. Your config should be something like:

Code:
<Directory "/home/*/public_html">
...
...
-twantrd
 
  


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
apache2.x : force timeout instead of 404 Nathanael Linux - Server 1 09-25-2006 06:45 AM
Unwanted 404 error with apache Vossy Linux - Software 0 12-26-2005 08:31 PM
odd Apache 404 error Seventh Linux - Software 1 03-27-2005 03:43 AM
wget 404 error BarryM45 Linux - General 2 10-12-2004 05:12 AM
(404)error johncla Linux - Networking 1 03-25-2001 06:09 PM

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

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