Installing tinydns on centos 5.5

Source: Internet
Author: User

Requirements of tinydns

Copied with permission from the author. Original site is at http://www.djbdnsrocks.org

1) At least 2 unused IP addresses. 1 is usually fine.
2) daemontools-this was installed if you did my Qmail install. If not, please install that step!
3) UCSPI-TCP-this was also installed if you did my Qmail install. If not, please install that step too!
4) You will want ports 22 (SSH) and 53 (DNS) open. If you don't want
Anyone outside of your network using your DNS server (personally, I
Don't pass this port either) Don't forward port 53.

That is about it. When all those requirements have been met, you can now continue.

Installing tinydns

The first step is to install the daemon-tools:

 

# Cd/OPT

# Wget http://cr.yp.to/daemontools/daemontools-0.76.tar.gz

# Gunzip daemontools-0.76.tar

# Tar-xpf daemontools-0.76.tar

# Rm-F daemontools-0.76.tar

# Cd admin/daemontools-0.76

# Vi src/conf-CC

Append the following line at the end of the GCC line:-include/usr/include/errno. h

 

#./Package/install


One other package we need to prepare for djbdns to be functional is ucspi:

# Cd/OPT

# Wget http://cr.yp.to/ucspi-tcp/ucspi-tcp-0.88.tar.gz

# Gunzip ucspi-tcp-0.88.tar

# Tar-XF ucspi-tcp-0.88.tar

# Cd ucspi-tcp-0.88

# Vi src/conf-CC


Append the following line at the end of the GCC line:-include/usr/include/errno. h

# Make

# Make setup check

 

The next step is the document publication:

# Cd/OPT

# Wget http://cr.yp.to/djbdns/doc.tar.gz

Next we will unzip docs under/doc
:

# Gunzip <doc.tar.gz | (CD/; tar-xf -)

 

Use the following script to merge in system docs:

#! /Bin/sh

For I in packages commands cfunctions fileformats

Do

Sort-F/dev/null 'Find/doc/merge-name polici.html '>/doc/$ I. New

MV/doc/$ I. New/doc/$ I .html

Done

 

Save script into a file: script. Sh

# Chmod + x script. Sh

#./Script. Sh

 

# Cd/OPT

# Wget http://cr.yp.to/djbdns/djbdns-1.05.tar.gz

# Gunzip djbdns-1.05.tar

# Tar-XF djbdns-1.05.tar

# Cd djbdns-1.05

# Vi src/conf-CC

Append the following line at the end of the GCC line:-include/usr/include/errno. h

# Make

# Make setup check

 

All compiling gets done.

The next step is the DNS server configuration.

 

Using ing tinydns


We need two system user accounts:

# Groupadd-G 200 nofiles
# Useradd-G nofiles-u 201-D/var/Dnscache-c "tinydns"-S/sbin/nologin tinydns
# Useradd-G nofiles-u 202-D/var/Dnscache-c "tinydns"-S/sbin/nologin tinylog

# Tinydns-conf tinydns tinylog/var/tinydns <listened ip>

 

Starting tinydns


Now start the service with the following command:
# Ln-SF/var/tinydns/service

 

You can verify it is running by typing:
# Svstat/service/tinydns

 

Using ing tinydns


Once again, we need two system user accounts:

# Useradd-G nofiles-u 203-D/var/Dnscache-c "axfrdns"-S/sbin/nologin axfrdns
# Useradd-G nofiles-u 204-D/var/Dnscache-c "axfrdns"-S/sbin/nologin axfrlog
# Axfrdns-conf axfrdns axfrlog/var/axfrdns/var/tinydns <listened ip>

Starting axfrdns

Now start the service with the following command:

# Ln-SF/var/axfrdns/service

You can verify it is running by typing:
# Svstat/service/axfrdns

 

Stop tinydns & axfrdns

SVC-D/service/tinydns

SVC-D/service/axfrdns

 

Start tinydns & axfrdns

SVC-U/service/tinydns

SVC-U/service/axfrdns

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.