Solved

Apache on Linux .htaccess file configuration error message

Posted on 2010-11-15
8
747 Views
Last Modified: 2012-05-10
Apache is hosted on CentOS5.5 server.  There needs to be password protected stuff in the /services/apache/htdocs/TOOLS directory.  Basic information is provided under.  It so appears that the .htpasswd file is not being read properly.  Apache does have read access to the .htpasswd file.  

Could you tell me what appears to be the source of problem?

ERROR MESSAGE:
[Mon Nov 15 11:40:32 2010] [crit] [client 10.25.3.34] configuration error:  couldn't check access.  No groups file?: /TOOLS/
<Directory "/services/apache/htdocs">

RELATED CONFIG in httpd.conf FILE
    #Options Indexes FollowSymLinks

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
#   Options FileInfo AuthConfig Limit
#
    AllowOverride All
#
# Controls who can get stuff from this server.
#
    Order allow,deny
    Allow from all
</Directory>

LOCATION AND PERMISSION OF THE REQUIRED FILES
-rw-r--r-- 1 root apache 157 Nov 15 11:14 /services/www/htdocs/TOOLS/.htaccess
-rw-r--r-- 1 root apache  18 Nov 15 11:00 /services/www/htdocs/TOOLS/.htpasswd

CONTENTS OF .htaccess FILE
AuthName "Access is Denied. Enter password"
AuthType Basic
AuthUserFile /services/apache/htdocs/TOOLS/.htpasswd
<Limit GET POST>
Require valid-user
</Limit>
0
Comment
Question by:farzanj
[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
  • 3
  • 3
  • 2
8 Comments
 
LVL 4

Expert Comment

by:max-hb
ID: 34138149
Typo in your .htaccess?!
AuthUserFile /services/apache/htdocs/TOOLS/.htpasswd
vs.
AuthUserFile /services/www/htdocs/TOOLS/.htpasswd
0
 
LVL 31

Author Comment

by:farzanj
ID: 34138700
That was a nice catch.  But still the error persists.  Exactly the same.

CONTENTS OF FILE: /services/www/htdocs/TOOLS/.htaccess
AuthName "Access is Denied. Enter password"
AuthType Basic
AuthUserFile /services/www/htdocs/TOOLS/.htpasswd
<Limit GET POST>
Require valid-user
</Limit>

RELATED httpd.conf FILE:
<Directory "/services/www/htdocs/TOOLS">
      AllowOverride AuthConfig
</Directory>
0
 
LVL 3

Expert Comment

by:Prograministrator
ID: 34138753
check the path,

you typed two different paths in your question.

/services/apache/htdocs/TOOLS/.htpasswd

/services/www/htdocs/TOOLS/.htpasswd

if the folder name is "www" change the path in your htaccess file and httpd.conf (<Directory "/services/apache/htdocs">)
0
DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

 
LVL 4

Accepted Solution

by:
max-hb earned 350 total points
ID: 34138830
Have you installed the neccessary apache modules? You should need:
mod_auth_basic
mod_authn_file
mod_authz_user

You can check if these modules are installed by creating a file phpinfo.php on your web server with the following content:

<?php
phpinfo();
?>

Open that file in your web browser and look at the section called "Loaded modules".
0
 
LVL 3

Assisted Solution

by:Prograministrator
Prograministrator earned 150 total points
ID: 34138849
Sorry,
I did not notice for your last comment.

Check the required modules is loaded well,

means check this three lines in your httpd.conf :

LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authz_user_module modules/mod_authz_user.so
0
 
LVL 31

Author Comment

by:farzanj
ID: 34139473
Thank you.  This fixed the problem.

I kind of knew that one of the modules was missing but I didn't know which one.

So the question becomes this:
Is there some Apache documentation of a way to query which functionality is obtained by which modules?

Functionality ---> Modules list
0
 
LVL 4

Expert Comment

by:max-hb
ID: 34139546
At http://httpd.apache.org/docs/2.0/en/mod/ you'll find a extensive list of apache modules organized by categories.
0
 
LVL 31

Author Closing Comment

by:farzanj
ID: 34144647
Thank you guys.  The last comment did not completely answer my question.  May be this is it but I wanted to know better place where it would map major Apache functionalities with modules.  May be there isn't one but please post it if you find one.

I appreciate your help.
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

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

It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Fine Tune your automatic Updates for Ubuntu / Debian
The viewer will learn how to count occurrences of each item in an array.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

751 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