Apache serves static page but not Drupal on Mercury install

I used the most recent stackscript (id=353) to setup Mercury-Pantheon. All went well but after setting up Vhosts, Apache won't serve Drupal. It will serve /update.php and static files however. I would normally suspect a problem with .htaccess, but it seems correct and is serving /update.php from the Drupal DB I loaded in to MySQL.

Page Could Not Be Loaded

We're very sorry, but the page could not be loaded properly. This should be fixed very soon, and we apologize for any inconvenience.
Debug Info:

Status: 500
Response: Internal Server Error
XID: 1175281737

Varnish

The default localhost port for Varnish to talk to Apache is 8080 which is clearly working.

etc/apache2/ports.conf:

NameVirtualHost 127.0.0.1:8080
Listen 8080

etc/apache2/sites-available/default (same as etc/apache2/sites-enabled/000-default):

 <virtualhost 127.0.0.1:8080="">ServerAdmin webmaster@localhost

    DocumentRoot /var/www
     <directory>Options FollowSymLinks
        AllowOverride None</directory> 
     <directory var="" www="">Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
        allow from all</directory> 

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
     <directory "="" usr="" lib="" cgi-bin"="">AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all</directory> 

    ErrorLog /var/log/apache2/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog /var/log/apache2/access.log combined

    Alias /doc/ "/usr/share/doc/"
    <directory "="" usr="" share="" doc="">Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128</directory></virtualhost> 

etc/hosts:

127.0.0.1       localhost.localdomain   localhost
173.255.243.141 li253-141.members.linode.com    li253-141
2600:3c01::f03c:91ff:fe93:150e li253-141.members.linode.com    li253-141

# The following lines are desirable for IPv6 capable hosts
::1     ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

apache2ctl -S:

VirtualHost configuration:
127.0.0.1:8080  is a NameVirtualHost
default server li253-141.members.linode.com (/etc/apache2/sites-enabled/000-default:1)
port 8080 namevhost li253-141.members.linode.com (/etc/apache2/sites-enabled/000-default:1)
Syntax OK

Can't figure out what's wrong. Haven't setup DNS yet, just want to tweak Mercury and Drupal using the IP address before going live. Also, not sure, but the IP for user doc Apache directive doesn't look right. Shouldn't it be 127.0.0.1?

6 Replies

Re ran the script. You don't have to do anything beyond that to get it running - simple operator failure.

However, after the site started serving the front page, accessing admin stuff failed, and then all pages stopped working, returning a Varnish 500 error. Is there additional config/tweaking or cache-flushing required to get it running smoothly?

I set this up on an account with 1GB of RAM. I did "free -m" and it showed nearly all of that being consumed. Not what I would have expected. Maybe this is overkill for my site that's not going to see more than a few thousand page views/day for a while.

I'm using the mercury/pantheon stacks script to set up my 512mb linode. It installs fine but after using the site a while, it dies with this error:

> Page Could Not Be Loaded

We're very sorry, but the page could not be loaded properly. This should be fixed very soon, and we apologize for any inconvenience.

Debug Info:

Status: 500

Response: Internal Server Error

XID: 1322147567

Varnish

total used free shared buffers cached

Mem: 497 479 17 0 26 295

-/+ buffers/cache: 158 338

Swap: 255 111 144

I've tried to avoid varnish by installing just the pressflow option but still end up with the 'Internal Server Error' problem.

I assume you setup Mercury and then imported your site files and DB from another existing site as I did? That being the case, I did not flush the cache tables before importing the DB so that's what initially gets displayed, until the cache expires. After the cache expired (I manually flushed Drupal's cache) I found fatal PHP errors.

BTW, make sure you add your /sites/default/files directory and not just the whole /sites directory from your existing site as Mercury installs the solr directory in /sites/all Mercury also installs some contrib modules in /sites/all/modules so add your own contribs to that directory.

See this thread I started that discusses the underlying problem for me and perhaps for you as well: http://forum.linode.com/viewtopic.php?t=7705

Also see my comments about that issue here: http://groups.drupal.org/node/147824#comment-577774

(You'll have to join that group if you want to post there)

Check your Apache error log in /var/log/apache2/error.log

Also review the log for the stackscript install in /root/stackscript.log

As mentioned in the D.O thread, it appeared that Hudson did not get installed which might have something to do with this problem.

I gave up on Mercury via the stackscript, for now.

Doesn't seem to work when importing an existing D6 site. I even tried using the latest pull from the Pantheon Git, but it failed to install.

Just using the standard LAMP stack with APC and it works well enough.

May give Pantheon a shot when it's publicly available at the end of October if their pricing plans are competitive.

By the way, did you make sure to check the apache error logs to see if there was anything to clue in on what the problem may have been?

Yes, but I don't remember what the PHP errors were. I don't recall getting any useful clues though.

Trying to setup and optimize and maintain a complex stack like that on Linode I'm beginning to realize isn't worth the hassle as Pantheon is right around the corner, assuming of course that it's competitively priced with Linode.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct