migrate-ds.pl.8 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164
  1. .\" Hey, EMACS: -*- nroff -*-
  2. .\" First parameter, NAME, should be all caps
  3. .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
  4. .\" other parameters are allowed: see man(7), man(1)
  5. .TH MIGRATE-DS.PL 8 "May 18, 2008"
  6. .\" Please adjust this date whenever revising the manpage.
  7. .\"
  8. .\" Some roff macros, for reference:
  9. .\" .nh disable hyphenation
  10. .\" .hy enable hyphenation
  11. .\" .ad l left justify
  12. .\" .ad b justify to both left and right margins
  13. .\" .nf disable filling
  14. .\" .fi enable filling
  15. .\" .br insert line break
  16. .\" .sp <n> insert n+1 empty lines
  17. .\" for manpage-specific macros, see man(7)
  18. .SH NAME
  19. migrate\-ds.pl \- Directory Server Migration script
  20. .SH SYNOPSIS
  21. .B migrate\-ds.pl
  22. [\-\-options] \fB\-\-\fR [args]
  23. .SH DESCRIPTION
  24. Directory Server Migration script - migrates Directory Server from
  25. older releases to the current release.
  26. .PP
  27. This script will copy instances (data and configuration) from the old
  28. server root directory to their new FHS locations. This script does a
  29. copy only \- the data in the old instances will be left untouched. The
  30. old instances must be shutdown first to ensure that the databases are
  31. copied safely. During migration your migrated instances will be started.
  32. .PP
  33. .SH OPTIONS
  34. A summary of options is included below:
  35. .TP
  36. .B \fB\-\-help\fR
  37. This message
  38. .TP
  39. .B \fB\-\-version\fR
  40. Print the version and exit
  41. .TP
  42. .B \fB\-\-debug\fR
  43. Turn on debugging
  44. .TP
  45. .B \fB\-\-oldsroot\fR
  46. The old server root directory to migrate from
  47. .TP
  48. .B \fB\-\-actualsroot\fR This is the old location of the old server root.
  49. .TP
  50. .B \fB\-\-silent\fR
  51. Use silent setup \- no user input
  52. .TP
  53. .B \fB\-\-file\fR=\fIname\fR
  54. Use the file 'name' in .inf format to supply the
  55. default answers
  56. .TP
  57. .B \fB\-\-keepcache\fR
  58. Do not delete the temporary .inf file generated by
  59. this program
  60. .TP
  61. .B \fB\-\-logfile\fR
  62. Log migration messages to this file \- otherwise, a temp
  63. file will be used
  64. .TP
  65. .B \fB\-\-instance\fR
  66. By default, all directory server instances will be
  67. migrated. You can use this argument to specify one
  68. or more (e.g. \fB\-i\fR slapd\-foo \fB\-i\fR slapd\-bar) if you do
  69. not want to migrate all of them.
  70. .TP
  71. .B \fB\-\-cross\fR
  72. See below.
  73. .PP
  74. For all options, you can also use the short name e.g. \fB\-h\fR, \fB\-d\fR, etc.
  75. For the \fB\-d\fR argument, specifying it more than once will increase the
  76. debug level e.g. \fB\-ddddd\fR
  77. .PP
  78. args:
  79. You can supply default .inf data in this format:
  80. .IP
  81. section.param=value
  82. .PP
  83. e.g.
  84. .IP
  85. General.FullMachineName=foo.example.com
  86. .PP
  87. or
  88. .IP
  89. "slapd.Suffix=dc=example, dc=com"
  90. .PP
  91. Values passed in this manner will override values in an .inf file
  92. given with the \fB\-f\fR argument.
  93. .PP
  94. actualsroot:
  95. This is used when you must migrate from one machine to another. The
  96. usual case is that you have mounted the old server root on a different
  97. root directory, either via a network mount, or by copying a tarball
  98. made using a relative directory on the source machine to the
  99. destination machine and untarring it.
  100. .PP
  101. For example: machineA is a 32bit machine, and you want to migrate your
  102. servers to a new 64bit machine. Lets assume your old server root on
  103. machineA was /opt/myds, and your new machine also wants to use a
  104. server root of /opt/myds. There are a couple of different ways to
  105. proceed. Either make a tarball of opt/myds from machineA using a
  106. relative path (i.e. NOT /opt/myds) or use NFS to mount
  107. machineA:/opt/myds on a different mount point
  108. (e.g. machineB:/migration/opt/myds).
  109. .PP
  110. If you do this, you should give the old "real" server root (/opt/myds)
  111. as the \fB\-\-actualsroot\fR argument, and use /migration/opt/myds for the
  112. \fB\-\-oldsroot\fR argument. That is, the oldsroot is the physical location of
  113. the files on disk. The actualsroot is the old value of the server root
  114. on the source machine.
  115. .PP
  116. cross:
  117. Also known as crossplatform, or 'c', or 'x'.
  118. This is when the source machine is a different architecture than the
  119. destination machine. In this case, only certain data will be available
  120. for migration. Changelog information will not be migrated, and replicas
  121. will need to be reinitialized (if migrating masters or hubs). This type
  122. of migration requires that all of your old databases have been dumped
  123. to LDIF format, and the LDIF file must be in the default database directory
  124. (usually /opt/fedora\-ds/slapd\-instance/db), and the LDIF file must have
  125. the same name as the database instance directory, with a ".ldif". For
  126. example, if you have
  127. .IP
  128. .ad l
  129. .nf
  130. /opt/fedora\-ds/slapd\-instance/db/userRoot/
  131. and
  132. /opt/fedora\-ds/slapd\-instance/db/NetscapeRoot/
  133. .na
  134. .fi
  135. .PP
  136. you must first use db2ldif to export these databases to LDIF e.g.
  137. .IP
  138. .ad l
  139. .nf
  140. cd /opt/fedora\-ds/slapd\-instance
  141. \&./db2ldif \fB\-n\fR userRoot \fB\-a\fR /opt/fedora\-ds/slapd\-instance/db/userRoot.ldif and
  142. \&./db2ldif \fB\-n\fR NetscapeRoot \fB\-a\fR /opt/fedora\-ds/slapd\-instance/db/NetscapeRoot.ldif
  143. .fi
  144. .na
  145. .PP
  146. Then you must somehow make your old server root directory available on
  147. the destination machine, either by creating a tar archive on the source
  148. and copying it to the destination, or by network mounting the source
  149. directory on the destination machine.
  150. .br
  151. .SH AUTHOR
  152. migrate-ds.pl was written by the 389 Project.
  153. .SH "REPORTING BUGS"
  154. Report bugs to http://bugzilla.redhat.com.
  155. .SH COPYRIGHT
  156. Copyright \(co 2008 Red Hat, Inc.
  157. .br
  158. This manual page was written by Michele Baldessari <[email protected]>,
  159. for the Debian project (but may be used by others).
  160. .br
  161. This is free software. You may redistribute copies of it under the terms of
  162. the Directory Server license found in the LICENSE file of this
  163. software distribution. This license is essentially the GNU General Public
  164. License version 2 with an exception for plug-in distribution.