Hey all,

So I finally broke down and got a GoDaddy account with 2 domains. So far, I've had no luck with setting up multiple sites within the same Drupal installation. Here's what I'd like to set up:

mydrupalsite.com
mydrupalsite.com/test

anotherdrupalsite.com
anotherdrupalsite.com/test

awikisite.com - a pmWiki driven site

anhtmlsite.com - static html

I read something somewhere about needing to set up links or virtual host settings. Not sure where to start there, so I'm testing out multisite on one domain for now:

mydrupalsite.com/drupal/mysite
mydrupalsite.com/drupal/mysite/test
mydrupalsite.com/drupal/anothersite
mydrupalsite.com/drupal/anothersite/test

I've got all the appropriate folders within the drupal/sites directory, but it doesn't seem to be working. The default site is up and running. Could that be the problem? Do i need to remove the default site?

Any pointers would be greatly appreciated. Thanks!

B

Comments

vm’s picture

no need to remove the default site. The problem is most certainly the part you don't understand as quoted here:

I read something somewhere about needing to set up links or virtual host settings. Not sure where to start there, so I'm testing out multisite on one domain for now:

Even with one domain, you need to point with a symlink or domain pointer.

What I'd suggest you do.

Set up a subdomain.maindomain.com
during your subdomain creation, you should "somewhere" in your host panel have the ability to tell your subdomain where to point to. At that stage you will have your subdomain point back to your maindomain, where index.php lies.

_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

bigbman’s picture

OK so, you're saying I should point drupal.mydrupalsite.com to mydrupalsite.com/drupal. From there I should be able to access any number of multisites like:

drupal.mydrupalsite.com/drupal/mysite
drupal.mydrupalsite.com/drupal/mysite/test
drupal.mydrupalsite.com/drupal/anothersite
drupal.mydrupalsite.com/drupal/anothersite/test

I'll give this a try. From there though, I'd like to have separate domain names for each site:

mydrupalsite.com
test.mydrupalsite.com

anothersite.com
test.anothersite.com

myhtmlsite.com

mypmwikisite.com

Does this sound possible? Thanks very much Misunderstood - looking forward to trying this out.

vm’s picture

From there I should be able to access any number of multisites

no, from there you can only access the installation for the subdomain.maindomain.com site.

each multisite needs to run its own install.

to explain the way it works in lamens terms

a multisite when pointed to the main install
searches your sites folder for a matching folder
then runs install.php so you can set up the DB same as you did with main install

Then when visitors come to a domain, or subdomain the same thing happens.
a user visits subdomain, subdomain points to main domain, and searches sites folder for the match.

I suggested doing a subdomain, so you can get your feet wet with a test install before jumping into "other" domains and pointers. Doing so would give greater insight on how it will work when you are ready to do a multisite for a production environment.
_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

bigbman’s picture

hmmm, I see two places to fool around with subdomains on GoDaddy. Does anyone have specific examples/instructions on how to get started on GoDaddy?

I'm obviously new to GoDaddy and setting this up on a remote server. I've been playing around with Drupal hosted on Windows/Apache for a while, but haven't done anything this complicated before.

I'm not 100% confident I get what you're suggesting VeryMisunderstood, but I'll keep digging into it. Any further clarification would be much appreciated if you have the time. Thanks so much for your help thus far. Drupal's community ROCKS!!!

B

vm’s picture

not sure how else I can direct you.

I'll try through a test multisite install I have.

I installed my first site at verymisunderstood.com (This site is in the public root)
I then set up a subdomain on my host called dev.verymisunderstood.com
I then went into my sites folder of my site1.com install and created a dev.verymisunderstood.com folder. In this folder I placed a fresh settings.php file
I went back to my host panel and set the subdomain dev.verymisunderstood.com to point to verymisunderstood.com

Now when I called dev.verymisunderstood.com for the first time
it, upon finding a blank settings.php file triggered the drupal install.
whereby I was able to set up a second site of a multisite.

you may want to research both here and on google, the term "symlink" which is another method of pointing. However, I found it much easier using the hosts panel to point my subdomain to my main domain.
_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

bigbman’s picture

So here's what I have in my root folder, and what I'd like to do with it. I'd like each domain to point directly at each folder so the url remains clean. I'll try what you suggested, but I'm not sure I'll get what I'm looking for.

GoDaddy Root:

./drupal (Drupal install)
     index.php
     /sites
          /default
          /drupalsite1             <-- www.drupalsite1.com
          /dev.drupalsite1       <-- www.dev.drupalsite1.com
          /drupalsite2             <-- www.drupalsite2.com
./pmWiki                           <-- www.wikisite.com
./html
     /htmlsite1                    <-- www.htmlsite1.com
     /htmlsite2                    <-- www.htmlsite2.com

Thanks in advance for any further help.

B

vm’s picture

the folder: dev.drupalsite1 in sites ?

should actuall be dev.drupalsite1.com in sites

as well as

the folder: /drupalsite2 in sites ?

should be www.drupalsite2.com
in sites.

you have to use the entire address as the folder name
_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

bigbman’s picture

actually, the documentation says it'll accept different formats - including taking out the www. and .com. I've tried it all. I think the issue is this:

my domain is actually called bryansbiz.com (be nice now hackers), and it points to the root folder in my account. So, I'm testing multisite with www.bryansbiz.com/drupal/site1, which probably screws it up.

I think what I need to do is point bryansbiz.com to the drupal directory. From there, GoDaddy has something called 'masking' which comes close to what I've seen called virtual host. I can point a third domain to a site folder this way... I think. It's basically a redirect that hides the destination url.

bigbman’s picture

So here's where I am so far (making progress):

www.bryansbiz.com
- points to the host root folder, which contains a static welcome page, and a drupal installation folder (./drupal)

www.bryansbusiness.com
- set up as a redirect to www.bryansbiz.com/drupal and uses what GoDaddy calls "masking" (pretty sure it's the same as virtual host) to display the URL as www.bryansbusiness.com, even though it points to the drupal folder.

So far, both URLs take me to the default site login page. Problem is, I cannot login using www.bryansbusiness.com - it just takes me back to the login page without any errors or logs. I can login fine using www.bryansbiz.com/drupal.

It seems like "masking" is the way to go, but I can't seem to get past this login issue. Has anyone else had this problem?

Once I get this working, I should be able to move on to multisite.

bigbman’s picture

so bryansbusiness.com now can login to the default site. Guess it just took some time for the masking to go into effect.

Still, a multisite/subsite called "test" is not reachable. I get a "page not found" error from the default site. Within ./sites I have

./sites
./sites/default
./sites/all
./sites/bryansbusiness.com.test

I should be able to reach "test", yes?