0

I have existing Drupal 7 site and I want to create a sub-domain using the multisite feature of drupal.

I followed all the steps required for drupal multisite as below.

Suppose my existing site url is www.abc.com and I want to make a sub-domain as www.jobs.abc.com

Steps I followed.

  1. Under sites folder I created a new folder jobs.abc.com and copied the default.settings.php file renamed it as settings.php

    sites/jobs.abc.com/settings.php

2.My existing domain settings.php file is under default folder sites/default/settings.php

3.I Renamed the example.sites.php to sites.php and added the following two lines.

$sites['www.abc.com'] = 'default'; $sites['www.jobs.abc.com'] = 'jobs.abc.com';

Finally I installed the Multisite wizard module http://ftp.drupal.org/files/projects/multisite_wizard-7.x-1.3.tar.gz

I configured the module it is showing me the message

"Hint: the folders names should be the same as values of domain-folder array in the site.php file Folders to be created: default,job.abc.com" please find the screenshot.

enter image description here

I have already created these folders there. I am not sure why its showing this message again.

  • Are you sure that you have created the folders in the proper directory and that they are browsable by the server? Supposing that you have your drupal installed in /var/www/mydrupal, the following folders should exist: /var/www/mydrupal/sites/default and /var/www/mydrupal/sites/jobs.abc.com and the server (usually Apache) should be the owner of the directories (usually www-data user). If it's not try to change the ownership (in Linux the command looks like: chown -R www-data:www-data /var/www/mydrupal/sites/jobs.abc.com ) – F1234k Sep 14 '14 at 14:40
  • I have created the same folders, even both the folders contains the settings.php files, do not understand why the folders are not detected. Regarding the ownership I will check with this. – Mudasir Sep 15 '14 at 8:30
  • I have condensed my comment in an answer for posterity reasons. – F1234k Sep 17 '14 at 14:52
1

Having the folders that the message states in your sites/ directory involves two basic steps:

  1. Creating the directories
  2. Making the directories visible to the web server

In a typical Ubuntu installation with Apache as your server the first step is accomplished by executing the mkdir command in your sites directory:

Example

cd /var/www/my_drupal_site/sites
mkdir jobs.abc.com

and for the second step using the chown command.

chown -R www-data:www-data default
chown -R www-data:www-data jobs.abc.com

The chown command changes the ownership of the directory and with the -R flag it does the same thing recursively for every contained subdirectory and file. The www-data is the default user and group that Apache runs as (so if you have an nginx setup, you will probably have to change this).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.