Deleted your rndc.key file? No worries here’s how to recover/rebuild it

Apr 22nd, 2012 | By | Category: Internet, Linux / Freebsd

Well had a brain fart today and my rndc.key file went out the window.. Not too fun as it shut down my entire DNS and a ton of domains..  So I had ot scramble to figure out how to get it back adn so i did..

Actually what I deleted was my rndc.key file but I dont even know why that was there in the first place as I’ve changed the setup now to have it all in the named.conf file with a reference to an rndc.conf file.. same deal just different filenames.

Anyawys, firstly go into your named.conf file and remove an include calls to rndc.key as we are getting rid of that

Next run this as root rndc-confgen.  It will spit out a bunch of text.. some you need to copy to a rdnc.conf file and the other stuff to your named.conf file


Problem solved, enjoy your nameserver again

Tags: , , , , , , ,

Leave a Comment