
10-30-2008, 08:21 AM
|
|
|
redirect a subdomain to external IP
Hi,
Is there any way to redirect a subdomain on a machine A to point to an IP adress on a second machine B.
thanks
william !
|

10-30-2008, 08:34 AM
|
|
|
What control panel are you using for this subdomain ?
|

10-30-2008, 09:00 AM
|
|
Corporate Member
|
|
Join Date: Jan 2008
Location: Jax, FL
Posts: 2,648
|
|
Edit the DNS zone for the domain and create a record like this:
subdomain IN A 192.168.1.1
That will cause all requests for that subdomain to go to the second server. Ask your host for assistance if you cannot edit the DNS zone.
__________________â Daniel | Server Complete | [simpligreat]* integration servicesâ Premium Hosting Solutions --- VPS | Hybrid | Dedicated | Backupsâ Now located in TWO premium datacenters --- GNAX AtlantaNAP (Atlanta, GA) | DataBank (Dallas, TX)â Stunning seamless results that look simply great. | [simpligreat]* integration services
|

10-30-2008, 09:23 AM
|
|
Web Hosting Master
|
|
Join Date: Aug 2007
Posts: 6,895
|
|
You can add these lines to .htaccess file of your sub domain. RewriteEngine on
RewriteCond %{HTTP_HOST} ^test.domain.com$
RewriteRule ^(.*)$ "http\:\/\/192\.168\.1\.1" [R=301,L]
this will redirect test.domain.com to 192.168.1.1( You will have to edit your subdomain instead of test.domain.com and replace the IP with machine B IP )
__________________iHubNet Ltd - Premium Hosting Solutions 4 ALL ⢠Solid Support ⢠Solid Equipment ⢠Solid Network Shared Hosting / Reseller Hosting / Managed ServerMatt A.
|

10-30-2008, 10:21 AM
|
|
Web Hosting Master
|
|
Join Date: Jun 2006
Location: it seems on line ;)
Posts: 923
|
|
Quote:
Originally Posted by marigwil
Hi,
Is there any way to redirect a subdomain on a machine A to point to an IP adress on a second machine B.
thanks
william !
Include this line within the .htaccess file (root html directory of your subdomain_machine):
redirect 301 <root_of_your_subdomain_location> <second_machine_IP>
sample:
redirect 301 /subdomain/ http://11.111.111.11/
it will display the new home for your subdomain, whatever you call it
__________________Gonzalo
"To venture is to risk one's life; not to venture is to lose one's reason to live"
Last edited by freeflyer : 10-30-2008 at 10:27 AM.
Reason: typo
|

10-30-2008, 11:09 AM
|
|
|
ANSWER
Quote:
Originally Posted by InfusionHosting
What control panel are you using for this subdomain ?
i am using PLESK
|

10-30-2008, 11:12 AM
|
|
|
Hi all, thanks, problem solved.
I have used solution from SC-Daniel with Neuf Telecom.
Thanks
|

10-30-2008, 11:14 AM
|
|
Junior Guru Wannabe
|
|
Join Date: Sep 2007
Posts: 40
|
|
Quote:
Originally Posted by marigwil
i am using PLESK
I don't use Plesk, so I'm not entirely sure if you can change the DNS entries from the control panel.
I suggest you contact your hosting company and request them to update the A Record for the sub-domain so that it points to the new IP address. However, I don't recommend you use the .htaccess method as suggested above.
|

10-30-2008, 11:17 AM
|
|
|
Quote:
Originally Posted by JstTom
I don't use Plesk, so I'm not entirely sure if you can change the DNS entries from the control panel.
I suggest you contact your hosting company and request them to update the A Record for the sub-domain so that it points to the new IP address. However, I don't recommend you use the .htaccess method as suggested above.
Yes I will USE A entry in DNS with my hosting provider.
Thanks
|

10-31-2008, 01:03 AM
|
|
Web Hosting Master
|
|
Join Date: Aug 2003
Location: Gods Own Country
Posts: 850
|
|
Quote:
Originally Posted by marigwil
Hi,
Is there any way to redirect a subdomain on a machine A to point to an IP adress on a second machine B.
thanks
william !
Yes, its very simple. Just edit the DNS entry for the subdomain with the machine B's IP.
__________________
Blessen Cherian
CTO, www.bobcares.comMy 2 cent on Preventing DDOS
HeMan and the Masters of VPS
|

10-31-2008, 01:04 AM
|
|
Junior Guru
|
|
Join Date: Apr 2006
Posts: 181
|
|
I'm lovin the 1000s ways people explain this.
__________________â HastyFree - Solutions for the Web - http://www.hastyfree.comâ Join the Revolution Today! See why we're raved!â Tons of Scripts, 99.9% Uptime Guarantee, Active Community!
|

10-31-2008, 01:12 AM
|
|
Web Hosting Master
|
|
Join Date: Jun 2006
Location: it seems on line ;)
Posts: 923
|
|
Quote:
Originally Posted by blessen
Yes, its very simple. Just edit the DNS entry for the subdomain with the machine B's IP.
Is that redirecting? The subdomain would not be available under different URLs, just
under the one matching the new DNS entry.
__________________Gonzalo
"To venture is to risk one's life; not to venture is to lose one's reason to live"
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
| Postbit Selector |
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|
|
| Login: |
|
|
| Advertisement: |
|
|
| Web Hosting News: |
|
|
|