Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for
Website redirection to other server on same network ?
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Plusnet Community
- :
- Forum
- :
- Help with my Plusnet services
- :
- Everything else
- :
- Website redirection to other server on same networ...
Website redirection to other server on same network ?
04-12-2013 9:33 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
To save me Googling this for ages ......
My website lands on a page on server running as a virtual machine. This handles email and web while another separate couple of virtual machines handle other tasks on my network.
Ideally I'd like to run separate servers for mail, web, forum, shop etc. This is easily done for the mail by redirecting ports 110 and 25 etc to my VM which is running the email server.
What I need is to filter the incoming traffic to the appropriate virtual machine i.e.
www.mydomain.com/shop -> 192.168.5.100
www.mydomain.com/forum -> 192.168.5.101
www.mydomain.com/private -> 192.168.5.102
etc etc.
Any easy way to do it ? I know I could use different ports i,e, www.mydomain.com:81 -> 192.168.5.100 as port mapping on the router but it would be neater for people to land on my home page then get redirected (seamlessly) to the appropriate server without even noticing there was a redirect going on.
Pointers ? Places to look ? Keywords to Google ? Examples ? All will help
Ta
Dom
My website lands on a page on server running as a virtual machine. This handles email and web while another separate couple of virtual machines handle other tasks on my network.
Ideally I'd like to run separate servers for mail, web, forum, shop etc. This is easily done for the mail by redirecting ports 110 and 25 etc to my VM which is running the email server.
What I need is to filter the incoming traffic to the appropriate virtual machine i.e.
www.mydomain.com/shop -> 192.168.5.100
www.mydomain.com/forum -> 192.168.5.101
www.mydomain.com/private -> 192.168.5.102
etc etc.
Any easy way to do it ? I know I could use different ports i,e, www.mydomain.com:81 -> 192.168.5.100 as port mapping on the router but it would be neater for people to land on my home page then get redirected (seamlessly) to the appropriate server without even noticing there was a redirect going on.
Pointers ? Places to look ? Keywords to Google ? Examples ? All will help

Ta
Dom
Message 1 of 5
(952 Views)
4 REPLIES 4
Re: Website redirection to other server on same network ?
04-12-2013 9:41 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Have you considered shop.mydomain.com, forum.mydomain.com, private.mydomain.com?
That would be a doddle with DNS entries - but you would need an IP block if the servers are on your LAN.
That would be a doddle with DNS entries - but you would need an IP block if the servers are on your LAN.
jelv (a.k.a Spoon Whittler) Why I have left Plusnet (warning: long post!) Broadband: Andrews & Arnold Home::1 (FTTC 80/20) Line rental: Pulse 8 Home Line Rental (£14.40/month) Mobile: iD mobile (£4/month) |
Message 2 of 5
(384 Views)
Re: Website redirection to other server on same network ?
04-12-2013 9:47 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
That is where the plan falls down - I have a single static IP.
My website traffic is minimal but specialist and I'd like to keep various people out of various areas which would be easier to do with multiple VMs running dedicated sites.
I had/have huge problems with Chinese and Russian hackers so by segmenting everything makes it slightly easier to manage.
I'm looking at the mod_rewrite directives in Apache at the moment - before I embark on this I just wanted some input from members with a bit more web knowledge than me
*Edit - stumbled upon proxypass which could well do the job. Will have to experiment tomorrow !
My website traffic is minimal but specialist and I'd like to keep various people out of various areas which would be easier to do with multiple VMs running dedicated sites.
I had/have huge problems with Chinese and Russian hackers so by segmenting everything makes it slightly easier to manage.
I'm looking at the mod_rewrite directives in Apache at the moment - before I embark on this I just wanted some input from members with a bit more web knowledge than me

*Edit - stumbled upon proxypass which could well do the job. Will have to experiment tomorrow !
Message 3 of 5
(384 Views)
Re: Website redirection to other server on same network ?
04-12-2013 9:53 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Use nginx and the Reverse Proxy function.
You can do something similar to:
location /shop {
proxy_pass http://192.168.5.100/;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location /forum {
proxy_pass http://192.168.5.101/;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
http://wiki.nginx.org/HttpProxyModule
Cheers
B.
You can do something similar to:
location /shop {
proxy_pass http://192.168.5.100/;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location /forum {
proxy_pass http://192.168.5.101/;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
http://wiki.nginx.org/HttpProxyModule
Cheers
B.
Message 4 of 5
(384 Views)
Re: Website redirection to other server on same network ?
04-12-2013 9:56 PM
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Report to Moderator
Thanks Barry - I just found proxypass on my journeys (I run Apache by the way).
I was just editing my post as you posted
Will give it a play tomorrow.
Dom
I was just editing my post as you posted

Will give it a play tomorrow.
Dom
Message 5 of 5
(384 Views)
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Plusnet Community
- :
- Forum
- :
- Help with my Plusnet services
- :
- Everything else
- :
- Website redirection to other server on same networ...