| 1 |
# SOME DESCRIPTIVE TITLE |
| 2 |
# Copyright (C) YEAR Free Software Foundation, Inc. |
| 3 |
# This file is distributed under the same license as the PACKAGE package. |
| 4 |
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. |
| 5 |
# |
| 6 |
#, fuzzy |
| 7 |
msgid "" |
| 8 |
msgstr "" |
| 9 |
"Project-Id-Version: PACKAGE VERSION\n" |
| 10 |
"POT-Creation-Date: 2020-03-02 15:09+0000\n" |
| 11 |
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
| 12 |
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
| 13 |
"Language-Team: LANGUAGE <[email protected]>\n" |
| 14 |
"Language: \n" |
| 15 |
"MIME-Version: 1.0\n" |
| 16 |
"Content-Type: text/plain; charset=CHARSET\n" |
| 17 |
"Content-Transfer-Encoding: 8bit\n" |
| 18 |
|
| 19 |
#. type: Title == |
| 20 |
#: internals.adoc:2 |
| 21 |
#, no-wrap |
| 22 |
msgid "DRBD Internals" |
| 23 |
msgstr "DRBD内幕" |
| 24 |
|
| 25 |
#. type: Plain text |
| 26 |
#: internals.adoc:11 |
| 27 |
msgid "" |
| 28 |
"This chapter gives _some_ background information about some of DRBD's " |
| 29 |
"internal algorithms and structures. It is intended for interested users " |
| 30 |
"wishing to gain a certain degree of background knowledge about DRBD. It does" |
| 31 |
" not dive into DRBD's inner workings deep enough to be a reference for DRBD " |
| 32 |
"developers. For that purpose, please refer to the papers listed in " |
| 33 |
"<<s-publications>>, and of course to the comments in the DRBD source code." |
| 34 |
msgstr "" |
| 35 |
"本章介绍了DRBD的一些内部算法和结构的背景信息。它是为有兴趣的用户希望获得DRBD一定程度的背景知识。它没有深入研究DRBD的内部工作机制,不能作为DRBD开发人员的参考。为此,请参阅<<s-publications>>中列出的论文,当然也请参阅DRBD源代码中的注释。" |
| 36 |
|
| 37 |
#. type: Title === |
| 38 |
#: internals.adoc:13 |
| 39 |
#, no-wrap |
| 40 |
msgid "DRBD meta data" |
| 41 |
msgstr "DRBD元数据" |
| 42 |
|
| 43 |
#. type: Plain text |
| 44 |
#: internals.adoc:17 |
| 45 |
msgid "" |
| 46 |
"indexterm:[meta data]DRBD stores various pieces of information about the " |
| 47 |
"data it keeps in a dedicated area. This metadata includes:" |
| 48 |
msgstr "indexterm:[meta data]DRBD存储关于它保存在一个专用区域中的数据的各种信息。此元数据包括:" |
| 49 |
|
| 50 |
#. type: Plain text |
| 51 |
#: internals.adoc:19 |
| 52 |
msgid "the size of the DRBD device," |
| 53 |
msgstr "DRBD设备的大小," |
| 54 |
|
| 55 |
#. type: Plain text |
| 56 |
#: internals.adoc:20 |
| 57 |
msgid "the Generation Identifier (GI, described in detail in <<s-gi>>)," |
| 58 |
msgstr "生成标识符(GI,详细说明见<<s-gi>>)," |
| 59 |
|
| 60 |
#. type: Plain text |
| 61 |
#: internals.adoc:21 |
| 62 |
msgid "the Activity Log (AL, described in detail in <<s-activity-log>>)." |
| 63 |
msgstr "活动日志(AL,在<<s-activity-log>>中详细描述)。" |
| 64 |
|
| 65 |
#. type: Plain text |
| 66 |
#: internals.adoc:22 |
| 67 |
msgid "" |
| 68 |
"the quick-sync bitmap (described in detail in <<s-quick-sync-bitmap>>)," |
| 69 |
msgstr "快速同步位图(详见<<s-quick-sync-bitmap>>)," |
| 70 |
|
| 71 |
#. type: Plain text |
| 72 |
#: internals.adoc:25 |
| 73 |
msgid "" |
| 74 |
"This metadata may be stored _internally_ or _externally_. Which method is " |
| 75 |
"used is configurable on a per-resource basis." |
| 76 |
msgstr "此元数据可以存储在内部或外部。所使用的方法是基于每个资源可配置的。" |
| 77 |
|
| 78 |
#. type: Title ==== |
| 79 |
#: internals.adoc:27 |
| 80 |
#, no-wrap |
| 81 |
msgid "Internal meta data" |
| 82 |
msgstr "内部元数据" |
| 83 |
|
| 84 |
#. type: Plain text |
| 85 |
#: internals.adoc:34 |
| 86 |
msgid "" |
| 87 |
"indexterm:[meta data]Configuring a resource to use internal meta data means " |
| 88 |
"that DRBD stores its meta data on the same physical lower-level device as " |
| 89 |
"the actual production data. It does so by setting aside an area at the _end_" |
| 90 |
" of the device for the specific purpose of storing metadata." |
| 91 |
msgstr "" |
| 92 |
"indexterm:[meta data]将资源配置为使用内部元数据意味着DRBD将其元数据存储在与实际生产数据相同的物理低级设备上。它通过在设备的末端留出一个区域来存储元数据。" |
| 93 |
|
| 94 |
#. type: Block title |
| 95 |
#: internals.adoc:35 internals.adoc:85 |
| 96 |
#, no-wrap |
| 97 |
msgid "Advantage" |
| 98 |
msgstr "优势" |
| 99 |
|
| 100 |
#. type: Plain text |
| 101 |
#: internals.adoc:40 |
| 102 |
msgid "" |
| 103 |
"Since the meta data are inextricably linked with the actual data, no special" |
| 104 |
" action is required from the administrator in case of a hard disk failure. " |
| 105 |
"The meta data are lost together with the actual data and are also restored " |
| 106 |
"together." |
| 107 |
msgstr "由于元数据与实际数据有着千丝万缕的联系,因此在硬盘出现故障时,管理员无需执行任何特殊操作。元数据与实际数据一起丢失,也一起还原。" |
| 108 |
|
| 109 |
#. type: Block title |
| 110 |
#: internals.adoc:41 internals.adoc:89 |
| 111 |
#, no-wrap |
| 112 |
msgid "Disadvantage" |
| 113 |
msgstr "劣势" |
| 114 |
|
| 115 |
#. type: Plain text |
| 116 |
#: internals.adoc:49 |
| 117 |
msgid "" |
| 118 |
"In case of the lower-level device being a single physical hard disk (as " |
| 119 |
"opposed to a RAID set), internal meta data may negatively affect write " |
| 120 |
"throughput. The performance of write requests by the application may trigger" |
| 121 |
" an update of the meta data in DRBD. If the meta data are stored on the same" |
| 122 |
" magnetic disk of a hard disk, the write operation may result in two " |
| 123 |
"additional movements of the write/read head of the hard disk." |
| 124 |
msgstr "" |
| 125 |
"如果较低级别的设备是单个物理硬盘(而不是RAID集),内部元数据可能会对写入吞吐量产生负面影响。应用程序的写请求的性能可能触发DRBD中的元数据的更新。如果元数据存储在硬盘的同一个磁盘上,则写入操作可能导致硬盘的写/读磁头的两个额外移动。" |
| 126 |
|
| 127 |
#. type: delimited block = |
| 128 |
#: internals.adoc:56 |
| 129 |
msgid "" |
| 130 |
"If you are planning to use internal meta data in conjunction with an " |
| 131 |
"existing lower-level device that already has data which you wish to " |
| 132 |
"preserve, you _must_ account for the space required by DRBD's meta data." |
| 133 |
msgstr "如果您计划将内部元数据与现有的较低级别设备结合使用,而该设备已具有您希望保留的数据,则 _必须_ 考虑DRBD元数据所需的空间。" |
| 134 |
|
| 135 |
#. type: delimited block = |
| 136 |
#: internals.adoc:60 |
| 137 |
msgid "" |
| 138 |
"Otherwise, upon DRBD resource creation, the newly created metadata would " |
| 139 |
"overwrite data at the end of the lower-level device, potentially destroying " |
| 140 |
"existing files in the process." |
| 141 |
msgstr "否则,在创建DRBD资源时,新创建的元数据将覆盖较低级别设备末尾的数据,从而可能在该过程中破坏现有文件。" |
| 142 |
|
| 143 |
#. type: Plain text |
| 144 |
#: internals.adoc:63 |
| 145 |
msgid "To avoid that, you must do one of the following things:" |
| 146 |
msgstr "要避免这种情况,您必须执行以下操作之一:" |
| 147 |
|
| 148 |
#. type: Plain text |
| 149 |
#: internals.adoc:68 |
| 150 |
msgid "" |
| 151 |
"Enlarge your lower-level device. This is possible with any logical volume " |
| 152 |
"management facility (such as indexterm:[LVM]LVM) as long as you have free " |
| 153 |
"space available in the corresponding volume group. It may also be supported " |
| 154 |
"by hardware storage solutions." |
| 155 |
msgstr "" |
| 156 |
"扩容你的下层设备。只要在相应的卷组中有可用空间,任何逻辑卷管理工具(如indexterm:[LVM]LVM)都可以做到这一点。硬件存储解决方案也可能支持它。" |
| 157 |
|
| 158 |
#. type: Plain text |
| 159 |
#: internals.adoc:71 |
| 160 |
msgid "" |
| 161 |
"Shrink your existing file system on your lower-level device. This may or may" |
| 162 |
" not be supported by your file system." |
| 163 |
msgstr "缩容较低级别设备上的现有文件系统。您的文件系统可能支持,也可能不支持。" |
| 164 |
|
| 165 |
#. type: Plain text |
| 166 |
#: internals.adoc:74 |
| 167 |
msgid "" |
| 168 |
"If neither of the two are possible, use <<s-external-meta-data,external meta" |
| 169 |
" data>> instead." |
| 170 |
msgstr "如果两者都不可能,请改用<<s-external-meta-data,external meta data>>。" |
| 171 |
|
| 172 |
#. type: Plain text |
| 173 |
#: internals.adoc:77 |
| 174 |
msgid "" |
| 175 |
"To estimate the amount by which you must enlarge your lower-level device or " |
| 176 |
"shrink your file system, see <<s-meta-data-size>>." |
| 177 |
msgstr "要估计必须放大低级设备或缩小文件系统的数量,请参见<<s-meta-data-size>>。" |
| 178 |
|
| 179 |
#. type: Title ==== |
| 180 |
#: internals.adoc:79 |
| 181 |
#, no-wrap |
| 182 |
msgid "External meta data" |
| 183 |
msgstr "外部元数据" |
| 184 |
|
| 185 |
#. type: Plain text |
| 186 |
#: internals.adoc:84 |
| 187 |
msgid "" |
| 188 |
"indexterm:[meta data]External meta data is simply stored on a separate, " |
| 189 |
"dedicated block device distinct from that which holds your production data." |
| 190 |
msgstr "indexterm:[meta data]外部元数据简单地存储在一个独立的专用块设备上,与保存生产数据的设备不同。" |
| 191 |
|
| 192 |
#. type: Plain text |
| 193 |
#: internals.adoc:88 |
| 194 |
msgid "" |
| 195 |
"For some write operations, using external meta data produces a somewhat " |
| 196 |
"improved latency behavior." |
| 197 |
msgstr "对于某些写操作,使用外部元数据会产生稍有改进的延迟行为。" |
| 198 |
|
| 199 |
#. type: Plain text |
| 200 |
#: internals.adoc:95 |
| 201 |
msgid "" |
| 202 |
"Meta data are not inextricably linked with the actual production data. This " |
| 203 |
"means that manual intervention is required in the case of a hardware failure" |
| 204 |
" destroying just the production data (but not DRBD meta data), to effect a " |
| 205 |
"full data sync from the surviving node onto the subsequently replaced disk." |
| 206 |
msgstr "" |
| 207 |
"元数据与实际生产数据并非密不可分。这意味着,在硬件故障仅破坏生产数据(而非DRBD元数据)的情况下,需要手动干预,以实现从幸存节点到随后更换的磁盘的完全数据同步。" |
| 208 |
|
| 209 |
#. type: Plain text |
| 210 |
#: internals.adoc:98 |
| 211 |
msgid "" |
| 212 |
"Use of external meta data is also the only viable option if _all_ of the " |
| 213 |
"following apply:" |
| 214 |
msgstr "如果适用以下所有条件,使用外部元数据也是唯一可行的选择:" |
| 215 |
|
| 216 |
#. type: Plain text |
| 217 |
#: internals.adoc:101 |
| 218 |
msgid "" |
| 219 |
"You are using DRBD to duplicate an existing device that already contains " |
| 220 |
"data you wish to preserve, _and_" |
| 221 |
msgstr "您正在使用DRBD复制已包含要保留的数据的现有设备,_并且_" |
| 222 |
|
| 223 |
#. type: Plain text |
| 224 |
#: internals.adoc:103 |
| 225 |
msgid "that existing device does not support enlargement, _and_" |
| 226 |
msgstr "现有设备不支持扩容,_并且_" |
| 227 |
|
| 228 |
#. type: Plain text |
| 229 |
#: internals.adoc:105 |
| 230 |
msgid "the existing file system on the device does not support shrinking." |
| 231 |
msgstr "设备上现有的文件系统不支持收缩。" |
| 232 |
|
| 233 |
#. type: Plain text |
| 234 |
#: internals.adoc:108 |
| 235 |
msgid "" |
| 236 |
"To estimate the required size of the block device dedicated to hold your " |
| 237 |
"device meta data, see <<s-meta-data-size>>." |
| 238 |
msgstr "要估计专用于保存设备元数据的块设备所需的大小,请参见<<s-meta-data-size>>。" |
| 239 |
|
| 240 |
#. type: Plain text |
| 241 |
#: internals.adoc:110 |
| 242 |
msgid "External meta data requires a minimum of a 1MB device size." |
| 243 |
msgstr "外部元数据至少需要1MB的设备大小。" |
| 244 |
|
| 245 |
#. type: Title ==== |
| 246 |
#: internals.adoc:112 |
| 247 |
#, no-wrap |
| 248 |
msgid "Estimating meta data size" |
| 249 |
msgstr "估计元数据大小" |
| 250 |
|
| 251 |
#. type: Plain text |
| 252 |
#: internals.adoc:116 |
| 253 |
msgid "" |
| 254 |
"indexterm:[meta data]You may calculate the exact space requirements for " |
| 255 |
"DRBD's meta data using the following formula:" |
| 256 |
msgstr "indexterm:[meta data]您可以使用以下公式计算DRBD元数据的确切空间需求:" |
| 257 |
|
| 258 |
#. type: Block title |
| 259 |
#: internals.adoc:118 |
| 260 |
#, no-wrap |
| 261 |
msgid "Calculating DRBD meta data size (exactly)" |
| 262 |
msgstr "计算DRBD元数据大小(精确)" |
| 263 |
|
| 264 |
#. type: Target for macro image |
| 265 |
#: internals.adoc:119 |
| 266 |
#, no-wrap |
| 267 |
msgid "images/metadata-size-exact.svg" |
| 268 |
msgstr "images/metadata-size-exact.svg" |
| 269 |
|
| 270 |
#. type: Plain text |
| 271 |
#: internals.adoc:122 |
| 272 |
#, no-wrap |
| 273 |
msgid "" |
| 274 |
"*_C~s~_* is the data device size in sectors, and *_N_* is the number of " |
| 275 |
"peers.\n" |
| 276 |
msgstr "" |
| 277 |
"*_C~s~_* is the data device size in sectors, and *_N_* is the number of " |
| 278 |
"peers.\n" |
| 279 |
|
| 280 |
#. If |
| 281 |
#. you are using the <<al-stripe,al-stripes>> setting, additional space of |
| 282 |
#. size |
| 283 |
#. _al-stripes_ times _al-strip-size_ is required. |
| 284 |
#. type: Plain text |
| 285 |
#: internals.adoc:131 |
| 286 |
msgid "" |
| 287 |
"You may retrieve the device size (in bytes) by issuing `blockdev --getsize64" |
| 288 |
" <device>`; to convert to MB, divide by 1048576 (= 2^20^ or 1024^2^)." |
| 289 |
msgstr "" |
| 290 |
"您可以通过发出 `blockdev --" |
| 291 |
"getsize64 <device>` ;为转换为MB,除以1048576(=2^20^或1024^2^)来检索设备大小(字节)。" |
| 292 |
|
| 293 |
#. type: Plain text |
| 294 |
#: internals.adoc:134 |
| 295 |
msgid "" |
| 296 |
"In practice, you may use a reasonably good approximation, given below. Note " |
| 297 |
"that in this formula, the unit is megabytes, not sectors:" |
| 298 |
msgstr "实际上,您可以使用一个相当好的近似值,如下所示。注意,在这个公式中,单位是兆字节,而不是扇区:" |
| 299 |
|
| 300 |
#. type: Block title |
| 301 |
#: internals.adoc:136 |
| 302 |
#, no-wrap |
| 303 |
msgid "Estimating DRBD meta data size (approximately)" |
| 304 |
msgstr "估计DRBD元数据大小(大约)" |
| 305 |
|
| 306 |
#. type: Target for macro image |
| 307 |
#: internals.adoc:137 |
| 308 |
#, no-wrap |
| 309 |
msgid "images/metadata-size-approx.svg" |
| 310 |
msgstr "images/metadata-size-approx.svg" |
| 311 |
|
| 312 |
#. type: Title === |
| 313 |
#: internals.adoc:140 |
| 314 |
#, no-wrap |
| 315 |
msgid "Generation Identifiers" |
| 316 |
msgstr "生成标识符" |
| 317 |
|
| 318 |
#. type: Plain text |
| 319 |
#: internals.adoc:144 |
| 320 |
msgid "" |
| 321 |
"indexterm:[generation identifiers]DRBD uses _generation identifiers_ (GIs) " |
| 322 |
"to identify \"generations\" of replicated data." |
| 323 |
msgstr "indexterm:[generation identifiers]DRBD使用生成标识符(GIs)来标识复制数据的 \"生成\"。" |
| 324 |
|
| 325 |
#. type: Plain text |
| 326 |
#: internals.adoc:146 |
| 327 |
msgid "This is DRBD's internal mechanism used for" |
| 328 |
msgstr "这是DRBD的内部机制,用于" |
| 329 |
|
| 330 |
#. type: Plain text |
| 331 |
#: internals.adoc:149 |
| 332 |
msgid "" |
| 333 |
"determining whether the two nodes are in fact members of the same cluster " |
| 334 |
"(as opposed to two nodes that were connected accidentally)," |
| 335 |
msgstr "确定这两个节点是否实际上是同一集群的成员(与意外连接的两个节点相反)," |
| 336 |
|
| 337 |
#. type: Plain text |
| 338 |
#: internals.adoc:152 |
| 339 |
msgid "" |
| 340 |
"determining the direction of background re-synchronization (if necessary)," |
| 341 |
msgstr "确定背景重新同步的方向(如有必要)," |
| 342 |
|
| 343 |
#. type: Plain text |
| 344 |
#: internals.adoc:155 |
| 345 |
msgid "" |
| 346 |
"determining whether full re-synchronization is necessary or whether partial " |
| 347 |
"re-synchronization is sufficient," |
| 348 |
msgstr "确定是否需要完全重新同步或部分重新同步是否足够," |
| 349 |
|
| 350 |
#. type: Plain text |
| 351 |
#: internals.adoc:157 |
| 352 |
msgid "indexterm:[split brain]identifying split brain." |
| 353 |
msgstr "indexterm:[split brain]识别裂脑。" |
| 354 |
|
| 355 |
#. type: Title ==== |
| 356 |
#: internals.adoc:159 |
| 357 |
#, no-wrap |
| 358 |
msgid "Data generations" |
| 359 |
msgstr "数据生成" |
| 360 |
|
| 361 |
#. type: Plain text |
| 362 |
#: internals.adoc:163 |
| 363 |
msgid "" |
| 364 |
"DRBD marks the start of a new _data generation_ at each of the following " |
| 365 |
"occurrences:" |
| 366 |
msgstr "DRBD在以下每一次出现时都标志着新数据生成的开始:" |
| 367 |
|
| 368 |
#. FIXME PRe |
| 369 |
#. type: Plain text |
| 370 |
#: internals.adoc:167 |
| 371 |
msgid "The initial device full sync," |
| 372 |
msgstr "初始设备完全同步," |
| 373 |
|
| 374 |
#. type: Plain text |
| 375 |
#: internals.adoc:169 |
| 376 |
msgid "a disconnected resource switching to the primary role," |
| 377 |
msgstr "断开连接的资源切换到主角色," |
| 378 |
|
| 379 |
#. type: Plain text |
| 380 |
#: internals.adoc:171 |
| 381 |
msgid "a resource in the primary role disconnecting." |
| 382 |
msgstr "主角色中的资源正在断开连接。" |
| 383 |
|
| 384 |
#. type: Plain text |
| 385 |
#: internals.adoc:179 |
| 386 |
msgid "" |
| 387 |
"Thus, we can summarize that whenever a resource is in the _Connected_ " |
| 388 |
"connection state, and both nodes' disk state is _UpToDate_, the current data" |
| 389 |
" generation on both nodes is the same. The inverse is also true. Note that " |
| 390 |
"the current implementation uses the lowest bit to encode the role of the " |
| 391 |
"node (Primary/Secondary). Therefore, the lowest bit might be different on " |
| 392 |
"distinct nodes even if they are considered to have the same data generation." |
| 393 |
msgstr "" |
| 394 |
"因此,我们可以总结出,每当资源处于 _Connected_ 连接状态,并且两个节点的磁盘状态都是 _UpToDate_ 时,两个节点上的当前数据生成都是相同的。反之亦然。注意,当前实现使用最低的位来编码节点的角色(主/次)。因此,即使被认为具有相同的数据生成,不同节点上的最低位也可能不同。" |
| 395 |
|
| 396 |
#. type: Plain text |
| 397 |
#: internals.adoc:182 |
| 398 |
msgid "" |
| 399 |
"Every new data generation is identified by an 8-byte, universally unique " |
| 400 |
"identifier (UUID)." |
| 401 |
msgstr "每个新的数据生成都由一个8字节的通用唯一标识符(UUID)标识。" |
| 402 |
|
| 403 |
#. type: Title ==== |
| 404 |
#: internals.adoc:184 |
| 405 |
#, no-wrap |
| 406 |
msgid "The generation identifier tuple" |
| 407 |
msgstr "生成标识符元组" |
| 408 |
|
| 409 |
#. type: Plain text |
| 410 |
#: internals.adoc:188 |
| 411 |
msgid "" |
| 412 |
"DRBD keeps some pieces of information about current and historical data " |
| 413 |
"generations in the local resource meta data:" |
| 414 |
msgstr "DRBD在本地资源元数据中保留一些有关当前和历史数据生成的信息:" |
| 415 |
|
| 416 |
#. type: Block title |
| 417 |
#: internals.adoc:189 |
| 418 |
#, no-wrap |
| 419 |
msgid "Current UUID" |
| 420 |
msgstr "当前UUID" |
| 421 |
|
| 422 |
#. type: Plain text |
| 423 |
#: internals.adoc:194 |
| 424 |
msgid "" |
| 425 |
"This is the generation identifier for the current data generation, as seen " |
| 426 |
"from the local node's perspective. When a resource is _Connected_ and fully " |
| 427 |
"synchronized, the current UUID is identical between nodes." |
| 428 |
msgstr "从本地节点的角度看,这是当前数据生成的生成标识符。当资源连接并完全同步时,节点之间的当前UUID是相同的。" |
| 429 |
|
| 430 |
#. type: Block title |
| 431 |
#: internals.adoc:195 |
| 432 |
#, no-wrap |
| 433 |
msgid "Bitmap UUIDs" |
| 434 |
msgstr "Bitmap UUIDs" |
| 435 |
|
| 436 |
#. type: Plain text |
| 437 |
#: internals.adoc:199 |
| 438 |
msgid "" |
| 439 |
"This is the UUID of the generation against which this on-disk bitmap is " |
| 440 |
"tracking changes (per remote host). Like the on-disk sync bitmap itself, " |
| 441 |
"this identifier is only relevant while the remote host is disconnected." |
| 442 |
msgstr "这是此磁盘上位图跟踪更改(每个远程主机)所依据的生成的UUID。与磁盘上同步位图本身一样,此标识符仅在远程主机断开连接时才相关。" |
| 443 |
|
| 444 |
#. If the resource is _Connected_, this UUID is always empty (zero). FIXME |
| 445 |
#. type: Block title |
| 446 |
#: internals.adoc:202 |
| 447 |
#, no-wrap |
| 448 |
msgid "Historical UUIDs" |
| 449 |
msgstr "历史UUIDs" |
| 450 |
|
| 451 |
#. type: Plain text |
| 452 |
#: internals.adoc:205 |
| 453 |
msgid "" |
| 454 |
"These are the identifiers of data generations preceding the current one, " |
| 455 |
"sized to have one slot per (possible) remote host." |
| 456 |
msgstr "这些是当前数据生成之前的数据生成的标识符,大小为每个(可能的)远程主机有一个插槽。" |
| 457 |
|
| 458 |
#. type: Plain text |
| 459 |
#: internals.adoc:208 |
| 460 |
msgid "" |
| 461 |
"Collectively, these items are referred to as the _generation identifier " |
| 462 |
"tuple_, or \"__GI tuple__\" for short." |
| 463 |
msgstr "这些项统称为 _generation identifier tuple_ ,简称为 \"__GI tuple__\"。" |
| 464 |
|
| 465 |
#. type: Title ==== |
| 466 |
#: internals.adoc:210 |
| 467 |
#, no-wrap |
| 468 |
msgid "How generation identifiers change" |
| 469 |
msgstr "生成标识符如何更改" |
| 470 |
|
| 471 |
#. type: Title ===== |
| 472 |
#: internals.adoc:213 |
| 473 |
#, no-wrap |
| 474 |
msgid "Start of a new data generation" |
| 475 |
msgstr "开始新的数据生成" |
| 476 |
|
| 477 |
#. type: Plain text |
| 478 |
#: internals.adoc:218 |
| 479 |
msgid "" |
| 480 |
"When a node in _Primary_ role loses connection to its peer (either by " |
| 481 |
"network failure or manual intervention), DRBD modifies its local generation " |
| 482 |
"identifiers in the following manner:" |
| 483 |
msgstr "当处于 _主要_ 角色的节点失去与其对等节点的连接时(通过网络故障或手动干预),DRBD按以下方式修改其本地生成标识符:" |
| 484 |
|
| 485 |
#. type: Block title |
| 486 |
#: internals.adoc:220 |
| 487 |
#, no-wrap |
| 488 |
msgid "GI tuple changes at start of a new data generation" |
| 489 |
msgstr "在新数据生成开始时更改GI元组" |
| 490 |
|
| 491 |
#. type: Target for macro image |
| 492 |
#: internals.adoc:221 |
| 493 |
#, no-wrap |
| 494 |
msgid "images/gi-changes-newgen.svg" |
| 495 |
msgstr "images/gi-changes-newgen.svg" |
| 496 |
|
| 497 |
#. type: Plain text |
| 498 |
#: internals.adoc:225 |
| 499 |
msgid "" |
| 500 |
"The primary creates a new UUID for the new data generation. This becomes the" |
| 501 |
" _new_ current UUID for the primary node." |
| 502 |
msgstr "主节点为新的数据生成创建一个新的UUID。这将成为主节点的当前UUID。" |
| 503 |
|
| 504 |
#. type: Plain text |
| 505 |
#: internals.adoc:229 |
| 506 |
msgid "" |
| 507 |
"The _previous_ current UUID now refers to the generation the bitmap is " |
| 508 |
"tracking changes against, so it becomes the new bitmap UUID for the primary " |
| 509 |
"node." |
| 510 |
msgstr "前一个当前的UUID现在引用位图跟踪更改的生成,因此它成为主节点的新位图UUID。" |
| 511 |
|
| 512 |
#. type: Plain text |
| 513 |
#: internals.adoc:231 |
| 514 |
msgid "On the secondary node(s), the GI tuple remains unchanged." |
| 515 |
msgstr "在次节点上,GI元组保持不变。" |
| 516 |
|
| 517 |
#. type: Title ===== |
| 518 |
#: internals.adoc:234 |
| 519 |
#, no-wrap |
| 520 |
msgid "Completion of re-synchronization" |
| 521 |
msgstr "重新同步完成" |
| 522 |
|
| 523 |
#. type: Plain text |
| 524 |
#: internals.adoc:238 |
| 525 |
msgid "" |
| 526 |
"When re-synchronization concludes, the synchronization target adopts the " |
| 527 |
"entire GI tuple from the synchronization source." |
| 528 |
msgstr "当重新同步结束时,同步目标采用来自同步源的整个GI元组。" |
| 529 |
|
| 530 |
#. type: Plain text |
| 531 |
#: internals.adoc:240 |
| 532 |
msgid "" |
| 533 |
"The synchronization source keeps the same set, and doesn't generate new " |
| 534 |
"UUIDs." |
| 535 |
msgstr "同步源保持相同的集合,并且不生成新的uuid。" |
| 536 |
|
| 537 |
#. type: Title ==== |
| 538 |
#: internals.adoc:243 |
| 539 |
#, no-wrap |
| 540 |
msgid "How DRBD uses generation identifiers" |
| 541 |
msgstr "DRBD如何使用生成标识符" |
| 542 |
|
| 543 |
#. type: Plain text |
| 544 |
#: internals.adoc:248 |
| 545 |
msgid "" |
| 546 |
"When a connection between nodes is established, the two nodes exchange their" |
| 547 |
" currently available generation identifiers, and proceed accordingly. A " |
| 548 |
"number of possible outcomes exist:" |
| 549 |
msgstr "当节点之间建立连接时,两个节点交换其当前可用的生成标识符,并相应地继续。存在许多可能的结果:" |
| 550 |
|
| 551 |
#. type: Block title |
| 552 |
#: internals.adoc:249 |
| 553 |
#, no-wrap |
| 554 |
msgid "Current UUIDs empty on both nodes" |
| 555 |
msgstr "两个节点上的当前uuid均为空" |
| 556 |
|
| 557 |
#. type: Plain text |
| 558 |
#: internals.adoc:255 |
| 559 |
msgid "" |
| 560 |
"The local node detects that both its current UUID and the peer's current " |
| 561 |
"UUID are empty. This is the normal occurrence for a freshly configured " |
| 562 |
"resource that has not had the initial full sync initiated. No " |
| 563 |
"synchronization takes place; it has to be started manually." |
| 564 |
msgstr "" |
| 565 |
"本地节点检测到其当前UUID和对等方的当前UUID都为空。这是新配置的资源的正常情况,该资源尚未启动初始完全同步。不进行同步;必须手动启动。" |
| 566 |
|
| 567 |
#. type: Block title |
| 568 |
#: internals.adoc:256 |
| 569 |
#, no-wrap |
| 570 |
msgid "Current UUIDs empty on one node" |
| 571 |
msgstr "一个节点上的当前uuid为空" |
| 572 |
|
| 573 |
#. type: Plain text |
| 574 |
#: internals.adoc:266 |
| 575 |
msgid "" |
| 576 |
"The local node detects that the peer's current UUID is empty, and its own is" |
| 577 |
" not. This is the normal case for a freshly configured resource on which the" |
| 578 |
" initial full sync has just been initiated, the local node having been " |
| 579 |
"selected as the initial synchronization source. DRBD now sets all bits in " |
| 580 |
"the on-disk sync bitmap (meaning it considers the entire device out-of-" |
| 581 |
"sync), and starts synchronizing as a synchronization source. In the opposite" |
| 582 |
" case (local current UUID empty, peer's non-empty), DRBD performs the same " |
| 583 |
"steps, except that the local node becomes the synchronization target." |
| 584 |
msgstr "" |
| 585 |
"本地节点检测到对等方的当前UUID为空,而其自身的UUID为空。对于刚刚启动初始完全同步的新配置资源,这是正常情况,已选择本地节点作为初始同步源。DRBD现在设置磁盘同步位图中的所有位(意味着它认为整个设备不同步),并作为同步源开始同步。在相反的情况下(本地当前UUID为空,对等端为非空),DRBD执行相同的步骤,只是本地节点成为同步目标。" |
| 586 |
|
| 587 |
#. type: Block title |
| 588 |
#: internals.adoc:267 |
| 589 |
#, no-wrap |
| 590 |
msgid "Equal current UUIDs" |
| 591 |
msgstr "匹配当前 UUIDs" |
| 592 |
|
| 593 |
#. type: Plain text |
| 594 |
#: internals.adoc:273 |
| 595 |
msgid "" |
| 596 |
"The local node detects that its current UUID and the peer's current UUID are" |
| 597 |
" non-empty and equal. This is the normal occurrence for a resource that went" |
| 598 |
" into disconnected mode at a time when it was in the secondary role, and was" |
| 599 |
" not promoted on either node while disconnected. No synchronization takes " |
| 600 |
"place, as none is necessary." |
| 601 |
msgstr "" |
| 602 |
"本地节点检测到其当前UUID和对等方的当前UUID不为空且相等。这是资源在处于次要角色时进入断开连接模式的正常情况,并且在断开连接时未在任何节点上升级。不需要同步,因为不需要同步。" |
| 603 |
|
| 604 |
#. type: Block title |
| 605 |
#: internals.adoc:274 |
| 606 |
#, no-wrap |
| 607 |
msgid "Bitmap UUID matches peer's current UUID" |
| 608 |
msgstr "位图UUID与对等方的当前UUID匹配" |
| 609 |
|
| 610 |
#. type: Plain text |
| 611 |
#: internals.adoc:288 |
| 612 |
msgid "" |
| 613 |
"The local node detects that its bitmap UUID matches the peer's current UUID," |
| 614 |
" and that the peer's bitmap UUID is empty. This is the normal and expected " |
| 615 |
"occurrence after a secondary node failure, with the local node being in the " |
| 616 |
"primary role. It means that the peer never became primary in the meantime " |
| 617 |
"and worked on the basis of the same data generation all along. DRBD now " |
| 618 |
"initiates a normal, background re-synchronization, with the local node " |
| 619 |
"becoming the synchronization source. If, conversely, the local node detects " |
| 620 |
"that _its_ bitmap UUID is empty, and that the _peer's_ bitmap matches the " |
| 621 |
"local node's current UUID, then that is the normal and expected occurrence " |
| 622 |
"after a failure of the local node. Again, DRBD now initiates a normal, " |
| 623 |
"background re-synchronization, with the local node becoming the " |
| 624 |
"synchronization target." |
| 625 |
msgstr "" |
| 626 |
"本地节点检测到其位图UUID与对等方的当前UUID匹配,并且对等方的位图UUID为空。这是在次要节点发生故障(本地节点处于主要角色)后发生的正常且预期的事件。这意味着对等方从来没有在同一时间成为主要的,并且一直在同一数据生成的基础上工作。DRBD现在启动一个正常的后台重新同步,本地节点成为同步源。相反,如果本地节点检测到其位图UUID为空,并且该位图与本地节点的当前UUID匹配,则这是本地节点发生故障后的正常和预期发生。再次,DRBD现在启动一个正常的后台重新同步,本地节点成为同步目标。" |
| 627 |
|
| 628 |
#. type: Block title |
| 629 |
#: internals.adoc:289 |
| 630 |
#, no-wrap |
| 631 |
msgid "Current UUID matches peer's historical UUID" |
| 632 |
msgstr "当前UUID与对等方的历史UUID匹配" |
| 633 |
|
| 634 |
#. type: Plain text |
| 635 |
#: internals.adoc:301 |
| 636 |
msgid "" |
| 637 |
"The local node detects that its current UUID matches one of the peer's " |
| 638 |
"historical UUID's. This implies that while the two data sets share a common " |
| 639 |
"ancestor, and the peer node has the up-to-date data, the information kept in" |
| 640 |
" the peer node's bitmap is outdated and not usable. Thus, a normal " |
| 641 |
"synchronization would be insufficient. DRBD now marks the entire device as " |
| 642 |
"out-of-sync and initiates a full background re-synchronization, with the " |
| 643 |
"local node becoming the synchronization target. In the opposite case (one of" |
| 644 |
" the local node's historical UUID matches the peer's current UUID), DRBD " |
| 645 |
"performs the same steps, except that the local node becomes the " |
| 646 |
"synchronization source." |
| 647 |
msgstr "" |
| 648 |
"本地节点检测到其当前的UUID与对等方的历史UUID之一匹配。这意味着,虽然这两个数据集共享一个共同的祖先,并且对等方节点具有最新的数据,但对等方节点位图中保留的信息已过时且不可用。因此,正常的同步是不够的。DRBD现在将整个设备标记为不同步,并启动完全后台重新同步,本地节点将成为同步目标。在相反的情况下(本地节点的一个历史UUID与对等节点的当前UUID匹配),DRBD执行相同的步骤,只是本地节点成为同步源。" |
| 649 |
|
| 650 |
#. ERROR: FIXME |
| 651 |
#. type: Block title |
| 652 |
#: internals.adoc:304 |
| 653 |
#, no-wrap |
| 654 |
msgid "Bitmap UUIDs match, current UUIDs do not" |
| 655 |
msgstr "位图uuid匹配,当前uuid不匹配" |
| 656 |
|
| 657 |
#. type: Plain text |
| 658 |
#: internals.adoc:311 |
| 659 |
msgid "" |
| 660 |
"indexterm:[split brain]The local node detects that its current UUID differs " |
| 661 |
"from the peer's current UUID, and that the bitmap UUID's match. This is " |
| 662 |
"split brain, but one where the data generations have the same parent. This " |
| 663 |
"means that DRBD invokes split brain auto-recovery strategies, if configured." |
| 664 |
" Otherwise, DRBD disconnects and waits for manual split brain resolution." |
| 665 |
msgstr "" |
| 666 |
"indexterm:[split " |
| 667 |
"brain]本地节点检测到其当前UUID与对等节点的当前UUID不同,并且位图UUID匹配。这是分裂的大脑,但其中的数据世代有相同的父母。这意味着,如果配置了DRBD,它会调用分割大脑自动恢复策略。否则,DRBD将断开连接,等待手动拆分大脑分辨率。" |
| 668 |
|
| 669 |
#. type: Block title |
| 670 |
#: internals.adoc:312 |
| 671 |
#, no-wrap |
| 672 |
msgid "Neither current nor bitmap UUIDs match" |
| 673 |
msgstr "当前uuid和位图uuid都不匹配" |
| 674 |
|
| 675 |
#. type: Plain text |
| 676 |
#: internals.adoc:318 |
| 677 |
msgid "" |
| 678 |
"The local node detects that its current UUID differs from the peer's current" |
| 679 |
" UUID, and that the bitmap UUID's _do not_ match. This is split brain with " |
| 680 |
"unrelated ancestor generations, thus auto-recovery strategies, even if " |
| 681 |
"configured, are moot. DRBD disconnects and waits for manual split brain " |
| 682 |
"resolution." |
| 683 |
msgstr "" |
| 684 |
"本地节点检测到其当前UUID与对等方的当前UUID不同,并且位图UUID的不匹配。这是分裂的大脑与无关的祖先世代,因此自动恢复策略,即使配置,是没有意义的。DRBD断开连接并等待手动分割大脑分辨率。" |
| 685 |
|
| 686 |
#. type: Block title |
| 687 |
#: internals.adoc:319 |
| 688 |
#, no-wrap |
| 689 |
msgid "No UUIDs match" |
| 690 |
msgstr "无Uuid匹配" |
| 691 |
|
| 692 |
#. type: Plain text |
| 693 |
#: internals.adoc:325 |
| 694 |
msgid "" |
| 695 |
"Finally, in case DRBD fails to detect even a single matching element in the " |
| 696 |
"two nodes' GI tuples, it logs a warning about unrelated data and " |
| 697 |
"disconnects. This is DRBD's safeguard against accidental connection of two " |
| 698 |
"cluster nodes that have never heard of each other before." |
| 699 |
msgstr "" |
| 700 |
"最后,如果DRBD在两个节点的GI元组中甚至检测不到一个匹配的元素,它会记录一个关于不相关数据和断开连接的警告。这是DRBD防止两个以前从未听说过的集群节点意外连接的保护措施。" |
| 701 |
|
| 702 |
#. type: Title === |
| 703 |
#: internals.adoc:328 |
| 704 |
#, no-wrap |
| 705 |
msgid "The Activity Log" |
| 706 |
msgstr "活动日志" |
| 707 |
|
| 708 |
#. type: Title ==== |
| 709 |
#: internals.adoc:331 |
| 710 |
#, no-wrap |
| 711 |
msgid "Purpose" |
| 712 |
msgstr "目的" |
| 713 |
|
| 714 |
#. type: Plain text |
| 715 |
#: internals.adoc:339 |
| 716 |
msgid "" |
| 717 |
"indexterm:[Activity Log]During a write operation DRBD forwards the write " |
| 718 |
"operation to the local backing block device, but also sends the data block " |
| 719 |
"over the network. These two actions occur, for all practical purposes, " |
| 720 |
"simultaneously. Random timing behavior may cause a situation where the write" |
| 721 |
" operation has been completed, but the transmission via the network has not " |
| 722 |
"yet taken place, or vice versa." |
| 723 |
msgstr "" |
| 724 |
"indexterm:[Activity " |
| 725 |
"Log]在写操作期间,DRBD将写操作转发到本地备份块设备,但也通过网络发送数据块。出于所有实际目的,这两个动作同时发生。随机定时行为可能导致写入操作已完成,但经由网络的传输尚未发生的情况,反之亦然。" |
| 726 |
|
| 727 |
#. type: Plain text |
| 728 |
#: internals.adoc:353 |
| 729 |
msgid "" |
| 730 |
"If, at this moment, the active node fails and fail-over is being initiated, " |
| 731 |
"then this data block is out of sync between nodes -- it has been written on " |
| 732 |
"the failed node prior to the crash, but replication has not yet completed. " |
| 733 |
"Thus, when the node eventually recovers, this block must be removed from the" |
| 734 |
" data set during subsequent synchronization. Otherwise, the crashed node " |
| 735 |
"would be \"one write ahead\" of the surviving node, which would violate the " |
| 736 |
"\"all or nothing\" principle of replicated storage. This is an issue that is" |
| 737 |
" not limited to DRBD, in fact, this issue exists in practically all " |
| 738 |
"replicated storage configurations. Many other storage solutions (just as " |
| 739 |
"DRBD itself, prior to version 0.7) thus require that after a failure of the " |
| 740 |
"active node the data must be fully synchronized after its recovery." |
| 741 |
msgstr "" |
| 742 |
"如果此时活动节点发生故障,并且正在启动故障转移,则此数据块在节点之间不同步—它在崩" |
| 743 |
"溃之前已写入到发生故障的节点上,但复制尚未完成。因此,当节点最终恢复时,必须在后" |
| 744 |
"续同步期间从数据集中删除此块。否则,崩溃的节点将比幸存的节点 \"提前一次写入\",这" |
| 745 |
"将违反复制存储的 \"全部或无\" 原则。这是一个不仅限于DRBD的问题,事实上,这个问题" |
| 746 |
"实际上存在于几乎所有的复制存储配置中。许多其他存储解决" |
| 747 |
"方案(就像DRBD本身一样,在0.7之前)因此要求在活动节点发生故障后,数据在恢复后必须完全同步。" |
| 748 |
|
| 749 |
#. type: Plain text |
| 750 |
#: internals.adoc:358 |
| 751 |
msgid "" |
| 752 |
"DRBD's approach, since version 0.7, is a different one. The _activity log_ " |
| 753 |
"(AL), stored in the meta data area, keeps track of those blocks that have " |
| 754 |
"\"recently\" been written to. Colloquially, these areas are referred to as " |
| 755 |
"_hot extents_." |
| 756 |
msgstr "" |
| 757 |
"DRBD的方法,因为版本0.7,是不同的。存储在元数据区域中的 _活动日志_(AL)跟踪那些 \"最近\" 被写入的块。通俗地说,这些地区被称为 \"热区\"。" |
| 758 |
|
| 759 |
#. type: Plain text |
| 760 |
#: internals.adoc:364 |
| 761 |
msgid "" |
| 762 |
"If a temporarily failed node that was in active mode at the time of failure " |
| 763 |
"is synchronized, only those hot extents highlighted in the AL need to be " |
| 764 |
"synchronized (plus any blocks marked in the bitmap on the now-active peer), " |
| 765 |
"rather than the full device. This drastically reduces synchronization time " |
| 766 |
"after an active node crash." |
| 767 |
msgstr "" |
| 768 |
"如果同步发生故障时处于活动模式的临时故障节点,则只需要同步AL中突出显示的热数据块(加上当前活动对等机上位图中标记的任何块),而不需要同步整个设备。这大大缩短了活动节点崩溃后的同步时间。" |
| 769 |
|
| 770 |
#. type: Title ==== |
| 771 |
#: internals.adoc:366 |
| 772 |
#, no-wrap |
| 773 |
msgid "Active extents" |
| 774 |
msgstr "活动范围" |
| 775 |
|
| 776 |
#. type: Plain text |
| 777 |
#: internals.adoc:373 |
| 778 |
msgid "" |
| 779 |
"indexterm:[Activity Log]The activity log has a configurable parameter, the " |
| 780 |
"number of active extents. Every active extent adds 4MiB to the amount of " |
| 781 |
"data being retransmitted after a Primary crash. This parameter must be " |
| 782 |
"understood as a compromise between the following opposites:" |
| 783 |
msgstr "" |
| 784 |
"indexterm:[活动日志]活动日志有一个可配置的参数,即活动扩展的数量。每个活动数据块都会在主崩溃后重新传输的数据量上增加4MiB。必须将此参数理解为以下两个对立面之间的折衷:" |
| 785 |
|
| 786 |
#. type: Block title |
| 787 |
#: internals.adoc:374 |
| 788 |
#, no-wrap |
| 789 |
msgid "Many active extents" |
| 790 |
msgstr "许多活动范围" |
| 791 |
|
| 792 |
#. type: Plain text |
| 793 |
#: internals.adoc:381 |
| 794 |
msgid "" |
| 795 |
"Keeping a large activity log improves write throughput. Every time a new " |
| 796 |
"extent is activated, an old extent is reset to inactive. This transition " |
| 797 |
"requires a write operation to the meta data area. If the number of active " |
| 798 |
"extents is high, old active extents are swapped out fairly rarely, reducing " |
| 799 |
"meta data write operations and thereby improving performance." |
| 800 |
msgstr "" |
| 801 |
"保持较大的活动日志可以提高写吞吐量。每次激活新数据块时,旧数据块都会重置为非活动数据块。此转换需要对元数据区域执行写操作。如果活动扩展数据块的数量很高,则旧的活动扩展数据块很少被换出,从而减少元数据写入操作,从而提高性能。" |
| 802 |
|
| 803 |
#. type: Block title |
| 804 |
#: internals.adoc:382 |
| 805 |
#, no-wrap |
| 806 |
msgid "Few active extents" |
| 807 |
msgstr "活动范围很少" |
| 808 |
|
| 809 |
#. type: Plain text |
| 810 |
#: internals.adoc:385 |
| 811 |
msgid "" |
| 812 |
"Keeping a small activity log reduces synchronization time after active node " |
| 813 |
"failure and subsequent recovery." |
| 814 |
msgstr "保持一个小的活动日志可以减少活动节点故障和后续恢复后的同步时间。" |
| 815 |
|
| 816 |
#. type: Title ==== |
| 817 |
#: internals.adoc:388 |
| 818 |
#, no-wrap |
| 819 |
msgid "Selecting a suitable Activity Log size" |
| 820 |
msgstr "选择适当的活动日志大小" |
| 821 |
|
| 822 |
#. type: Plain text |
| 823 |
#: internals.adoc:394 |
| 824 |
msgid "" |
| 825 |
"indexterm:[Activity Log]Consideration of the number of extents should be " |
| 826 |
"based on the desired synchronization time at a given synchronization rate. " |
| 827 |
"The number of active extents can be calculated as follows:" |
| 828 |
msgstr "indexterm:[活动日志]应根据给定同步速率下的所需同步时间来考虑扩展数据块的数量。活动范围的数量可以按以下方式计算:" |
| 829 |
|
| 830 |
#. type: Block title |
| 831 |
#: internals.adoc:396 |
| 832 |
#, no-wrap |
| 833 |
msgid "Active extents calculation based on sync rate and target sync time" |
| 834 |
msgstr "基于同步速率和目标同步时间的活动数据块计算" |
| 835 |
|
| 836 |
#. type: Target for macro image |
| 837 |
#: internals.adoc:397 |
| 838 |
#, no-wrap |
| 839 |
msgid "images/al-extents.svg" |
| 840 |
msgstr "images/al-extents.svg" |
| 841 |
|
| 842 |
#. type: Plain text |
| 843 |
#: internals.adoc:402 |
| 844 |
msgid "" |
| 845 |
"_R_ is the synchronization rate, given in MiB/s. _t~sync~_ is the target " |
| 846 |
"synchronization time, in seconds. _E_ is the resulting number of active " |
| 847 |
"extents." |
| 848 |
msgstr "_R_ 是同步速率,以MiB/s为单位。_t~sync_ 是目标同步时间,以秒为单位。_E_ 是活动范围的结果数量。" |
| 849 |
|
| 850 |
#. type: Plain text |
| 851 |
#: internals.adoc:407 |
| 852 |
msgid "" |
| 853 |
"To provide an example, suppose the cluster has an I/O subsystem with a " |
| 854 |
"throughput rate of 200 MiByte/s that was configured to a synchronization " |
| 855 |
"rate (_R_) of 60 MiByte/s, and we want to keep the target synchronization " |
| 856 |
"time (_t~sync~_) at 4 minutes or 240 seconds:" |
| 857 |
msgstr "" |
| 858 |
"举个例子,假设集群有一个I/O子系统,其吞吐量 (_R_) 为200兆字节/秒,配置为60兆字节/秒的同步速率,并且我们希望将目标同步时间(_t~tsync~_)保持在4分或240秒:" |
| 859 |
|
| 860 |
#. type: Block title |
| 861 |
#: internals.adoc:409 |
| 862 |
#, no-wrap |
| 863 |
msgid "" |
| 864 |
"Active extents calculation based on sync rate and target sync time (example)" |
| 865 |
msgstr "基于同步速率和目标同步时间的活动数据块计算(示例)" |
| 866 |
|
| 867 |
#. type: Target for macro image |
| 868 |
#: internals.adoc:410 |
| 869 |
#, no-wrap |
| 870 |
msgid "images/al-extents-example.svg" |
| 871 |
msgstr "images/al-extents-example.svg" |
| 872 |
|
| 873 |
#. type: Plain text |
| 874 |
#: internals.adoc:414 |
| 875 |
msgid "" |
| 876 |
"On a final note, DRBD 9 needs to keep an AL even on the Secondary nodes, as " |
| 877 |
"their data might be used to synchronize other Secondary nodes." |
| 878 |
msgstr "最后,DRBD 9需要在次要节点上保持AL,因为它们的数据可能用于同步其他次要节点。" |
| 879 |
|
| 880 |
#. type: Title === |
| 881 |
#: internals.adoc:417 |
| 882 |
#, no-wrap |
| 883 |
msgid "The quick-sync bitmap" |
| 884 |
msgstr "快速同步位图" |
| 885 |
|
| 886 |
#. type: Plain text |
| 887 |
#: internals.adoc:424 |
| 888 |
msgid "" |
| 889 |
"indexterm:[quick-sync bitmap]indexterm:[bitmap (DRBD-specific concept)]The " |
| 890 |
"quick-sync bitmap is the internal data structure which DRBD uses, on a per-" |
| 891 |
"resource per-peer basis, to keep track of blocks being in sync (identical on" |
| 892 |
" both nodes) or out-of sync. It is only relevant when a resource is in " |
| 893 |
"disconnected mode." |
| 894 |
msgstr "" |
| 895 |
"indexterm:[quick-sync bitmap]indexterm:[bitmap(DRBD-specific concept)]quick " |
| 896 |
"sync bitmap是内部数据结构,DRBD在每个对等资源上使用它来跟踪正在同步(在两个节点上相同)或不同步的块。它只在资源处于断开连接模式时才相关。" |
| 897 |
|
| 898 |
#. type: Plain text |
| 899 |
#: internals.adoc:431 |
| 900 |
msgid "" |
| 901 |
"In the quick-sync bitmap, one bit represents a 4-KiB chunk of on-disk data. " |
| 902 |
"If the bit is cleared, it means that the corresponding block is still in " |
| 903 |
"sync with the peer node. That implies that the block has not been written to" |
| 904 |
" since the time of disconnection. Conversely, if the bit is set, it means " |
| 905 |
"that the block has been modified and needs to be re-synchronized whenever " |
| 906 |
"the connection becomes available again." |
| 907 |
msgstr "" |
| 908 |
"在快速同步位图中,一位表示磁盘上的4 " |
| 909 |
"KiB数据块。如果该位被清除,则表示对应的块仍与对等节点同步。这意味着自断开连接时起就没有写入块。相反,如果设置了位,则意味着块已被修改,并且需要在连接再次可用时重新同步。" |
| 910 |
|
| 911 |
#. type: Plain text |
| 912 |
#: internals.adoc:441 |
| 913 |
msgid "" |
| 914 |
"As DRBD detects write I/O on a disconnected device, and hence starts setting" |
| 915 |
" bits in the quick-sync bitmap, it does so in RAM -- thus avoiding expensive" |
| 916 |
" synchronous metadata I/O operations. Only when the corresponding blocks " |
| 917 |
"turn cold (that is, expire from the <<s-activity-log,Activity Log>>), DRBD " |
| 918 |
"makes the appropriate modifications in an on-disk representation of the " |
| 919 |
"quick-sync bitmap. Likewise, if the resource happens to be manually shut " |
| 920 |
"down on the remaining node while disconnected, DRBD flushes the _complete_ " |
| 921 |
"quick-sync bitmap out to persistent storage." |
| 922 |
msgstr "" |
| 923 |
"当DRBD检测到断开连接的设备上的写I/O,并因此开始在快速同步位图中设置位时,它在RAM中这样做——从而避免了昂贵的同步元数据I/O操作。只有当相应的块变冷时(即,从<<s-activity-" |
| 924 |
"log,Activity " |
| 925 |
"Log>>过期),DRBD才会在快速同步位图的磁盘表示中进行适当的修改。同样,如果在断开连接的同时碰巧手动关闭了剩余节点上的资源,DRBD会将快速同步位图刷新到持久存储。" |
| 926 |
|
| 927 |
#. type: Plain text |
| 928 |
#: internals.adoc:447 |
| 929 |
msgid "" |
| 930 |
"When the peer node recovers or the connection is re-established, DRBD " |
| 931 |
"combines the bitmap information from both nodes to determine the _total data" |
| 932 |
" set_ that it must re-synchronize. Simultaneously, DRBD <<s-gi-use,examines " |
| 933 |
"the generation identifiers>> to determine the _direction_ of " |
| 934 |
"synchronization." |
| 935 |
msgstr "" |
| 936 |
"当对等节点恢复或重新建立连接时,DRBD结合来自两个节点的位图信息来确定必须重新同步的 _总数据集_ 。同时,DRBD<<s-gi-use,examines " |
| 937 |
"the generation identifiers>>以确定同步的 _方向_ 。" |
| 938 |
|
| 939 |
#. type: Plain text |
| 940 |
#: internals.adoc:453 |
| 941 |
msgid "" |
| 942 |
"The node acting as the synchronization source then transmits the agreed-upon" |
| 943 |
" blocks to the peer node, clearing sync bits in the bitmap as the " |
| 944 |
"synchronization target acknowledges the modifications. If the re-" |
| 945 |
"synchronization is now interrupted (by another network outage, for example) " |
| 946 |
"and subsequently resumed it will continue where it left off" |
| 947 |
msgstr "" |
| 948 |
"然后,作为同步源的节点将商定的块发送到对等节点,在同步目标确认修改时清除位图中的同步位。如果重新同步现在被中断(例如,被另一个网络中断)并随后恢复,它将在中断的地方继续" |
| 949 |
|
| 950 |
#. type: Plain text |
| 951 |
#: internals.adoc:455 |
| 952 |
msgid "" |
| 953 |
"with any additional blocks modified in the meantime being added to the re-" |
| 954 |
"synchronization data set, of course." |
| 955 |
msgstr "当然,同时修改的任何其他块都会被添加到重新同步数据集中。" |
| 956 |
|
| 957 |
#. type: Plain text |
| 958 |
#: internals.adoc:462 |
| 959 |
msgid "" |
| 960 |
"Re-synchronization may be also be paused and resumed manually with the " |
| 961 |
"indexterm:[drbdadm, pause-sync]`drbdadm pause-sync` and indexterm:[drbdadm, " |
| 962 |
"resume-sync]`drbdadm resume-sync` commands. You should, however, not do so " |
| 963 |
"light-heartedly -- interrupting re-synchronization leaves your secondary " |
| 964 |
"node's disk _Inconsistent_ longer than necessary." |
| 965 |
msgstr "" |
| 966 |
"使用indexterm:[drbdadm,pause-sync] `drbdadm pause-" |
| 967 |
"sync` 和indexterm:[drbdadm,resume-sync]`drbdadm resume-" |
| 968 |
"sync`命令也可以暂停并手动恢复重新同步。但是,您不应该心平气和地这样做——中断重新同步会使辅助节点的磁盘不一致的时间超过必要的时间。" |
| 969 |
|
| 970 |
#. type: Title === |
| 971 |
#: internals.adoc:464 |
| 972 |
#, no-wrap |
| 973 |
msgid "The Peer-Fencing interface" |
| 974 |
msgstr "节点围栏接口" |
| 975 |
|
| 976 |
#. type: Plain text |
| 977 |
#: internals.adoc:473 |
| 978 |
msgid "" |
| 979 |
"DRBD has an interface defined for fencingfootnote:[For a discussion about " |
| 980 |
"Fencing and STONITH, please see the corresponding Pacemaker page " |
| 981 |
"http://clusterlabs.org/doc/crm_fencing.html.] the peer node in case of the " |
| 982 |
"replication link being interrupted. The `drbd-peer-outdater` helper, bundled" |
| 983 |
" with Heartbeat, is the reference implementation for this interface. " |
| 984 |
"However, you may easily implement your own peer fencing helper program." |
| 985 |
msgstr "" |
| 986 |
"DRBD有一个为fencing定义的接口footnote:[有关围栏和STONITH的讨论,请参见相应的起搏器页面http://clusterlabs.org/doc/crm\\u" |
| 987 |
" Fencing.html.]如果复制链接被中断,则是对等节点。与Heartbeat捆绑在一起的“drbd peer " |
| 988 |
"outdater”助手是此接口的引用实现。但是,您可以轻松实现自己的同伴击剑助手程序。" |
| 989 |
|
| 990 |
#. type: Plain text |
| 991 |
#: internals.adoc:475 |
| 992 |
msgid "The fencing helper is invoked only in case" |
| 993 |
msgstr "只有在出现以下情况时才会调用击剑助手" |
| 994 |
|
| 995 |
#. type: Plain text |
| 996 |
#: internals.adoc:478 |
| 997 |
msgid "" |
| 998 |
"a `fence-peer` handler has been defined in the resource's (or `common`) " |
| 999 |
"`handlers` section, _and_" |
| 1000 |
msgstr "在资源的(或“common”)“handler s”部分中定义了“fence peer”处理程序,然后_" |
| 1001 |
|
| 1002 |
#. type: Plain text |
| 1003 |
#: internals.adoc:481 |
| 1004 |
msgid "" |
| 1005 |
"the `fencing` option for the resource is set to either `resource-only` or " |
| 1006 |
"`resource-and-stonith`, _and_" |
| 1007 |
msgstr "资源的“fencing”选项设置为“resource only”或“resource and stonith”_" |
| 1008 |
|
| 1009 |
#. type: Plain text |
| 1010 |
#: internals.adoc:486 |
| 1011 |
msgid "" |
| 1012 |
"the replication link is interrupted long enough for DRBDfootnote:[That means" |
| 1013 |
" e.g. a TCP timeout, the `ping-timeout`, or the kernel triggers a connection " |
| 1014 |
"abort e.g. because the network link goes down.] to detect a network failure." |
| 1015 |
msgstr "" |
| 1016 |
"复制链接中断的时间足够DRBDfootnote:[这意味着TCP超时、“ping超时”或内核触发连接中止,例如因为网络链接断开。]以检测网络故障。" |
| 1017 |
|
| 1018 |
#. type: Plain text |
| 1019 |
#: internals.adoc:491 |
| 1020 |
msgid "" |
| 1021 |
"The program or script specified as the `fence-peer` handler, when it is " |
| 1022 |
"invoked, has the `DRBD_RESOURCE` and `DRBD_PEER` environment variables " |
| 1023 |
"available. They contain the name of the affected DRBD resource and the " |
| 1024 |
"peer's hostname, respectively." |
| 1025 |
msgstr "" |
| 1026 |
"当调用指定为“fence " |
| 1027 |
"peer”处理程序的程序或脚本时,它具有“DRBD_RESOURCE”和“DRBD_peer”环境变量。它们分别包含受影响的DRBD资源的名称和对等主机名。" |
| 1028 |
|
| 1029 |
#. type: Plain text |
| 1030 |
#: internals.adoc:494 |
| 1031 |
msgid "" |
| 1032 |
"Any peer fencing helper program (or script) must return one of the following" |
| 1033 |
" exit codes:" |
| 1034 |
msgstr "任何对等围栏帮助程序(或脚本)必须返回以下退出代码之一:" |
| 1035 |
|
| 1036 |
#. type: Block title |
| 1037 |
#: internals.adoc:495 |
| 1038 |
#, no-wrap |
| 1039 |
msgid "`fence-peer` handler exit codes" |
| 1040 |
msgstr "`fence peer`handler退出代码" |
| 1041 |
|
| 1042 |
#. type: Table |
| 1043 |
#: internals.adoc:504 |
| 1044 |
#, no-wrap |
| 1045 |
msgid "" |
| 1046 |
"Exit code;Implication\n" |
| 1047 |
"3;Peer's disk state was already _Inconsistent_.\n" |
| 1048 |
"4;Peer's disk state was successfully set to _Outdated_ (or was _Outdated_ to begin with).\n" |
| 1049 |
"5;Connection to the peer node failed, peer could not be reached.\n" |
| 1050 |
"6;Peer refused to be outdated because the affected resource was in the primary role.\n" |
| 1051 |
"7;Peer node was successfully fenced off the cluster. This should never occur unless `fencing` is set to `resource-and-stonith` for the affected resource.\n" |
| 1052 |
msgstr "" |
| 1053 |
"Exit code;Implication\n" |
| 1054 |
"3;Peer's disk state was already _Inconsistent_.\n" |
| 1055 |
"4;Peer's disk state was successfully set to _Outdated_ (or was _Outdated_ to begin with).\n" |
| 1056 |
"5;Connection to the peer node failed, peer could not be reached.\n" |
| 1057 |
"6;Peer refused to be outdated because the affected resource was in the primary role.\n" |
| 1058 |
"7;Peer node was successfully fenced off the cluster. This should never occur unless `fencing` is set to `resource-and-stonith` for the affected resource.\n" |