{"record":{"id":"a067055ea1610ca4","repo":"TechnitiumSoftware/DnsServer","slug":"the-notify-option-is-invalid-for-0-zones-1","errorCode":null,"errorMessage":"The Notify option is invalid for {0} zones: {1}","messagePattern":"The Notify option is invalid for (.+?) zones: (.+?)","errorType":"validation","errorClass":"ArgumentException","httpStatus":null,"severity":"error","filePath":"DnsServerCore/Dns/Zones/ForwarderZone.cs","lineNumber":341,"sourceCode":"                    case AuthZoneTransfer.AllowOnlyZoneNameServers:\n                    case AuthZoneTransfer.AllowZoneNameServersAndUseSpecifiedNetworkACL:\n                        throw new ArgumentException(\"The Zone Transfer option is invalid for \" + GetZoneTypeName() + \" zones: \" + value.ToString(), nameof(ZoneTransfer));\n                }\n\n                base.ZoneTransfer = value;\n            }\n        }\n\n        public override AuthZoneNotify Notify\n        {\n            get { return base.Notify; }\n            set\n            {\n                switch (value)\n                {\n                    case AuthZoneNotify.ZoneNameServers:\n                    case AuthZoneNotify.BothZoneAndSpecifiedNameServers:\n                        throw new ArgumentException(\"The Notify option is invalid for \" + GetZoneTypeName() + \" zones: \" + value.ToString(), nameof(Notify));\n\n                    case AuthZoneNotify.SeparateNameServersForCatalogAndMemberZones:\n                        if (this is CatalogZone)\n                            break;\n\n                        throw new ArgumentException(\"The Notify option is invalid for \" + GetZoneTypeName() + \" zones: \" + value.ToString(), nameof(Notify));\n                }\n\n                base.Notify = value;\n            }\n        }\n\n        public override AuthZoneUpdate Update\n        {\n            get { return base.Update; }\n            set\n            {\n                switch (value)","sourceCodeStart":323,"sourceCodeEnd":359,"githubUrl":"https://github.com/TechnitiumSoftware/DnsServer/blob/d0484b6c1e7439cdc53d67d81e9c876cda2ad756/DnsServerCore/Dns/Zones/ForwarderZone.cs#L323-L359","documentation":"Thrown by the ForwarderZone.Notify setter when value is AuthZoneNotify.ZoneNameServers (1) or AuthZoneNotify.BothZoneAndSpecifiedNameServers (3). These NOTIFY modes push change notifications to the zone's authoritative name servers (its NS records), but a Conditional Forwarder is non-authoritative and has no NS set, so there is nothing to notify. Valid notify options for a forwarder zone are None(0), SpecifiedNameServers(2), and (only for CatalogZone) SeparateNameServersForCatalogAndMemberZones(4). ArgumentException names 'Notify'.","triggerScenarios":"Assigning zone.Notify = AuthZoneNotify.ZoneNameServers or AuthZoneNotify.BothZoneAndSpecifiedNameServers on a ForwarderZone via the zone settings API or a config batch.","commonSituations":"Defaulting Notify to 'BothZoneAndSpecifiedNameServers' across all zones during provisioning; copying notify settings from a primary zone; UI not filtering notify options by zone type.","solutions":["For a ForwarderZone use Notify = None, SpecifiedNameServers, or (if catalog) SeparateNameServersForCatalogAndMemberZones.","When you need to notify explicit secondaries only, configure them as SpecifiedNameServers.","Drive the available Notify enum values from the zone type in your settings UI."],"exampleFix":"// before\nzone.Notify = AuthZoneNotify.BothZoneAndSpecifiedNameServers;\n\n// after\nzone.Notify = AuthZoneNotify.SpecifiedNameServers; // forwarder: notify only the list you provide","handlingStrategy":"type-guard","validationCode":"var valid = new[] { AuthZoneNotify.None, AuthZoneNotify.SpecifiedNameServers };\nif (zone is CatalogZone) valid = valid.Append(AuthZoneNotify.SeparateNameServersForCatalogAndMemberZones).ToArray();\nif (!valid.Contains(value)) throw new ArgumentException($\"Notify {value} not valid for this zone.\");\nzone.Notify = value;","typeGuard":"static bool IsValidForwarderNotify(AuthZoneNotify v, Zone z) => v == AuthZoneNotify.None || v == AuthZoneNotify.SpecifiedNameServers || (v == AuthZoneNotify.SeparateNameServersForCatalogAndMemberZones && z is CatalogZone);","tryCatchPattern":"try { zone.Notify = value; }\ncatch (ArgumentException) { zone.Notify = AuthZoneNotify.SpecifiedNameServers; }","preventionTips":["For a plain ForwarderZone, Notify may only be None or SpecifiedNameServers.","Reserve the name-server-based Notify modes for authoritative zones that have NS records.","Gate the catalog/member mode behind an 'is CatalogZone' check in the UI."],"tags":["dns","forwarder-zone","notify","argumentexception"],"backgroundTag":null,"analyzedSha":"d0484b6c1e7439cdc53d67d81e9c876cda2ad756","analyzedAt":"2026-08-13T22:57:35.508Z","schemaVersion":2},"datasetVersion":"2026-08-14T00:17:13.853Z"}