Recent Topics

1 Nov 17, 2008 13:35    

My b2evolution Version: 2.x

I'm setting up a new website which I expect to grow to handle 10's of thousands of individual blogs with possibly millions of daily page views at peak load.

I'll start out with a normal hosted installation but will eventually scale out the infrastructure to include hardware http load balancers with multiple instances of b2evolution installed on multiple servers (all sharing the same DB instance installed on a dedicated server of its own). The goal is that all the users on the system would feel like they are logging into one gigantic server.

Has anyone used b2evolution with http load balancers sharing a single DB?

I'm only looking for general advice at this point and not specific how-to instruction since I won't be scaling out the site until 2010.

Thanks for any input.

2 Nov 17, 2008 14:06

I share instalations (due the users tables and some more data) in a single db (you just need to change some configurations, its not that hard), but I never share dbss as you say. Did you had any ideas to achieve that or you just walking the first steps?

3 Nov 17, 2008 18:26

Interesting project. No advice yet.

4 Nov 17, 2008 22:35

Gabriel1980 wrote:

... Did you had any ideas to achieve that or you just walking the first steps?

I was evaluating ExpressionEngine previously as a CMS/Blogging engine and that's how it has been done for large sites... load balancer -> multiple web servers -> single DB instance = 1 common URL for all users.

Unfortunately, the ExpressionEngine license specifically forbid multi-authored blogs (I checked with them directly about it) and there's just no way we're going to buy a separate license for each blogger at $250 a piece... we're talking about eventually reaching 10's of thousands of bloggers for a nonprofit corporation here :-(

I'm just taking the first step here so this is my exploration phase.

5 Nov 21, 2008 06:21

Hi khai.n,

I have implemented b2evo on 2 different domains residing on two different servers: Server A hosts one domain and the DB, Server B hosts another domain. The b2evo instance on Server B connects remotely to DB on Server A.

Is this what you are looking for? It just takes some modifications on the config file and skin.

The more tricky thing I find is to keep the files in the "media" folder in sync among different servers. You might want to consider whether your implementation will be affected by this.

6 Nov 21, 2008 10:39

C.R.T. wrote:

Hi khai.n,

I have implemented b2evo on 2 different domains residing on two different servers: Server A hosts one domain and the DB, Server B hosts another domain. The b2evo instance on Server B connects remotely to DB on Server A.

Is this what you are looking for? It just takes some modifications on the config file and skin.

The more tricky thing I find is to keep the files in the "media" folder in sync among different servers. You might want to consider whether your implementation will be affected by this.

Your setup is close to what I have in mind so it's looking like this will work.
What you have done and what I have in mind are not that much different.

For my setup the servers will all 'host the same domain' behind a load balancer; this way to the outside world they'll just see 1 URL, and the DB will be in its own server.

Thanks for confirming this. I won't be implementing this fancy setup until next year since I'll be starting out with a normal install (all on 1 server) and it will take a while to scale up enough users to require the fancy setup. At least now I know it's possible. Thanks!

7 Nov 22, 2008 12:12

khai.n wrote:

Gabriel1980 wrote:

... Did you had any ideas to achieve that or you just walking the first steps?

I was evaluating ExpressionEngine previously as a CMS/Blogging engine and that's how it has been done for large sites... load balancer -> multiple web servers -> single DB instance = 1 common URL for all users.

Unfortunately, the ExpressionEngine license specifically forbid multi-authored blogs (I checked with them directly about it) and there's just no way we're going to buy a separate license for each blogger at $250 a piece... we're talking about eventually reaching 10's of thousands of bloggers for a nonprofit corporation here :-(

I'm just taking the first step here so this is my exploration phase.

I guess its very doable what you ask; as far as I do the same in the same sever. What I do is to twist conf/advanced.php, indicating which tables are shared and which ones are not:

$db_config['aliases'] = array(
		'T_antispam'            => 'B2E_antispam',
		'T_basedomains'         => 'DIFFERENT-DOMAIN_basedomains',
		'T_blogs'               => $tableprefix.'blogs',
		'T_categories'          => $tableprefix.'categories',
		'T_coll_group_perms'    => $tableprefix.'bloggroups',
		'T_coll_user_perms'     => $tableprefix.'blogusers',
		'T_coll_settings'       => $tableprefix.'coll_settings',
		'T_comments'            => $tableprefix.'comments',
		'T_cron__log'           => $tableprefix.'cron__log',
		'T_cron__task'          => $tableprefix.'cron__task',
		'T_files'               => $tableprefix.'files',
		'T_filetypes'           => $tableprefix.'filetypes',
		'T_groups'              => 'B2E_groups',
		'T_global__cache'       => 'CACHE_DIFFERENT-DOMAIN_global__cache',
		'T_hitlog'              => 'DIFFERENT-DOMAIN_hitlog',
		'T_items__item'         => $tableprefix.'items__item',
		'T_items__itemtag'      => $tableprefix.'items__itemtag',
		'T_items__prerendering' => $tableprefix.'items__prerendering',
		'T_items__status'       => $tableprefix.'items__status',
		'T_items__tag'          => $tableprefix.'items__tag',
		'T_items__type'         => $tableprefix.'items__type',
		'T_links'               => $tableprefix.'links',
		'T_locales'             => $tableprefix.'locales',
		'T_plugins'             => $tableprefix.'plugins',
		'T_pluginevents'        => $tableprefix.'pluginevents',
		'T_pluginsettings'      => $tableprefix.'pluginsettings',
		'T_pluginusersettings'  => $tableprefix.'pluginusersettings',
		'T_postcats'            => $tableprefix.'postcats',
		'T_sessions'            => 'DIFFERENT-DOMAIN_sessions',
		'T_settings'            => $tableprefix.'settings',
		'T_skins__container'    => $tableprefix.'skins__container',
		'T_skins__skin'         => $tableprefix.'skins__skin',
		'T_subscriptions'       => $tableprefix.'subscriptions',
		'T_users'               => 'B2E_users',
		'T_useragents'          => 'DIFFERENT-DOMAIN_useragents',
		'T_usersettings'        => $tableprefix.'usersettings',
		'T_widget'              => $tableprefix.'widget',

The B2E table prefix, is for sharing a common user database among sites. And the default "$tableprefix" feeds a site with content. And the table prefix DIFFERENT-DOMAIN are for sharing stats data from the same domain (so if you mirrored contents of that shared db, you could get independet stats within the b2evo admin interface) My two cents! :D

PS1: Of course, on conf/_basic_conf.php you should twist the independent tableprefix and the url of each site. Dunno if its what you really need, but its a clue about that its possible to do it! :D (this works for me, as I could have different sites, sharing a common user db; plus if those sites are hosed in different domains, I could get some usage stats, beyond server stats)
PS2: Whoever knows how to share different instalations among servers... please buzz us! (Im also intrested!)


Form is loading...