Hi,

I will be hosting around 100-500 drupal sites shortly... I thought of using the drupal multi site feature(obviously).. but the problem here is that if each of the site use different database.. sites will become slow.. and if all the sites are using the same database with prefix.. again its bad .. db will contain around 50*500=25000 tables!

So was thinking of using one set of tables and adding a field called "site_name" which will indicate to which site the row belongs to.. and hacking the drupal core to take care of this field....

Things to be done for this...
1) add "WHERE site_name='$site_name'", "site_name='$site_name' " in all the simple database queries...(SELECT, UPDATE,INSERT)

2) queries using join and other complex queries.... have no idea as of now

3) table sequences is to be taken care of by not adding site_name to this table...

4) when adding new modules.. take care of this field...

Is there any other cases to be considered when hacking drupal??
What will be the major issues that will be faced when doin this?

Is there any other way that about 500+ sites can be hosted with the same cost/site or lesser ratio :)

Comments

gpk’s picture