FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > CentOS > CentOS

 
 
LinkBack Thread Tools
 
Old 04-18-2008, 08:12 PM
Pam Astor
 
Default Can't get .htaccess to work

Hi,

I'm trying to password protect one of my web accessable
directories and I can't get .htaccess to work in a Centos 5.1 box
Here's what I did

I created an .htaccess file with the contents:

AuthName "Restricted Area"
AuthType Basic
AuthUserFile /home/mysite/.htpasswd
AuthGroupFile /dev/null
require valid-user

and I uploaded it to the dir I want to protect. Then I created my password
outside of my web dir with the command: htpasswd -c .htpasswd pam
then followed password prompts, created my password.

So then I go to the site, and am not seeing any password required box,
I can see site without a login.

So then I figured it's not turned on in apache, and went to httpd.conf and changed
AllowOverride None to AllowOverride AuthConfig

When I reload, apache will not reload.

What am I doing wrong?
__________________________________________________ _______________
Pack up or back up–use SkyDrive to transfer files or keep extra copies. Learn how.
http://www.windowslive.com/skydrive/overview.html?ocid=TXT_TAGLM_WL_Refresh_skydrive_p ackup_042008______________________________________ _________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 04-18-2008, 08:28 PM
Morten Nilsen
 
Default Can't get .htaccess to work

Pam Astor wrote:

When I reload, apache will not reload.

What am I doing wrong?


I suspect your only fault is not checking the logs..
Right after you issue service httpd start,
go look at /var/log/messages and /var/log/httpd/*

--
Cheers,
Morten
:wq
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 

Thread Tools




All times are GMT. The time now is 05:40 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org