Orchard Installation to Web Farm with single (shared) SQL database

Topics: Administration, Installing Orchard
Feb 25, 2015 at 4:23 PM
Hello Orchard Guru's!

I'm a newbie in Orchard, but I've got task for installation of Orchard CMS to our enterprise Web Farm behind LBA, but with single SQL server and DB for both instances, and I've got questions:
  • Is it possible to share the single database for two or more instances of Orchard installed to web farm?
  • How should I set it up, if during the installation of second instance of Orchard, database already exist?
  • Which folders must be shared and how do you suggest to do it? Maybe some modules are availiable for such purpose?
Thanks in advance!
Developer
Feb 25, 2015 at 5:23 PM
  1. Yes, simply have both your Orchard instances point to that database.
  2. Setup one instance first, then copy & paste the App_Data folder to your second instance. This will include the Settings.txt file, which will have the status set to Running and will have the correct DB connection string you used to setup the first instance.
  3. If you (or your site users) will be uploading files to the Media folder, you need to make sure they exist on all nodes in your farm. If you were hosting on Azure, you'd be using the Azure blob Storage provider. If you aren't on Azure, you could perhaps setup a virtual directory that points to some Media folder on a network share or file cluster. Alternatively, you could implement your own storage provider (by implementing IStorageProvider and related interfaces) and mimic Azure Blob Storage. Perhaps there are other, better options, but these came to mind first.
Marked as answer by apogosov on 2/27/2015 at 6:51 AM