Editing DNS records over SSH on cPanel

On a system running cPanel you can edit a domain's DNS records over SSH like this:

  1. Open the domain's zone file (replace domain.com with your own domain):

    nano /var/named/domain.com.db
    
  2. Edit the records, then press Ctrl + X to save and exit.

  3. Restart the DNS service:

    service named restart
    
Was this article helpful?