[GH-ISSUE #1773] Add new nameserver zones, to allow internally on companies, to resolve private dns #761

Closed
opened 2026-03-16 00:09:51 +03:00 by kerem · 3 comments
Owner

Originally created by @miguelgargallo on GitHub (Sep 4, 2022).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/1773

Add new nameserver zones, to allow internally on companies, to resolve private dns

Originally created by @miguelgargallo on GitHub (Sep 4, 2022). Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/1773 Add new nameserver zones, to allow internally on companies, to resolve private dns
kerem closed this issue 2026-03-16 00:09:56 +03:00
Author
Owner

@Lyamc commented on GitHub (Sep 30, 2022):

Are you unable to do so? It should be straight forward:

To add test.example.com --> 192.168.1.200 and example.com --> 192.168.1.2 to the nameserver

Create the zone, add the entries

sudo nano /var/named/example.com.zone

$TTL 3D
@               IN      SOA     ns1.example.com. dns.example.com. (
                                199609203       ; Serial
                                28800           ; Refresh
                                7200            ; Retry
                                604800          ; Expire
                                86400)          ; Minimum TTL
                        NS      example.com.
test                    A       192.168.1.200
@                       A       192.168.1.2

Add the zone to the config

sudo nano /etc/named.toml

[[zones]]
# zone: this is the ORIGIN of the zone, aka the base name, '.' is implied on the end
zone = "example.com"

# zone_type: Primary, Secondary, Hint, Forward
zone_type = "Primary"

# file: this is relative to $directory
file = "example.com.zone"

Apply the new configuration

sudo systemctl restart named

<!-- gh-comment-id:1262974917 --> @Lyamc commented on GitHub (Sep 30, 2022): Are you unable to do so? It should be straight forward: To add `test.example.com` --> `192.168.1.200` and `example.com` --> `192.168.1.2` to the nameserver # Create the zone, add the entries `sudo nano /var/named/example.com.zone` ``` $TTL 3D @ IN SOA ns1.example.com. dns.example.com. ( 199609203 ; Serial 28800 ; Refresh 7200 ; Retry 604800 ; Expire 86400) ; Minimum TTL NS example.com. test A 192.168.1.200 @ A 192.168.1.2 ``` # Add the zone to the config `sudo nano /etc/named.toml` ``` [[zones]] # zone: this is the ORIGIN of the zone, aka the base name, '.' is implied on the end zone = "example.com" # zone_type: Primary, Secondary, Hint, Forward zone_type = "Primary" # file: this is relative to $directory file = "example.com.zone" ``` # Apply the new configuration `sudo systemctl restart named`
Author
Owner

@miguelgargallo commented on GitHub (Oct 1, 2022):

Let me check on that!

<!-- gh-comment-id:1264414108 --> @miguelgargallo commented on GitHub (Oct 1, 2022): Let me check on that!
Author
Owner

@miguelgargallo commented on GitHub (Dec 28, 2022):

Thanks for you time, and Merry Christmas 🎄

<!-- gh-comment-id:1366961365 --> @miguelgargallo commented on GitHub (Dec 28, 2022): Thanks for you time, and Merry Christmas 🎄
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#761
No description provided.