Bind Converting Zone Files Between Text and Raw Formats

Bind9

With the development of the BIND 9.9 branch, zone file storage for slaved zones has been changed to expect the raw zone format by default in order to provide some performance boost. This article mentions about converting the ext file to raw format and vice versa.

Topic

  • How to convert bind raw zone data file to text format?
  • How to convert bind text zone data file to raw format?

apt

  • Linux

Solution


Rename and Re-transfer

A BIND 9.9 slave server which encounters a zone file it cannot read, rename or delete those files. Refer to the following article configure slave zone data to be written in text format.

https://www.tekfik.com/kb/linux/bind/bind-slave-zone-text-format

Manual Conversion

The named-compilezone utility, which is part of the BIND distribution, can be used to convert zones from text to raw and from raw to text.

Example
convert raw zone file "example.com.raw", containing data for zone example.com, to text-format zone file "example.com.text"

named-compilezone -f raw -F text -o example.com.text example.com example.com.raw

convert text format zone file "example.com.text", containing data for zone example.com, to raw zone file "example.com.raw"

named-compilezone -f text -F raw -o example.com.raw example.com example.com.text

You May Also Like

avatar

About the Author: TekFik

TekFik is a technical blogging site helps techies and engineers to solve their day to day issues and also allows everyone to share knowledge and feedback. Please feel free to contact us at tekfik.rd@gmail.com if there is anything.

Leave a Reply

Your email address will not be published. Required fields are marked *