Problem installing Drupal 7 using XAMPP on a Mac

Problems with the Mac OS X version of XAMPP, questions, comments, and anything related.

Problem installing Drupal 7 using XAMPP on a Mac

Postby Mark123 » 14. February 2011 17:58

I am running into problems installing Drupal 7 using XAMPP on a Mac.

To install drupal, you just need to point your browser to the druapal directory. However, when trying to do this ( with http://localhost/~Mark/drupal ) I get the error:

Server error!
The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there was an error in a CGI script.
Error 500

I found a 2.5 year old post ( http://drupal.org/node/291669 ) where the following suggestion worked for several people:
I fixed it by changing the AllowOverride directive inside of the container from AllowOverride AuthConfig to be AllowOverride All. This is on line 220 of /Applications/xampp/etc/httpd.conf.

However, that problem has been fixed by now: it already has the setting 'AllowOverride All'.

So I checked error_log and find: /Users/Mark/Sites/drupal/.htaccess: Options not allowed here

I looked in .htaccess but can't figure anything out; various options are set, but you would think those would be necessary. Part of the file is as follows:

Code: Select all
# Protect files and directories from prying eyes.
<FilesMatch "\.(engine|inc|info|install|make|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl)$|^(\..*|Entries.*|Repository|Root|Tag|Template)$">
  Order allow,deny
</FilesMatch>

# Don't show directory listings for URLs which map to a directory.
Options -Indexes

# Follow symbolic links in this directory.
Options +FollowSymLinks

# Multiviews creates problems with aliased URLs and is not needed for Drupal.
Options -Multiviews


Does anybody have a solution for this? Thanks!
Mark123
 
Posts: 5
Joined: 14. February 2011 17:17

Re: Problem installing Drupal 7 using XAMPP on a Mac

Postby Mark123 » 14. February 2011 18:31

I went through the .htaccess file deleting lots of various text, and found that deleting this chunk of text will work:
Code: Select all
# Don't show directory listings for URLs which map to a directory.
Options -Indexes

# Follow symbolic links in this directory.
Options +FollowSymLinks

# Multiviews creates problems with aliased URLs and is not needed for Drupal.
Options -Multiviews

# Make Drupal handle any 404 errors.
ErrorDocument 404 /index.php

# Force simple error message for requests for non-existent favicon.ico.
<Files favicon.ico>
  # There is no end quote below, for compatibility with Apache 1.3.
  ErrorDocument 404 "The requested file favicon.ico was not found.
</Files>

# Set the default handler.
DirectoryIndex index.php index.html index.htm

# Override PHP settings that cannot be changed at runtime. See
# sites/default/default.settings.php and drupal_initialize_variables() in
# includes/bootstrap.inc for settings that can be changed at runtime.

# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
  php_flag magic_quotes_gpc                 off
  php_flag magic_quotes_sybase              off
  php_flag register_globals                 off
  php_flag session.auto_start               off
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_flag mbstring.encoding_translation    off
</IfModule>

However, deleting different parts of this chunk didn't work, I needed to delete the whole thing.

Does anybody know why this chunk of code would need to be deleted from .htaccess? Is there some setting I could change to enable this code to work?
Mark123
 
Posts: 5
Joined: 14. February 2011 17:17

Re: Problem installing Drupal 7 using XAMPP on a Mac

Postby Mark123 » 14. February 2011 19:30

Narrowed the problem a little more. Problems occur with both 'Options' directives and 'php_flag' directives.

In file error_log, the error 'Options not allowed here' occurs for:
Code: Select all
# Don't show directory listings for URLs which map to a directory.
Options -Indexes

# Follow symbolic links in this directory.
Options +FollowSymLinks

# Multiviews creates problems with aliased URLs and is not needed for Drupal.
Options -Multiviews


The error 'php_flag not allowed here' occurs for:
Code: Select all
# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
  php_flag magic_quotes_gpc                 off
  php_flag magic_quotes_sybase              off
  php_flag register_globals                 off
  php_flag session.auto_start               off
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_flag mbstring.encoding_translation    off
</IfModule>
Mark123
 
Posts: 5
Joined: 14. February 2011 17:17

Re: Problem installing Drupal 7 using XAMPP on a Mac

Postby Mark123 » 14. February 2011 22:47

Small correction, but bigger mystery:
In httpd.conf, there are 2 locations where AllowOveride is set, and I was looking at the wrong one. On line 190, AllowOverride can be set as a default for all directories. There indeed the value was set to 'None'. I changed the value to 'All', expecting that the 'Options not allowed here' error would go away, but it didn't. (Turned XAMPP off and back on as well.)
Mark123
 
Posts: 5
Joined: 14. February 2011 17:17

Re: Problem installing Drupal 7 using XAMPP on a Mac

Postby Mark123 » 15. February 2011 00:30

Didn't get the problem figured out, so I switched from XAMPP to MAMP. There are great instructions at http://drupal.org/node/66187, and the install went without a problem.
Mark123
 
Posts: 5
Joined: 14. February 2011 17:17


Return to XAMPP for Mac OS X

Who is online

Users browsing this forum: No registered users and 1 guest