INSTALL.html 39 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
  2. "http://www.w3.org/TR/html4/loose.dtd">
  3. <html>
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  6. <title>
  7. GnuDIP Release 2.3.5 - INSTALL File
  8. </title>
  9. <base target="_blank">
  10. </head>
  11. <body bgcolor=white>
  12. <table><tr valign=middle><td>
  13. <img align=middle src="gnudip/html/gnudip.jpg" alt="GnuDIP Logo" border=0 height=60 width=113>
  14. </td><td>
  15. <h1>GnuDIP Release 2.3.5 - INSTALL File</h1>
  16. </table>
  17. <hr>
  18. <h3>Preliminary Steps</h3>
  19. <ol>
  20. <li>
  21. Become familiar with the set of low privilege UNIX user IDs used for running
  22. daemons on your system.
  23. <p>
  24. Many UNIX systems use a very simple system. There is a user ID named
  25. <code>nobody</code>. The <code>nobody</code> user ID cannot be logged in to.
  26. It can only be reached through the "<code>root</code>" user ID. It also has
  27. its own group. A process running under this ID will only be able to read files
  28. that are "world readable", and only able to modify or delete files that are
  29. "world writable".
  30. <p>
  31. Within this set up it is common practice to run the BIND
  32. <code>named</code> daemon as user <code>nobody</code>. Also, the sample
  33. configuration file that comes with the Apache web server source will run all
  34. CGI scripts as user <code>nobody</code>.
  35. <p>
  36. Some systems (apparently Red Hat does this) have several "<code>nobody</code>"
  37. user ID-s. Each daemon that can be run as a low privilege user gets its own
  38. user ID.
  39. <p>
  40. In these instructions, we assume that there is a single <code>nobody</code>
  41. user ID. When we refer to the <code>nobody</code> user ID, the reader should
  42. substitute the appropriate user ID for the daemon being discussed.
  43. <p><li>
  44. Move the directory <a href="gnudip/"><code>gnudip</code></a>
  45. to <code>/usr/local</code> (or <code>/opt</code>, or wherever you wish -
  46. we will assume <code>/usr/local</code> in what follows).
  47. If you copy this directory instead,
  48. be careful that the file ownerships of the files in
  49. the <a href="gnudip/etc/"><code>gnudip/etc/</code></a>
  50. directory do not change.
  51. </ol>
  52. <h3>The "MiniDIP" Alternative</h3>
  53. <blockquote>
  54. This package includes a bare bones version of GnuDIP with no database
  55. or web tool. There is a <u>single configuration file</u>, which includes the list
  56. of host names and their passwords.
  57. <p>
  58. The <a href="gnudip/sbin/minidip.pl"><code>minidip.pl</code></a>
  59. Perl script is a <code>(X)INETD</code> daemon address update server program.
  60. The <a href="gnudip/lib/miniupdt.pm"><code>miniupdt.pm</code></a>
  61. Perl script is a CGI address update server program.
  62. They use <a href="gnudip/etc/minidip.conf"><code>minidip.conf</code></a>
  63. in the GnuDIP configuration directory as the configuration file.
  64. The <code>(X)INETD</code> daemon allow the name of the configuration file
  65. to be overridden using command argument.
  66. <p>
  67. The <code>BIND</code> setup (this option does not support "back ends"
  68. - see below) is the same as for the full GnuDIP software.
  69. <p>
  70. The <code>(X)INETD</code> daemon setup is the same as for the
  71. standard GnuDIP <code>(X)INETD</code> daemon.
  72. <p>
  73. The CGI setup is also the same as for the standard GnuDIP CGI, if it is
  74. acceptable to have "<code>/gnudip/cgi-bin/miniupdt.cgi</code>"
  75. as the URL for the CGI. Otherwise you will need to use "<code>ScriptAlias</code>"
  76. definitions to suit your needs.
  77. <p>
  78. Combining
  79. <a href="gnudip/sbin/minidip.pl"><code>minidip.pl</code></a>
  80. and
  81. <a href="gnudip/lib/miniupdt.pm"><code>miniupdt.pm</code></a>
  82. with the
  83. <a href="gnudip/sbin/multinsupd.pl"><code>multinsupd.pl</code></a>
  84. script discussed below in "Linking Non-GnuDIP Host Names to a GnuDIP Host Name"
  85. can provide a great deal of functionality.
  86. </blockquote>
  87. <h3>Upgrading an Existing MySQL Database</h3>
  88. <ol>
  89. <li>
  90. If you have an existing GnuDIP MySQL database, upgrade this GnuDIP database. Note that
  91. there have been no database changes since release 2.3.0.
  92. <p>
  93. Start the MySQL client using:
  94. <pre>
  95. # mysql -p
  96. </pre>
  97. Follow the contents of
  98. <a href="upgrade.mysql"><code>upgrade.mysql</code></a> to do the <u>first part</u> the
  99. upgrade.
  100. <p>
  101. Or you can read and edit the contents of <code>upgrade.mysql</code>, setting the
  102. MySQL database name, and then use:
  103. <pre>
  104. # mysql -fvp < upgrade.mysql
  105. </pre>
  106. <p>
  107. The <code>upgrade.mysql</code> file is designed to upgrade from either
  108. either release 2.1.2 or release 2.2.x when used in this "automatic" way.
  109. In the latter case however, <u>some error messages</u> may be produced.
  110. <p>
  111. Scan the GnuDIP database and generate the statements to complete the database
  112. upgrade using:
  113. <pre>
  114. # <a href="gnudip/sbin/gdipdbcnv.pl">/usr/local/gnudip/sbin/gdipdbcnv.pl</a> database localhost user password > myupgrade.mysql
  115. </pre>
  116. The arguments are the MySQL database name, the server running MySQL, and the
  117. user name and password to connect to MySQL with, respectively. Read and understand the
  118. file that <code>gdipdbcnv.pl</code> produced:
  119. <ul>
  120. <li>
  121. There will be statements to delete and recreate the contents of the
  122. <code>globalprefs</code> table.
  123. <p><li>
  124. If you used
  125. <code>DOMAIN_TYPE='GLOBAL'</code> in Release 2.1.2
  126. (which is no longer an option - see
  127. <a href="release.html">
  128. <code>release.html</code></a>), then the value of the <code>domain</code>
  129. column will be the empty string for each row of the <code>users</code> table. The statements
  130. generated by <code>gdipdbcnv.pl</code> will replace each such row with several replacement
  131. rows - one for each domain.
  132. </ul>
  133. <p>
  134. When you have examined these MySQL statements, run them using:
  135. <pre>
  136. # mysql -p < myupgrade.mysql
  137. </pre>
  138. </ol>
  139. <h3>New Database Set Up</h3>
  140. <ol>
  141. <li>
  142. If you have no existing GnuDIP database and <b>wish to use MySQL</b>, create a new
  143. GnuDIP MySQL database.
  144. <p>
  145. Start the MySQL client using:
  146. <pre>
  147. # mysql -p
  148. </pre>
  149. Follow the contents of
  150. <a href="gnudip.mysql"><code>gnudip.mysql</code></a> to define the MySQL database and user.
  151. <p>
  152. Or you can read and edit the contents of <code>gnudip.mysql</code> setting the
  153. MySQL database name, and the user name and password to connect to MySQL with,
  154. and then use:
  155. <pre>
  156. # mysql -vp < gnudip.mysql
  157. </pre>
  158. <p><li>
  159. If you have no existing GnuDIP database and <b>wish to use the Linux/UNIX file system</b>,
  160. create a new GnuDIP "flat file" database.
  161. <p>
  162. Delete the two UNIX symbolic links
  163. <code>/usr/local/gnudip/lib/dbprefs.pm</code> and
  164. <code>/usr/local/gnudip/lib/dbusers.pm</code>.
  165. By default these point to
  166. <code>/usr/local/gnudip/lib/dbprefs_mysql.pm</code> and
  167. <code>/usr/local/gnudip/lib/dbusers_mysql.pm</code>, respectively,
  168. which contain the code to handle MySQL.
  169. <p>
  170. Recreate these links using:
  171. <pre>
  172. # ln -s dbprefs_flat.pm /usr/local/gnudip/lib/dbprefs.pm
  173. # ln -s dbusers_flat.pm /usr/local/gnudip/lib/dbusers.pm
  174. </pre>
  175. <p>
  176. By default, <code>dbprefs_flat.pm</code> uses a file named
  177. <code>/usr/local/gnudip/run/database/globalprefs</code>,
  178. and <code>dbusers_flat.pm</code> uses a directory named
  179. <code>/usr/local/gnudip/run/database/users</code>.
  180. <p>
  181. The directories
  182. <code>/usr/local/gnudip/run/database</code> and
  183. <code>/usr/local/gnudip/run/database/users</code>
  184. are already set up.
  185. These directories must be readable and writable only by the owner and owned
  186. by user "<code>nobody</code>" (the "<code>nobody</code>" that Apache will
  187. run the GnuDIP CGI script as - see step one above). The processes that create
  188. and update files in these directories will be running as that user.
  189. <p>
  190. These names can be changed in
  191. <a href="gnudip/etc/gnudip.conf"><code>/usr/local/gnudip/etc/gnudip.conf</code></a>.
  192. <p><li>
  193. If you have no existing GnuDIP database and <b>wish to use PostgreSQL</b>,
  194. create a new GnuDIP PostgreSQL database.
  195. <p>
  196. Delete the three UNIX symbolic links
  197. <code>/usr/local/gnudip/lib/dbcxore.pm</code>,
  198. <code>/usr/local/gnudip/lib/dbprefs.pm</code> and
  199. <code>/usr/local/gnudip/lib/dbusers.pm</code>.
  200. By default these point to
  201. <code>/usr/local/gnudip/lib/dbcore_mysql.pm</code>,
  202. <code>/usr/local/gnudip/lib/dbprefs_mysql.pm</code> and
  203. <code>/usr/local/gnudip/lib/dbusers_mysql.pm</code>, respectively,
  204. which contain the code to handle MySQL.
  205. <p>
  206. Recreate these links using:
  207. <pre>
  208. # ln -s dbcore_pgsql.pm /usr/local/gnudip/lib/dbcore.pm
  209. # ln -s dbprefs_pgsql.pm /usr/local/gnudip/lib/dbprefs.pm
  210. # ln -s dbusers_pgsql.pm /usr/local/gnudip/lib/dbusers.pm
  211. </pre>
  212. <p>
  213. Start the PostgreSQL client using:
  214. <pre>
  215. # psql -U postgres template1
  216. </pre>
  217. Follow the contents of
  218. <a href="gnudip.pgsql"><code>gnudip.pgsql</code></a> to define the PostgreSQL database
  219. and user.
  220. <p>
  221. Or you can read and edit the contents of <code>gnudip.pgsql</code> setting the
  222. PostgreSQL database name, and the user name and password to connect to PostgreSQL with,
  223. and then use:
  224. <pre>
  225. # psql -U postgres template1 -f gnudip.pgsql
  226. </pre>
  227. <p><li>
  228. You may change from one type of GnuDIP database to another by using the scripts
  229. <a href="gnudip/sbin/gdipunld.pl"><code>gnudip/sbin/gdipunld.pl</code></a>
  230. and
  231. <a href="gnudip/sbin/gdipreld.pl"><code>gnudip/sbin/gdipreld.pl</code></a>
  232. to dump and restore your <u>user</u> database:
  233. <pre>
  234. # gdipunld.pl -h
  235. usage: gdipunld.pl [ -h | [ [-o | -a] outfile ] ]
  236. usage: Dumps the users table to a flat file.
  237. usage: -h: Print this usage message.
  238. usage: -o: Specify file to write output to.
  239. usage: -a: Specify file to append output to.
  240. # gdipreld.pl -h
  241. usage: gdipreld.pl [ -h | [ -i infile ] ]
  242. usage: Loads the users table from a flat file.
  243. usage: -h: Print this usage message.
  244. usage: -i: Specify file to read from.
  245. </pre>
  246. <p>
  247. You will have to re-enter system settings and domains by hand.
  248. </ol>
  249. <h3>DNS Server Set Up</h3>
  250. <ol>
  251. <li>
  252. If you are using a legacy version of BIND that cannot be updated using
  253. the dynamic DNS protocol by <code>nsupdate</code>, or
  254. <a href="http://tinydns.org/">tinydns</a>,
  255. you must set up the GnuDIP "back end" scripts. This is
  256. discussed in <a href="BACKEND.html">BACKEND.html</a>.
  257. <p><li>
  258. <p>
  259. Otherwise choose a zone or zones, and get BIND setup for dynamic updates
  260. for these zones.
  261. <p>
  262. The description provided in the next four steps shows one way to achieve
  263. this for one zone and key. For other configuration options please read
  264. the BIND 8 or BIND 9 documentation.
  265. <p><li>
  266. <p>
  267. Generate the key files required by the <code>nsupdate</code> command.
  268. This will at the same time generate a "TSIG key" which you will later
  269. have to use in configuring the <code>named</code> daemon.
  270. <p>
  271. For BIND 8 use "<code>dnskeygen</code>" to generate key files.
  272. This goes something like this sample:
  273. <blockquote>
  274. <pre>
  275. # dnskeygen -H 128 -h -n gnudip-key
  276. ** Adding dot to the name to make it fully qualified domain name**
  277. Generating 128 bit HMAC-MD5 Key for gnudip-key.
  278. Generated 128 bit Key for gnudip-key. id=0 alg=157 flags=513
  279. # ls
  280. Kgnudip-key.+157+00000.key Kgnudip-key.+157+00000.private
  281. # cat Kgnudip-key.+157+00000.private
  282. Private-key-format: v1.2
  283. Algorithm: 157 (HMAC)
  284. Key: fegHlhVt3opPIiK8V4cjLw==
  285. # cat Kgnudip-key.+157+00000.key
  286. gnudip-key. IN KEY 513 3 157 fegHlhVt3opPIiK8V4cjLw==
  287. </pre>
  288. </blockquote>
  289. <p>
  290. For BIND 9 use "<code>dnssec-keygen</code>" to generate key files.
  291. This goes something like this sample:
  292. <blockquote>
  293. <pre>
  294. # dnssec-keygen -a hmac-md5 -b 128 -n HOST gnudip-key
  295. Kgnudip-key.+157+36000
  296. # ls
  297. Kgnudip-key.+157+36000.key Kgnudip-key.+157+36000.private
  298. # cat Kgnudip-key.+157+36000.private
  299. Private-key-format: v1.2
  300. Algorithm: 157 (HMAC)
  301. Key: fegHlhVt3opPIiK8V4cjLw==
  302. # cat Kgnudip-key.+157+36000.key
  303. gnudip-key. IN KEY 513 3 157 fegHlhVt3opPIiK8V4cjLw==
  304. </pre>
  305. </blockquote>
  306. <p>
  307. For both Bind 8 and 9, examine the files that were generated to
  308. determine the key that was generated. In the examples above this
  309. key is:
  310. <blockquote><pre>
  311. fegHlhVt3opPIiK8V4cjLw==
  312. </pre></blockquote>
  313. You will <u>use this key later to configure your BIND <code>named</code>
  314. daemon</u>, to control dynamic update access to the GnuDIP dynamic zone.
  315. <p>
  316. Move the key files generated to
  317. <a href="gnudip/etc/"><code>/usr/local/gnudip/etc/</code></a>.
  318. Remove the samples that are already there.
  319. These files should not be writable by anyone.
  320. These files should be readable only by the owner and owned
  321. by user "<code>nobody</code>" (the "<code>nobody</code>" that Apache will
  322. run the GnuDIP CGI script as - see step one above). The <code>nsupdate</code>
  323. command which will read these files will be running as that user.
  324. <p><li>
  325. <p>
  326. Update the definition of the "<code>nsupdate</code>" parameter in the
  327. <a href="gnudip/etc/gnudip.conf"><code>/usr/local/gnudip/etc/gnudip.conf</code></a>
  328. file.
  329. <p>
  330. For BIND 8 follow this sample:
  331. <blockquote>
  332. <pre>
  333. # BIND nsupdate command
  334. nsupdate = /usr/bin/nsupdate -v -k /usr/local/gnudip/etc:gnudip-key.
  335. </pre>
  336. </blockquote>
  337. Note that the trailing period ("<code>.</code>") is required.
  338. <p>
  339. For BIND 9 follow this sample:
  340. <blockquote>
  341. <pre>
  342. # BIND nsupdate command
  343. nsupdate = /usr/bin/nsupdate -v -k /usr/local/gnudip/etc/Kgnudip-key.+157+36000.private
  344. </pre>
  345. Or you could do:
  346. <pre>
  347. # BIND nsupdate command
  348. nsupdate = /usr/bin/nsupdate -v
  349. nsupdate = -k /usr/local/gnudip/etc/Kgnudip-key.+157+36000.private
  350. </pre>
  351. </blockquote>
  352. <p>
  353. Note that parameter names in <code>gnudip.conf</code> may appear more than once.
  354. The values are concatentated with an intervening blank.
  355. <p>
  356. As shown above, the command line options for <code>nsupdate</code>
  357. differ between BIND 8 and BIND 9. However, the <code>nsupdate</code> standard
  358. input commands generated by GnuDIP are compatible with either BIND 8 or
  359. BIND 9.
  360. <p><li>
  361. <p>
  362. Now you must configure the target BIND <code>named</code> daemon to contain
  363. the key generated above, and also of course your GnuDIP dynamic zone.
  364. <p>
  365. Note that <u>the <code>named</code> daemon may run on a different machine than
  366. the machine that will run the GnuDIP CGI (and thereby the <code>nsupdate</code>
  367. command)</u>. The <code>nsupdate</code> command determines
  368. what DNS server to send its update request
  369. to by doing a DNS lookup for the "<code>SOA</code>" record for the domain name whose
  370. information is being updated. The <code>SOA</code> record identifies the master DNS
  371. server for this domain name. <b>The <code>nsupdate</code> command will send the
  372. update request to the master DNS server for the domain</b>.
  373. <p>
  374. Recall that the sample TSIG key generated above was:
  375. <blockquote><pre>
  376. fegHlhVt3opPIiK8V4cjLw==
  377. </pre></blockquote>
  378. <p>
  379. Create a file called <code>gnudip-keyfile</code> in your <code>named</code>
  380. configuration directory.
  381. This file should not be writable by anyone. This file should be readable only
  382. by the owner and owned by user "<code>nobody</code>"
  383. (the "<code>nobody</code>" that the <code>named</code> daemon will run
  384. as - see step one above).
  385. The file <code>gnudip-keyfile</code> should contain something like this sample:
  386. <pre>
  387. key gnudip-key {
  388. algorithm hmac-md5;
  389. // the TSIG key
  390. secret "fegHlhVt3opPIiK8V4cjLw==";
  391. };
  392. </pre>
  393. Note that <u>the contents of this file are entirely different from the files
  394. created during key generation</u> above. This is not a copy of one of those files.
  395. You will have to <u>create this file manually</u>. The sample key
  396. "<code>fegHlhVt3opPIiK8V4cjLw==</code>" must be replaced by the key that you
  397. generated.
  398. <p>
  399. Now you must add a section to define the GnuDIP dynamic zone in your
  400. <code>named.conf</code> file.
  401. <p>
  402. For BIND 8 the new section would look something like:
  403. <blockquote>
  404. <pre>
  405. // include definition of GnuDIP update key
  406. include "gnudip-keyfile";
  407. // define GnuDIP dynamic DNS zone
  408. zone "dyn.you.net" in {
  409. type master;
  410. file "run/zone-dyn.you.net";
  411. allow-query { any; };
  412. allow-update { key gnudip-key; };
  413. };
  414. </pre>
  415. </blockquote>
  416. <p>
  417. For BIND 9 the new section would look something like:
  418. <blockquote>
  419. <pre>
  420. // include definition of GnuDIP update key
  421. include "gnudip-keyfile";
  422. // define GnuDIP dynamic DNS zone
  423. zone "dyn.you.net" in {
  424. type master;
  425. file "run/zone-dyn.you.net";
  426. allow-query { any; };
  427. update-policy { grant gnudip-key subdomain dyn.you.net; };
  428. };
  429. </pre>
  430. </blockquote>
  431. In the examples above, note that the string <b><code>gnudip-key</code>
  432. refers to the name</b> of the key,
  433. whereas the string <b><code>gnudip-keyfile</code> refers to the
  434. file</b> containing the syntax to define that key name.
  435. <p>
  436. Notice above that the zone file is in a subdirectory called <code>run</code>.
  437. This directory should be owned by user "<code>nobody</code>"
  438. (or whatever user ID <code>named</code> runs as) so that
  439. <code>named</code> may create files in it.
  440. <p>
  441. You can set up <code>$TTL</code> and <code>SOA</code> values for the dynamic
  442. zones by setting up an initial
  443. zone file for BIND. BIND will read this the first time, and use the values from
  444. the file. Continuing the previous example, for the file
  445. <code>run/zone-dyn.you.net</code> try something like this sample:
  446. <pre>
  447. $TTL 86400 ; default TTL (1 day)
  448. @ IN SOA ns.you.net. root.you.net. (
  449. 0 ; serial
  450. 3600 ; refresh (1 hour)
  451. 1800 ; retry (30 minutes)
  452. 604800 ; expire (1 week)
  453. 0 ; TTL for NACK-s (0 seconds)
  454. )
  455. IN NS ns.you.net.
  456. IN A IP_address
  457. </pre>
  458. This zone file should again be owned by user <code>nobody</code>, so that
  459. <code>named</code> may modify it.
  460. <p>
  461. This sample supposes that you want clients to use
  462. <code>dyn.you.net</code> as the name of the GnuDIP server, in addition to the
  463. name of the GnuDIP subdomain.
  464. The <code>A</code> record is required for this. You will not be allowed to
  465. use a <code>CNAME</code> record for this, because the name of the record would
  466. be the same as the name of the <code>SOA</code> record. You can maintain this
  467. <code>A</code> record using <code>nsupdate</code> if the address changes.
  468. <p>
  469. The <code>SOA</code> and <code>NS</code> records may point into an entirely
  470. different domain.
  471. <p>
  472. Note that <b>the base domain <code>you.net</code> can be made the GnuDIP dynamic
  473. domain</b> if you wish. If the <code>NS</code> records point to names within
  474. <code>you.net</code>, you will need glue records in the usual way.
  475. <p>
  476. Note that <u>the default TTL value in this start up file will not apply</u>
  477. to the records added using <code>nsupdate</code>. The
  478. <code>nsupdate</code> command requires a TTL value
  479. with each record added. GnuDIP will use a value of zero for this TTL, unless a
  480. value is specified in
  481. <a href="gnudip/etc/gnudip.conf"><code>/usr/local/gnudip/etc/gnudip.conf</code></a>
  482. (see below).
  483. <p>
  484. You may want to <u>retain a copy of this inital zone file</u>, for use with the
  485. <a href="gnudip/sbin/gdipzone.pl"><code>gnudip/sbin/gdipzone.pl</code></a>
  486. script discussed below.
  487. <p>
  488. Note that if you are the operator of a serious
  489. production shop rather than a home hobbiest, you
  490. will need to set up BIND to do "<b>dynamic update forwarding</b>"
  491. and "<b>incremental zone transfers</b>" to slave DNS servers from the master DNS
  492. server. These details are not explained here.
  493. <p><li>
  494. If the call to the <code>nsupdate</code> command by the GnuDIP CGI script
  495. fails for any reason, the precise command that was invoked as well as the input
  496. that was passed to it and the output from it will be wriiten to the system log.
  497. <p>
  498. <b>The simplest way to debug your BIND configuration is probably by using
  499. <code>nsupdate</code>, the <code>dig</code> command and the <code>ping</code>
  500. command at the UNIX command prompt</b>. For example, <u><b>on the machine where
  501. the GnuDIP CGI script and <code>nsupdate</code> will run</b></u>, try:
  502. <pre>
  503. # dig tester.dyn.you.net. soa
  504. ; &lt;&lt;&gt;&gt; DiG 9.1.3 &lt;&lt;&gt;&gt; tester.dyn.you.net. soa
  505. ;; global options: printcmd
  506. ;; Got answer:
  507. ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 34673
  508. ;; flags: qr aa rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0
  509. ;; QUESTION SECTION:
  510. ;tester.dyn.you.net. IN SOA
  511. ;; AUTHORITY SECTION:
  512. dyn.you.net. 0 IN SOA you.net. root.you.net. 484 3600 1800 604800 0
  513. ;; Query time: 8 msec
  514. ;; SERVER: 192.168.0.2#53(192.168.0.2)
  515. ;; WHEN: Tue Oct 23 14:47:24 2001
  516. ;; MSG SIZE rcvd: 88
  517. # su - nobody
  518. # /usr/bin/nsupdate -v -k /usr/local/gnudip/etc/Kgnudip-key.+157+36000.private
  519. &gt; update add tester.dyn.you.net. 0 A 127.0.0.1
  520. &gt;
  521. &gt; #
  522. # exit
  523. # ping tester.dyn.you.net.
  524. PING tester.dyn.you.net (127.0.0.1): 56 data bytes
  525. 64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=0.2 ms
  526. 64 bytes from 127.0.0.1: icmp_seq=1 ttl=255 time=0.1 ms
  527. --- tester.dyn.you.net ping statistics ---
  528. 2 packets transmitted, 2 packets received, 0% packet loss
  529. round-trip min/avg/max = 0.1/0.1/0.2 ms
  530. #
  531. </pre>
  532. In the "<code>su</code>" command, the "<code>nobody</code>" that the
  533. GnuDIP CGI and (X)INETD daemon will run as should be used (see above).
  534. You may want to try the <code>nsupdate</code> as root first.
  535. <p>
  536. If your <code>nobody</code> user is not set up to allow the use of
  537. "<code>su - ...</code>", you may instead try:
  538. <pre>
  539. # sudo -u nobody /usr/bin/nsupdate -v \
  540. -k /usr/local/gnudip/etc/Kgnudip-key.+157+36000.private
  541. </pre>
  542. <p>
  543. The output from the <code>dig</code> command shows that <code>nsupdate</code>
  544. will send its update request to <code>you.net</code>.
  545. <p>
  546. Note that <code>nsupdate</code> accumulates update input lines until it sees an
  547. empty line.
  548. Only then does it do the updates.
  549. To stop <code>nsupdate</code> use "<code>Ctrl-D</code>" to generate
  550. an end of file.
  551. <p>
  552. <b>Remember that BIND comes with documentation</b>.
  553. <p>
  554. You may also want to take advantage of
  555. <a href="http://isc.org/services/public/lists/bind-lists.html">
  556. the BIND mailing lists</a> or
  557. <a href="http://www.isc.org/ml-archives/">their archives</a>.
  558. </ol>
  559. <h3>Editing the Configuration File</h3>
  560. <blockquote>
  561. Edit
  562. <a href="gnudip/etc/gnudip.conf"><code>/usr/local/gnudip/etc/gnudip.conf</code></a>.
  563. There are comments in the sample that is already there.
  564. <p>
  565. In particular, check whether you need a "<code>-p</code>" option for the "<code>logger</code>"
  566. commands in order to ensure that log messages go somewhere acceptable. One user has suggested
  567. "<code>/usr/bin/logger -p local3.err</code>" for Solaris 8 using the default configuration
  568. for syslogd.
  569. <p>Also, check the path to your sendmail program (or sendmail clone). For example
  570. Solaris 8 by default puts sendmail in <code>/usr/lib/sendmail</code>.
  571. <p>
  572. A sendmail alias (or clone equivalent) to direct mail for the "return path" user (the
  573. GnuDIP "nobody" user unless the sendmail "<code>-f</code>" option is used) to
  574. <code>/dev/null</code> is also a good idea, so returned mail for a bad E-mail address
  575. disappears.
  576. <p>
  577. If you already have a <code>gnudip.conf</code> file for an existing installation,
  578. <b>review the sample <code>gnudip.conf</code> file for new parameters</b>.
  579. <p>
  580. Make sure that everything in <code>/usr/local/gnudip/etc/</code> is readable only by
  581. the owner and owned by user "<code>nobody</code>" (the "<code>nobody</code>" that
  582. Apache will run the GnuDIP CGI script as - see step one above), and not writable by
  583. any user.
  584. <p>
  585. You may wish to create a directory <b><code>/etc/gnudip</code></b>,
  586. move (i.e. rename) the directory <code>/usr/local/gnudip/etc</code> to
  587. <code>/usr/local/gnudip/etc_orig</code> (for later reference), and set
  588. <code>/usr/local/gnudip/etc</code> as a <b>symbolic link</b> to
  589. <code>/etc/gnudip</code>. Then create your configuration files
  590. in <code>/etc/gnudip</code>. If you later upgrade, you can then just rename
  591. <code>/usr/local/gnudip/etc</code> to <code>/usr/local/gnudip/etc_orig</code>, and
  592. recreate the link. This practice allows the switch to a new release in production
  593. environments to consist of two "<code>mv</code>" commands and one "<code>ln</code>"
  594. command, which would take only a few seconds.
  595. </blockquote>
  596. <h3>Apache Web Server Set Up</h3>
  597. <blockquote>
  598. The instructions here are for Apache. But it should be possible to use
  599. the web interface with other servers.
  600. <p>
  601. <b>The user maintenance commands or remote maintenance daemon</b> described
  602. below <b>may be used in place of</b> or in addition to <b>the GnuDIP Web
  603. interface</b>. However, the HTTP client update interface is incorporated into
  604. the web interface. The Apache configuration can be made simpler if only
  605. the HTTP client interface is desired. Only the CGI definition
  606. statements are required.
  607. </blockquote>
  608. <ol>
  609. <li>
  610. To run as a standard CGI, add these lines to your Apache configuration file:
  611. <pre>
  612. Alias /gnudip/html/ /usr/local/gnudip/html/
  613. &lt;Location /gnudip/html/&gt;
  614. Options Indexes
  615. ReadmeName .README
  616. HeaderName .HEADER
  617. RemoveHandler .pl
  618. RemoveType .pl
  619. AddType text/plain .pl
  620. &lt;/Location&gt;
  621. ScriptAlias /gnudip/cgi-bin/ /usr/local/gnudip/cgi-bin/
  622. </pre>
  623. The URL for the Web Tool will be:
  624. <pre>
  625. http://yourserver/gnudip/cgi-bin/gnudip.cgi
  626. </pre>
  627. The self sign up page will be directly available at:
  628. <pre>
  629. http://yourserver/gnudip/cgi-bin/gnudip.cgi?action=signup
  630. </pre>
  631. Note that this URL is <b>different than the URL</b> for GnuDIP following the installation
  632. instructions <b>for Release 2.1.2</b>. Following those instructions the URL would be
  633. <pre>
  634. http://yourserver/cgi-bin/gnudip2.cgi
  635. </pre>
  636. To provide compatibility copy the perl script
  637. <a href="gnudip/cgi-bin/gnudip2.cgi"><code>/usr/local/gnudip/cgi-bin/gnudip2.cgi</code></a>
  638. to the
  639. <code>cgi-bin</code> directory for your Apache server (or make a
  640. symbolic link). This short script will redirect
  641. to the new URL. Modify
  642. <a href="gnudip/cgi-bin/gnudip2.cgi"><code>gnudip2.cgi</code></a>
  643. to match any change you made to the two Apache configuration lines above.
  644. <p>
  645. Other Apache configurations are possible.
  646. <p><li>
  647. The web tool will run under
  648. <a href="http://perl.apache.org/#modules">mod_perl Apache::Registry</a>.
  649. <p>
  650. To use mod_perl, instead of the lines described above, add these lines
  651. to your Apache configuration file:
  652. <pre>
  653. Alias /gnudip/html/ /usr/local/gnudip/html/
  654. &lt;Location /gnudip/html/&gt;
  655. Options Indexes
  656. ReadmeName .README
  657. HeaderName .HEADER
  658. RemoveHandler .pl
  659. RemoveType .pl
  660. AddType text/plain .pl
  661. &lt;/Location&gt;
  662. Alias /gnudip/cgi-bin/ /usr/local/gnudip/cgi-bin/
  663. &lt;Location /gnudip/cgi-bin/&gt;
  664. SetHandler perl-script
  665. PerlHandler Apache::Registry
  666. Options +ExecCGI
  667. PerlSendHeader On
  668. &lt;/Location&gt;
  669. </pre>
  670. <p><li>
  671. The web tool will run under
  672. <a href="http://www.fastcgi.com/">FastCGI</a>
  673. using <code>mod_fastcgi</code> and <code>FCGI.pm</code>.
  674. <p>
  675. To use FastCGI, instead of the lines described above, add these lines
  676. to your Apache configuration file:
  677. <pre>
  678. Alias /gnudip/html/ /usr/local/gnudip/html/
  679. &lt;Location /gnudip/html/&gt;
  680. Options Indexes
  681. ReadmeName .README
  682. HeaderName .HEADER
  683. RemoveHandler .pl
  684. RemoveType .pl
  685. AddType text/plain .pl
  686. &lt;/Location&gt;
  687. Alias /gnudip/cgi-bin/ /usr/local/gnudip/fcgi-bin/
  688. &lt;Location /gnudip/cgi-bin/&gt;
  689. SetHandler fastcgi-script
  690. Options +ExecCGI
  691. &lt;/Location&gt;
  692. </pre>
  693. <p>
  694. When running under mod_perl or FastCGI, adding the line
  695. "<code>persistance = YES</code>"
  696. to <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>
  697. will cause the web tool to use persistant database connections, and to
  698. retain the contents of <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>,
  699. the preferences from the <code>globalprefs</code> table and the
  700. list of domains from the <code>domains</code> table,
  701. and any other configuration files in memory, rather
  702. than re-accessing these files or tables. Make sure that persistance is not on when
  703. configuring your system while running under mod_perl or FastCGI.
  704. </ol>
  705. <h3>Customizing the Web Interface</h3>
  706. <ol>
  707. <li>
  708. The parameters <code>header_file</code> and <code>trailer_file</code> in
  709. <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>
  710. specify a file of HTML to be included at the top and bottom of each
  711. HTML page, respectively. An example of what can be done using these
  712. files is provided.
  713. <p><li>
  714. The parameters <code>URL_sendURL</code>, <code>URL_self_signup</code>
  715. and <code>URL_delthisuser</code> in
  716. <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>
  717. specify URL-s which should take the place of the "Forgotten Password",
  718. "Self Registration" and "Delete Current User" form buttons.
  719. See the comments in <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>
  720. for more information.
  721. <p><li>
  722. The parameters <code>no_robots_prfx</code> and <code>no_robots_imgcmd</code> in
  723. <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>
  724. must be correctly specified in order to user the GnuDIP feature to
  725. suppress automated abuse of "Self Registration", "Forgotten Password"
  726. and "Change E-mail Address".
  727. See the comments in <a href="gnudip/etc/gnudip.conf">gnudip.conf</a>.
  728. If you have <a href="http://www.ImageMagick.org/">ImageMagick</a>
  729. installed then the
  730. <a href="gnudip/sbin/textimage.sh">
  731. sample/default text image generation script</a>
  732. should work for you.
  733. <p>
  734. Once you have ensured the defaults will work, or provided and alternative
  735. image generation script, you can turn this option on in "System Settings"
  736. in the web interface.
  737. <p>
  738. <b>Without this, the GnuDIP Web Interface is vulnerable to being used as the
  739. "man in the middle" for an E-mail bombardment attack.</b>
  740. <p>
  741. A program can "GET" and "POST" the pages that send an E-mail
  742. repeatedly to send an E-mail bombardment to a third party. The
  743. bombardment will seem to come from the GnuDIP site.
  744. </ol>
  745. <h3>(X)INETD Daemon Set Up</h3>
  746. <ol>
  747. <li>
  748. Add an entry to <code>/etc/services</code> like this sample:
  749. <pre>
  750. gnudip 3495/tcp
  751. </pre>
  752. <p><li>
  753. If you use the
  754. <a href="http://www.synack.net/xinetd/"><code>xinetd</code></a>
  755. replacement for <code>inetd</code>, add an entry to
  756. <code>/etc/xinetd.conf</code> like this sample:
  757. <pre>
  758. service gnudip
  759. {
  760. flags = REUSE
  761. socket_type = stream
  762. protocol = tcp
  763. wait = no
  764. user = nobody
  765. server = /usr/local/gnudip/sbin/gdipinet.pl
  766. bind = 0.0.0.0
  767. only_from = 192.168.0.0/24
  768. only_from += 127.0.0.1
  769. only_from += 24.64.0.0/13
  770. only_from += 64.5.210.224/31
  771. only_from += 64.5.221.128/27
  772. }
  773. </pre>
  774. You should of course choose values for "<code>only_from</code>" that are
  775. appropriate to your circumstances. You may want to just leave these lines
  776. out.
  777. <p>
  778. Note that the "<code>nobody</code>" user ID used here should be <b>the same one
  779. Apache will run the GnuDIP CGI script as</b> (see step one above).
  780. <p>
  781. If you have XINETD with TCP wrappers compiled in, make an entry in
  782. <code>/etc/hosts.allow</code> like this sample:
  783. <pre>
  784. gdipinet.pl: 24.64.0.0/255.248.0.0 \
  785. 64.5.210.224/255.255.255.232 \
  786. 64.5.221.128/255.255.255.160
  787. </pre>
  788. For early releases of XINETD with TCP wrappers, you must use the
  789. service name instead of the process/program name, as follows:
  790. <pre>
  791. gnudip: 24.64.0.0/255.248.0.0 \
  792. 64.5.210.224/255.255.255.232 \
  793. 64.5.221.128/255.255.255.160
  794. </pre>
  795. If you left out "<code>only_from</code>" above, then you would instead
  796. use a line like:
  797. <pre>
  798. gdipinet.pl: ALL
  799. </pre>
  800. or for early releases of XINETD
  801. <pre>
  802. gnudip: ALL
  803. </pre>
  804. <p><li>
  805. Or make an equivalent entry in <code>/etc/inetd.conf</code> like this sample:
  806. <pre>
  807. gnudip stream tcp nowait nobody /usr/sbin/tcpd /usr/local/gnudip/sbin/gdipinet.pl
  808. </pre>
  809. Note that the tokens are separated by tab characters.
  810. <p>
  811. Note that the "<code>nobody</code>" user ID used here should be <b>the same one
  812. Apache will run the GnuDIP CGI script as</b> (see step one above).
  813. <p>
  814. Make an entry in <code>/etc/hosts.allow</code> like this sample:
  815. <pre>
  816. gdipinet.pl: 24.64.0.0/255.248.0.0 \
  817. 64.5.210.224/255.255.255.232 \
  818. 64.5.221.128/255.255.255.160
  819. </pre>
  820. If you are not imposing access restrictions, then you would instead
  821. use a line like:
  822. <pre>
  823. gdipinet.pl: ALL
  824. </pre>
  825. <p><li>
  826. If you have restricted the IP addresses for <code>gdipinet.pl</code> using
  827. <code>/etc/xinetd.conf</code> and/or <code>/etc/hosts.allow</code>,
  828. you may want to restrict the IP addresses for this port in your firewall too.
  829. <p><li>
  830. We assume in what follows that you have added
  831. <a href="gnudip/sbin/"<code>/usr/local/gnudip/sbin</code></a>
  832. to your <code>PATH</code> environment variable.
  833. <p><li>
  834. Check that the <code>logger</code> command used by the (X)INETD script
  835. has been correctly defined by using
  836. <a href="gnudip/sbin/gdipinet.pl"><code>gnudip/sbin/gdipinet.pl</code></a>
  837. at the command line. This should go something like this:
  838. <pre>
  839. # su - nobody
  840. # gdipinet.pl
  841. Could not get IP address of client
  842. # exit
  843. </pre>
  844. Here, the "<code>nobody</code>" that the (X)INETD daemon will run as
  845. should be used (see above).
  846. <p>
  847. If your <code>nobody</code> user is not set up to allow the use of
  848. "<code>su - ...</code>", you may instead try:
  849. <pre>
  850. # pushd /tmp
  851. # sudo -u nobody gdipinet.pl
  852. Could not get IP address of client
  853. # popd
  854. </pre>
  855. <p>
  856. Ensure that the message "<code>Could not get IP address of client</code>"
  857. also appears in your system log.
  858. <p>
  859. This test is important. <b>The (X)INETD daemon has no other way to report
  860. errors</b>.
  861. <p>
  862. Also, note that the <code>gdipinet.pl</code> script suppresses
  863. Perl warning and error messages (that is "STDERR") shortly after it starts,
  864. since under (X)INETD these would get sent to the network client.
  865. It is however possible to capture these for trouble shooting:
  866. <pre>
  867. # gdipinet.pl -h
  868. usage: gdipinet.pl [ -h | -e STDERR_file ]
  869. usage: GnuDIP (X)INETD Daemon.
  870. usage: -h: Print this usage message.
  871. usage: -e: Specify filename prefix for STDERR output. The file name
  872. usage: will be this prefix followed by the process ID.
  873. </pre>
  874. You could for example use "<code>gdipinet.pl -e /tmp/gdipinet_STDERR_</code>".
  875. </ol>
  876. <h3>Configure the Web Interface</h3>
  877. <ol>
  878. <li>
  879. Create an administrative user for gnudip using
  880. <a href="gnudip/sbin/gdipadmin.pl"><code>gnudip/sbin/gdipadmin.pl</code></a>:
  881. <pre>
  882. # gdipadmin.pl -h
  883. usage: gdipadmin.pl [ -h | [ -u ] userid password ]
  884. usage: Add GnuDIP administrative user "user" with password "password".
  885. usage: -h: Print this usage message.
  886. usage: -u: Update user if it already exists.
  887. </pre>
  888. <p>
  889. If you are using the "flat file" GnuDIP database, then before running
  890. <code>gdipadmin.pl</code> do:
  891. <pre>
  892. # su - nobody
  893. </pre>
  894. Here, the same "<code>nobody</code>" as used for the CGI scripts and the (X)INETD
  895. daemon should be used (see step one above).
  896. This will ensure that the file that is created is owned by user "<code>nobody</code>",
  897. and can be used by these GnuDIP scripts.
  898. <p>
  899. If your <code>nobody</code> user is not set up to allow the use of
  900. "<code>su - ...</code>", you may instead try:
  901. <pre>
  902. # pushd /tmp
  903. # sudo -u nobody gdipadmin.pl ...
  904. # popd
  905. </pre>
  906. <p>
  907. Note that administrative users cannot be used as dynamic host names. Unlike
  908. "host" users, they do not exist only within a particular domain. <b>Any user
  909. name you use for an administrative user will become "reserved", and
  910. unavailable as a dynamic host name</b>.
  911. <p><li>
  912. <font size="+1"><b>
  913. In the next step, or any time you encounter a problem with the web tool,
  914. remember to check the <u>system log</u> for error messages
  915. from GnuDIP. If the Web Tool encounters any difficulties using the
  916. <code>logger</code> command, error messages will be written to the
  917. <u>Apache error log</u>.
  918. </b></font>
  919. <p>
  920. <font size="+1">
  921. In particular, <b><u>look in the system log or Apache error log for error
  922. messages</u></b> if you get an error from the web tool like this:
  923. </font>
  924. <p>
  925. <center><table border="1"><tr><td>
  926. <center>
  927. <h2>Error: GnuDIP Configuration or Interface Problem</h2>
  928. An internal GnuDIP operation has failed, due to a configuration error, or
  929. the failure of a system service required by GnuDIP.
  930. <p>
  931. Please report this problem to your administrator if it persists.
  932. </center>
  933. </tr></table></center>
  934. <p><li>
  935. Go to the Web Tool and login as this new user.
  936. <p>
  937. Using "Administrative Settings",
  938. add more configuration stuff. There are explanations on the page.
  939. In particular, you will need to set your main GnuDIP domain here.
  940. <p>
  941. If you want more than one domain, use "Add Domain" to add them.
  942. <p>
  943. If you did not enable self registration for users, use "Add User" to add users.
  944. <p><li>
  945. If in the future you ever remove a domain, or turn off wildcards or
  946. mail exchangers, you should use the script
  947. <a href="gnudip/sbin/gdipdbfix.pl"><code>gnudip/sbin/gdipdbfix.pl</code></a>
  948. to bring the user database into agreement with the new configuration options:
  949. <pre>
  950. # gdipdbfix.pl -h
  951. usage: gdipdbfix.pl [ -h ]
  952. usage: Scans the database and modifies or deletes users in
  953. usage: the user database in order to be consistent with the
  954. usage: set of domains and the administrative settings.
  955. usage: -h: Print this usage message.
  956. </pre>
  957. </ol>
  958. <h3>Keeping DNS in Sync with the Database</h3>
  959. <blockquote>
  960. You may want to use the script
  961. <a href="gnudip/sbin/gdipzone.pl"><code>gnudip/sbin/gdipzone.pl</code></a>
  962. in a weekly or monthly scheduled job to reload the zone files from scratch:
  963. <pre>
  964. # gdipzone.pl -h
  965. usage: gdipzone.pl [ -h | [ -o outfile ] [domain] ]
  966. usage: Scans the database and generates nsupdate input to create zone
  967. usage: records. Scans for all domains unless "domain" is specified.
  968. usage: -h: Print this usage message.
  969. usage: -o: Specify file to write output to.
  970. </pre>
  971. <p>
  972. Following the example above, the process would be:
  973. <ul>
  974. <li>
  975. shutdown <code>named</code> using "<code>ndc stop</code>" for BIND 8 or
  976. "<code>rndc stop</code>" for BIND 9.
  977. <p><li>
  978. for BIND 9, delete the file <code>run/zone-dyn.you.net.jnl</code>
  979. <p>
  980. Make certain the "<code>rndc stop</code>" worked before you do this!!!
  981. <p><li>
  982. replace the file <code>run/zone-dyn.you.net</code> with an initial zone
  983. file like the one used above
  984. <p><li>
  985. restart <code>named</code>
  986. <p><li>
  987. run <code>nsupdate</code> using the output from <code>gdipzone.pl</code>
  988. as input
  989. </ul>
  990. </blockquote>
  991. <h3>Purging Unused User Names</h3>
  992. <blockquote>
  993. You may want to use the script
  994. <a href="gnudip/sbin/gdipdlet.pl"><code>gnudip/sbin/gdipdlet.pl</code></a>
  995. in a nightly or weekly scheduled job to delete database rows and any zone records for
  996. users whose IP address has not been updated for a specified number of days.
  997. <pre>
  998. # gdipdlet.pl -h
  999. usage: gdipdlet.pl [ -h | [ -d ] [ -o outfile ] days ]
  1000. usage: Generates the nsupdate input needed to delete zone records
  1001. usage: not updated within "days" days. Optionally, it also
  1002. usage: deletes the user from the database.
  1003. usage: -h: Print this usage message.
  1004. usage: -d: Delete users from the database.
  1005. usage: -o: Specify file to write output to.
  1006. </pre>
  1007. </blockquote>
  1008. <h3>User Maintenance Commands</h3>
  1009. <blockquote>
  1010. There are four line commands that may be useful for user maintenance from
  1011. the command line or scripts. These are described in
  1012. <a href="maintenance_commands.html"><code>maintenance_commands.html</code></a>.
  1013. </blockquote>
  1014. <h3>Remote Maintenance Daemon</h3>
  1015. <blockquote>
  1016. There is also an (X)INETD daemon that may be used to provide the same
  1017. capabilities as the user maintenance commands via a network protocol.
  1018. This is described in <a href="remote.html"><code>remote.html</code></a>.
  1019. </blockquote>
  1020. <h3>Linking Non-GnuDIP Host Names to a GnuDIP Host Name</h3>
  1021. <blockquote>
  1022. You may want to use the script
  1023. <a href="gnudip/sbin/multinsupd.pl"><code>gnudip/sbin/multinsupd.pl</code></a>
  1024. to filter the commands being passed to the <code>nsupdate</code> command,
  1025. in order to insert non-GnuDIP aliases for GnuDIP host names. See the comments
  1026. in the script, as well as the example and comments in
  1027. <a href="gnudip/etc/gnudip.conf"><code>gnudip/etc/gnudip.conf</code></a>,
  1028. <a href="gnudip/etc/minidip.conf"><code>gnudip/etc/minidip.conf</code></a> and
  1029. <a href="gnudip/etc/multinsupd.conf"><code>gnudip/etc/multinsupd.conf</code></a>.
  1030. <p>
  1031. This script goes some distance towards addressing the item
  1032. "A Mechanism to Link Non-GnuDIP Host Names to a GnuDIP Host Name" in
  1033. <a href="TODO.html"><code>TODO.html</code></a>.
  1034. </blockquote>
  1035. <h3>-T, -w, "use warnings;" and All That</h3>
  1036. <blockquote>
  1037. Perl fans may notice that the code does not use "-T" or "-w" on the
  1038. "shebang" line. Nor is "use warnings;" used.
  1039. <b>This is deliberate.</b> These options are helpful in testing, but a
  1040. great maintenance nuisance when used in publicly released software.
  1041. <p>
  1042. If you want to add these, go ahead. If you get warning or error messages,
  1043. fix the problem and submit a patch to the mailing list, explaining what
  1044. release of Perl you are using, and any upgrades you have made to the core
  1045. Perl modules. While you are at it, perhaps you should ask in your E-mail
  1046. about joining the GnuDIP support team.
  1047. </blockquote>
  1048. <p><hr>
  1049. </body>
  1050. </html>