Web Hosting Forum Login
Not a member yet? Sign up

How to point subdomain to another server?

  • HOME
  • FORUMS
  • WEB DESIGN
  • WEB HOSTING OFFERS
  • ADVERTISING
  • FIND A HOST
  • WEB HOSTING
  • QUICK MENU
  • REGISTER HERE - Join us for FREE
Results 1 to 9 of 9
  1. #1
    Join Date
    Oct 2013
    Posts
    20
    Thanks
    4
    Thanked 1 Time in 1 Post
    Thumbs Up/Down
    Received: 0/0
    Given: 8/0

    How to point subdomain to another server?

    I'm using WHM/cPanel and I had my domain name hosted on an IP, just wondering how can I setup a sub domain to point to a different server independently without a redirection?

  2. #2
    Join Date
    Jul 2016
    Location
    Hertfordshire, UK
    Posts
    674
    Thanks
    33
    Thanked 151 Times in 132 Posts
    Thumbs Up/Down
    Received: 305/3
    Given: 114/3
    You should just be able to change the DNS for that subdomain in the DNS zone for the domain. Just point those records at the other server.
    UK Web Hosting | Reseller Hosting | VPS | Domain Registration | Affiliates
    100% Cloud Powered | 30 Day Money Back Guarantee | cPanel | 365 Day UK Support
    https://www.ljshost.com

  3. #3
    Join Date
    Jan 2017
    Posts
    43
    Thanks
    5
    Thanked 18 Times in 12 Posts
    Thumbs Up/Down
    Received: 35/0
    Given: 35/0
    Hi elzorro,

    You can login to your DNS management for your domain and add an a record for your sub-domain. The below is a sample record in from my DNS zone. ftp1 would be your sub-domain name. The 0.0.0.0 should be replace with the ip of your other server.

    ftp1 A - IPv4 Address 0.0.0.0

  4. #4
    Join Date
    Oct 2013
    Posts
    20
    Thanks
    4
    Thanked 1 Time in 1 Post
    Thumbs Up/Down
    Received: 0/0
    Given: 8/0
    Quote Originally Posted by LJSHost View Post
    You should just be able to change the DNS for that subdomain in the DNS zone for the domain. Just point those records at the other server.
    Would you mind giving me a real example? I will use A record for this?


    Quote Originally Posted by kevinhng86 View Post
    Hi elzorro,

    You can login to your DNS management for your domain and add an a record for your sub-domain. The below is a sample record in from my DNS zone. ftp1 would be your sub-domain name. The 0.0.0.0 should be replace with the ip of your other server.

    ftp1 A - IPv4 Address 0.0.0.0
    Can you share me an image how to setup this? I am new to WHM/cPanel.

    One question more, Instead of pointing for a sub domain, I can point for a sub folder

    For example

    example.com/myblog/

    /myblog/ will be hosted on other hosting servers.

    I have not ever done this in the past.

  5. #5
    Join Date
    Jan 2017
    Posts
    43
    Thanks
    5
    Thanked 18 Times in 12 Posts
    Thumbs Up/Down
    Received: 35/0
    Given: 35/0
    Quote Originally Posted by elzorro View Post
    Would you mind giving me a real example? I will use A record for this?




    Can you share me an image how to setup this? I am new to WHM/cPanel.

    One question more, Instead of pointing for a sub domain, I can point for a sub folder

    For example

    example.com/myblog/

    /myblog/ will be hosted on other hosting servers.

    I have not ever done this in the past.
    I do not think you can point a folder to another hosting provider. I don't think DNS record allow you to point a folder to an ip, DNS only allow you to point the URL itself but not the fragment of it which is the folder structure. However I think you can point the sub-domain to a difference server and then use mod-rewrite or redirect your folder to your sub-domain.

    For Cpanel edit of DNS record check out this link https://documentation.cpanel.net/display/ALD/Edit+DNS+Zone.

    In Cpanel click on simple DNS zone editor. You will get that screen in the image. In the name box of add an A record put in the sub-domain name. In the address box of add an A record is the I.Pv4.0 address of the hosting server. After fill in that two box you can click add an A record.

    Name:  Screenshot from 2017-01-12 01:21:23.jpg
Views: 68
Size:  52.7 KB

    For redirection you need to use .htaccess file with rewrite engine. You can add the below to the .htaccess file on your web-root directory.
    Code:
    Options +FollowSymLinks
    RewriteEngine On
    Redirect 301 /myblog http://myblog.yourdomain.com/

  6. The Following User Says Thank You to kevinhng86 For This Useful Post:
    elzorro (01-12-2017)

  7. #6
    Join Date
    Jul 2016
    Location
    Hertfordshire, UK
    Posts
    674
    Thanks
    33
    Thanked 151 Times in 132 Posts
    Thumbs Up/Down
    Received: 305/3
    Given: 114/3
    Quote Originally Posted by elzorro View Post
    Would you mind giving me a real example? I will use A record for this?

    Can you share me an image how to setup this? I am new to WHM/cPanel.
    If you upload a screen shot of the zone file for this domain I can show you what needs changing.
    UK Web Hosting | Reseller Hosting | VPS | Domain Registration | Affiliates
    100% Cloud Powered | 30 Day Money Back Guarantee | cPanel | 365 Day UK Support
    https://www.ljshost.com

  8. #7
    Join Date
    Oct 2013
    Posts
    20
    Thanks
    4
    Thanked 1 Time in 1 Post
    Thumbs Up/Down
    Received: 0/0
    Given: 8/0
    Quote Originally Posted by kevinhng86 View Post
    I do not think you can point a folder to another hosting provider. I don't think DNS record allow you to point a folder to an ip, DNS only allow you to point the URL itself but not the fragment of it which is the folder structure. However I think you can point the sub-domain to a difference server and then use mod-rewrite or redirect your folder to your sub-domain.

    For Cpanel edit of DNS record check out this link https://documentation.cpanel.net/display/ALD/Edit+DNS+Zone.

    In Cpanel click on simple DNS zone editor. You will get that screen in the image. In the name box of add an A record put in the sub-domain name. In the address box of add an A record is the I.Pv4.0 address of the hosting server. After fill in that two box you can click add an A record.

    Name:  Screenshot from 2017-01-12 01:21:23.jpg
Views: 68
Size:  52.7 KB

    For redirection you need to use .htaccess file with rewrite engine. You can add the below to the .htaccess file on your web-root directory.
    Code:
    Options +FollowSymLinks
    RewriteEngine On
    Redirect 301 /myblog http://myblog.yourdomain.com/
    I don't think it is simple like that. Thanks for guiding me.
    This should add in cPanel of a domain, not in WHM, right?

    Quote Originally Posted by LJSHost View Post
    If you upload a screen shot of the zone file for this domain I can show you what needs changing.
    Is this the zone file? here is mine

    Name:  dns-zone-file.png
Views: 30
Size:  133.7 KB

  9. #8
    Join Date
    Jul 2016
    Location
    Hertfordshire, UK
    Posts
    674
    Thanks
    33
    Thanked 151 Times in 132 Posts
    Thumbs Up/Down
    Received: 305/3
    Given: 114/3
    That does not seem to be the correct zone file.
    It needs to be the zone file from the domain that has the sub domain you want to point somewhere else.

    WHM creates addon domains as a redirected subdomain for the domain but sub domains are still sub domains.

    for example subdomain.domain.com you would need the zone file for domain.com
    UK Web Hosting | Reseller Hosting | VPS | Domain Registration | Affiliates
    100% Cloud Powered | 30 Day Money Back Guarantee | cPanel | 365 Day UK Support
    https://www.ljshost.com

  10. #9
    Join Date
    Jan 2017
    Posts
    43
    Thanks
    5
    Thanked 18 Times in 12 Posts
    Thumbs Up/Down
    Received: 35/0
    Given: 35/0
    Quote Originally Posted by elzorro View Post
    I don't think it is simple like that. Thanks for guiding me.
    This should add in cPanel of a domain, not in WHM, right?



    Is this the zone file? here is mine

    Name:  dns-zone-file.png
Views: 30
Size:  133.7 KB
    With that panel style, under the add new entries, the first white box just put in your subdomain name. The select box should have an record mention something in regard to A, Cname, etc. Choose A. After that it will probably produce a white box somewhere. Type the I.P in that white box. For Ipv4 server use the A name record. For Ipv6 server use AAAA record.

Newer Threads

  1. forumrating
    Gecko
    Replies: 5 | Views: 54
    Last post by Gecko, 01-12-2017, 03:02 AM
  2. forumrating
    Godaddy heavy pricing
    By forumrating in forum Domain Names
    Gecko
    Replies: 6 | Views: 128
    Last post by Gecko, 01-20-2017, 06:42 AM
  3. forumrating
    Gecko
    Replies: 1 | Views: 61
    Last post by Gecko, 01-12-2017, 03:25 AM
  4. AnnaBlanch
    vpsrus
    Replies: 11 | Views: 216
    Last post by vpsrus, 01-20-2017, 03:37 AM
  5. energizedit
    hfav
    Replies: 10 | Views: 413
    Last post by hfav, 01-20-2017, 02:30 AM

Older Threads

  1. wpspeedster
    LJSHost
    Replies: 7 | Views: 226
    Last post by LJSHost, 01-13-2017, 09:12 PM
  2. harrygreen90
    GswHosting
    Replies: 2 | Views: 184
    Last post by GswHosting, 01-11-2017, 07:16 PM
  3. harrygreen90
    DDoS protection service?
    By harrygreen90 in forum Dedicated Server
    RDO Servers
    Replies: 6 | Views: 416
    Last post by RDO Servers, 01-12-2017, 12:06 PM
  4. harrygreen90
    eva2000
    Replies: 8 | Views: 307
    Last post by eva2000, 01-15-2017, 01:08 AM

Latest Threads

  1. DefaultUser
    NickR
    Replies: 1 | Views: 9
    Last post by NickR, Today, 10:02 AM
  2. hostingcoupons
    eva2000
    Replies: 1 | Views: 30
    Last post by eva2000, Today, 06:56 AM
  3. hostingcoupons
    What ports do SFTP and FTPS use?
    By hostingcoupons in forum Web Hosting
    eva2000
    Replies: 2 | Views: 14
    Last post by eva2000, Today, 07:04 AM
  4. hostingcoupons
    Move WHMCS to Subdomain?
    By hostingcoupons in forum Reseller Hosting
    hostingcoupons
    Replies: 0 | Views: 8
    Last post by hostingcoupons, Today, 05:17 AM
  5. Aaron Lavers
    eva2000
    Replies: 1 | Views: 14
    Last post by eva2000, Today, 07:05 AM

Similar Threads

  1. Mihai B.
    meetdilip
    Replies: 3 | Views: 450
    Last post by meetdilip, 04-19-2016, 06:56 PM
  2. alwolsten
    alwolsten
    Replies: 0 | Views: 495
    Last post by alwolsten, 07-24-2015, 03:44 PM
  3. Joseph_Hill
    NickTheMusketeer
    Replies: 2 | Views: 783
    Last post by NickTheMusketeer, 01-19-2015, 02:27 PM
  4. Joe S.
    dandeedo
    Replies: 8 | Views: 1311
    Last post by dandeedo, 11-27-2014, 05:53 AM
  5. marco
    marco
    Replies: 9 | Views: 2407
    Last post by marco, 10-04-2014, 06:21 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Web Hosting Forum

ForumWeb.Hosting is a web hosting forum where you’ll find in-depth discussions and resources to help you find the best hosting providers for your websites or how to manage your hosting whether you are new or experienced. You’ll find it all here. With topics ranging from web hosting, internet marketing, search engine optimization, social networking, make money online, affiliate marketing as well as hands-on technical support for web design, programming and more. We are a growing community of like-minded people that is keen to help and support each other with ambitions and online endeavors. Learn and grow, make friends and contacts for life.

Community

The world's smartest hosting providers come here to discuss & share what's trending in the web hosting world!
Copyright ©2017, ForumWeb.Hosting. All rights reserved. Web Hosting Forum for webmasters, web hosting providers, designers and web developers.

Welcome to Forum Web Hosting

The World's Number 1 Web Hosting Community, Reviews & Services

Log in!

Continue with Facebook
Continue With Email. By signing up you indicate that you have read and agree to the Terms of Service and Privacy Policy.

Sign in Manually

Need an account? Sign up now!