In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
How to configure RHEL5 DNS, I believe that many inexperienced people do not know what to do, so this paper summarizes the causes of the problem and solutions, through this article I hope you can solve this problem.
RHEL5 is added on the basis of RHEL4. The same improvement of the system also allows more people to apply RHEL5, so this requires RHEL5 to be more powerful in configuration, mainly RHEL5 DNS configuration in service configuration, so here is a detailed introduction to the configuration of DNS in RHEL5:
1.RHEL5 DNS configuration installation
After installation, you will find that the named.conf file cannot be found under / etc/, so create it manually! Note that it is not created in the etc directory
Echo > / var/named/chroot/var/etc/named.conf
Vi named.conf
Edit content:
Options
{
Directory "/ var/named"
}
Zone "."
{
Type hint
File "named.ca"
}
Save and exit!
You can see here that the content is very simple, much less than the named.conf under AS4. Options is used to describe global properties, in which directory is set, and a zone is added to the working directory of the specified server. "." Analysis file named.ca pointing to a root domain to generate a named.ca file, you can first configure an available DNS
2. RHEL5 DNS configuration creation content
Create a resolv.conf DNS parsing file with only nameserver 127.0.0.1
Echo "nameserver 127.0.0.1" > / etc/resolv.conf
Then use instructions to create named.ca
Dig-t NS. > / var/named/chroot/var/named/named.ca
Start the domain name service
Service named start
3.RHEL5 DNS configuration edit file
At this point, we can edit the above resolv.conf file and add other dns to it, such as:
Vi / etc/resolv.conf
Nameserver 127.0.0.1
Nameserver 202.103.24.68
Save and exit!
You can use host www.163.com to test whether it can be parsed
4.RHEL5 DNS configuration completes file editing
Next, let's continue to finish the named.conf file.
The editing content is as follows:
Vi named.conf
Options
{
Directory "/ var/named"
}
Zone "."
{
Type hint
File "named.ca"
}
Zone "xxx.com"
{
Type master
File "xxx.com.zone"
}
Zone "1.168.192.in-addr.arpa"
{
Type master
File "192.168.1.rev"
}
Save and exit!
Now that you have finished editing, you can see that you have added your own domain name and added positive and negative resolution!
5.RHEL5 DNS configuration add the appropriate file
Add the corresponding parsing file
/ var/named/chroot/var/named/xxx.com.zone and / var/named/chroot/var/named/192.168.1.rev
And edit the file:
Vi xxx.com.zone
@ IN SOA rhel5.com. Root (
20060801
1H
15M
1W
1D)
IN NS ns
IN MX 10 mail
Ns IN A 192.168.1.159
Www IN A 192.168.1.159
Mail IN A 192.168.1.159
Save and exit!
Vi 192.168.1.rev
@ IN SOA rhel5.com. Root (
20060801
1H
15M
1W
1D)
IN NS ns.xxx.com.
159 IN PTR ns.xxx.com.
159 IN PTR www.xxx.com.
159 IN PTR mail.xxx.com.
Save and exit!
Note: be sure to use Tab alignment!
Now that the configuration is complete, restart the named service:
Service named restart
Now let's test it:
[root@rhel5 /] # nslookup www.xxx.com
Server: 127.0.0.1
Address: 127.0.0.1#53
Name: www.xxx.com
Address: 192.168.1.159
[root@rhel5 /] # nslookup mail.xxx.com
Server: 127.0.0.1
Address: 127.0.0.1#53
Name: mail.xxx.com
Address: 192.168.1.159
You can see that it can be parsed successfully!
RHEL5 DNS is a little more troublesome than RHEL4 DNS, even if you choose the DNS service when you install the system, you should install the RPM package of bind after entering the system normally, and then install the RPM package of caching-nameserver. The system will install the bind.util package by default, so that the package used by the DNS service will be fully installed.
After reading the above, have you mastered how to configure RHEL5 DNS? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.