|
|
A loopback zone is a reverse zone that enables a host to resolve the loopback address (127.0.0.1) to the name localhost. The loopback address is used by the host to enable it to direct network traffic to itself. You can configure a loopback zone manually or you can import it from an existing BIND zone file.
Normally you do not have to configure a loopback zone, because Network Registrar automatically creates one for you. If, however, you accidentally delete the loopback zone, you can use the instructions in this appendix to create a new one.
Before manually configuring a loopback zone, you should create a loopback address file.
A name server needs one additional db.ADDR file to cover the loopback network: the db.l27.0.0 file, which provides a special address that hosts use to direct traffic to themselves. The network is almost always 127.0.0, and the host number is almost always 127.0.0.1.
Here are the contents of the db.l27.0.0 file:
O.O.127.in-addr.arpa. IN SOA terminator.movie.edu. al.robocop.movie.edu. (
1 | ; Serial |
|---|---|
10800 | ; Refresh after 3 hours |
3600 | ; Retry after 1 hour |
604800 | ; Expire after 1 week |
86400 ) | ; Minimum TTL of 1 day |
Name servers need this file because no one has responsibility for network 127, yet systems use it for a loopback address. Since no one has direct responsibility, everyone who uses it is individually responsible for it. You could omit this file and your name server would operate. However, a lookup of 127.0.0.1 might fail because the root name server contacted was not configured to map 127.0.0.1 to a name. Cisco recommends that you provide the mapping yourself.
Step 1 Within the CLI, use the zone create command to create a loopback zone.
The following example adds the zone 127.in-addr.arpa, specifying that it is a primary zone, the name server is localhost, and the hostmaster is loopback.
nrcmd> zone 127.in-addr.arpa.create primary localhost loopback
Step 2 Use the zone command addRR to add the pointer (PTR) resource record.
Although the zone command automatically creates the NS and SOA record for you, you need to use the addRR command to create a PTR record for the name server named in the ns field. The following example adds the name 1.0.0, the type PTR, and the data localhost.
nrcmd> zone 127.in-addr.arpa.addRR 1.0.0 PTR localhost
Step 3 Use the zone command addRR to add the Address (A) resource record.
The A record provides the name-to-address mapping for the zone. The following example adds the name localhost, the type A, and the data 127.0.0.1.
nrcmd> zone 127.in-addr.arpa addRR localhost A 127.0.0.1
Network Registrar automatically appends the zone name to the ns, person, and data fields, that is localhost.127.in-addr.arpa and loopback.127.in-addr.arpa.
The easiest and quickest way to create a primary zone is to import an existing BIND format zone file.
Use the zone command create to create a primary zone by importing an existing file that is in BIND format. The following example adds the zone 127.in-addr.arpa, specifying that it is a primary zone and to import the BIND file, hosts.local.
nrcmd> zone 127.in-addr.arpa create primary file=hosts.local
Step 1 Use the save command to save your changes to Network Registrar's configuration database.
nrcmd> save
Step 2 Use the server command to reload the servers.
nrcmd> server DNS reload
![]()
![]()
![]()
![]()
![]()
![]()
![]()
Posted: Thu Nov 18 13:47:18 PST 1999
Copyright 1989-1999©Cisco Systems Inc.