By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,869 Members | 1,742 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,869 IT Pros & Developers. It's quick & easy.

Apache/Gallery Question: Setting Up 10+ Servers With One Domain Name

P: n/a
Hello!

Suppose I have ten servers at ten ips:

x.x.x.1
x.x.x.2
x.x.x.3
x.x.x.4 and so on

Each server hosts 100+ photo galleries, all under a single domain name,
but in different directories:

gallery.com/gallery100
gallery.com/gallery2000
gallery.com/gallery300
gallery.com/gallery4442

How is it possible to configue apache to point to ten different
servers, depending on which gallery is accessed?

I don't want the domain to be merely forwarded, but all hits in any
gallery, such as gallery.com/gallery4442, must leave
gallery.com/gallery4442 in the access window.

Is this possible? What's the best way to do this? Thanks so much!

(If this isn't clear, I'll elaborate). Thanks!!

Jul 17 '05 #1
Share this Question
Share on Google+
10 Replies


P: n/a
You could use a header("location: ") redirect, or you could set up sub
domains and point each to their respective server's IP: ex. g1.gallery.com,
g2.gallery.com, etc - like php does with usx.php.net. Contact your net admin
to find out how to do that - there may be a web interface that allows you to
do domain forwarding/pointing.

What, I wonder, are you doing with 1000 photo galleries? ;-)

"Captain Ranger McCoy" <mo***********@yahoo.com> wrote in message
news:11**********************@o13g2000cwo.googlegr oups.com...
Hello!

Suppose I have ten servers at ten ips:

x.x.x.1
x.x.x.2
x.x.x.3
x.x.x.4 and so on

Each server hosts 100+ photo galleries, all under a single domain name,
but in different directories:

gallery.com/gallery100
gallery.com/gallery2000
gallery.com/gallery300
gallery.com/gallery4442

How is it possible to configue apache to point to ten different
servers, depending on which gallery is accessed?

I don't want the domain to be merely forwarded, but all hits in any
gallery, such as gallery.com/gallery4442, must leave
gallery.com/gallery4442 in the access window.

Is this possible? What's the best way to do this? Thanks so much!

(If this isn't clear, I'll elaborate). Thanks!!

Jul 17 '05 #2

P: n/a
Hello!

You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.

How do the big guys do it?

Thanks!

Jul 17 '05 #3

P: n/a
Use a SAN (Storage Area Network). There are ISPs that will do this for you
under their managed hosting plans, or you could purchase the hardware
yourself. If you have spacial requirements that necessitate a SAN system you
will probably have high bandwidth requirements and be better served by
managed hosting than an in-house solution.

ECRIA
http://www.ecria.com
Jul 17 '05 #4

P: n/a
jo************@yahoo.com wrote:
You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.


I heard the jargon "Round-robin DNS", but didn't dig on that.

--
<?php echo 'Just another PHP saint'; ?>
Email: rrjanbiah-at-Y!com Blog: http://rajeshanbiah.blogspot.com

Jul 17 '05 #5

P: n/a
>> You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.


I heard the jargon "Round-robin DNS", but didn't dig on that.


Round-robin DNS requires *EVERY* server in the round-robin to have
access to *EVERY* piece of content it needs to serve. One way of
doing this is a big storage farm (which can contain as many CPUs
as needed) with all the content on it, and some web servers that
remote-mount all the volumes.

If you need more content, grow the storage farm. If you need more
horsepower, add more web servers. Eventually you'll need to upgrade
the bandwidth between the servers and the storage farm. As far
as Apache is concerned, each system has a whole lot of local content.

Gordon L. Burditt
Jul 17 '05 #6

P: n/a
Captain Ranger McCoy wrote:
Hello!

Suppose I have ten servers at ten ips:

x.x.x.1
x.x.x.2
x.x.x.3
x.x.x.4 and so on

Each server hosts 100+ photo galleries, all under a single domain name,
but in different directories:

gallery.com/gallery100
gallery.com/gallery2000
gallery.com/gallery300
gallery.com/gallery4442

How is it possible to configue apache to point to ten different
servers, depending on which gallery is accessed?

I don't want the domain to be merely forwarded, but all hits in any
gallery, such as gallery.com/gallery4442, must leave
gallery.com/gallery4442 in the access window.

Is this possible? What's the best way to do this? Thanks so much!

(If this isn't clear, I'll elaborate). Thanks!!


You're going to have a problem here. If all servers have access to the
same content, they can all have the same domain name. However, if
they're going to server up different content, there needs to be a way to
differentiate them.

For instance - let's say you have a web page with six images. If you
had all your servers named gallery.com, the web page would be pulled
form one of the servers. But now the browser would request the first
image on the page (i.e. "picture1.gif" or "gallery100/picture1.gif").
But there is no guarantee that the request would end up at the same
server which sent the page itself (since all servers have the same host
name). The only solution to this is to have all servers have access to
the same information.

You could offload some of the work to other machines - especially if you
need to server dynamic pages and/or use a databases. In this case
different machines can contain different dynamic pages and/or databases.
This way you might be able to get by with a few servers having access
to all content. Alternatively, you could implement one server acting as
a proxy and use it to forward requests to other servers. It's more work
and not as scalable, but if you're doing a lot of static pages it might
work better.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Jul 17 '05 #7

P: n/a
jo************@yahoo.com wrote:
Hello!

You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.

How do the big guys do it?


Probably the same way our company does it: big, expensive load balancers
(>USD$15,000 each....and we've got about 10 of them).

To achieve what you want you're going to need a "director" of some sort that
can interpret a HTTP request then direct that request to the correct
server/IP. Your external DNS will point "gallery.com" to the director
which will then distribute the work load based on the requested content.
This is usually done with load balancers or firewalls/routers/switches with
high layer[1] packet inspection - none of that level of equipment come
cheap.

Cheers,

James
[1] as in "OSI model" layer 4+
--
IBM's original motto:
Cogito ergo vendo; vendo ergo sum.

Jul 17 '05 #8

P: n/a
Gordon Burditt wrote:
You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.
I heard the jargon "Round-robin DNS", but didn't dig on that.


Round-robin DNS requires *EVERY* server in the round-robin to have
access to *EVERY* piece of content it needs to serve.


No it doesn't. But it does make life a lot simpler.
One way of
doing this is a big storage farm (which can contain as many CPUs
as needed) with all the content on it, and some web servers that
remote-mount all the volumes.


Presumably the content is split across multiple servers because there's too
much to fit on just one?

Assuming you're running Linux You caould set up a network raid device using
the data areas of the servers.

If you want a programmatic solution - think 404 handler.

C.
Jul 17 '05 #9

P: n/a
yeah Yahoo can afford $$$$$$$$$$$$$$$$$$$$$$$ wereas you might not be able
to afford $$$$$$$$$$$$$$$$$ - load balancers sound about right
<jo************@yahoo.com> wrote in message
news:11**********************@g43g2000cwa.googlegr oups.com...
Hello!

You know how yahoo has thousands of servers, but you only ever see
"yahoo.com/..." in the browser window?

I'd like to do the same thing, so as to avoid sub domains such as
g1.gallery.com,
g2.gallery.com, etc

so that everything is just at gallery.com.

How do the big guys do it?

Thanks!

Jul 17 '05 #10

P: n/a
As often, it depends...

Do you want to spread the network load, or the disk load? In the latter
case you might want to try a far simpler solution like NFS driectories.

HTH

Gerard
Op 25 Jun 2005 19:00:31 -0700 schreef Captain Ranger McCoy:
Hello!

Suppose I have ten servers at ten ips:

x.x.x.1
x.x.x.2
x.x.x.3
x.x.x.4 and so on

Each server hosts 100+ photo galleries, all under a single domain name,
but in different directories:

gallery.com/gallery100
gallery.com/gallery2000
gallery.com/gallery300
gallery.com/gallery4442

How is it possible to configue apache to point to ten different
servers, depending on which gallery is accessed?

I don't want the domain to be merely forwarded, but all hits in any
gallery, such as gallery.com/gallery4442, must leave
gallery.com/gallery4442 in the access window.

Is this possible? What's the best way to do this? Thanks so much!

(If this isn't clear, I'll elaborate). Thanks!!

Jul 17 '05 #11

This discussion thread is closed

Replies have been disabled for this discussion.