The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

creating a cPanel account that already has DNS zone

Discussion in 'Bind / DNS / Nameserver Issues' started by ladydi711, Oct 5, 2015.

  1. ladydi711

    ladydi711 Well-Known Member

    Joined:
    Sep 4, 2001
    Messages:
    120
    Likes Received:
    3
    Trophy Points:
    18
    Hi,

    I host a DNS zone on my cPanel server that is not associated with a cPanel account.

    I now have the need to have an account (it would be a subdomain.mydomain.com).

    I do not want to inadvertently cause problems with the existing zone records.

    What is the best way to accomplish this without risking unintended changes to the existing zone?

    Thanks in Advance!
    Diane
     
  2. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    275
    Likes Received:
    31
    Trophy Points:
    28
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    You can just make a backup of the DNS zone and then overwrite the newly created one after you add the subdomain.

    Code:
    # cp /var/named/domain.com.db /var/named/domain.com.db.bk
    go into WHM and delete the zone, then go into cPanel and add the subdomain.
    Code:
    # cp -rf /var/named/domain.com.db.bk /var/named/domain.com.db 
    # service named reload
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Yes, as mentioned in the previous post, you can only do this by first backing up and removing the existing zone, followed by creating the account and copying over the saved zone.

    Thank you.
     
  4. ladydi711

    ladydi711 Well-Known Member

    Joined:
    Sep 4, 2001
    Messages:
    120
    Likes Received:
    3
    Trophy Points:
    18
    Thanks, All!

    I have noticed that the creation of a cPanel account creates some additional records that the current zone file will not have. Is there anything cPanel specific that I need to worry about/retain?

    Thanks,
    Diane
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    You can backup the zone that cPanel created before deleting it and then manually add those entries to the existing zone after copying it over.

    Thank you.
     
  6. ladydi711

    ladydi711 Well-Known Member

    Joined:
    Sep 4, 2001
    Messages:
    120
    Likes Received:
    3
    Trophy Points:
    18
    I've followed these steps, but when I Edit the zone in WHM, it is displaying the entries from the version of the zone after the new account was created. What step am I missing?
     
  7. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  8. ladydi711

    ladydi711 Well-Known Member

    Joined:
    Sep 4, 2001
    Messages:
    120
    Likes Received:
    3
    Trophy Points:
    18
    Yes, unfortunately, that did not work. I opened a cPanel support ticket and they instructed me that because the serial number of the old zone was less than the serial of the new zone, it was only using the new zone. I manually had to add all the records needed from the old zone.
     
  9. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    649
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page