Running Drupal on lycos server

Rhi wants to try out drupal but was having real trouble getting it running on her Lycos hosting service.

First up, it seems Lycos doesn't like the default .htaccess file. So much so that after installing Drupal she couldn't even see her site and only got "Error 500" messages. We've worked round that by disabling it until we suss out what the problem is.

More significantly, we couldn't get Drupal to connect to the database at all. A short test script that tried to connect directly was working fine...

<?php
$dbhost
= 'hostname';
$dbuser = 'username';
$dbpass = 'password';

if (
mysql_connect($dbhost, $dbuser, $dbpass)) {
print
'<strong>Connected!<br /></strong>';
}
?>

This had us stumped for a few hours! However, I suddenly realised that if a basic connection script works, but connection stops when Drupal tries to connect, then Drupal must change something along the way. "What if it alters a $GLOBAL?" A bit of debugging (by testing the ability to connect as the bootstrap progresses) and I found everything is fine until drupal_unset_globals. If you check what globals are set you discover that there are two little parameters:

  • ___db_user
  • ___db_host

Lycos control panel provides you with your username and says that the host is localhost but ___db_user and ___db_host seem to have the "true" values. The username is the same as the reported MySQL username, but the ___db_host contains a completely different path and port!

If these values get unset then connection fails, but if you add the above two keys to the list of allowed globals (line 139 of bootstrap.inc) then the system can connect.

I've only just got this set up, so there may be more hiccups to come. There are some other globals that look to be specific to Lycos, so I added those to the list of allowed globals too, just to be safe. I'm not sure that was strictly needed, but it probably doesn't hurt! These other globals are:

  • webc_real_domain_tab
  • webc_real_path
  • webc_real_domain

So the final list of allowed globals looks like:

<?php
$allowed
= array(
 
'_ENV' => 1,
 
'_GET' => 1,
 
'_POST' => 1,
 
'_COOKIE' => 1,
 
'_FILES' => 1,
 
'_SERVER' => 1,
 
'_REQUEST' => 1,
 
'access_check' => 1,
 
'___db_user' => 1,
 
'___db_host' => 1,
 
'webc_real_domain_tab' => 1,
 
'webc_real_path' => 1,
 
'webc_real_domain' => 1,
);
?>

It's over to Rhi now to see if the site is functional! Good luck!

Comments

"Fixed" .htaccess

We have managed to get the .htaccess file to work. Lycos was objecting to the lines


# Set some options.
Options -Indexes
Options +FollowSymLinks

 

So we commented them out, it's happy, and now we have clean urls to finish things off and help out Google and the other search engines. As Rhi says, all that's left now is the content!

Also posted at drupal.org

I've also posted this to the drupal.org site in case it helps out anyone else who is trying to use drupal on lycos.

Great advice

Thanks for fighting the shortcomings of lycos hosting :)
Your advice was very helpfull while installing http://www.archigraphie.de