I am trying to share user information across multiple sub-domains and came across this very good URL which explains how to achieve that using db_prefix.

http://drupal.org/node/201673

I am using V6.x and the way I started was that, I shared only users, users_roles and sessions tables across the domains, since I want every thing else to be different across sub domains.

I also want to know if this is a best practice, since I have plans to add around 20 sub domains in a long run and each sub domain will add around 40 tables to the existing database. Is that good to run the whole list of sub domains all from the same backend database or is there a way a better way to share user information especially on such a big domain containing various sub domains ?

I tested with two sub domains, main domain with some additional contributed modules and ended up with around 200 tables in the database. Using this sample, if I configure 20 sub domains in a long run, I expect to have around 1000 tables in a single database.

What impact is this going to have on the scalability and performance of the website if I decide to share tables for all the sub domains with a single database.

This looks little weird for any database designer. Is there a way to better single sign on or share user information across sub domains with out using a single database.

Comments

vinoth.3v’s picture

How much is your PHP memory Limit?

Best of Luck...

But i also wanted to know how it is possible to port contents to different databases but single user tables??

for E.g.

http://groups.mydrupaldomain.in
http://blogs.mydrupaldomain.in
http://books.mydrupaldomain.in
http://profiles.mydrupaldomain.in
http://xyz.mydrupaldomain.in
http://me.mydrupaldomain.in
https://secure.mydrupaldomain.in
https://cart.mydrupaldomain.in

All of the above sub domains should be live in different DBs but sharing same user accounts DB!!!

also is it possible to dynamically load modules based on the domains???

வினோத்

Vinoth - வினோத்