Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Is this redirect possible.

Discussion in 'Bind/DNS/Nameserver' started by keat63, Mar 19, 2019.

  1. keat63

    keat63 Well-Known Member

    Joined:
    Nov 20, 2014
    Messages:
    1,296
    Likes Received:
    91
    Trophy Points:
    28
    cPanel Access Level:
    Root Administrator
    We have a domain in use with https protocol.
    Let call it example.co.uk

    We have its .com equivilent which is currently parked. example.com

    At registrar level, I have web forwarding setup so any traffic destined for example.com is forwarded to example.co.uk.

    In my browser, if i type www.example.com, this is being forwarded to https://www.example.co.uk. so is working.

    However, if in my browser I type
    Code:
     https://www.example.com 
    , it goes nowhere, it times out.

    I have considered that example.com doesn't reside anywhere so subsequently doesn't have an ssl certificate.

    Is this even possible to redirect.
     
    #1 keat63, Mar 19, 2019
    Last edited by a moderator: Mar 19, 2019
  2. keat63

    keat63 Well-Known Member

    Joined:
    Nov 20, 2014
    Messages:
    1,296
    Likes Received:
    91
    Trophy Points:
    28
    cPanel Access Level:
    Root Administrator
    I've confirmed with the registrar, that this is not possible.
    The https certificate doesn't actually exist, so it can't be forwarded.

    However, would this work.
    I have a dedicated server (which doesn't host the .co.uk domain).
    If I change the NS records at registar level (for the .com) to point to this dedicated server.
    Then create a new account for the .com domain, and have CPanel install an SSL, could I then webforward this to the .co.uk hosting server.

    In effect.
    Registrar has NS records pointing to my dedicated server.
    My server, holds the DNS records and ssl cert, which in turn redirects the .com to the server holding the .co.uk domain.
    Its messy and I guess may put extra traffic on my server, but could this work.
     
  3. keat63

    keat63 Well-Known Member

    Joined:
    Nov 20, 2014
    Messages:
    1,296
    Likes Received:
    91
    Trophy Points:
    28
    cPanel Access Level:
    Root Administrator
    It seems to work.

    Although I had problems issuing an SSL certificate with a forwarder in place, so lets see what heppens upon SSL renewal.

    Is there a less messy way to do this ?
     
  4. Infopro

    Infopro cPanel Sr. Product Evangelist Staff Member

    Joined:
    May 20, 2003
    Messages:
    16,947
    Likes Received:
    485
    Trophy Points:
    583
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Is there a reason why simply setting up an Alias for the domain in your cPanel wouldn't work?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. keat63

    keat63 Well-Known Member

    Joined:
    Nov 20, 2014
    Messages:
    1,296
    Likes Received:
    91
    Trophy Points:
    28
    cPanel Access Level:
    Root Administrator
    I'm not sure what this is. ?

    Bear in mind that I have very little control over the .co.uk domain.
    This is hosted by a web developer, I only really have the registrar side of things.


    On the .com domain, I have full control.
     
  6. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    6,476
    Likes Received:
    506
    Trophy Points:
    263
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    A redirect would work just fine in this instance. Just set up a redirect in cPanel for example.com with/without www -> https://example.co.uk

    This should work for both http and https
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. keat63

    keat63 Well-Known Member

    Joined:
    Nov 20, 2014
    Messages:
    1,296
    Likes Received:
    91
    Trophy Points:
    28
    cPanel Access Level:
    Root Administrator
    Hi Lauren.

    I had a redirect already set up in my registrar control panel.
    Whilst this worked for example.com, it didn't work for https-example.com.
    example.com didn't reside anywhere.

    My work around was to change the NS entries at registrar level so example.com traffic would now be routed to my server.
    Then create examle .com on my server.

    My server then handles the redirect to the .co.uk domain, which also includes the https protocol.

    I don't envisage high volumes, however, it would have been nice if this could have been achieved at registrar level, which I guess would save hops and traffic being routed via my server.
     
  8. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    6,476
    Likes Received:
    506
    Trophy Points:
    263
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    this was exactly what I was suggesting you do, I am glad it works

    This would be something you'd need to discuss with the registrar, most likely the reason for this being is that there was no SSL for the site (both need to have an ssl) when the dns for it was hosted with the registrar.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice