How to Multi-Site Domains with DVH Servers

The following tutorial is on how to create multi-site on Drupalvaluehosting.com (DVH) servers.

The database is shared with table prefixes for each multi-site. The content and users is not shared but having all the multi-sites in one database instead of separate ones makes back ups and site retrieval a lot easier. The table prefixes allow that one database file to treat each prefix as a separate database.

In this tutorial your multi site is example.domain.com and your base drupal is in domain.com and it is the primary domain for your DVH hosting account

1)Create a subdomain in their control panel
delete the newly created subdomain folder using FTP or their File manager

2)In the FTP manager, navigate to the sites folder (the one with the deafult folder already in)
In sites folder create a folder called example.domain.com
Transfer into that folder, the settings.php from the original Drupal download

3)Log into your hosting account using SSH
Putty is a great client for windows

after logging in

type:

cd public_html
ln -s . example

3)Close Putty (the multisite link is created now.) Type example.domain.com in your web-browser and you should arrive at a installation screen.

4)Since the sites share the same database file make sure you enter a table prefix before anything else (if you don't do so, you'd face a whole load of sql errors that can only be fixed by replacing the settings.php file with the one that comes pre-packed with Drupal.) The table prefix option is in the advanced section of the installation screen on the administration page. I usually name my prefixes with the sub domain name to make it easier to remember the prefix.

5)Type in the database name of the primary domain.com database and the user name and passwords that have access to it. If the prefix was entered correctly you should see a Drupal site ready to be configured in example.domain.com

Optional step 6) In sites folder/example.domain.com folder you can add a themes folder and in that themes folder you can place the default theme of your choice for your multi-site. (theres no need to create an administration user to initiate the theme if the theme folder and its folders is in sites/themes/themename)

Average: 4.2 (19 votes)