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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Best Practice for Second Server Configuration

Discussion in 'General Discussion' started by verdon, Sep 21, 2017.

  1. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    847
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    Hi,

    I'm looking for some general guidance/tips on adding a second shared server to a one-man, one-server hosting business.

    I currently have one sever, i.e.
    domain: example.com (111.222.333.400)
    hostname: server1.example.com (111.222.333.400)
    dns: ns1.example.com (111.222.333.400) and ns2.example.com (111.222.333.401)

    I had thought to bring my second server online with
    hostname: server2.example.com (111.222.333.500)
    dns: ns3.example.com (111.222.333.500) and ns4.example.com (111.222.333.501)

    I created the zone file on the both servers for server2.example.com (111.222.333.500) and had the rDNS setup and it all resolves. I was going to do the same for ns3 and ns4 and then setup DNS clustering between the two.

    My first issue appeared when I tried to set the hostname for server2, and I received the error "
    The system cannot set the hostname to a domain owned by a user because all local email would be directed to the “nobody” account."

    So, I take it then that I cannot actually configure the second server before creating an account on it? Does that mean that I must have a unique domain registered just for this? Is my basic concept OK, or should I just treat the second server as a completely unique entity with no real connection to the first?

    I appreciate any thoughts.
     
    #1 verdon, Sep 21, 2017
    Last edited by a moderator: Sep 21, 2017
  2. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    847
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    Should I just remove the zone file for server2.example.com from server2, and then setup the dns cluster?
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,658
    Likes Received:
    1,425
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Are you sure that "server2.example.com" does not exist as a cPanel account on this server? Generally, it's okay if "example.com" exists as an account as long as "server2.example.com" isn't added as a subdomain or addon domain name.

    However, note that setting up DNS clustering between two hosting servers is what's called a WHM-to-WHM two-way sync configuration. This type of configuration is not recommended because it may cause DNS errors on your servers. You can read a full clustering guide at:

    Guide to DNS Cluster Configurations - cPanel Knowledge Base - cPanel Documentation

    Thank you.
     
  4. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    847
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    Hi,

    Yes. Thanks. There are no accounts at all on the 2nd server. The only zone file is the one I manually added (via WHM/Add DNS) for server2.example.com. example.com is the first server. I guess I'm trying to avoid registering unneeded domain.com just for the 2nd server, but am unsure of the best approach.

    Thanks for the link to clustering.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,658
    Likes Received:
    1,425
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Can you open a support ticket using the link in my signature so we can take a closer look? I don't believe that error message should appear if an account for "example.com" does not exist on the server.

    Thank you.
     
  6. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    847
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    Thank you. Support request ID 8886165
     
  7. verdon

    verdon Well-Known Member

    Joined:
    Nov 1, 2003
    Messages:
    847
    Likes Received:
    3
    Trophy Points:
    168
    Location:
    Northern Ontario, Canada
    cPanel Access Level:
    Root Administrator
    In case anyone is watching this, it seems like my initial attempt to add the new zone for server2.example.com using Home > DNS Functions > Add a DNS Zone resulted in an entry into /etc/userdomains and marked the domain as owned by nobody, which lead to the hostname error. It's not clear if that was the expected behaviour, and that is being investigated.

    The fix was to simply delete that DNS zone, then update my hostname to server2.example.com, after which I was prompted to create an A record for the new hostname, which recreated the zonefile, without the entry in /etc/userdomains .. and the server seems happy. I'll know better once all DNS has propagated, and I get an account or two set up.

    I'm guessing at this point, that in regards to the other question about DNS clustering in my initial post, that my thoughts of using server1 and server2 as secondary DNS for each other is not a good idea, and until I know better, I will just use each server for each own's primary and secondary DNS. I suppose the better practice would be to bring a 3rd DNS-only server online sometime, and use it as a secondary DNS for both.
     
    cPanelMichael likes this.
Loading...

Share This Page