Hi,
I am trying to develop a community site that is spread through different cities. Each city will have a subdomain.

I could successfully configure different subdomains with different databases for each city.
But then, I wanted to implement single sign on so moved to 'single database across all cities and share tables to enable single-sign-on' concept. The tables have suitable prefixes to isolate the content for different cities.

I started from scratch, and could set up the first subdomain(http://city1.example.com) . Then when I tried to install the second domain (http://city2.example.com/install.php), the install script gave me errors and warning saying some tables its trying to install are already present. Expected that too because shared tables will already be present.

Now, the problem is that the first subdomain is perfectly alright but the second domain is accessible only through http://city2.example.com/index.php
If I just try http://city2.example.com, the page throws out a lot of errors like below

Warning: Table 'praja17_drpl1.pune_access' doesn't exist query: SELECT CASE WHEN status=1 THEN 0 ELSE 1 END FROM pune_access WHERE type = 'host' AND LOWER('57.67.17.100') LIKE LOWER(mask) ORDER BY status DESC LIMIT 0, 1 in /home/praja17/public_html/content/includes/database.mysql.inc on line 172
...
...
...
...
Warning: Table 'praja17_drpl1.pune_watchdog' doesn't exist query: INSERT INTO pune_watchdog (uid, type, message, severity, link, location, referer, hostname, timestamp) VALUES (0, 'php', 'Table 'praja17_drpl1.pune_watchdog' doesn't exist\nquery: INSERT INTO pune_watchdog (uid, type, message, severity, link, location, referer, hostname, timestamp) VALUES (0, 'page not found', 'node', 1, '', 'http://pune.praja.in/', '', '57.67.17.100', 1181824928) in /home/praja17/public_html/content/includes/database.mysql.inc on line 172.', 2, '', 'http://pune.praja.in/', '', '57.67.17.100', 1181824928) in /home/praja17/public_html/content/includes/database.mysql.inc on line 172

Fatal error: Call to undefined function block_list() in /home/praja17/public_html/content/includes/theme.inc on line 1013

I have checked the .htacess file and made sure that it redirects to index.php. Other subdomain works alright so I suppose its got nothing to do with .htacess or setings.php.

Here is my database prefix table if thats of any hint

$db_prefix = array(
'default' => 'blr_',
'authmap' => 'shared_',
'profile_fields' => 'shared_',
'profile_values' => 'shared_',
'role' => 'shared_',
'sequences' => 'shared_',
'sessions' => 'shared_',
'users' => 'shared_',
'users_roles' => 'shared_',
);

I would appreciate any help.

If you really want to see the errors, visit http://praja.in (that should lead you to bangalore.praja.in) . That site is alright. http://pune.praja.in is accessible only through http://pune.praja.in/index.php

-Shastri

Comments

shas3n’s picture

Ouch! now even the index.php doesnt work.
What am I doing wrong?

shas3n’s picture

The problem automatically got resolved. Might have been some subdomain propagation delay though DNS or may be the FSM's noodly appendages interfering.
Anyway, I am happy now.