# SMBind-ng Installation Guide v0.91c ## Requirements * Any kind of webserver with php usage abilities (tested on apache2, lighttpd, nginx) * php interpreter (5.3 or greater - tested on 5.3) * php modules * one of mysql, pgsql * mdb2 * mdb2 sql drivers (tested on mysql) * cgi * smarty (version 2 or newer - tested on v2 and v3) * bind (9.3 or newer for dnssec abilities) * dnssec-tools (optional for securing dns zones) * acl (optional for securing dns zones) * SQL server (tested on MySQL) ## Installation ### Bind Set up your bind, and configure it to access other masters and enable zone transfer for its slaves. ### SMBind-ng PHP code Unpack contents to somewhere on your server (eg. /var/www/html/smbind-ng) and setup your virtual server to access by default the *index.php*. Create the following directories beside the *index.php* and make it writable by current webserver user: *tmp* *templates_c* All other directories and files can be write protected. ### Configuration directories and files 1. Create a subdirectory with full permission to user of your webserver for keeping your zones. You need to make it readable for bind. eg. */etc/smbind-ng* Recommended solution: owner of directory let the root user and bind group, webserver user let the member of the bind group, and the directory let writable by owned group. 2. Create a file with same permissions in this directory for saving zone definitions - eg. *touch smbind-ng.conf.* 3. Create a subdirectory for keeping zone files with write permissions by www-data and bind group. ### Modify bind configuration On your bind options set this folder to use with *directory* option and *managed-keys* option (folder created at the step 3 above). Include the master configuration files into your bind config - what created at the step 2. Restart your bind daemon. #### *Under bind9.9 or later only* You need to add your options the *masterfile-format text;* line, because these versions keep the zone files as binary format, and you couldn't preview the slave zones as human readable. Restart your bind daemon ### Database Create a database user with full permission to access a non existing database with any name. Log in your database server with that user, and create an empty database. Take the initial database dump, and load it to this schema with this newly created user. *mysql.sql* is for MySQL, *pgsql.sql* is for PostrgeSQL eg. for MySQL: *mysql -h yourserver -u youruser -pYourP@ssW0rd yourdb