2 Installation and Usage
kashifpk edited this page 2011-05-30 14:05:12 -07:00

Requirements for DNS-NG are:

python python-qt4 twisted-python sqlalchemy

Once you download or pull the source from github, you need to follow following steps to complete the installation.

  1. Unzip the code into a folder. Install python and python setuptools if not already present. Install twisted and sqlalchemy using easy_install. For example:

        easy_install sqlalchemy
        easy_install twisted
    
  2. Install apropriate database driver for python if not present. For example, if you want to use MySQL as the backend db, you need to install the mysql-python package.

        easy_install mysql-python
    
  3. Edit the config.py file to update your database type and access credentials

  4. Create tables in the database using:

        python DNS_NG.py --setup_db
    
  5. Now you can run the DNS server using either

        python DNS_NG.py
    
                 _or _
    
        python DNS_NG.py --daemon (For running as a daemon/service)
    
  6. To run the Qt4 User Interface, run

         python DNS_UI.py
    

The DNS server allows you to redirect any domain/subdomain to an ip address of your liking. All redirect ruls and incoming DNS requests are logged into the backend DB. Redirection rules can also be applied to specific clients and specific DNS query types like A requests.