lfc.xml 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [
  4. <!ENTITY mdash "&#x2014;" >
  5. ]>
  6. <chapter id="kea-lfc">
  7. <title>The LFC process</title>
  8. <section id="kea-lfc-overview">
  9. <title>Overview</title>
  10. <para><command>kea-lfc</command> is a service process that removes
  11. redundant infomation from the files used to provide persistent storage
  12. for the memfile data base backend. This service is written to run as a
  13. stand alone process.
  14. </para>
  15. <para>While <command>kea-lfc</command> can be started externally it should
  16. be started by the Kea DHCP servers.
  17. </para>
  18. <para>The process operates on a set of files, using them for input and output
  19. of the lease entries and to indicate where it is in the process in case of an
  20. interruption. Currently the caller must supply names for all of the files, in
  21. the future this requirement may be relaxed with the process getting the names
  22. from either the config file or from defaults.
  23. </para>
  24. </section>
  25. <section id="kea-lfc-usage">
  26. <title>Command Line Options</title>
  27. <para><command>kea-lfc</command> is run as follows:
  28. <screen>
  29. kea-lfc [-4 | -6] -c config-file -p pid-file -x previous-file -i copy-file -o output-file -f finish-file
  30. </screen>
  31. </para>
  32. <para>The argument <command>-4</command> or <command>-6</command> selects the protocol
  33. version of the lease files.
  34. </para>
  35. <para>The <command>-c</command> argument specifies the configuration file. This is
  36. required, but not currently used by the process.
  37. </para>
  38. <para>The <command>-p</command> argument specifies the PID file. When the
  39. <command>kea-lfc</command> process starts it attempts to determine if another
  40. instance of the process is already running by examining the pid file. If one
  41. is running it aborts the new process. If one isn't running it writes its
  42. pid into the pid file.
  43. </para>
  44. <para>The other filenames specify where the <command>kea-lfc</command> process
  45. should look for input, write its output and use for bookkeeping.
  46. <itemizedlist>
  47. <listitem><simpara>
  48. <command>previous</command> &mdash;
  49. When <command>kea-lfc</command> starts this
  50. is the result of any previous run of <command>kea-lfc</command>.
  51. When <command>kea-lfc</command> finishes it is the result of this run.
  52. If <command>kea-lfc</command> is interrupted before compelting
  53. this file may not exist.
  54. </simpara></listitem>
  55. <listitem><simpara>
  56. <command>input</command> &mdash;
  57. Before the DHCP server invokes <command>kea-lfc</command> it will
  58. copy the current lease file here and then call <command>kea-lfc</command>
  59. with this file.
  60. </simpara></listitem>
  61. <listitem><simpara>
  62. <command>output</command> &mdash;
  63. The temporary file <command>kea-lfc</command> should use to write the leases.
  64. Upon completion of writing this this file it will be moved to the finish file
  65. (see below).
  66. </simpara></listitem>
  67. <listitem><simpara>
  68. <command>finish</command> &mdash;
  69. Another temporary file <command>kea-lfc</command> uses for bookkeeping. When
  70. <command>kea-lfc</command> completes writing the outputfile it moves it to this
  71. file name. After <command>kea-lfc</command> finishes deleting the other files
  72. (previous and input) it moves this file to previous lease file. By moving the
  73. files in this fashion the <command>kea-lfc</command> and the DHCP server
  74. processes can determine the correct file to use even if one of the
  75. processes was interrupted before completing its task.
  76. </simpara></listitem>
  77. </itemizedlist>
  78. </para>
  79. <para>There are several additional arguments mostly for debugging purposes.
  80. <command>-d</command> Sets the logging level to debug. <command>-v</command> and
  81. <command>-V</command> print out version stamps with <command>-V</command> providing
  82. a longer form. <command>-h</command> prints out the usage string.
  83. </para>
  84. </section>
  85. </chapter>