TechnitiumSoftware/DnsServer · warning · InvalidDataException

HistoryRecordInfo format version not supported.

Error message

HistoryRecordInfo format version not supported.

What it means

Thrown by HistoryRecordInfo.ReadRecordInfoFrom when the version byte read from a history (deleted-record) entry is not 1. HistoryRecordInfo stores only the deletion timestamp; version 1 is the sole supported writer format. The default branch rejects any other version so a corrupt or incompatible history file fails fast instead of producing wrong deletion times.

Source

Thrown at DnsServerCore/Dns/ResourceRecords/HistoryRecordInfo.cs:66

        {
            return new HistoryRecordInfo(bR);
        }

        #endregion

        #region protected

        protected override void ReadRecordInfoFrom(BinaryReader bR)
        {
            byte version = bR.ReadByte();
            switch (version)
            {
                case 1:
                    _deletedOn = bR.BaseStream.ReadDateTime();
                    break;

                default:
                    throw new InvalidDataException("HistoryRecordInfo format version not supported.");
            }
        }

        protected override void WriteRecordInfoTo(BinaryWriter bW)
        {
            bW.Write((byte)1); //version

            bW.BaseStream.WriteDateTime(_deletedOn);
        }

        #endregion

        #region properties

        public DateTime DeletedOn
        {
            get { return _deletedOn; }
            set { _deletedOn = value; }

View on GitHub (pinned to d0484b6c1e)

Solutions

  1. Clear the zone's history store (the deleted-records history) so new entries are written in the current format.
  2. Restore history from a backup produced by a compatible build, or accept history loss for the affected zone.
  3. Upgrade to the build that wrote the history file if you need to preserve it before downgrading.
Defensive patterns

Strategy: fallback

Try / catch

// History is non-critical; on format error, skip the entry.
try { entry = new HistoryRecordInfo(bR); }
catch (InvalidDataException ex) when (ex.Message == "HistoryRecordInfo format version not supported.")
{ entry = null; }

Prevention

When it happens

Trigger: Deserializing a zone history entry whose version byte is not 1, e.g. from a newer server's history file, a truncated file, or a corrupted history store. Triggered when the zone history view is loaded.

Common situations: Server downgrade after a HistoryRecordInfo format change; history file corruption after a crash; restoring a history backup from an incompatible build.

Related errors


AI-assisted analysis of TechnitiumSoftware/DnsServer@d0484b6c1e (2026-08-13). Data as JSON: /api/errors/ee6a359b78770aac. Report an issue: GitHub.