create separate DB for each blog on wordpress multisite?

We are trying to build a separate DB for each blog on our network can we achieve this with Multi DB plugin

Thanks

  • Patrick

    Hi there @yns

    Welcome to WPMU DEV, glad to have you aboard!

    Yes, you can assign a specific database for selected blogs in your multisite network. But you must do so manually by creating a VIP database for each one.

    That's important to remember: the Multi-DB plugin cannot create those VIP databases automatically. See Vaughan's reply below.

    You'll find all you need to know about VIP databases in the usage documentation here (click the Usage tab at the top of the page):
    https://premium.wpmudev.org/project/multi-db/

  • Vaughan

    Hi @yns,

    Hope you're well?

    Not quite, Multi-DB is used to spread the load when you have a few thousand sites on your network, You will not get any benefit from it unless you have a few thousand blogs.

    It doesn't spread the load by making each blog have it's own DB, so you could ultimately have 10 or 20 sites on 1 DB before it starts to use a different DB, there is no way of making it create a new DB for each site, what if your multisite has 50,000 blogs on it? are you really going to create 50,000 different databases?

    I do not know of any plugins that allow multisite to use a seperate DB for each blog, there are other scaling plugins, but these work in a similar way to multi-db in that they spread the load, but still you will end up with multiple blogs on each DB.

    Hope this helps

  • yns

    Hi there thanks for the reply I do understand that it is hard to keep 50,000 dbs for each blog and it will be hard to maintain them individually our concern for doing so is the stability of single db handling all the blogs plus some of the themes we need to customize for some blogs and due to single db its hard to do so cause if we customize the theme for one blog other blog that are using the same theme will be effected if am wrong please correct me as I am told single database Multisite Wordpress will not be able to handle huge number of blogs and it will crash specially when mostly all of the blogs will be E-commerce blogs on the multisite network installation

    Thanks

  • Vaughan

    Hi,

    Yes, changes to parent themes would affect all sites using that theme, in this case, I think the recommended option would be to create child themes which could be used for each subsite.

    A single WP DB can actually handle a lot of sites, i've seen a few multisites that have well over a thousand blogs and do not have any DB scaling functions such as multi-db and work fine.

    A corrupted table in one of the blogs, shouldn't actually affect any other blogs on the network, as that table is actually unique to that particular blog.

    The only exception to that is if it's one of the main network tables, such as users, usermeta, sitemeta & so on, but then even with multi-db, corruption in those tables would still cause issues for the rest of the network.

    Hope this helps

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.