1
0
forked from docs/doc-exports

DMS UMN 20240723 version

Reviewed-by: Antonova, Ekaterina <ekantono@noreply.gitea.eco.tsi-dev.otc-service.com>
Co-authored-by: Chen, Junjie <chenjunjie@huawei.com>
Co-committed-by: Chen, Junjie <chenjunjie@huawei.com>
This commit is contained in:
Chen, Junjie 2024-08-14 12:31:58 +00:00 committed by zuul
parent 03628e607a
commit 1588318a68
66 changed files with 2368 additions and 1298 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -15,7 +15,7 @@
<ul id="CreateUserAndGrantPolicy__ul94341340896"><li id="CreateUserAndGrantPolicy__en-us_topic_0000001489537442_li205729227246">Choose <strong id="CreateUserAndGrantPolicy__b1858910519411">Service List</strong> &gt; <strong id="CreateUserAndGrantPolicy__b1454646121811"></strong><strong id="CreateUserAndGrantPolicy__b1184811302187"></strong><strong id="CreateUserAndGrantPolicy__b1653110518187">Distributed Message Service</strong>. Then click <strong id="CreateUserAndGrantPolicy__b11369753161817">Create Instance</strong> on the console of DMS for Kafka. If a message appears indicating that you cannot perform the operation, the <strong id="CreateUserAndGrantPolicy__b575975610140">DMS ReadOnlyAccess</strong> policy is in effect.</li><li id="CreateUserAndGrantPolicy__en-us_topic_0000001489537442_li1857212212418">Choose <strong id="CreateUserAndGrantPolicy__b11309981431">Service List</strong> &gt; <strong id="CreateUserAndGrantPolicy__b13091810434">Elastic Volume Service</strong>. If a message appears indicating that you have insufficient permissions, the <strong id="CreateUserAndGrantPolicy__b1099919118614">DMS ReadOnlyAccess</strong> policy is in effect.</li><li id="CreateUserAndGrantPolicy__li888103121617">Choose <strong id="CreateUserAndGrantPolicy__b175372181515">Service List</strong> &gt; Distributed Message Service. If the Kafka instance list can be displayed, the <strong id="CreateUserAndGrantPolicy__b948089141716">DMS ReadOnlyAccess</strong><strong id="CreateUserAndGrantPolicy__b6176194316177"></strong> policy is in effect.</li></ul> <ul id="CreateUserAndGrantPolicy__ul94341340896"><li id="CreateUserAndGrantPolicy__en-us_topic_0000001489537442_li205729227246">Choose <strong id="CreateUserAndGrantPolicy__b1858910519411">Service List</strong> &gt; <strong id="CreateUserAndGrantPolicy__b1454646121811"></strong><strong id="CreateUserAndGrantPolicy__b1184811302187"></strong><strong id="CreateUserAndGrantPolicy__b1653110518187">Distributed Message Service</strong>. Then click <strong id="CreateUserAndGrantPolicy__b11369753161817">Create Instance</strong> on the console of DMS for Kafka. If a message appears indicating that you cannot perform the operation, the <strong id="CreateUserAndGrantPolicy__b575975610140">DMS ReadOnlyAccess</strong> policy is in effect.</li><li id="CreateUserAndGrantPolicy__en-us_topic_0000001489537442_li1857212212418">Choose <strong id="CreateUserAndGrantPolicy__b11309981431">Service List</strong> &gt; <strong id="CreateUserAndGrantPolicy__b13091810434">Elastic Volume Service</strong>. If a message appears indicating that you have insufficient permissions, the <strong id="CreateUserAndGrantPolicy__b1099919118614">DMS ReadOnlyAccess</strong> policy is in effect.</li><li id="CreateUserAndGrantPolicy__li888103121617">Choose <strong id="CreateUserAndGrantPolicy__b175372181515">Service List</strong> &gt; Distributed Message Service. If the Kafka instance list can be displayed, the <strong id="CreateUserAndGrantPolicy__b948089141716">DMS ReadOnlyAccess</strong><strong id="CreateUserAndGrantPolicy__b6176194316177"></strong> policy is in effect.</li></ul>
</li></ol> </li></ol>
</div> </div>
<div class="section" id="CreateUserAndGrantPolicy__en-us_topic_0170877288_section7529733164812"><h4 class="sectiontitle">Example Custom Policies</h4><p id="CreateUserAndGrantPolicy__p1595734521412">You can create custom policies to supplement the system-defined policies of DMS for Kafka. For details about actions supported in custom policies, see "Permissions Policies and Supported Actions" in <em id="CreateUserAndGrantPolicy__i1057741915557">Distributed Message Service API Reference</em></p> <div class="section" id="CreateUserAndGrantPolicy__en-us_topic_0170877288_section7529733164812"><h4 class="sectiontitle">Example Custom Policies</h4><p id="CreateUserAndGrantPolicy__p1595734521412">You can create custom policies to supplement the system-defined policies of DMS for Kafka. For details about actions supported in custom policies, see <a href="https://docs.otc.t-systems.com/en-us/api/dms/api-grant-policy.html" target="_blank" rel="noopener noreferrer">Permissions Policies and Supported Actions</a>"Permissions Policies and Supported Actions" in <em id="CreateUserAndGrantPolicy__i1057741915557">Distributed Message Service API Reference</em></p>
<p id="CreateUserAndGrantPolicy__p1419391112413">To create a custom policy, choose either visual editor or JSON.</p> <p id="CreateUserAndGrantPolicy__p1419391112413">To create a custom policy, choose either visual editor or JSON.</p>
<ul id="CreateUserAndGrantPolicy__ul181934111948"><li id="CreateUserAndGrantPolicy__li819351117414">Visual editor: Select cloud services, actions, resources, and request conditions. This does not require knowledge of policy syntax.</li><li id="CreateUserAndGrantPolicy__li019313113419">JSON: Create a JSON policy or edit an existing one.</li></ul> <ul id="CreateUserAndGrantPolicy__ul181934111948"><li id="CreateUserAndGrantPolicy__li819351117414">Visual editor: Select cloud services, actions, resources, and request conditions. This does not require knowledge of policy syntax.</li><li id="CreateUserAndGrantPolicy__li019313113419">JSON: Create a JSON policy or edit an existing one.</li></ul>
<p id="CreateUserAndGrantPolicy__p1119431112414">For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/iam/iam_01_0016.html" target="_blank" rel="noopener noreferrer">Creating a Custom Policy</a>. The following lists examples of common DMS for Kafka custom policies.</p> <p id="CreateUserAndGrantPolicy__p1119431112414">For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/iam/iam_01_0016.html" target="_blank" rel="noopener noreferrer">Creating a Custom Policy</a>. The following lists examples of common DMS for Kafka custom policies.</p>

View File

@ -6,7 +6,7 @@
<div class="section" id="Kafka-client-best-practice__section65310184020"><h4 class="sectiontitle">Producers</h4><ol id="Kafka-client-best-practice__ol53887211062"><li id="Kafka-client-best-practice__li9388102113614">Synchronous replication: Set <strong id="Kafka-client-best-practice__b105761128192612">acks</strong> to <strong id="Kafka-client-best-practice__b1576122812612">all</strong>.</li><li id="Kafka-client-best-practice__li43881121866">Retry message sending: Set <strong id="Kafka-client-best-practice__b84721347102619">retries</strong> to <strong id="Kafka-client-best-practice__b24731747142611">3</strong>.</li><li id="Kafka-client-best-practice__li33888211962">Optimize message sending: For latency-sensitive messages, set <strong id="Kafka-client-best-practice__b1575215511269">linger.ms</strong> to <strong id="Kafka-client-best-practice__b175225117261">0</strong>. For latency-insensitive messages, set <strong id="Kafka-client-best-practice__b11162568262">linger.ms</strong> to a value ranging from <strong id="Kafka-client-best-practice__b1716125642616">100</strong> to <strong id="Kafka-client-best-practice__b16171156112618">1000</strong>.</li><li id="Kafka-client-best-practice__li133881421268">Ensure that the producer has sufficient JVM memory to avoid blockages.</li><li id="Kafka-client-best-practice__li18921123181613">Set the timestamp to the local time. Messages will fail to age if the timestamp is a future time.</li></ol> <div class="section" id="Kafka-client-best-practice__section65310184020"><h4 class="sectiontitle">Producers</h4><ol id="Kafka-client-best-practice__ol53887211062"><li id="Kafka-client-best-practice__li9388102113614">Synchronous replication: Set <strong id="Kafka-client-best-practice__b105761128192612">acks</strong> to <strong id="Kafka-client-best-practice__b1576122812612">all</strong>.</li><li id="Kafka-client-best-practice__li43881121866">Retry message sending: Set <strong id="Kafka-client-best-practice__b84721347102619">retries</strong> to <strong id="Kafka-client-best-practice__b24731747142611">3</strong>.</li><li id="Kafka-client-best-practice__li33888211962">Optimize message sending: For latency-sensitive messages, set <strong id="Kafka-client-best-practice__b1575215511269">linger.ms</strong> to <strong id="Kafka-client-best-practice__b175225117261">0</strong>. For latency-insensitive messages, set <strong id="Kafka-client-best-practice__b11162568262">linger.ms</strong> to a value ranging from <strong id="Kafka-client-best-practice__b1716125642616">100</strong> to <strong id="Kafka-client-best-practice__b16171156112618">1000</strong>.</li><li id="Kafka-client-best-practice__li133881421268">Ensure that the producer has sufficient JVM memory to avoid blockages.</li><li id="Kafka-client-best-practice__li18921123181613">Set the timestamp to the local time. Messages will fail to age if the timestamp is a future time.</li></ol>
</div> </div>
<div class="section" id="Kafka-client-best-practice__section785814360014"><h4 class="sectiontitle">Topics</h4><p id="Kafka-client-best-practice__p178951621165816">Recommended topic configurations: Use 3 replicas, enable synchronous replication, and set the minimum number of in-sync replicas to 2. The number of in-sync replicas cannot be the same as the number of replicas of the topic. Otherwise, if one replica is unavailable, messages cannot be produced.</p> <div class="section" id="Kafka-client-best-practice__section785814360014"><h4 class="sectiontitle">Topics</h4><p id="Kafka-client-best-practice__p178951621165816">Recommended topic configurations: Use 3 replicas, enable synchronous replication, and set the minimum number of in-sync replicas to 2. The number of in-sync replicas cannot be the same as the number of replicas of the topic. Otherwise, if one replica is unavailable, messages cannot be produced.</p>
<p id="Kafka-client-best-practice__p07361810728">You can enable or disable automatic topic creation. If automatic topic creation is enabled, the system automatically creates a topic when a message is created in or retrieved from a topic that does not exist. This topic has the following default settings: 3 partitions, 3 replicas, aging time 72 hours, synchronous replication and flushing disabled, <strong id="Kafka-client-best-practice__b167644278297">CreateTime</strong> message timestamp, and maximum 10,485,760 bytes message size.</p> <p id="Kafka-client-best-practice__p07361810728">You can enable or disable automatic topic creation. If automatic topic creation is enabled, the system automatically creates a topic when a message is produced in or consumed from a topic that does not exist. This topic has the following default settings: 3 partitions, 3 replicas, aging time 72 hours, synchronous replication and flushing disabled, <strong id="Kafka-client-best-practice__b167644278297">CreateTime</strong> message timestamp, and maximum 10,485,760 bytes message size.</p>
</div> </div>
<div class="section" id="Kafka-client-best-practice__section194821855405"><h4 class="sectiontitle">Others</h4><p id="Kafka-client-best-practice__p13895172119589">Maximum number of connections: 3000</p> <div class="section" id="Kafka-client-best-practice__section194821855405"><h4 class="sectiontitle">Others</h4><p id="Kafka-client-best-practice__p13895172119589">Maximum number of connections: 3000</p>
<p id="Kafka-client-best-practice__p9895521195815">Maximum size of a message: 10 MB</p> <p id="Kafka-client-best-practice__p9895521195815">Maximum size of a message: 10 MB</p>

File diff suppressed because it is too large Load Diff

View File

@ -13,18 +13,18 @@
</thead> </thead>
<tbody><tr id="TagManagement__row43636201815"><td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.1 "><p id="TagManagement__p336313201814">Tag key</p> <tbody><tr id="TagManagement__row43636201815"><td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.1 "><p id="TagManagement__p336313201814">Tag key</p>
</td> </td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.2 "><ul id="TagManagement__ul133310231694"><li id="TagManagement__li833315236915">Cannot be left blank.</li><li id="TagManagement__li1733312319916">Must be unique for the same instance.</li><li id="TagManagement__li071752814194">Can contain 1 to 128 characters.</li><li id="TagManagement__li187665401268">Can contain letters, digits, spaces, and special characters _.:=+-@ : = + - @</li><li id="TagManagement__li1933311235916">Cannot start or end with a space.</li></ul> <td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.2 "><ul id="TagManagement__ul133310231694"><li id="TagManagement__li833315236915">Cannot be left blank.</li><li id="TagManagement__li1733312319916">Must be unique for the same instance.</li><li id="TagManagement__li071752814194">Can contain 1 to 128 characters.</li><li id="TagManagement__li187665401268">Can contain letters, digits, spaces, and special characters _.:=+-@ : = + - @</li><li id="TagManagement__li1933311235916">Cannot start or end with a space.</li><li id="TagManagement__li10155182510220">Cannot start with <strong id="TagManagement__b20870191531115">_sys_</strong>.</li></ul>
</td> </td>
</tr> </tr>
<tr id="TagManagement__row193632201781"><td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.1 "><p id="TagManagement__p736315201282">Tag value</p> <tr id="TagManagement__row193632201781"><td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.1 "><p id="TagManagement__p736315201282">Tag value</p>
</td> </td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.2 "><ul id="TagManagement__ul1216717306916"><li id="TagManagement__li2279188184015">Can contain 0 to 255 characters.</li><li id="TagManagement__li1169310184412">Can contain letters, digits, spaces, and special characters _.:=+-@ : = + - @</li><li id="TagManagement__li111671630290">Cannot start or end with a space.</li></ul> <td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.3.1.2 "><ul id="TagManagement__ul1216717306916"><li id="TagManagement__li2279188184015">Can contain 0 to 255 characters.</li><li id="TagManagement__li1169310184412">Can contain letters, digits, spaces, and special characters _.:=+-@ : = + - @</li><li id="TagManagement__li358452535110">Cannot start or end with a space in instance creation.</li></ul>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
<div class="section" id="TagManagement__section184051819123810"><h4 class="sectiontitle">Configuring Kafka Instance Tags</h4><ol id="TagManagement__ol3625154473819"><li id="TagManagement__li68751861819"><span>Log in to the console.</span></li><li id="TagManagement__li189561034172215"><span>Click <strong id="TagManagement__b14774858509570">Service List</strong> and choose <strong id="TagManagement__b2055053229570">Application</strong> &gt; <strong id="TagManagement__b18820194239570">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="TagManagement__li1489192711531"><span>Click the name of an instance.</span></li><li id="TagManagement__li189991214141019"><span>In the navigation pane on the left, choose <strong id="TagManagement__b365705373516">Tags</strong>.</span><p><p id="TagManagement__p16898133410247">View the tags of the instance.</p> <div class="section" id="TagManagement__section184051819123810"><h4 class="sectiontitle">Procedure</h4><ol id="TagManagement__ol3625154473819"><li id="TagManagement__li68751861819"><span>Log in to the console.</span></li><li id="TagManagement__li189561034172215"><span>Click <strong id="TagManagement__b14774858509570">Service List</strong> and choose <strong id="TagManagement__b2055053229570">Application</strong> &gt; <strong id="TagManagement__b18820194239570">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="TagManagement__li1489192711531"><span>Click the name of an instance.</span></li><li id="TagManagement__li189991214141019"><span>In the navigation pane on the left, choose <strong id="TagManagement__b365705373516">Tags</strong>.</span><p><p id="TagManagement__p16898133410247">View the tags of the instance.</p>
</p></li><li id="TagManagement__li658882719391"><span>Perform the following operations as required:</span><p><ul id="TagManagement__ul143482985319"><li id="TagManagement__li184341129115317">Add a tag<ol type="a" id="TagManagement__ol15591750115315"><li id="TagManagement__li165913500532">Click <strong id="TagManagement__b192779879635755">Create/Delete Tag</strong>.</li><li id="TagManagement__li75973412544">Enter a tag key and a tag value, and click <strong id="TagManagement__b17953037173518">Add</strong>.<p id="TagManagement__p1580923115586">If you have predefined tags, select a predefined pair of tag key and value, and click <strong id="TagManagement__b99061025123610">Add</strong>.</p> </p></li><li id="TagManagement__li658882719391"><span>Perform the following operations as required:</span><p><ul id="TagManagement__ul143482985319"><li id="TagManagement__li184341129115317">Add a tag<ol type="a" id="TagManagement__ol15591750115315"><li id="TagManagement__li165913500532">Click <strong id="TagManagement__b192779879635755">Create/Delete Tag</strong>.</li><li id="TagManagement__li75973412544">Enter a tag key and a tag value, and click <strong id="TagManagement__b17953037173518">Add</strong>.<p id="TagManagement__p1580923115586">If you have predefined tags, select a predefined pair of tag key and value, and click <strong id="TagManagement__b99061025123610">Add</strong>.</p>
</li><li id="TagManagement__li1217122155815">Click <strong id="TagManagement__b13934927193610">OK</strong>.</li></ol> </li><li id="TagManagement__li1217122155815">Click <strong id="TagManagement__b13934927193610">OK</strong>.</li></ol>
</li><li id="TagManagement__li1931437145316">Delete a tag<p id="TagManagement__p10415343125317"><a name="TagManagement__li1931437145316"></a><a name="li1931437145316"></a>Delete a tag using either of the following methods:</p> </li><li id="TagManagement__li1931437145316">Delete a tag<p id="TagManagement__p10415343125317"><a name="TagManagement__li1931437145316"></a><a name="li1931437145316"></a>Delete a tag using either of the following methods:</p>

Binary file not shown.

After

Width:  |  Height:  |  Size: 348 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

View File

@ -1,56 +1,55 @@
<a name="kafka-bp-migration"></a><a name="kafka-bp-migration"></a> <a name="kafka-bp-migration"></a><a name="kafka-bp-migration"></a>
<h1 class="topictitle1">Kafka Data Migration Overview</h1> <h1 class="topictitle1">Kafka Data Migration Overview</h1>
<div id="body0000001880476976"><div class="section" id="kafka-bp-migration__section161785186531"><h4 class="sectiontitle">Scenario</h4><p id="kafka-bp-migration__p104021942510">You can migrate Kafka services to connect message producers and consumers to a new Kafka instance and can even migrate persisted message data to the new Kafka instance. Kafka services can be migrated in the following two scenarios:</p> <div id="body0000001880476976"><p id="kafka-bp-migration__p104021942510">You can migrate Kafka services to connect message producers and consumers to a new Kafka instance and can even migrate persisted message data to the new Kafka instance. Kafka services can be migrated in the following two scenarios:</p>
<ul id="kafka-bp-migration__ul955893365311"><li id="kafka-bp-migration__li20807548639">Migrating services to the cloud without downtime<p id="kafka-bp-migration__p23722521738"><a name="kafka-bp-migration__li20807548639"></a><a name="li20807548639"></a>Services that have high requirements on continuity must be smoothly migrated to the cloud because they cannot afford a long downtime.</p> <ul id="kafka-bp-migration__ul955893365311"><li id="kafka-bp-migration__li20807548639">Migrating services to the cloud without downtime<p id="kafka-bp-migration__p23722521738"><a name="kafka-bp-migration__li20807548639"></a><a name="li20807548639"></a>Services that have high requirements on continuity must be smoothly migrated to the cloud because they cannot afford a long downtime.</p>
</li><li id="kafka-bp-migration__li19558173316537">Re-deploying services on the cloud<p id="kafka-bp-migration__p1955853315314"><a name="kafka-bp-migration__li19558173316537"></a><a name="li19558173316537"></a>A Kafka instance deployed within an AZ is not capable of cross-AZ disaster recovery. For higher reliability, you can re-deploy services to an instance that is deployed across AZs.</p> </li><li id="kafka-bp-migration__li19558173316537">Re-deploying services on the cloud<p id="kafka-bp-migration__p1955853315314"><a name="kafka-bp-migration__li19558173316537"></a><a name="li19558173316537"></a>A Kafka instance deployed within an AZ is not capable of cross-AZ disaster recovery. For higher reliability, you can re-deploy services to an instance that is deployed across AZs.</p>
</li></ul> </li></ul>
</div>
<div class="section" id="kafka-bp-migration__section1284410782819"><h4 class="sectiontitle">Preparation</h4><ol id="kafka-bp-migration__ol12783651202016"><li id="kafka-bp-migration__li15761833132812">Configure the network environment.<p id="kafka-bp-migration__p5857104883517"><a name="kafka-bp-migration__li15761833132812"></a><a name="li15761833132812"></a>A Kafka instance can be accessed within a VPC or over a public network. For public network access, the producer and consumer must have public access permissions, and the following security group rules must be configured.</p> <div class="section" id="kafka-bp-migration__section1284410782819"><h4 class="sectiontitle">Preparation</h4><ol id="kafka-bp-migration__ol12783651202016"><li id="kafka-bp-migration__li15761833132812">Configure the network environment.<p id="kafka-bp-migration__p5857104883517"><a name="kafka-bp-migration__li15761833132812"></a><a name="li15761833132812"></a>A Kafka instance can be accessed within a VPC or over a public network. For public network access, the producer and consumer must have public access permissions, and the following security group rules must be configured.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kafka-bp-migration__table221215285815" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Security group rules</caption><thead align="left"><tr id="kafka-bp-migration__row12120281784"><th align="left" class="cellrowborder" valign="top" width="13.211321132113211%" id="mcps1.3.2.2.1.2.2.6.1.1"><p id="kafka-bp-migration__p82125284818">Direction</p> <div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kafka-bp-migration__table221215285815" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Security group rules</caption><thead align="left"><tr id="kafka-bp-migration__row12120281784"><th align="left" class="cellrowborder" valign="top" width="13.211321132113211%" id="mcps1.3.3.2.1.2.2.6.1.1"><p id="kafka-bp-migration__p82125284818">Direction</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="15.151515151515152%" id="mcps1.3.2.2.1.2.2.6.1.2"><p id="kafka-bp-migration__p521314281811">Protocol</p> <th align="left" class="cellrowborder" valign="top" width="15.151515151515152%" id="mcps1.3.3.2.1.2.2.6.1.2"><p id="kafka-bp-migration__p521314281811">Protocol</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="15.151515151515152%" id="mcps1.3.2.2.1.2.2.6.1.3"><p id="kafka-bp-migration__p1121312289817">Port</p> <th align="left" class="cellrowborder" valign="top" width="15.151515151515152%" id="mcps1.3.3.2.1.2.2.6.1.3"><p id="kafka-bp-migration__p1121312289817">Port</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="18.02180218021802%" id="mcps1.3.2.2.1.2.2.6.1.4"><p id="kafka-bp-migration__p1421310286815">Source</p> <th align="left" class="cellrowborder" valign="top" width="18.02180218021802%" id="mcps1.3.3.2.1.2.2.6.1.4"><p id="kafka-bp-migration__p1421310286815">Source</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="38.46384638463846%" id="mcps1.3.2.2.1.2.2.6.1.5"><p id="kafka-bp-migration__p81371838802">Description</p> <th align="left" class="cellrowborder" valign="top" width="38.46384638463846%" id="mcps1.3.3.2.1.2.2.6.1.5"><p id="kafka-bp-migration__p81371838802">Description</p>
</th> </th>
</tr> </tr>
</thead> </thead>
<tbody><tr id="kafka-bp-migration__row1421316282820"><td class="cellrowborder" valign="top" width="13.211321132113211%" headers="mcps1.3.2.2.1.2.2.6.1.1 "><p id="kafka-bp-migration__p2021319281816">Inbound</p> <tbody><tr id="kafka-bp-migration__row1421316282820"><td class="cellrowborder" valign="top" width="13.211321132113211%" headers="mcps1.3.3.2.1.2.2.6.1.1 "><p id="kafka-bp-migration__p2021319281816">Inbound</p>
</td> </td>
<td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.2.2.1.2.2.6.1.2 "><p id="kafka-bp-migration__p1021352815816">TCP</p> <td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.3.2.1.2.2.6.1.2 "><p id="kafka-bp-migration__p1021352815816">TCP</p>
</td> </td>
<td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.2.2.1.2.2.6.1.3 "><p id="kafka-bp-migration__p1921320288819">9094</p> <td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.3.2.1.2.2.6.1.3 "><p id="kafka-bp-migration__p1921320288819">9094</p>
</td> </td>
<td class="cellrowborder" valign="top" width="18.02180218021802%" headers="mcps1.3.2.2.1.2.2.6.1.4 "><p id="kafka-bp-migration__p1121316281483">0.0.0.0/0</p> <td class="cellrowborder" valign="top" width="18.02180218021802%" headers="mcps1.3.3.2.1.2.2.6.1.4 "><p id="kafka-bp-migration__p1121316281483">0.0.0.0/0</p>
</td> </td>
<td class="cellrowborder" valign="top" width="38.46384638463846%" headers="mcps1.3.2.2.1.2.2.6.1.5 "><p id="kafka-bp-migration__p151381038801">Accessing a Kafka instance in a public network (in plaintext)</p> <td class="cellrowborder" valign="top" width="38.46384638463846%" headers="mcps1.3.3.2.1.2.2.6.1.5 "><p id="kafka-bp-migration__p151381038801">Accessing a Kafka instance in a public network (in plaintext)</p>
</td> </td>
</tr> </tr>
<tr id="kafka-bp-migration__row131381384015"><td class="cellrowborder" valign="top" width="13.211321132113211%" headers="mcps1.3.2.2.1.2.2.6.1.1 "><p id="kafka-bp-migration__p2138123810010">Inbound</p> <tr id="kafka-bp-migration__row131381384015"><td class="cellrowborder" valign="top" width="13.211321132113211%" headers="mcps1.3.3.2.1.2.2.6.1.1 "><p id="kafka-bp-migration__p2138123810010">Inbound</p>
</td> </td>
<td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.2.2.1.2.2.6.1.2 "><p id="kafka-bp-migration__p3138538509">TCP</p> <td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.3.2.1.2.2.6.1.2 "><p id="kafka-bp-migration__p3138538509">TCP</p>
</td> </td>
<td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.2.2.1.2.2.6.1.3 "><p id="kafka-bp-migration__p21387381002">9095</p> <td class="cellrowborder" valign="top" width="15.151515151515152%" headers="mcps1.3.3.2.1.2.2.6.1.3 "><p id="kafka-bp-migration__p21387381002">9095</p>
</td> </td>
<td class="cellrowborder" valign="top" width="18.02180218021802%" headers="mcps1.3.2.2.1.2.2.6.1.4 "><p id="kafka-bp-migration__p151384381409">0.0.0.0/0</p> <td class="cellrowborder" valign="top" width="18.02180218021802%" headers="mcps1.3.3.2.1.2.2.6.1.4 "><p id="kafka-bp-migration__p151384381409">0.0.0.0/0</p>
</td> </td>
<td class="cellrowborder" valign="top" width="38.46384638463846%" headers="mcps1.3.2.2.1.2.2.6.1.5 "><p id="kafka-bp-migration__p1345124955213">Accessing a Kafka instance in a public network (in ciphertext)</p> <td class="cellrowborder" valign="top" width="38.46384638463846%" headers="mcps1.3.3.2.1.2.2.6.1.5 "><p id="kafka-bp-migration__p1345124955213">Accessing a Kafka instance in a public network (in ciphertext)</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
</li><li id="kafka-bp-migration__li172712547204">Create a Kafka instance.<p id="kafka-bp-migration__p10567954132013"><a name="kafka-bp-migration__li172712547204"></a><a name="li172712547204"></a>The specifications of the new instance cannot be lower than the original specifications. For more information, see <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</p> </li><li id="kafka-bp-migration__li172712547204">Create the target Kafka instance.<p id="kafka-bp-migration__p10567954132013"><a name="kafka-bp-migration__li172712547204"></a><a name="li172712547204"></a>The specifications of the target instance cannot be lower than the original specifications. For more information, see <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</p>
</li><li id="kafka-bp-migration__li0611153218296">Create a topic.<p id="kafka-bp-migration__p1245253311294"><a name="kafka-bp-migration__li0611153218296"></a><a name="li0611153218296"></a>Create a topic with the same configurations as the original Kafka instance, including the topic name, number of replicas, number of partitions, message aging time, and whether to enable synchronous replication and flushing. For more information, see <a href="kafka-ug-180604018.html">Creating a Kafka Topic</a>.</p> </li><li id="kafka-bp-migration__li0611153218296">Create a topic in the target Kafka instance.<p id="kafka-bp-migration__p1245253311294"><a name="kafka-bp-migration__li0611153218296"></a><a name="li0611153218296"></a>Create a topic with the same configurations as the original Kafka instance, including the topic name, number of replicas, number of partitions, message aging time, and whether to enable synchronous replication and flushing. For more information, see <a href="kafka-ug-180604018.html">Creating a Kafka Topic</a>.</p>
</li></ol> </li></ol>
</div> </div>
<div class="section" id="kafka-bp-migration__section66351235101020"><h4 class="sectiontitle">Migration Scheme 1: Migrating the Production First</h4><p id="kafka-bp-migration__p132040473113">Migrate the message production service to the new Kafka instance. After migration, the original Kafka instance will no longer produce messages. After all messages of the original Kafka instance are consumed, migrate the message consumption service to the new Kafka instance to consume messages of this instance.</p> <div class="section" id="kafka-bp-migration__section66351235101020"><h4 class="sectiontitle">Migration Scheme 1: Migrating the Production First</h4><p id="kafka-bp-migration__p132040473113">Migrate the message production service to the new Kafka instance. After migration, the original Kafka instance will no longer produce messages. After all messages of the original Kafka instance are consumed, migrate the message consumption service to the new Kafka instance to consume messages of this instance.</p>
<ol id="kafka-bp-migration__ol102566315910"><li id="kafka-bp-migration__li125618316592"><span>Change the Kafka connection address of the producer to that of the new Kafka instance.</span></li><li id="kafka-bp-migration__li625673175912"><span>Restart the production service so that the producer can send new messages to the new Kafka instance.</span></li><li id="kafka-bp-migration__li1925613325914"><span>Check the consumption progress of each consumer group in the original Kafka instance until all data in the original Kafka instance is consumed.</span></li><li id="kafka-bp-migration__li82565385913"><span>Change the Kafka connection addresses of the consumers to those of the new Kafka instance.</span></li><li id="kafka-bp-migration__li13256133185917"><span>Restart the consumption service so that consumers can consume messages from the new Kafka instance.</span></li><li id="kafka-bp-migration__li12561138598"><span>Check whether consumers consume messages properly from the new Kafka instance.</span></li><li id="kafka-bp-migration__li1325673145918"><span>The migration is complete.</span></li></ol> <ol id="kafka-bp-migration__ol102566315910"><li id="kafka-bp-migration__li125618316592"><span>Change the Kafka connection address of the producer to that of the new Kafka instance.</span></li><li id="kafka-bp-migration__li625673175912"><span>Restart the production service so that the producer can send new messages to the new Kafka instance.</span></li><li id="kafka-bp-migration__li1925613325914"><a name="kafka-bp-migration__li1925613325914"></a><a name="li1925613325914"></a><span>Check the consumption progress of each consumer group in the original Kafka instance until all data in the original Kafka instance is consumed.</span></li><li id="kafka-bp-migration__li82565385913"><span>Change the Kafka connection addresses of the consumers to those of the new Kafka instance.</span></li><li id="kafka-bp-migration__li13256133185917"><span>Restart the consumption service so that consumers can consume messages from the new Kafka instance.</span></li><li id="kafka-bp-migration__li12561138598"><span>Check whether consumers consume messages properly from the new Kafka instance.</span></li><li id="kafka-bp-migration__li1325673145918"><span>The migration is complete.</span></li></ol>
<p id="kafka-bp-migration__p1456915924519">This is a common migration scheme. It is simple and easy to control on the service side. During the migration, the message sequence is ensured, so this scheme is <strong id="kafka-bp-migration__b167441119142616">suitable for scenarios with strict requirements on the message sequence</strong>. However, latency may occur because there is a period when you have to wait for all data to be consumed.</p> <p id="kafka-bp-migration__p1456915924519">This is a common migration scheme. It is simple and easy to control on the service side. During the migration, the message sequence is ensured, so this scheme is <strong id="kafka-bp-migration__b167441119142616">suitable for scenarios with strict requirements on the message sequence</strong>. However, latency may occur because there is a period when you have to wait for all data to be consumed.</p>
</div> </div>
<div class="section" id="kafka-bp-migration__section163553541014"><h4 class="sectiontitle">Migration Scheme 2: Migrating the Production Later</h4><p id="kafka-bp-migration__p10292175955518">Use multiple consumers for the consumption service. Some consume messages from the original Kafka instance, and others consume messages from the new Kafka instances. Then, migrate the production service to the new Kafka instance so that all messages can be consumed in time.</p> <div class="section" id="kafka-bp-migration__section163553541014"><h4 class="sectiontitle">Migration Scheme 2: Migrating the Production Later</h4><p id="kafka-bp-migration__p10292175955518">Use multiple consumers for the consumption service. Some consume messages from the original Kafka instance, and others consume messages from the new Kafka instances. Then, migrate the production service to the new Kafka instance so that all messages can be consumed in time.</p>
@ -59,7 +58,12 @@
</p></li><li id="kafka-bp-migration__li34113261704"><span>Change the Kafka connection address of the producer to that of the new Kafka instance.</span></li><li id="kafka-bp-migration__li3417261805"><span>Restart the producer client to migrate the production service to the new Kafka instance.</span></li><li id="kafka-bp-migration__li141826403"><span>After the production service is migrated, check whether the consumption service connected to the new Kafka instance is normal.</span></li><li id="kafka-bp-migration__li134116261701"><span>After all data in the original Kafka is consumed, close the original consumption clients.</span></li><li id="kafka-bp-migration__li9418265012"><span>The migration is complete.</span></li></ol> </p></li><li id="kafka-bp-migration__li34113261704"><span>Change the Kafka connection address of the producer to that of the new Kafka instance.</span></li><li id="kafka-bp-migration__li3417261805"><span>Restart the producer client to migrate the production service to the new Kafka instance.</span></li><li id="kafka-bp-migration__li141826403"><span>After the production service is migrated, check whether the consumption service connected to the new Kafka instance is normal.</span></li><li id="kafka-bp-migration__li134116261701"><span>After all data in the original Kafka is consumed, close the original consumption clients.</span></li><li id="kafka-bp-migration__li9418265012"><span>The migration is complete.</span></li></ol>
<p id="kafka-bp-migration__p383015239103">In this scheme, the migration process is controlled by services. For a certain period of time, the consumption service consumes messages from both the original and new Kafka instances. Before the migration, message consumption from the new Kafka instance has already started, so there is no latency. However, early on in the migration, data is consumed from both the original and new Kafka instances, so the messages may not be consumed in the order that they are produced. This scheme is <strong id="kafka-bp-migration__b69670112920">suitable for services that require low latency but do not require strict message sequence</strong>.</p> <p id="kafka-bp-migration__p383015239103">In this scheme, the migration process is controlled by services. For a certain period of time, the consumption service consumes messages from both the original and new Kafka instances. Before the migration, message consumption from the new Kafka instance has already started, so there is no latency. However, early on in the migration, data is consumed from both the original and new Kafka instances, so the messages may not be consumed in the order that they are produced. This scheme is <strong id="kafka-bp-migration__b69670112920">suitable for services that require low latency but do not require strict message sequence</strong>.</p>
</div> </div>
<div class="section" id="kafka-bp-migration__section118231336159"><h4 class="sectiontitle">How Do I Migrate Persisted Data Along with Services?</h4><p id="kafka-bp-migration__p1154412511518">You can migrate consumed data from the original instance to a new instance by using the open-source tool <a href="https://github.com/miguecoll/kafka-mirror-maker" target="_blank" rel="noopener noreferrer">MirrorMaker</a>. This tool mirrors the original Kafka producer and consumer into new ones and migrates data to the new Kafka instance.</p> <div class="section" id="kafka-bp-migration__section20636193514107"><h4 class="sectiontitle">Migration Scheme 3: Migrating the Consumption First</h4><p id="kafka-bp-migration__p1678612717184">Use Smart Connect to synchronize the two Kafka instances, migrate the consumer first and then the producer to the new Kafka instance.</p>
<ol id="kafka-bp-migration__ol989251919189"><li id="kafka-bp-migration__li198921919131816"><span>Create a Smart Connect task for Kafka data replication. For details, see <a href="kafka-ug-0034.html">Replicating Kafka Instance Data</a>.</span></li><li id="kafka-bp-migration__li1947982952418"><span>On the <strong id="kafka-bp-migration__b48881092308">Message Query</strong> page of the Kafka console, check whether the latest messages and the synchronization progress of both Kafka instances are consistent. For details, see <a href="kafka-ug-190904001.html">Viewing Kafka Messages</a>.</span><p><ul id="kafka-bp-migration__ul8371183742315"><li id="kafka-bp-migration__li133710373231">Yes: Go to <a href="#kafka-bp-migration__li1925613325914">3</a>.</li><li id="kafka-bp-migration__li0305124915232">No: Check whether the synchronized data per minute of both Kafka instances is normal. If yes, wait for the synchronization progress of both Kafka instances to be consistent, then go to <a href="#kafka-bp-migration__li1925613325914">3</a>.</li></ul>
</p></li><li id="kafka-bp-migration__li1388980192810"><span>Change the Kafka connection addresses of the consumers to those of the new Kafka instance.</span></li><li id="kafka-bp-migration__li11889130152814"><span>Restart the consumption service so that consumers can consume messages from the new Kafka instance.</span></li><li id="kafka-bp-migration__li754993211278"><span>Check whether consumers consume messages properly from the new Kafka instance.</span></li><li id="kafka-bp-migration__li412301715295"><span>Change the Kafka connection address of the producer to that of the new Kafka instance.</span></li><li id="kafka-bp-migration__li10347184972910"><span>Restart the producer client to migrate the production service to the new Kafka instance.</span></li><li id="kafka-bp-migration__li853892113308"><span>After the production service is migrated, check whether the consumption service connected to the new Kafka instance is normal.</span></li><li id="kafka-bp-migration__li49330113516"><span>The migration is complete.</span></li></ol>
<p id="kafka-bp-migration__p1182384111146">This scheme uses Smart Connect to synchronize the source and target data in real time. However, the consumption progress is synchronized in batches. The consumption progress on the source and target partition may vary from 0 to 100. As a result, some messages are repeatedly consumed. This scheme applies to services where the message production must continue, end-to-end latency must be low, and repeated consumption can be tolerated.</p>
</div>
<div class="section" id="kafka-bp-migration__section118231336159"><h4 class="sectiontitle">How Do I Migrate Persisted Data Along with Services?</h4><p id="kafka-bp-migration__p1255416262446">You can migrate consumed data from the original instance to a new instance by using Smart Connect. This tool mirrors the original Kafka producer and consumer into new ones and migrates data to the new Kafka instance. For details, see <a href="kafka-ug-0034.html">Replicating Kafka Instance Data</a>.</p>
<p id="kafka-bp-migration__p16312115832318">Note that each cloud Kafka instance stores data in three replicas. Therefore, the storage space of the new instance should be three times that of the original single-replica message storage.</p> <p id="kafka-bp-migration__p16312115832318">Note that each cloud Kafka instance stores data in three replicas. Therefore, the storage space of the new instance should be three times that of the original single-replica message storage.</p>
</div> </div>
</div> </div>

View File

@ -1,8 +1,9 @@
<a name="kafka-dnat"></a><a name="kafka-dnat"></a> <a name="kafka-dnat"></a><a name="kafka-dnat"></a>
<h1 class="topictitle1">Accessing Kafka in a Public Network Using DNAT</h1> <h1 class="topictitle1">Accessing Kafka in a Public Network Using DNAT</h1>
<div id="body0000001281228876"><div class="section" id="kafka-dnat__section185011081712"><h4 class="sectiontitle">Scenario</h4><p id="kafka-dnat__p6619128711">You can use destination NAT (DNAT) to access a Kafka instance so that the instance can provide services on the public network through port mapping.</p> <div id="body0000001281228876"><p id="kafka-dnat__p19683172804311">Enable public access in either of the following ways:</p>
</div> <ul id="kafka-dnat__ul348793544318"><li id="kafka-dnat__li9674183914311">On the Kafka console, access Kafka instances using EIPs. For details, see <a href="kafka-ug-0319001.html">Configuring Kafka Public Access</a>.</li><li id="kafka-dnat__li94871335104318">Configure port mapping from EIPs to specified instance ports using destination NAT (DNAT).</li></ul>
<p id="kafka-dnat__p152752135016">This section describes how to access Kafka over a public network using DNAT.</p>
<div class="section" id="kafka-dnat__section10453192819399"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-dnat__p1031515311514">You have created EIPs. The number of EIPs is the same as the number of brokers in the Kafka instance. For details about how to create an EIP, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/eip/eip_0002.html" target="_blank" rel="noopener noreferrer">Assigning an EIP</a>.</p> <div class="section" id="kafka-dnat__section10453192819399"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-dnat__p1031515311514">You have created EIPs. The number of EIPs is the same as the number of brokers in the Kafka instance. For details about how to create an EIP, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/eip/eip_0002.html" target="_blank" rel="noopener noreferrer">Assigning an EIP</a>.</p>
</div> </div>
<div class="section" id="kafka-dnat__section124115445717"><h4 class="sectiontitle">Step 1: Obtain Information About the Kafka Instance</h4><ol id="kafka-dnat__ol667514716913"><li id="kafka-dnat__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-dnat__li14905725134512"><span>Click <span><img id="kafka-dnat__image1337542211106" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-dnat__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-dnat__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-dnat__section124115445717"><h4 class="sectiontitle">Step 1: Obtain Information About the Kafka Instance</h4><ol id="kafka-dnat__ol667514716913"><li id="kafka-dnat__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-dnat__li14905725134512"><span>Click <span><img id="kafka-dnat__image1337542211106" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-dnat__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-dnat__p11964174020277">Select the region where your Kafka instance is located.</p>
@ -23,7 +24,7 @@
</p></li><li id="kafka-dnat__li183907943516"><span>Create DNAT rules for other private network addresses of the Kafka instance recorded in <a href="#kafka-dnat__li122701357121013">5</a>. <strong id="kafka-dnat__b1172611241982">Configure a unique EIP for each DNAT rule.</strong></span><p><p id="kafka-dnat__p1944471016354">For details about how to create a DNAT rule, see <a href="#kafka-dnat__li2872030202015">2</a> to <a href="#kafka-dnat__li295532675915">4</a>.</p> </p></li><li id="kafka-dnat__li183907943516"><span>Create DNAT rules for other private network addresses of the Kafka instance recorded in <a href="#kafka-dnat__li122701357121013">5</a>. <strong id="kafka-dnat__b1172611241982">Configure a unique EIP for each DNAT rule.</strong></span><p><p id="kafka-dnat__p1944471016354">For details about how to create a DNAT rule, see <a href="#kafka-dnat__li2872030202015">2</a> to <a href="#kafka-dnat__li295532675915">4</a>.</p>
</p></li><li id="kafka-dnat__li1062193864112"><a name="kafka-dnat__li1062193864112"></a><a name="li1062193864112"></a><span>After all DNAT rules are created, click the <strong id="kafka-dnat__b31657489369">DNAT Rules</strong> tab to view the created DNAT rules and record the EIPs corresponding to the private IP addresses.</span></li></ol> </p></li><li id="kafka-dnat__li1062193864112"><a name="kafka-dnat__li1062193864112"></a><a name="li1062193864112"></a><span>After all DNAT rules are created, click the <strong id="kafka-dnat__b31657489369">DNAT Rules</strong> tab to view the created DNAT rules and record the EIPs corresponding to the private IP addresses.</span></li></ol>
</div> </div>
<div class="section" id="kafka-dnat__section1937716142915"><h4 class="sectiontitle">Step 4: Bind EIPs on the Kafka Console</h4><ol id="kafka-dnat__ol194925410487"><li id="kafka-dnat__li5884135811429"><span>Click <strong id="kafka-dnat__b6016345795654">Service List</strong> and choose <strong id="kafka-dnat__b88010161395654">Application</strong> &gt; <strong id="kafka-dnat__b17632873995654">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-dnat__li742112394811"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-dnat__li319117501325"><span>In the <strong id="kafka-dnat__b12591145315012">Advanced Settings</strong> section on the <strong id="kafka-dnat__b165917531009">Basic Information</strong> tab page, click <strong id="kafka-dnat__b8591353202">Modify</strong> next to <strong id="kafka-dnat__b75911653803">Cross-VPC Access</strong>.</span></li><li id="kafka-dnat__li11450213708"><span>Change the values of <strong id="kafka-dnat__b828373793819">advertised.listeners IP Address/Domain Name</strong> to the EIPs in the DNAT rules. Ensure that the mapping between the private network addresses and the EIPs is consistent with that recorded in <a href="#kafka-dnat__li1062193864112">6</a>. Then click <strong id="kafka-dnat__b7580159203815">Save</strong>.</span><p><div class="fignone" id="kafka-dnat__fig15689320154314"><a name="kafka-dnat__fig15689320154314"></a><a name="fig15689320154314"></a><span class="figcap"><b>Figure 5 </b>Changing the advertised.listeners IP address (for DNAT access)</span><br><span><img id="kafka-dnat__image1968919207433" src="en-us_image_0000001329138322.png"></span></div> <div class="section" id="kafka-dnat__section1937716142915"><h4 class="sectiontitle">Step 4: Map EIPs to the Port 9011 of Private IP Addresses</h4><ol id="kafka-dnat__ol194925410487"><li id="kafka-dnat__li5884135811429"><span>Click <strong id="kafka-dnat__b6016345795654">Service List</strong> and choose <strong id="kafka-dnat__b88010161395654">Application</strong> &gt; <strong id="kafka-dnat__b17632873995654">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-dnat__li742112394811"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-dnat__li319117501325"><span>In the <strong id="kafka-dnat__b12591145315012">Advanced Settings</strong> section on the <strong id="kafka-dnat__b165917531009">Basic Information</strong> tab page, click <strong id="kafka-dnat__b8591353202">Modify</strong> next to <strong id="kafka-dnat__b75911653803">Cross-VPC Access</strong>.</span></li><li id="kafka-dnat__li11450213708"><span>Change the values of <strong id="kafka-dnat__b828373793819">advertised.listeners IP Address/Domain Name</strong> to the EIPs in the DNAT rules. Ensure that the mapping between the private network addresses and the EIPs is consistent with that recorded in <a href="#kafka-dnat__li1062193864112">6</a>. Then click <strong id="kafka-dnat__b7580159203815">Save</strong>.</span><p><div class="fignone" id="kafka-dnat__fig15689320154314"><a name="kafka-dnat__fig15689320154314"></a><a name="fig15689320154314"></a><span class="figcap"><b>Figure 5 </b>Changing the advertised.listeners IP address (for DNAT access)</span><br><span><img id="kafka-dnat__image1968919207433" src="en-us_image_0000001329138322.png"></span></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-dnat__section72114271643"><h4 class="sectiontitle">Step 5: Verify Connectivity</h4><p id="kafka-dnat__p2063111531619">Check whether messages can be created and retrieved by referring to <a href="kafka-ug-180604020.html">Connecting to Kafka Using the Client (Plaintext Access)</a> or <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</p> <div class="section" id="kafka-dnat__section72114271643"><h4 class="sectiontitle">Step 5: Verify Connectivity</h4><p id="kafka-dnat__p2063111531619">Check whether messages can be created and retrieved by referring to <a href="kafka-ug-180604020.html">Connecting to Kafka Using the Client (Plaintext Access)</a> or <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</p>

View File

@ -1,7 +1,7 @@
<a name="kafka-faq-200426013"></a><a name="kafka-faq-200426013"></a> <a name="kafka-faq-200426013"></a><a name="kafka-faq-200426013"></a>
<h1 class="topictitle1">How Do I Synchronize Data from One Kafka Instance to Another?</h1> <h1 class="topictitle1">How Do I Synchronize Data from One Kafka Instance to Another?</h1>
<div id="body1587865348902"><p id="kafka-faq-200426013__p147331239111018">Unfortunately, you cannot synchronize two Kafka instances in real time. To migrate services from one instance to another, create messages to both instances. After all messages in the original instance have been retrieved or aged, you can migrate services to the new instance.</p> <div id="body1587865348902"><p id="kafka-faq-200426013__p5867155591910">On the Kafka console, you can create a Smart Connect task for instance data replication. For details, see <a href="kafka-ug-0034.html">Replicating Kafka Instance Data</a>.</p>
</div> </div>
<div> <div>
<div class="familylinks"> <div class="familylinks">

File diff suppressed because it is too large Load Diff

View File

@ -8,7 +8,13 @@
</th> </th>
</tr> </tr>
</thead> </thead>
<tbody><tr id="kafka-ug-00001__row173616203516"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p1717411138497">2024-06-14</p> <tbody><tr id="kafka-ug-00001__row4266100131820"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p426610171810">2024-07-19</p>
</td>
<td class="cellrowborder" valign="top" width="80.78999999999999%" headers="mcps1.3.1.1.3.1.2 "><p id="kafka-ug-00001__p182665001817">Added:</p>
<ul id="kafka-ug-00001__ul14961171681816"><li id="kafka-ug-00001__li5961131620182">Supported Smart Connect. See <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a> and <a href="kafka-ug-0065.html">Migrating Data Using Smart Connect</a>.</li></ul>
</td>
</tr>
<tr id="kafka-ug-00001__row173616203516"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p1717411138497">2024-06-14</p>
</td> </td>
<td class="cellrowborder" valign="top" width="80.78999999999999%" headers="mcps1.3.1.1.3.1.2 "><p id="kafka-ug-00001__p118966302157">Added the following content:</p> <td class="cellrowborder" valign="top" width="80.78999999999999%" headers="mcps1.3.1.1.3.1.2 "><p id="kafka-ug-00001__p118966302157">Added the following content:</p>
<ul id="kafka-ug-00001__ul137681731164915"><li id="kafka-ug-00001__li676873164914">Added sections <a href="ProductDescPrivilegeManagement.html">Permission</a>, <a href="CreateUserAndGrantPolicy.html">Creating a User and Granting DMS for Kafka Permissions</a>, <a href="kafka-ug-181221001.html">Modifying Kafka Instance Specifications</a>, <a href="kafka_ug_0046.html">Deleting Kafka Messages</a>, <a href="kafka_ug_0023.html">Reassigning Kafka Partitions</a>, and <a href="kafka-ug-0041.html">Creating a Kafka Consumer Group</a>.</li><li id="kafka-ug-00001__li828245871620">Supported Kafka v3.x. See <a href="Kafka-specification.html">Specifications</a> and <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li496862192819">Added single-node specifications. See <a href="Kafka-specification.html">Specifications</a> and <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li1854143710178">SSL setting can be changed. See <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a> and <a href="kafka_ug_0044.html">Configuring Plaintext or Ciphertext Access to Kafka Instances</a>.</li><li id="kafka-ug-00001__li1647010512179">Added <a href="kafka-ug-00003.html">Getting Started</a>.</li></ul> <ul id="kafka-ug-00001__ul137681731164915"><li id="kafka-ug-00001__li676873164914">Added sections <a href="ProductDescPrivilegeManagement.html">Permission</a>, <a href="CreateUserAndGrantPolicy.html">Creating a User and Granting DMS for Kafka Permissions</a>, <a href="kafka-ug-181221001.html">Modifying Kafka Instance Specifications</a>, <a href="kafka_ug_0046.html">Deleting Kafka Messages</a>, <a href="kafka_ug_0023.html">Reassigning Kafka Partitions</a>, and <a href="kafka-ug-0041.html">Creating a Kafka Consumer Group</a>.</li><li id="kafka-ug-00001__li828245871620">Supported Kafka v3.x. See <a href="Kafka-specification.html">Specifications</a> and <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li496862192819">Added single-node specifications. See <a href="Kafka-specification.html">Specifications</a> and <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li1854143710178">SSL setting can be changed. See <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a> and <a href="kafka_ug_0044.html">Configuring Plaintext or Ciphertext Access to Kafka Instances</a>.</li><li id="kafka-ug-00001__li1647010512179">Added <a href="kafka-ug-00003.html">Getting Started</a>.</li></ul>
@ -25,7 +31,7 @@
<tr id="kafka-ug-00001__row15574102917320"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p557413299317">2022-10-30</p> <tr id="kafka-ug-00001__row15574102917320"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p557413299317">2022-10-30</p>
</td> </td>
<td class="cellrowborder" valign="top" width="80.78999999999999%" headers="mcps1.3.1.1.3.1.2 "><p id="kafka-ug-00001__p17574132916313">This release incorporates the following changes:</p> <td class="cellrowborder" valign="top" width="80.78999999999999%" headers="mcps1.3.1.1.3.1.2 "><p id="kafka-ug-00001__p17574132916313">This release incorporates the following changes:</p>
<ul id="kafka-ug-00001__ul1555194911317"><li id="kafka-ug-00001__li395251218503">Removed support for normal queues.</li><li id="kafka-ug-00001__li28411381200">Added description about Kafka v2.7, automatic topic creation, and disk encryption in section <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li7555549934">Added two methods for connecting to a Kafka instance: <a href="kafka-ug-0001.html">Accessing Kafka Using a VPC Endpoint Across VPCs</a> and <a href="kafka-dnat.html">Accessing Kafka in a Public Network Using DNAT</a>.</li><li id="kafka-ug-00001__li411493813317">Added description about how to modify topic parameters, export topics, and view sample code for connecting to instances. Related sections are <a href="kafka-ug-200506001.html">Changing Kafka Message Retention Period</a>, <a href="kafka-ug-0006.html">Changing Kafka Partition Quantity</a>, "Modifying Synchronous Replication and Synchronous Flushing", <a href="kafka_ug_0027.html">Exporting the Kafka Topic List</a>, and <a href="kafka_ug_0024.html">Viewing Sample Code of Kafka Production and Consumption</a>.</li><li id="kafka-ug-00001__li149041024653">Added description about user management in sections <a href="kafka-ug-0003.html">Configuring Kafka Users</a>, <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>, "Resetting SASL_SSL Password", and "Deleting SASL_SSL Users".</li><li id="kafka-ug-00001__li1773944514617">Added description about consumer group management in sections <a href="kafka_ug_0021.html">Querying the Kafka Consumer Group List</a>, <a href="kafka-ug-0012.html">Deleting a Kafka Consumer Group</a>, <a href="kafka-ug-0014.html">Viewing and Resetting Kafka Consumption Offsets</a>, and <a href="kafka-ug-0015.html">Viewing Kafka Consumer Details</a>.</li><li id="kafka-ug-00001__li77461325592">Added description about how to modify configuration parameters in section <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>.</li><li id="kafka-ug-00001__li3178121485817">Added description about tags in sections <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>, <a href="kafka-ug-180604014.html">Viewing and Modifying Basic Information of a Kafka Instance</a>, and <a href="TagManagement.html">Configuring Kafka Instance Tags</a>.</li><li id="kafka-ug-00001__li2497618125917">Added <a href="kafka-faq-191030002.html">Instances</a>, <a href="kafka-faq-191030001.html">Connections</a>, <a href="kafka-faq-191030003.html">Topics and Partitions</a>, <a href="kafka-faq-200423001.html">Consumer Groups</a>, <a href="kafka-faq-190416001.html">Messages</a>, and <a href="kafka-faq-191030004.html">Monitoring &amp; Alarm</a> to FAQs.</li></ul> <ul id="kafka-ug-00001__ul1555194911317"><li id="kafka-ug-00001__li395251218503">Removed support for normal queues.</li><li id="kafka-ug-00001__li28411381200">Added description about Kafka v2.7, automatic topic creation, and disk encryption in section <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>.</li><li id="kafka-ug-00001__li7555549934">Added two methods for connecting to a Kafka instance: <a href="kafka-ug-0001.html">Accessing Kafka Using a VPC Endpoint Across VPCs</a> and <a href="kafka-dnat.html">Accessing Kafka in a Public Network Using DNAT</a>.</li><li id="kafka-ug-00001__li411493813317">Added description about how to modify topic parameters, export topics, and view sample code for connecting to instances. Related sections are <a href="kafka-ug-200506001.html">Changing Kafka Message Retention Period</a>, <a href="kafka-ug-0006.html">Changing Kafka Partition Quantity</a>, "Modifying Synchronous Replication and Synchronous Flushing", <a href="kafka_ug_0027.html">Exporting the Kafka Topic List</a>, and <a href="kafka_ug_0024.html">Viewing Sample Code of Kafka Production and Consumption</a>.</li><li id="kafka-ug-00001__li149041024653">Added description about user management in sections <a href="kafka-ug-0003.html">Configuring Kafka ACL Users</a>, <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>, "Resetting SASL_SSL Password", and "Deleting SASL_SSL Users".</li><li id="kafka-ug-00001__li1773944514617">Added description about consumer group management in sections <a href="kafka_ug_0021.html">Querying the Kafka Consumer Group List</a>, <a href="kafka-ug-0012.html">Deleting a Kafka Consumer Group</a>, <a href="kafka-ug-0014.html">Viewing and Resetting Kafka Consumption Offsets</a>, and <a href="kafka-ug-0015.html">Viewing Kafka Consumer Information</a>.</li><li id="kafka-ug-00001__li77461325592">Added description about how to modify configuration parameters in section <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>.</li><li id="kafka-ug-00001__li3178121485817">Added description about tags in sections <a href="kafka-ug-180604013.html">Creating a Kafka Instance</a>, <a href="kafka-ug-180604014.html">Viewing and Modifying Basic Information of a Kafka Instance</a>, and <a href="TagManagement.html">Configuring Kafka Instance Tags</a>.</li><li id="kafka-ug-00001__li2497618125917">Added <a href="kafka-faq-191030002.html">Instances</a>, <a href="kafka-faq-191030001.html">Connections</a>, <a href="kafka-faq-191030003.html">Topics and Partitions</a>, <a href="kafka-faq-200423001.html">Consumer Groups</a>, <a href="kafka-faq-190416001.html">Messages</a>, and <a href="kafka-faq-191030004.html">Monitoring &amp; Alarm</a> to FAQs.</li></ul>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-00001__row79111887134"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p79131582132">2020-08-11</p> <tr id="kafka-ug-00001__row79111887134"><td class="cellrowborder" valign="top" width="19.21%" headers="mcps1.3.1.1.3.1.1 "><p id="kafka-ug-00001__p79131582132">2020-08-11</p>

View File

@ -1,21 +1,17 @@
<a name="kafka-ug-0001"></a><a name="kafka-ug-0001"></a> <a name="kafka-ug-0001"></a><a name="kafka-ug-0001"></a>
<h1 class="topictitle1">Accessing Kafka Using a VPC Endpoint Across VPCs</h1> <h1 class="topictitle1">Accessing Kafka Using a VPC Endpoint Across VPCs</h1>
<div id="body0000001096588567"><div class="section" id="kafka-ug-0001__section128927211065"><h4 class="sectiontitle">Context</h4><p id="kafka-ug-0001__p1449521416556">VPCs are logically isolated from each other. If a Kafka instance and a Kafka client are in different VPCs within a region, they cannot communicate with each other. In this case, you can use one of the following methods to access a Kafka instance across VPCs:</p> <div id="body0000001096588567"><p id="kafka-ug-0001__p1449521416556">VPCs are logically isolated from each other. If a Kafka instance and a Kafka client are in different VPCs within a region, they cannot communicate with each other. In this case, you can use one of the following methods to access a Kafka instance across VPCs:</p>
<ul id="kafka-ug-0001__ul97214158109"><li id="kafka-ug-0001__li5721515171018">Establish a VPC peering connection to allow two VPCs to communicate with each other. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/vpc/vpc_peering_0000.html" target="_blank" rel="noopener noreferrer">VPC Peering Connection</a>.</li><li id="kafka-ug-0001__li113217487569">Use VPC Endpoint (VPCEP) to establish a cross-VPC connection.</li></ul> <ul id="kafka-ug-0001__ul97214158109"><li id="kafka-ug-0001__li5721515171018">Establish a VPC peering connection to allow two VPCs to communicate with each other. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/vpc/vpc_peering_0000.html" target="_blank" rel="noopener noreferrer">VPC Peering Connection</a>.</li><li id="kafka-ug-0001__li113217487569">Use VPC Endpoint (VPCEP) to establish a cross-VPC connection.</li></ul>
</div> <p id="kafka-ug-0001__p19184161715520">The following describes how to use VPCEP to implement cross-VPC access.</p>
<div class="section" id="kafka-ug-0001__section1856313495332"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-0001__p19184161715520">The following describes how to use VPCEP to implement cross-VPC access.</p>
<p id="kafka-ug-0001__p190851815389">VPCEP provides two types of resources: VPC endpoint services and VPC endpoints.</p> <p id="kafka-ug-0001__p190851815389">VPCEP provides two types of resources: VPC endpoint services and VPC endpoints.</p>
<ul id="kafka-ug-0001__ul321112193919"><li id="kafka-ug-0001__li13214126397">A VPC endpoint service can be a Kafka instance which is accessed using VPC endpoints.</li><li id="kafka-ug-0001__li7537121183910">A VPC endpoint is a secure and private channel for connecting a VPC to a VPC endpoint service.</li></ul> <ul id="kafka-ug-0001__ul321112193919"><li id="kafka-ug-0001__li13214126397">A VPC endpoint service can be a Kafka instance which is accessed using VPC endpoints.</li><li id="kafka-ug-0001__li7537121183910">A VPC endpoint is a secure and private channel for connecting a VPC to a VPC endpoint service.</li></ul>
<div class="fignone" id="kafka-ug-0001__fig17225659161619"><span class="figcap"><b>Figure 1 </b>Working principle of accessing a Kafka instance across VPCs</span><br><span><img class="eddx" id="kafka-ug-0001__image169875400199" src="en-us_image_0000001376864660.png"></span></div> <div class="fignone" id="kafka-ug-0001__fig17225659161619"><span class="figcap"><b>Figure 1 </b>Working principle of accessing a Kafka instance across VPCs</span><br><span><img class="eddx" id="kafka-ug-0001__image169875400199" src="en-us_image_0000001376864660.png"></span></div>
</div>
<div class="section" id="kafka-ug-0001__section1677691110218"><h4 class="sectiontitle">Procedure</h4><div class="fignone" id="kafka-ug-0001__fig12258108164017"><span class="figcap"><b>Figure 2 </b>Process for accessing a Kafka instance across VPCs</span><br><span><img class="eddx" id="kafka-ug-0001__image1225820804011" src="en-us_image_0000001382159745.png"></span></div>
</div>
<div class="section" id="kafka-ug-0001__section171840351866"><h4 class="sectiontitle">Creating a VPC Endpoint Service</h4><ol id="kafka-ug-0001__ol16700104831910"><li id="kafka-ug-0001__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0001__li14905725134512"><span>Click <span><img id="kafka-ug-0001__image106626547332" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0001__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0001__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0001__section171840351866"><h4 class="sectiontitle">Creating a VPC Endpoint Service</h4><ol id="kafka-ug-0001__ol16700104831910"><li id="kafka-ug-0001__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0001__li14905725134512"><span>Click <span><img id="kafka-ug-0001__image106626547332" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0001__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0001__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0001__li189561034172215"><span>Click <strong id="kafka-ug-0001__b8197419395652">Service List</strong> and choose <strong id="kafka-ug-0001__b208156690895652">Application</strong> &gt; <strong id="kafka-ug-0001__b126641929395652">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0001__li1933311013310"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0001__li1470016488194"><a name="kafka-ug-0001__li1470016488194"></a><a name="li1470016488194"></a><span>In the <strong id="kafka-ug-0001__b6166141111476">Advanced Settings</strong> section on the <strong id="kafka-ug-0001__b1848582144719">Basic Information</strong> tab page, obtain the listeners IP addresses and port IDs of the instance for <strong id="kafka-ug-0001__b1522495205117">Cross-VPC Access</strong>.</span><p><div class="fignone" id="kafka-ug-0001__fig25911341876"><span class="figcap"><b>Figure 3 </b>Cross-VPC accessrelated listeners IP addresses and corresponding port IDs of the Kafka instance</span><br><span><img id="kafka-ug-0001__image959123411716" src="en-us_image_0000001328948884.png"></span></div> </p></li><li id="kafka-ug-0001__li189561034172215"><span>Click <strong id="kafka-ug-0001__b8197419395652">Service List</strong> and choose <strong id="kafka-ug-0001__b208156690895652">Application</strong> &gt; <strong id="kafka-ug-0001__b126641929395652">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0001__li1933311013310"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0001__li1470016488194"><a name="kafka-ug-0001__li1470016488194"></a><a name="li1470016488194"></a><span>In the <strong id="kafka-ug-0001__b6166141111476">Advanced Settings</strong> section on the <strong id="kafka-ug-0001__b1848582144719">Basic Information</strong> tab page, obtain the listeners IP addresses and port IDs of the instance for <strong id="kafka-ug-0001__b1522495205117">Cross-VPC Access</strong>.</span><p><div class="fignone" id="kafka-ug-0001__fig25911341876"><span class="figcap"><b>Figure 2 </b>Cross-VPC accessrelated listeners IP addresses and corresponding port IDs of the Kafka instance</span><br><span><img id="kafka-ug-0001__image959123411716" src="en-us_image_0000001328948884.png"></span></div>
</p></li><li id="kafka-ug-0001__li42609420212"><span>In the <strong id="kafka-ug-0001__b186011912105317">Network</strong> section on the <strong id="kafka-ug-0001__b10988161818536">Basic Information</strong> tab page, view the VPC to which the Kafka instance belongs.</span><p><div class="fignone" id="kafka-ug-0001__fig23264316235"><span class="figcap"><b>Figure 4 </b>Viewing the VPC to which the Kafka instance belongs</span><br><span><img id="kafka-ug-0001__image176598590259" src="en-us_image_0000001244372389.png"></span></div> </p></li><li id="kafka-ug-0001__li42609420212"><span>In the <strong id="kafka-ug-0001__b186011912105317">Network</strong> section on the <strong id="kafka-ug-0001__b10988161818536">Basic Information</strong> tab page, view the VPC to which the Kafka instance belongs.</span><p><div class="fignone" id="kafka-ug-0001__fig23264316235"><span class="figcap"><b>Figure 3 </b>Viewing the VPC to which the Kafka instance belongs</span><br><span><img id="kafka-ug-0001__image176598590259" src="en-us_image_0000001244372389.png"></span></div>
</p></li><li id="kafka-ug-0001__li19701310122315"><a name="kafka-ug-0001__li19701310122315"></a><a name="li19701310122315"></a><span>Click the VPC to obtain the VPC ID on the VPC console.</span><p><div class="fignone" id="kafka-ug-0001__fig99101255497"><span class="figcap"><b>Figure 5 </b>Obtaining the VPC ID</span><br><span><img id="kafka-ug-0001__image2091014550918" src="en-us_image_0000001328950348.png"></span></div> </p></li><li id="kafka-ug-0001__li19701310122315"><a name="kafka-ug-0001__li19701310122315"></a><a name="li19701310122315"></a><span>Click the VPC to obtain the VPC ID on the VPC console.</span><p><div class="fignone" id="kafka-ug-0001__fig99101255497"><span class="figcap"><b>Figure 4 </b>Obtaining the VPC ID</span><br><span><img id="kafka-ug-0001__image2091014550918" src="en-us_image_0000001328950348.png"></span></div>
</p></li><li id="kafka-ug-0001__li11323122315289"><a name="kafka-ug-0001__li11323122315289"></a><a name="li11323122315289"></a><span>Call the VPC Endpoint API to create a VPC endpoint service. For details, see <a href="https://docs.otc.t-systems.com/en-us/api/vpcep/vpcep_06_0201.html" target="_blank" rel="noopener noreferrer">Creating a VPC Endpoint Service</a>.</span><p><pre class="screen" id="kafka-ug-0001__screen52371811174315">POST https://<em id="kafka-ug-0001__i819634216494">{endpoint}</em>/v1/<em id="kafka-ug-0001__i1953114460497">{project_id}</em>/vpc-endpoint-services</pre> </p></li><li id="kafka-ug-0001__li11323122315289"><a name="kafka-ug-0001__li11323122315289"></a><a name="li11323122315289"></a><span>Call the VPC Endpoint API to create a VPC endpoint service. For details, see <a href="https://docs.otc.t-systems.com/en-us/api/vpcep/vpcep_06_0201.html" target="_blank" rel="noopener noreferrer">Creating a VPC Endpoint Service</a>.</span><p><pre class="screen" id="kafka-ug-0001__screen52371811174315">POST https://<em id="kafka-ug-0001__i819634216494">{endpoint}</em>/v1/<em id="kafka-ug-0001__i1953114460497">{project_id}</em>/vpc-endpoint-services</pre>
<p id="kafka-ug-0001__p712372418441">Set the following request parameter to the specified values, and other parameters as required.</p> <p id="kafka-ug-0001__p712372418441">Set the following request parameter to the specified values, and other parameters as required.</p>
<ul id="kafka-ug-0001__ul109721527154415"><li id="kafka-ug-0001__li15324130161810"><strong id="kafka-ug-0001__b1123819614449">port_id</strong>: one of the port IDs obtained in <a href="#kafka-ug-0001__li1470016488194">5</a>.</li><li id="kafka-ug-0001__li14232192411218"><strong id="kafka-ug-0001__b22112913445">vpc_id</strong>: VPC ID obtained in <a href="#kafka-ug-0001__li19701310122315">7</a>.</li><li id="kafka-ug-0001__li457099124"><strong id="kafka-ug-0001__b99181273379">server_type</strong>: <strong id="kafka-ug-0001__b153813413375">VM</strong></li><li id="kafka-ug-0001__li1290312328219"><strong id="kafka-ug-0001__b8612192333713">client_port</strong>: <strong id="kafka-ug-0001__b116991425193719">9011</strong></li><li id="kafka-ug-0001__li259317341130"><strong id="kafka-ug-0001__b412256203719">server_port</strong>: <strong id="kafka-ug-0001__b1851955833711">9011</strong></li><li id="kafka-ug-0001__li197244514318"><strong id="kafka-ug-0001__b5780810105014">protocol</strong>: <strong id="kafka-ug-0001__b11509212135018">TCP</strong></li><li id="kafka-ug-0001__li181221312743"><strong id="kafka-ug-0001__b11843132317500">approval_enabled</strong>: <strong id="kafka-ug-0001__b5519426205010">false</strong></li><li id="kafka-ug-0001__li20472512516"><strong id="kafka-ug-0001__b871713397509">service_type</strong>: <strong id="kafka-ug-0001__b1630154215501">interface</strong></li><li id="kafka-ug-0001__li163603457186"><strong id="kafka-ug-0001__b1235715261301">endpoint</strong>: VPCEP endpoint obtained from <a href="https://docs.otc.t-systems.com/en-us/endpoint/index.html" target="_blank" rel="noopener noreferrer">Regions and Endpoints</a>. The region must be the same as that of the Kafka instance.</li><li id="kafka-ug-0001__li124628547309"><strong id="kafka-ug-0001__b1914218591611">project_id</strong>: project ID obtained from <a href="https://docs.otc.t-systems.com/en-us/api/vpcep/vpcep_08_0003.html" target="_blank" rel="noopener noreferrer">Obtaining a Project ID</a>. The region must be the same as that of the Kafka instance.</li></ul> <ul id="kafka-ug-0001__ul109721527154415"><li id="kafka-ug-0001__li15324130161810"><strong id="kafka-ug-0001__b1123819614449">port_id</strong>: one of the port IDs obtained in <a href="#kafka-ug-0001__li1470016488194">5</a>.</li><li id="kafka-ug-0001__li14232192411218"><strong id="kafka-ug-0001__b22112913445">vpc_id</strong>: VPC ID obtained in <a href="#kafka-ug-0001__li19701310122315">7</a>.</li><li id="kafka-ug-0001__li457099124"><strong id="kafka-ug-0001__b99181273379">server_type</strong>: <strong id="kafka-ug-0001__b153813413375">VM</strong></li><li id="kafka-ug-0001__li1290312328219"><strong id="kafka-ug-0001__b8612192333713">client_port</strong>: <strong id="kafka-ug-0001__b116991425193719">9011</strong></li><li id="kafka-ug-0001__li259317341130"><strong id="kafka-ug-0001__b412256203719">server_port</strong>: <strong id="kafka-ug-0001__b1851955833711">9011</strong></li><li id="kafka-ug-0001__li197244514318"><strong id="kafka-ug-0001__b5780810105014">protocol</strong>: <strong id="kafka-ug-0001__b11509212135018">TCP</strong></li><li id="kafka-ug-0001__li181221312743"><strong id="kafka-ug-0001__b11843132317500">approval_enabled</strong>: <strong id="kafka-ug-0001__b5519426205010">false</strong></li><li id="kafka-ug-0001__li20472512516"><strong id="kafka-ug-0001__b871713397509">service_type</strong>: <strong id="kafka-ug-0001__b1630154215501">interface</strong></li><li id="kafka-ug-0001__li163603457186"><strong id="kafka-ug-0001__b1235715261301">endpoint</strong>: VPCEP endpoint obtained from <a href="https://docs.otc.t-systems.com/en-us/endpoint/index.html" target="_blank" rel="noopener noreferrer">Regions and Endpoints</a>. The region must be the same as that of the Kafka instance.</li><li id="kafka-ug-0001__li124628547309"><strong id="kafka-ug-0001__b1914218591611">project_id</strong>: project ID obtained from <a href="https://docs.otc.t-systems.com/en-us/api/vpcep/vpcep_08_0003.html" target="_blank" rel="noopener noreferrer">Obtaining a Project ID</a>. The region must be the same as that of the Kafka instance.</li></ul>
@ -23,23 +19,24 @@
<p id="kafka-ug-0001__p163352316615">Record the value of <strong id="kafka-ug-0001__b185461917134213">service_name</strong> in the response. This parameter indicates the name of the VPC endpoint service.</p> <p id="kafka-ug-0001__p163352316615">Record the value of <strong id="kafka-ug-0001__b185461917134213">service_name</strong> in the response. This parameter indicates the name of the VPC endpoint service.</p>
</p></li><li id="kafka-ug-0001__li7368125918119"><a name="kafka-ug-0001__li7368125918119"></a><a name="li7368125918119"></a><span>Repeat <a href="#kafka-ug-0001__li11323122315289">8</a> to create VPC endpoint services for other port IDs obtained in <a href="#kafka-ug-0001__li1470016488194">5</a> and record the VPC endpoint service names.</span></li></ol> </p></li><li id="kafka-ug-0001__li7368125918119"><a name="kafka-ug-0001__li7368125918119"></a><a name="li7368125918119"></a><span>Repeat <a href="#kafka-ug-0001__li11323122315289">8</a> to create VPC endpoint services for other port IDs obtained in <a href="#kafka-ug-0001__li1470016488194">5</a> and record the VPC endpoint service names.</span></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0001__section386115711369"><h4 class="sectiontitle">(Optional) Adding a Whitelist Record</h4><p id="kafka-ug-0001__p195501184377">If the Kafka client and Kafka instance belong to different accounts, add the ID of the account to which the Kafka client belongs to the whitelist of the endpoint service. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/vpcep/vpcep_02_02034.html" target="_blank" rel="noopener noreferrer">Add a Whitelist Record</a>.</p> <div class="section" id="kafka-ug-0001__section386115711369"><h4 class="sectiontitle">(Optional) Adding a Whitelist</h4><p id="kafka-ug-0001__p83651213518">The VPC endpoint service can be used across accounts through a whitelist.</p>
<p id="kafka-ug-0001__p195501184377">If the Kafka client and Kafka instance belong to different accounts, add the ID of the account to which the Kafka client belongs to the whitelist of the endpoint service. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/vpcep/vpcep_02_02034.html" target="_blank" rel="noopener noreferrer">Add a Whitelist Record</a>.</p>
</div> </div>
<div class="section" id="kafka-ug-0001__section1649245213366"><h4 class="sectiontitle">Creating a VPC Endpoint</h4><ol id="kafka-ug-0001__ol5270192011377"><li id="kafka-ug-0001__li182701720183719"><a name="kafka-ug-0001__li182701720183719"></a><a name="li182701720183719"></a><span>Click <strong id="kafka-ug-0001__b15527122581412">Service List</strong>. Then choose <strong id="kafka-ug-0001__b17528142516141">Network</strong> &gt; <strong id="kafka-ug-0001__b17528172581414">VPC Endpoint</strong>.</span></li><li id="kafka-ug-0001__li1097665924012"><span>Click <strong id="kafka-ug-0001__b3597125717507">Create VPC Endpoint</strong>.</span></li><li id="kafka-ug-0001__li8149409405"><span>Set the following parameters:</span><p><ul id="kafka-ug-0001__ul165655051517"><li id="kafka-ug-0001__li1256500171513"><strong id="kafka-ug-0001__b14242221408">Region</strong>: Select the region that the Kafka instance is in.</li><li id="kafka-ug-0001__li1689535162214"><strong id="kafka-ug-0001__b176289169117">Service Category</strong>: Select <strong id="kafka-ug-0001__b82312504015">Find a service by name</strong>.</li><li id="kafka-ug-0001__li5677124012253"><strong id="kafka-ug-0001__b204221111829">VPC Endpoint Service Name</strong>: Enter the VPC endpoint service name recorded in <a href="#kafka-ug-0001__li11323122315289">8</a> and click <strong id="kafka-ug-0001__b865911297120">Verify</strong>. If <strong id="kafka-ug-0001__b87887283210">Service name found</strong> is displayed, proceed with subsequent operations.</li><li id="kafka-ug-0001__li188779365268"><strong id="kafka-ug-0001__b18689638927">VPC</strong>: Select the VPC that the Kafka client is in.</li><li id="kafka-ug-0001__li19754165123816"><strong id="kafka-ug-0001__b911185212219">Subnet</strong>: Select the subnet that the Kafka client is in.</li><li id="kafka-ug-0001__li194121351184516"><strong id="kafka-ug-0001__b84235270611353">Private IP Address</strong>: Select <strong id="kafka-ug-0001__b84235270684224">Automatic</strong>.</li></ul> <div class="section" id="kafka-ug-0001__section1649245213366"><h4 class="sectiontitle">Creating a VPC Endpoint</h4><ol id="kafka-ug-0001__ol5270192011377"><li id="kafka-ug-0001__li182701720183719"><a name="kafka-ug-0001__li182701720183719"></a><a name="li182701720183719"></a><span>Click <strong id="kafka-ug-0001__b15527122581412">Service List</strong>. Then choose <strong id="kafka-ug-0001__b17528142516141">Network</strong> &gt; <strong id="kafka-ug-0001__b17528172581414">VPC Endpoint</strong>.</span></li><li id="kafka-ug-0001__li1097665924012"><span>Click <strong id="kafka-ug-0001__b3597125717507">Create VPC Endpoint</strong>.</span></li><li id="kafka-ug-0001__li8149409405"><span>Set the following parameters:</span><p><ul id="kafka-ug-0001__ul165655051517"><li id="kafka-ug-0001__li1256500171513"><strong id="kafka-ug-0001__b14242221408">Region</strong>: Select the region that the Kafka instance is in.</li><li id="kafka-ug-0001__li1689535162214"><strong id="kafka-ug-0001__b176289169117">Service Category</strong>: Select <strong id="kafka-ug-0001__b82312504015">Find a service by name</strong>.</li><li id="kafka-ug-0001__li5677124012253"><strong id="kafka-ug-0001__b204221111829">VPC Endpoint Service Name</strong>: Enter the VPC endpoint service name recorded in <a href="#kafka-ug-0001__li11323122315289">8</a> and click <strong id="kafka-ug-0001__b865911297120">Verify</strong>. If <strong id="kafka-ug-0001__b87887283210">Service name found</strong> is displayed, proceed with subsequent operations.</li><li id="kafka-ug-0001__li188779365268"><strong id="kafka-ug-0001__b18689638927">VPC</strong>: Select the VPC that the Kafka client is in.</li><li id="kafka-ug-0001__li19754165123816"><strong id="kafka-ug-0001__b911185212219">Subnet</strong>: Select the subnet that the Kafka client is in.</li><li id="kafka-ug-0001__li194121351184516"><strong id="kafka-ug-0001__b84235270611353">Private IP Address</strong>: Select <strong id="kafka-ug-0001__b84235270684224">Automatic</strong>.</li></ul>
<p id="kafka-ug-0001__p10346253114517">Retain the default values for other parameters. For details, see <a href="https://docs.otc.t-systems.com/usermanual/vpcep/en-us_topic_0131645189.html" target="_blank" rel="noopener noreferrer">Creating a VPC Endpoint</a>.</p> <p id="kafka-ug-0001__p10346253114517">Retain the default values for other parameters. For details, see <a href="https://docs.otc.t-systems.com/usermanual/vpcep/en-us_topic_0131645189.html" target="_blank" rel="noopener noreferrer">Creating a VPC Endpoint</a>.</p>
</p></li><li id="kafka-ug-0001__li74938503146"><span>Click <strong id="kafka-ug-0001__b16378375412"></strong><strong id="kafka-ug-0001__b121871040124112">Create Now</strong><strong id="kafka-ug-0001__b153931743154120"></strong>.</span></li><li id="kafka-ug-0001__li14345185919339"><span>Confirm the configurations and submit the request.</span></li><li id="kafka-ug-0001__li1265111693415"><span>Go back to the VPC endpoint list and check whether the status of the created VPC endpoint has changed to <strong id="kafka-ug-0001__b3376132791516">Accepted</strong>. The <strong id="kafka-ug-0001__b53766277157">Accepted</strong> state means that the VPC endpoint has been connected to the VPC endpoint service.</span><p><div class="fignone" id="kafka-ug-0001__fig855195817158"><span class="figcap"><b>Figure 6 </b>Checking the VPC endpoint status</span><br><span><img id="kafka-ug-0001__image15551958101511" src="en-us_image_0000001380194201.png"></span></div> </p></li><li id="kafka-ug-0001__li74938503146"><span>Click <strong id="kafka-ug-0001__b16378375412"></strong><strong id="kafka-ug-0001__b121871040124112">Create Now</strong><strong id="kafka-ug-0001__b153931743154120"></strong>.</span></li><li id="kafka-ug-0001__li14345185919339"><span>Confirm the configurations and submit the request.</span></li><li id="kafka-ug-0001__li1265111693415"><span>Go back to the VPC endpoint list and check whether the status of the created VPC endpoint has changed to <strong id="kafka-ug-0001__b3376132791516">Accepted</strong>. The <strong id="kafka-ug-0001__b53766277157">Accepted</strong> state means that the VPC endpoint has been connected to the VPC endpoint service.</span><p><div class="fignone" id="kafka-ug-0001__fig855195817158"><span class="figcap"><b>Figure 5 </b>Checking the VPC endpoint status</span><br><span><img id="kafka-ug-0001__image15551958101511" src="en-us_image_0000001380194201.png"></span></div>
</p></li><li id="kafka-ug-0001__li1942253845112"><a name="kafka-ug-0001__li1942253845112"></a><a name="li1942253845112"></a><span>Click the VPC endpoint ID. On the <strong id="kafka-ug-0001__b33123781">Summary</strong> tab page, obtain the private IP address.</span><p><p id="kafka-ug-0001__p979320487510">You can use the private IP address to access the VPC endpoint service.</p> </p></li><li id="kafka-ug-0001__li1942253845112"><a name="kafka-ug-0001__li1942253845112"></a><a name="li1942253845112"></a><span>Click the VPC endpoint ID. On the <strong id="kafka-ug-0001__b33123781">Summary</strong> tab page, obtain the private IP address.</span><p><p id="kafka-ug-0001__p979320487510">You can use the private IP address to access the VPC endpoint service.</p>
<div class="fignone" id="kafka-ug-0001__fig51201236201616"><span class="figcap"><b>Figure 7 </b>Viewing the private IP address</span><br><span><img id="kafka-ug-0001__image1012013369164" src="en-us_image_0000001328954164.png"></span></div> <div class="fignone" id="kafka-ug-0001__fig51201236201616"><span class="figcap"><b>Figure 6 </b>Viewing the private IP address</span><br><span><img id="kafka-ug-0001__image1012013369164" src="en-us_image_0000001328954164.png"></span></div>
</p></li><li id="kafka-ug-0001__li923645116109"><a name="kafka-ug-0001__li923645116109"></a><a name="li923645116109"></a><span>Repeat <a href="#kafka-ug-0001__li182701720183719">1</a> to <a href="#kafka-ug-0001__li1942253845112">7</a> to create a VPC endpoint for each VPC endpoint service created in <a href="#kafka-ug-0001__li7368125918119">9</a>, and view and record the private IP addresses of the VPC endpoint services.</span></li></ol> </p></li><li id="kafka-ug-0001__li923645116109"><a name="kafka-ug-0001__li923645116109"></a><a name="li923645116109"></a><span>Repeat <a href="#kafka-ug-0001__li182701720183719">1</a> to <a href="#kafka-ug-0001__li1942253845112">7</a> to create a VPC endpoint for each VPC endpoint service created in <a href="#kafka-ug-0001__li7368125918119">9</a>, and view and record the private IP addresses of the VPC endpoint services.</span></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0001__section159510175154"><h4 class="sectiontitle">Changing the advertised.listeners IP Addresses</h4><ol id="kafka-ug-0001__ol131014476156"><li id="kafka-ug-0001__li296363971814"><span>Click <strong id="kafka-ug-0001__b26820673795652">Service List</strong> and choose <strong id="kafka-ug-0001__b179920916395652">Application</strong> &gt; <strong id="kafka-ug-0001__b126737532595652">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0001__li024010166196"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0001__li202449304196"><span>On the <strong id="kafka-ug-0001__b14364133213810">Advanced Settings</strong> section of the <strong id="kafka-ug-0001__b1191815561766">Basic Information</strong> tab page, click <strong id="kafka-ug-0001__b123891311599">Modify</strong> for <strong id="kafka-ug-0001__b169194562064">Cross-VPC Access</strong> to change the value of <strong id="kafka-ug-0001__b09191556069">advertised.listeners IP address</strong> to the private IP addresses recorded in <a href="#kafka-ug-0001__li1942253845112">7</a> and <a href="#kafka-ug-0001__li923645116109">8</a>. Click <strong id="kafka-ug-0001__b755432213914">Save</strong>.</span><p><div class="notice" id="kafka-ug-0001__note8247191763718"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0001__p224821712375">Each IP address must match the corresponding port ID. Otherwise, the network will be disconnected.</p> <div class="section" id="kafka-ug-0001__section159510175154"><h4 class="sectiontitle">Modifying Parameter advertised.listeners IP</h4><ol id="kafka-ug-0001__ol131014476156"><li id="kafka-ug-0001__li296363971814"><span>Click <strong id="kafka-ug-0001__b26820673795652">Service List</strong> and choose <strong id="kafka-ug-0001__b179920916395652">Application</strong> &gt; <strong id="kafka-ug-0001__b126737532595652">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0001__li024010166196"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0001__li202449304196"><span>On the <strong id="kafka-ug-0001__b14364133213810">Advanced Settings</strong> section of the <strong id="kafka-ug-0001__b1191815561766">Basic Information</strong> tab page, click <strong id="kafka-ug-0001__b123891311599">Modify</strong> for <strong id="kafka-ug-0001__b169194562064">Cross-VPC Access</strong> to change the value of <strong id="kafka-ug-0001__b09191556069">advertised.listeners IP address</strong> to the private IP addresses recorded in <a href="#kafka-ug-0001__li1942253845112">7</a> and <a href="#kafka-ug-0001__li923645116109">8</a>. Click <strong id="kafka-ug-0001__b755432213914">Save</strong>.</span><p><div class="notice" id="kafka-ug-0001__note8247191763718"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0001__p224821712375">Each IP address must match the corresponding port ID. Otherwise, the network will be disconnected.</p>
</div></div> </div></div>
<div class="fignone" id="kafka-ug-0001__fig6446112151915"><a name="kafka-ug-0001__fig6446112151915"></a><a name="fig6446112151915"></a><span class="figcap"><b>Figure 8 </b>Changing the advertised.listeners IP addresses</span><br><span><img id="kafka-ug-0001__image5446226193" src="en-us_image_0000001380118889.png"></span></div> <div class="fignone" id="kafka-ug-0001__fig6446112151915"><a name="kafka-ug-0001__fig6446112151915"></a><a name="fig6446112151915"></a><span class="figcap"><b>Figure 7 </b>Changing the advertised.listeners IP addresses</span><br><span><img id="kafka-ug-0001__image5446226193" src="en-us_image_0000001380118889.png"></span></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0001__section72114271643"><h4 class="sectiontitle">Verifying Connectivity</h4><p id="kafka-ug-0001__p2063111531619">Check whether messages can be created and retrieved by referring to <a href="kafka-ug-180604020.html">Connecting to Kafka Using the Client (Plaintext Access)</a> or <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</p> <div class="section" id="kafka-ug-0001__section72114271643"><h4 class="sectiontitle">Verifying Connectivity</h4><p id="kafka-ug-0001__p2063111531619">Check whether messages can be created and retrieved by referring to <a href="kafka-ug-180604020.html">Connecting to Kafka Using the Client (Plaintext Access)</a> or <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</p>
<p id="kafka-ug-0001__p14394610154411">Notes:</p> <p id="kafka-ug-0001__p14394610154411">Notes:</p>
<ul id="kafka-ug-0001__ul469613431451"><li id="kafka-ug-0001__li388874315198">The address for connecting to a Kafka instance is in the format of "<em id="kafka-ug-0001__i7877652125319">advertised.listeners IP</em><strong id="kafka-ug-0001__b158781652105314">:9011</strong>". For example, the addresses for connecting to the Kafka instance shown in <a href="#kafka-ug-0001__fig6446112151915">Figure 8</a> are <strong id="kafka-ug-0001__b4879165213532">10.158.0.151:9011,10.158.0.162:9011,10.158.0.164:9011</strong>.</li><li id="kafka-ug-0001__li14696124317455">Configure inbound rules for the security group of the Kafka instance to allow access from <strong id="kafka-ug-0001__b197257441927">198.19.128.0/17</strong> over port <strong id="kafka-ug-0001__b66263456219">9011</strong>.</li><li id="kafka-ug-0001__li98341331018">If a network access control list (ACL) has been configured for the subnet of this instance, configure inbound rules for the network ACL to allow access from <strong id="kafka-ug-0001__b1987561781813">198.19.128.0/17</strong> and from the subnet used by the VPC endpoint.</li></ul> <ul id="kafka-ug-0001__ul469613431451"><li id="kafka-ug-0001__li388874315198">The address for connecting to a Kafka instance is in the format of "<em id="kafka-ug-0001__i7877652125319">advertised.listeners IP</em><strong id="kafka-ug-0001__b158781652105314">:9011</strong>". For example, the addresses for connecting to the Kafka instance shown in <a href="#kafka-ug-0001__fig6446112151915">Figure 7</a> are <strong id="kafka-ug-0001__b4879165213532">10.158.0.151:9011,10.158.0.162:9011,10.158.0.164:9011</strong>.</li><li id="kafka-ug-0001__li14696124317455">Configure inbound rules for the security group of the Kafka instance to allow access from <strong id="kafka-ug-0001__b197257441927">198.19.128.0/17</strong> over port <strong id="kafka-ug-0001__b66263456219">9011</strong>.</li><li id="kafka-ug-0001__li98341331018">If a network access control list (ACL) has been configured for the subnet of this instance, configure inbound rules for the network ACL to allow access from <strong id="kafka-ug-0001__b1987561781813">198.19.128.0/17</strong> and from the subnet used by the VPC endpoint.</li></ul>
<div class="note" id="kafka-ug-0001__note14901185218139"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0001__p1190175211319"><strong id="kafka-ug-0001__b5294743192118">198.19.128.0/17</strong> is the network segment allocated to the VPCEP service. To use VPCEP, allow access from this network segment.</p> <div class="note" id="kafka-ug-0001__note14901185218139"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0001__p1190175211319"><strong id="kafka-ug-0001__b5294743192118">198.19.128.0/17</strong> is the network segment allocated to the VPCEP service. To use VPCEP, allow access from this network segment.</p>
</div></div> </div></div>
</div> </div>

View File

@ -1,19 +1,18 @@
<a name="kafka-ug-0002"></a><a name="kafka-ug-0002"></a> <a name="kafka-ug-0002"></a><a name="kafka-ug-0002"></a>
<h1 class="topictitle1">Configuring Kafka Topic Permissions</h1> <h1 class="topictitle1">Configuring Kafka Topic Permissions</h1>
<div id="body0000001135061465"><p id="kafka-ug-0002__p39139363712">DMS supports access control list (ACL) for topics. You can differentiate user permissions by granting users different permissions in a topic.</p> <div id="body0000001135061465"><p id="kafka-ug-0002__p39139363712">Kafka instances with ciphertext access enabled support access control list (ACL) for topics. You can differentiate user permissions by granting users different permissions in a topic.</p>
<p id="kafka-ug-0002__p8060118">This section describes how to grant topic permissions to users after ciphertext access is enabled for Kafka instances. For details about how to create a user, see <a href="kafka-ug-0003.html">Configuring Kafka Users</a>.</p> <p id="kafka-ug-0002__p8060118">This section describes how to grant topic permissions to users after ciphertext access is enabled for Kafka instances. For details about how to create a user, see <a href="kafka-ug-0003.html">Configuring Kafka ACL Users</a>.</p>
<div class="note" id="kafka-ug-0002__note1040520370127"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p6405193714128">This function is unavailable for single-node instances.</p> <div class="note" id="kafka-ug-0002__note1040520370127"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p6405193714128">This function is unavailable for single-node instances.</p>
</div></div> </div></div>
<div class="section" id="kafka-ug-0002__section72106105915"><h4 class="sectiontitle">Constraints</h4><ul id="kafka-ug-0002__ul145581610135911"><li id="kafka-ug-0002__li18558210205911">If no user is granted any permission for a topic and <strong id="kafka-ug-0002__b2852114972419">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0002__b6853134992410">true</strong>, all users can subscribe to or publish messages to the topic.</li><li id="kafka-ug-0002__li45291455153115">If <strong id="kafka-ug-0002__b44614219542">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0002__b19461221185416">false</strong>, only the authorized users can subscribe to or publish messages to the topic. The value of <strong id="kafka-ug-0002__b8656183017547">allow.everyone.if.no.acl.found</strong> can be <a href="kafka-ug-0007.html">modified</a>.</li><li id="kafka-ug-0002__li5560515145914">If one or more users are granted permissions for a topic, only the authorized users can subscribe to or publish messages to the topic.</li><li id="kafka-ug-0002__li79206532597">If both the default and individual user permissions are configured for a topic, the union of the permissions is used.</li></ul> <div class="section" id="kafka-ug-0002__section72106105915"><h4 class="sectiontitle">Constraints</h4><ul id="kafka-ug-0002__ul145581610135911"><li id="kafka-ug-0002__li18558210205911">If parameter <strong id="kafka-ug-0002__b811114584494">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0002__b1161313018506">true</strong> and no topic is granted for a user, all users can subscribe to or publish messages to the topic. If permissions for a topic has been granted to one or more users, only these users can subscribe to or publish messages to the topic. The value of <strong id="kafka-ug-0002__b3674101014178">allow.everyone.if.no.acl.found</strong> can be <a href="kafka-ug-0007.html">modified</a>.</li><li id="kafka-ug-0002__li45291455153115">If <strong id="kafka-ug-0002__b44614219542">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0002__b19461221185416">false</strong>, only the authorized users can subscribe to or publish messages to the topic. The value of <strong id="kafka-ug-0002__b8656183017547">allow.everyone.if.no.acl.found</strong> can be <a href="kafka-ug-0007.html">modified</a>.</li><li id="kafka-ug-0002__li79206532597">If both the default and individual user permissions are configured for a topic, the union of the permissions is used.</li></ul>
</div> </div>
<div class="section" id="kafka-ug-0002__section10943454010"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-0002__ul894011501594"><li id="kafka-ug-0002__li21037611713">Ciphertext access has been enabled.</li><li id="kafka-ug-0002__li1985015521192">(Optional) A user has been created. For details, see <a href="kafka-ug-0003.html">Configuring Kafka Users</a>.</li></ul> <div class="section" id="kafka-ug-0002__section10943454010"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-0002__ul894011501594"><li id="kafka-ug-0002__li21037611713"><a href="kafka_ug_0044.html">Ciphertext has been enabled</a> for the instance.</li><li id="kafka-ug-0002__li1985015521192"><a href="kafka-ug-0003.html">A user is created</a>.</li></ul>
</div> </div>
<div class="section" id="kafka-ug-0002__section590513285108"><h4 class="sectiontitle">Configuring Topic Permissions</h4><ol id="kafka-ug-0002__ol19541635141014"><li id="kafka-ug-0002__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0002__li14905725134512"><span>Click <span><img id="kafka-ug-0002__image125587350" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0002__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0002__section590513285108"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0002__ol19541635141014"><li id="kafka-ug-0002__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0002__li14905725134512"><span>Click <span><img id="kafka-ug-0002__image125587350" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0002__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0002__li189561034172215"><span>Click <strong id="kafka-ug-0002__b176690015395711">Service List</strong> and choose <strong id="kafka-ug-0002__b203556207095711">Application</strong> &gt; <strong id="kafka-ug-0002__b214704539495711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0002__li374185811449"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0002__li1592622914109"><span>In the navigation pane, choose <strong id="kafka-ug-0002__b1656012185359">Topics</strong>.</span></li><li id="kafka-ug-0002__li5603131715114"><span>In the row containing the desired topic, click <strong id="kafka-ug-0002__b171077249911">Grant User Permission</strong>.</span><p><p id="kafka-ug-0002__p16385572030">In the upper part of the <strong id="kafka-ug-0002__b1573917158111">Grant User Permission</strong> dialog box, the topic information is displayed, including the topic name, number of partitions, aging time, number of replicas, and whether synchronous flushing and replication are enabled. You can enable <strong id="kafka-ug-0002__b742184451120">Default permissions</strong> to grant the same permissions for all users. You can use the search box to search for a user if there are many users. In the <strong id="kafka-ug-0002__b8834143011911">Users</strong> area, the list of created users is displayed. In the <strong id="kafka-ug-0002__b1455517403199">Selected</strong> area, grant permissions to the users.</p> </p></li><li id="kafka-ug-0002__li189561034172215"><span>Click <strong id="kafka-ug-0002__b176690015395711">Service List</strong> and choose <strong id="kafka-ug-0002__b203556207095711">Application</strong> &gt; <strong id="kafka-ug-0002__b214704539495711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0002__li374185811449"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0002__li1592622914109"><span>In the navigation pane, choose <strong id="kafka-ug-0002__b1656012185359">Topics</strong>.</span></li><li id="kafka-ug-0002__li5603131715114"><span>In the row containing the desired topic, click <strong id="kafka-ug-0002__b171077249911">Grant User Permission</strong>.</span></li><li id="kafka-ug-0002__li26339382112"><span>Grant topic permissions to users.</span><p><ul id="kafka-ug-0002__ul1324592715341"><li id="kafka-ug-0002__li3245132783414">To grant the same permissions to all users, select <strong id="kafka-ug-0002__b720650181312">Default permissions</strong> and then select permissions. As shown in the following figure, all users have the permission to publish messages to this topic.<div class="fignone" id="kafka-ug-0002__fig1296818488262"><span class="figcap"><b>Figure 1 </b>Granting the same permissions to all users</span><br><span><img id="kafka-ug-0002__image19968104882610" src="en-us_image_0000001803832641.png"></span></div>
</p></li><li id="kafka-ug-0002__li26339382112"><span>Grant topic permissions to users.</span><p><ul id="kafka-ug-0002__ul1324592715341"><li id="kafka-ug-0002__li3245132783414">To grant the same permissions to all users, select <strong id="kafka-ug-0002__b720650181312">Default permissions</strong> and then select permissions. As shown in the following figure, all users have the permission to publish messages to this topic.<div class="fignone" id="kafka-ug-0002__fig1296818488262"><span class="figcap"><b>Figure 1 </b>Granting the same permissions to all users</span><br><span><img id="kafka-ug-0002__image19968104882610" src="en-us_image_0000001803832641.png"></span></div> </li><li id="kafka-ug-0002__li98266361346">To grant different permissions to different users, do not select <strong id="kafka-ug-0002__b1891135551414">Default permissions</strong>. In the <strong id="kafka-ug-0002__b19982118144">Users</strong> area of the <strong id="kafka-ug-0002__b179918212145">Grant User Permission</strong> dialog box, select target users. If there are many users, enter the username in the search box for a quick search. In the <strong id="kafka-ug-0002__b8288885159">Selected</strong> area, configure permissions (<strong id="kafka-ug-0002__b828813810152">Subscribe</strong>, <strong id="kafka-ug-0002__b02896891510">Publish</strong>, or <strong id="kafka-ug-0002__b162895815154">Publish/Subscribe</strong>) for the users. As shown in the following figure, only the <strong id="kafka-ug-0002__b122738147152">test</strong>, <strong id="kafka-ug-0002__b927351491512">send</strong>, and <strong id="kafka-ug-0002__b142731814191520">receive</strong> users can subscribe to or publish messages to this topic. The <strong id="kafka-ug-0002__b1827361441516">send_receive</strong> user cannot subscribe to or publish messages to this topic.<div class="fignone" id="kafka-ug-0002__fig256093293211"><span class="figcap"><b>Figure 2 </b>Granting permissions to individual users</span><br><span><img id="kafka-ug-0002__image556017326322" src="en-us_image_0000001803837729.png"></span></div>
</li><li id="kafka-ug-0002__li98266361346">To grant different permissions to different users, do not select <strong id="kafka-ug-0002__b1891135551414">Default permissions</strong>. In the <strong id="kafka-ug-0002__b19982118144">Users</strong> area of the <strong id="kafka-ug-0002__b179918212145">Grant User Permission</strong> dialog box, select target users. In the <strong id="kafka-ug-0002__b8288885159">Selected</strong> area, configure permissions (<strong id="kafka-ug-0002__b828813810152">Subscribe</strong>, <strong id="kafka-ug-0002__b02896891510">Publish</strong>, or <strong id="kafka-ug-0002__b162895815154">Publish/Subscribe</strong>) for the users. As shown in the following figure, only the <strong id="kafka-ug-0002__b122738147152">test</strong>, <strong id="kafka-ug-0002__b927351491512">send</strong>, and <strong id="kafka-ug-0002__b142731814191520">receive</strong> users can subscribe to or publish messages to this topic. The <strong id="kafka-ug-0002__b1827361441516">send_receive</strong> user cannot subscribe to or publish messages to this topic.<div class="fignone" id="kafka-ug-0002__fig256093293211"><span class="figcap"><b>Figure 2 </b>Granting permissions to individual users</span><br><span><img id="kafka-ug-0002__image556017326322" src="en-us_image_0000001803837729.png"></span></div>
</li></ul> </li></ul>
<p id="kafka-ug-0002__p84261815153410"><strong id="kafka-ug-0002__b11658953165">If both the default and individual user permissions are configured for a topic, the union of the permissions is used.</strong> As shown in the following figure, the <strong id="kafka-ug-0002__b41554192161">test</strong> and <strong id="kafka-ug-0002__b1970421141615">receive</strong> users can subscribe to and publish messages to this topic.</p> <p id="kafka-ug-0002__p84261815153410"><strong id="kafka-ug-0002__b11658953165">If both the default and individual user permissions are configured for a topic, the union of the permissions is used.</strong> As shown in the following figure, the <strong id="kafka-ug-0002__b41554192161">test</strong> and <strong id="kafka-ug-0002__b1970421141615">receive</strong> users can subscribe to and publish messages to this topic.</p>
<div class="fignone" id="kafka-ug-0002__fig6811183873615"><span class="figcap"><b>Figure 3 </b>Granting topic permissions to users</span><br><span><img id="kafka-ug-0002__image1881153833617" src="en-us_image_0000001757003050.png"></span></div> <div class="fignone" id="kafka-ug-0002__fig6811183873615"><span class="figcap"><b>Figure 3 </b>Granting topic permissions to users</span><br><span><img id="kafka-ug-0002__image1881153833617" src="en-us_image_0000001757003050.png"></span></div>
@ -21,7 +20,7 @@
<div class="fignone" id="kafka-ug-0002__fig137611217184111"><span class="figcap"><b>Figure 4 </b>Viewing authorized users and their permissions</span><br><span><img id="kafka-ug-0002__image376101794110" src="en-us_image_0000001803846097.png"></span></div> <div class="fignone" id="kafka-ug-0002__fig137611217184111"><span class="figcap"><b>Figure 4 </b>Viewing authorized users and their permissions</span><br><span><img id="kafka-ug-0002__image376101794110" src="en-us_image_0000001803846097.png"></span></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0002__section1586284693920"><h4 class="sectiontitle">(Optional) Deleting Topic Permissions</h4><ol id="kafka-ug-0002__ol1077994717411"><li id="kafka-ug-0002__li15841952144118"><span>Log in to the console.</span></li><li id="kafka-ug-0002__li78417529412"><span>Click <span><img id="kafka-ug-0002__image1665094994" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0002__note118485234117"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p178415215415">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0002__section1586284693920"><h4 class="sectiontitle">Deleting Topic Permissions</h4><ol id="kafka-ug-0002__ol1077994717411"><li id="kafka-ug-0002__li15841952144118"><span>Log in to the console.</span></li><li id="kafka-ug-0002__li78417529412"><span>Click <span><img id="kafka-ug-0002__image1732627323" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0002__note118485234117"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0002__p178415215415">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0002__li138414528419"><span>Click <strong id="kafka-ug-0002__b44095891395711">Service List</strong> and choose <strong id="kafka-ug-0002__b82968184395711">Application</strong> &gt; <strong id="kafka-ug-0002__b112248447295711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0002__li108412522412"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0002__li9844521415"><span>In the navigation pane, choose <strong id="kafka-ug-0002__b1896910196359">Topics</strong>.</span></li><li id="kafka-ug-0002__li137961310438"><span>In the row containing the desired topic, click <strong id="kafka-ug-0002__b14290143212214">Grant User Permission</strong>.</span></li><li id="kafka-ug-0002__li11597174515430"><span>In the <strong id="kafka-ug-0002__b1638174819226">Selected</strong> area of the displayed <strong id="kafka-ug-0002__b1395256172218">Grant User Permission</strong> dialog box, locate the row that contains the user whose permissions are to be removed, click <strong id="kafka-ug-0002__b17662206192313">Delete</strong>, and click <strong id="kafka-ug-0002__b19957151615232">OK</strong>.</span></li></ol> </p></li><li id="kafka-ug-0002__li138414528419"><span>Click <strong id="kafka-ug-0002__b44095891395711">Service List</strong> and choose <strong id="kafka-ug-0002__b82968184395711">Application</strong> &gt; <strong id="kafka-ug-0002__b112248447295711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0002__li108412522412"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0002__li9844521415"><span>In the navigation pane, choose <strong id="kafka-ug-0002__b1896910196359">Topics</strong>.</span></li><li id="kafka-ug-0002__li137961310438"><span>In the row containing the desired topic, click <strong id="kafka-ug-0002__b14290143212214">Grant User Permission</strong>.</span></li><li id="kafka-ug-0002__li11597174515430"><span>In the <strong id="kafka-ug-0002__b1638174819226">Selected</strong> area of the displayed <strong id="kafka-ug-0002__b1395256172218">Grant User Permission</strong> dialog box, locate the row that contains the user whose permissions are to be removed, click <strong id="kafka-ug-0002__b17662206192313">Delete</strong>, and click <strong id="kafka-ug-0002__b19957151615232">OK</strong>.</span></li></ol>
</div> </div>

View File

@ -1,7 +1,7 @@
<a name="kafka-ug-0003"></a><a name="kafka-ug-0003"></a> <a name="kafka-ug-0003"></a><a name="kafka-ug-0003"></a>
<h1 class="topictitle1">Configuring Kafka Users</h1> <h1 class="topictitle1">Configuring Kafka ACL Users</h1>
<div id="body0000001088319628"><p id="kafka-ug-0003__p1338294114214">DMS supports access control list (ACL) for topics. You can differentiate user permissions by granting users different permissions in a topic.</p> <div id="body0000001088319628"><p id="kafka-ug-0003__p1338294114214">Kafka instances with ciphertext access enabled support access control list (ACL) for topics. You can isolate users by granting them different permissions in a topic.</p>
<p id="kafka-ug-0003__p8060118">This section describes how to create users, reset the password, and delete users with ciphertext access enabled. For details about how to grant topic permissions for users, see <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>.</p> <p id="kafka-ug-0003__p8060118">This section describes how to create users, reset the password, and delete users with ciphertext access enabled. For details about how to grant topic permissions for users, see <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>.</p>
<p id="kafka-ug-0003__p1458774110512"><strong id="kafka-ug-0003__b12253131455816">The maximum number of users that can be created for a Kafka instance is 20 or 500. Check the console for the actual limit.</strong></p> <p id="kafka-ug-0003__p1458774110512"><strong id="kafka-ug-0003__b12253131455816">The maximum number of users that can be created for a Kafka instance is 20 or 500. Check the console for the actual limit.</strong></p>
<p id="kafka-ug-0003__p1554081120315">There are two ways to create a user on the console. Accordingly, there are two ways to reset the user's password:</p> <p id="kafka-ug-0003__p1554081120315">There are two ways to create a user on the console. Accordingly, there are two ways to reset the user's password:</p>
@ -12,7 +12,28 @@
</div> </div>
<div class="section" id="kafka-ug-0003__section1516984134111"><h4 class="sectiontitle">Creating a User</h4><ol id="kafka-ug-0003__ol1698374734110"><li id="kafka-ug-0003__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li14905725134512"><span>Click <span><img id="kafka-ug-0003__image6685105755610" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0003__section1516984134111"><h4 class="sectiontitle">Creating a User</h4><ol id="kafka-ug-0003__ol1698374734110"><li id="kafka-ug-0003__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li14905725134512"><span>Click <span><img id="kafka-ug-0003__image6685105755610" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0003__li189561034172215"><span>Click <strong id="kafka-ug-0003__b212798716895711">Service List</strong> and choose <strong id="kafka-ug-0003__b98529038295711">Application</strong> &gt; <strong id="kafka-ug-0003__b203845457095711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li374185811449"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0003__li1035485134519"><span>On the <strong id="kafka-ug-0003__b1259335712715">Users</strong> page, click <strong id="kafka-ug-0003__b111191227816">Create User</strong>.</span></li><li id="kafka-ug-0003__li1269185312462"><span>In the displayed <strong id="kafka-ug-0003__b43101316194316">Create User</strong> dialog box, set the username and password, and click <strong id="kafka-ug-0003__b43101416104317">OK</strong>.</span><p><p id="kafka-ug-0003__p156921510185414">After the user is created, grant permissions to the user by referring to <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>.</p> </p></li><li id="kafka-ug-0003__li189561034172215"><span>Click <strong id="kafka-ug-0003__b212798716895711">Service List</strong> and choose <strong id="kafka-ug-0003__b98529038295711">Application</strong> &gt; <strong id="kafka-ug-0003__b203845457095711">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li374185811449"><span>Click the desired instance to go to the instance details page.</span></li><li id="kafka-ug-0003__li1035485134519"><span>On the <strong id="kafka-ug-0003__b1259335712715">Users</strong> page, click <strong id="kafka-ug-0003__b111191227816">Create User</strong>.</span></li><li id="kafka-ug-0003__li69251656205910"><span>Set user information by referring to <a href="kafka-ug-0003.html">Configuring Kafka ACL Users</a>.</span><p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0003__table1275514209" frame="border" border="1" rules="all"><caption><b>Table 1 </b>User creation parameters</caption><thead align="left"><tr id="kafka-ug-0003__row127520142016"><th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.8.2.6.2.1.2.3.1.1"><p id="kafka-ug-0003__p7641944173520">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="70%" id="mcps1.3.8.2.6.2.1.2.3.1.2"><p id="kafka-ug-0003__p264154419353">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="kafka-ug-0003__row1275131420010"><td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.8.2.6.2.1.2.3.1.1 "><p id="kafka-ug-0003__p1275214005">Username</p>
</td>
<td class="cellrowborder" valign="top" width="70%" headers="mcps1.3.8.2.6.2.1.2.3.1.2 "><p id="kafka-ug-0003__p14276181413010">The username used to access a Kafka instance, you can customize a name that complies with the rules: 464 characters; starts with a letter; can contain only letters, digits, hyphens (-), and underscores (_).</p>
</td>
</tr>
<tr id="kafka-ug-0003__row17276161419011"><td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.8.2.6.2.1.2.3.1.1 "><p id="kafka-ug-0003__p92761314208">Password</p>
</td>
<td class="cellrowborder" valign="top" width="70%" headers="mcps1.3.8.2.6.2.1.2.3.1.2 "><p id="kafka-ug-0003__p1027618149011">The password used to access a Kafka instance. A password must meet the following requirements:</p>
<ul id="kafka-ug-0003__ul1113719595913"><li id="kafka-ug-0003__li15561352706">Contains 8 to 32 characters.</li><li id="kafka-ug-0003__li5818649418">Contains at least three of the following character types: uppercase letters, lowercase letters, digits, and special characters `~! @#$ %^&amp;*()-_=+\|[{}];:'",&lt;.&gt;? and spaces, and cannot start with a hyphen (-).</li><li id="kafka-ug-0003__li994063220210">Cannot be the username spelled forward or backward.</li></ul>
</td>
</tr>
</tbody>
</table>
</div>
</p></li><li id="kafka-ug-0003__li1269185312462"><span>Click <strong id="kafka-ug-0003__b894372143917">OK</strong>.</span><p><p id="kafka-ug-0003__p156921510185414">After the user is created, grant permissions to the user by referring to <a href="kafka-ug-0002.html">Configuring Kafka Topic Permissions</a>.</p>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0003__section125811843123418"><a name="kafka-ug-0003__section125811843123418"></a><a name="section125811843123418"></a><h4 class="sectiontitle">Resetting the Password (for the Initial User)</h4><ol id="kafka-ug-0003__ol251622212416"><li id="kafka-ug-0003__li14877128154119"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li178771728154117"><span>Click <span><img id="kafka-ug-0003__image36143063912" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note19877192864117"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p4877028184118">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0003__section125811843123418"><a name="kafka-ug-0003__section125811843123418"></a><a name="section125811843123418"></a><h4 class="sectiontitle">Resetting the Password (for the Initial User)</h4><ol id="kafka-ug-0003__ol251622212416"><li id="kafka-ug-0003__li14877128154119"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li178771728154117"><span>Click <span><img id="kafka-ug-0003__image36143063912" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note19877192864117"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p4877028184118">Select the region where your Kafka instance is located.</p>
@ -23,16 +44,16 @@
</div></div> </div></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0003__section728275161010"><a name="kafka-ug-0003__section728275161010"></a><a name="section728275161010"></a><h4 class="sectiontitle">Resetting the User Password (for Non-initial Users)</h4><ol id="kafka-ug-0003__ol22913281193920"><li id="kafka-ug-0003__li5363940193920"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li9198519213"><span>Click <span><img id="kafka-ug-0003__image1835765291" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note61910516215"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p181912502116">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0003__section728275161010"><a name="kafka-ug-0003__section728275161010"></a><a name="section728275161010"></a><h4 class="sectiontitle">Resetting the User Password (for Non-initial Users)</h4><ol id="kafka-ug-0003__ol22913281193920"><li id="kafka-ug-0003__li5363940193920"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li9198519213"><span>Click <span><img id="kafka-ug-0003__image1248910052" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note61910516215"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p181912502116">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0003__li61911522111"><span>Click <strong id="kafka-ug-0003__b176245228314">Service List</strong> and choose <strong id="kafka-ug-0003__b13624172211314">Application</strong> &gt; <strong id="kafka-ug-0003__b12624192213111">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li18225237173632"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0003__li7459155164515"><span>On the <strong id="kafka-ug-0003__b021281211401">Users</strong> page, click <strong id="kafka-ug-0003__b42137122406">Reset Password</strong> in the row containing the desired user.</span></li><li id="kafka-ug-0003__li10847924172819"><span>Enter and confirm a new password, and click <strong id="kafka-ug-0003__b1591511193420">OK</strong>.</span><p><ul id="kafka-ug-0003__ul6531112611521"><li id="kafka-ug-0003__li253102610528">If the password is successfully reset, a success message is displayed.</li><li id="kafka-ug-0003__li453172616529">If the password fails to be reset, a failure message is displayed. In this case, reset the password again. If you still fail to reset the password after multiple attempts, contact customer service.</li></ul> </p></li><li id="kafka-ug-0003__li61911522111"><span>Click <strong id="kafka-ug-0003__b176245228314">Service List</strong> and choose <strong id="kafka-ug-0003__b13624172211314">Application</strong> &gt; <strong id="kafka-ug-0003__b12624192213111">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li18225237173632"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0003__li7459155164515"><span>On the <strong id="kafka-ug-0003__b021281211401">Users</strong> page, click <strong id="kafka-ug-0003__b42137122406">Reset Password</strong> in the row containing the desired user.</span></li><li id="kafka-ug-0003__li10847924172819"><span>Enter and confirm a new password, and click <strong id="kafka-ug-0003__b1591511193420">OK</strong>.</span><p><ul id="kafka-ug-0003__ul6531112611521"><li id="kafka-ug-0003__li253102610528">If the password is successfully reset, a success message is displayed.</li><li id="kafka-ug-0003__li453172616529">If the password fails to be reset, a failure message is displayed. In this case, reset the password again. If you still fail to reset the password after multiple attempts, contact customer service.</li></ul>
<div class="note" id="kafka-ug-0003__note42331528103619"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p205596336367">The system will display a success message only after the password is successfully reset on all brokers.</p> <div class="note" id="kafka-ug-0003__note42331528103619"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p205596336367">The system will display a success message only after the password is successfully reset on all brokers.</p>
</div></div> </div></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0003__section14541133610484"><h4 class="sectiontitle">Deleting a User</h4><ol id="kafka-ug-0003__ol1299471063115"><li id="kafka-ug-0003__li1443225255017"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li14432125216504"><span>Click <span><img id="kafka-ug-0003__image1875025979" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note543215210506"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p5432195217506">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0003__section14541133610484"><h4 class="sectiontitle">Deleting a User</h4><ol id="kafka-ug-0003__ol1299471063115"><li id="kafka-ug-0003__li1443225255017"><span>Log in to the console.</span></li><li id="kafka-ug-0003__li14432125216504"><span>Click <span><img id="kafka-ug-0003__image21067118" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0003__note543215210506"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p5432195217506">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0003__li154321352165017"><span>Click <strong id="kafka-ug-0003__b2125690036">Service List</strong> and choose <strong id="kafka-ug-0003__b209115655">Application</strong> &gt; <strong id="kafka-ug-0003__b537964125">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li843215245012"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0003__li133275219334"><span>Delete a user in either of the following ways:</span><p><ul id="kafka-ug-0003__ul202593219346"><li id="kafka-ug-0003__li10259182113344">On the <strong id="kafka-ug-0003__b17837202313438">Users</strong> page, click <strong id="kafka-ug-0003__b383772319432">Delete</strong> in the row containing the desired user.</li><li id="kafka-ug-0003__li62421826123420">On the <strong id="kafka-ug-0003__b737611514443">Users</strong> page, select one or more users and click <strong id="kafka-ug-0003__b17376175174418">Delete</strong> above the list.</li></ul> </p></li><li id="kafka-ug-0003__li154321352165017"><span>Click <strong id="kafka-ug-0003__b1425139183">Service List</strong> and choose <strong id="kafka-ug-0003__b1991659219">Application</strong> &gt; <strong id="kafka-ug-0003__b1167110199">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0003__li843215245012"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0003__li10282012152613"><span>In the navigation pane, choose <strong id="kafka-ug-0003__b1385995892611">Users</strong>.</span></li><li id="kafka-ug-0003__li133275219334"><span>Delete a user in either of the following ways:</span><p><ul id="kafka-ug-0003__ul202593219346"><li id="kafka-ug-0003__li10259182113344">In the row containing the desired user, click <strong id="kafka-ug-0003__b52431629162719">Delete</strong>.</li><li id="kafka-ug-0003__li62421826123420">Select one or more users and click <strong id="kafka-ug-0003__b17376175174418">Delete</strong> above the list.</li></ul>
<div class="note" id="kafka-ug-0003__note1781928182719"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p2082088102716">The initial user set when ciphertext access is enabled for the first time cannot be deleted.</p> <div class="note" id="kafka-ug-0003__note1781928182719"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0003__p2082088102716">The initial user set when ciphertext access is enabled for the first time cannot be deleted.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0003__li1343235275015"><span>In the displayed <strong id="kafka-ug-0003__b233134374614">Delete User</strong> dialog box, click <strong id="kafka-ug-0003__b0333154314614"></strong><strong id="kafka-ug-0003__b633512434466">OK</strong> to delete the user.</span></li></ol> </p></li><li id="kafka-ug-0003__li1343235275015"><span>In the displayed <strong id="kafka-ug-0003__b233134374614">Delete User</strong> dialog box, click <strong id="kafka-ug-0003__b0333154314614"></strong><strong id="kafka-ug-0003__b633512434466">OK</strong> to delete the user.</span></li></ol>

View File

@ -1,14 +1,14 @@
<a name="kafka-ug-0004"></a><a name="kafka-ug-0004"></a> <a name="kafka-ug-0004"></a><a name="kafka-ug-0004"></a>
<h1 class="topictitle1">Viewing Kafka Disk Usage</h1> <h1 class="topictitle1">Viewing Kafka Disk Usage</h1>
<div id="body0000001090230854"><p id="kafka-ug-0004__p14939848135420">This section describes how to view the disk usage of each broker on the Kafka console.</p> <div id="body0000001090230854"><p id="kafka-ug-0004__p849889185119">This section describes how to view the disk usage of each broker of a Kafka instance on the console.</p>
<div class="note" id="kafka-ug-0004__note192961281729"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0004__p17297138221">This function is unavailable for single-node instances.</p> <div class="note" id="kafka-ug-0004__note192961281729"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0004__p17297138221">This function is unavailable for single-node instances.</p>
</div></div> </div></div>
<div class="section" id="kafka-ug-0004__section4754556122714"><h4 class="sectiontitle">Viewing Kafka Disk Usage</h4><ol id="kafka-ug-0004__ol59872820289"><li id="kafka-ug-0004__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0004__li14905725134512"><span>Click <span><img id="kafka-ug-0004__image101211410165110" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0004__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0004__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0004__section4754556122714"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0004__ol59872820289"><li id="kafka-ug-0004__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0004__li14905725134512"><span>Click <span><img id="kafka-ug-0004__image101211410165110" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0004__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0004__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0004__li189561034172215"><span>Click <strong id="kafka-ug-0004__b2704863839572">Service List</strong> and choose <strong id="kafka-ug-0004__b5558757069572">Application</strong> &gt; <strong id="kafka-ug-0004__b9833927379572">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0004__li26520051765"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0004__b37651091376">Basic Information</strong> page.</span></li><li id="kafka-ug-0004__li31121328183210"><span>Go to the <strong id="kafka-ug-0004__b19135457115116">Disk Usage Statistics</strong> page.</span><p><div class="fignone" id="kafka-ug-0004__fig2022775915315"><span class="figcap"><b>Figure 1 </b>Viewing disk usage</span><br><span><img id="kafka-ug-0004__image42281359133118" src="en-us_image_0000001377028284.png"></span></div> </p></li><li id="kafka-ug-0004__li189561034172215"><span>Click <strong id="kafka-ug-0004__b2704863839572">Service List</strong> and choose <strong id="kafka-ug-0004__b5558757069572">Application</strong> &gt; <strong id="kafka-ug-0004__b9833927379572">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0004__li26520051765"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0004__b37651091376">Basic Information</strong> page.</span></li><li id="kafka-ug-0004__li31121328183210"><span>Go to the <strong id="kafka-ug-0004__b19135457115116">Disk Usage Statistics</strong> page.</span><p><p id="kafka-ug-0004__p41311311300">You can query topics that use the most disk space or topics that have used a specified amount or percentage of disk space.</p>
<p id="kafka-ug-0004__p41311311300">You can query topics that use the most disk space or topics that have used a specified amount or percentage of disk space.</p>
<p id="kafka-ug-0004__p199461301474">In the upper right corner of the page, click <strong id="kafka-ug-0004__b18333019158">View Metric</strong>. On the displayed Cloud Eye page, you can view metrics of Kafka instances.</p> <p id="kafka-ug-0004__p199461301474">In the upper right corner of the page, click <strong id="kafka-ug-0004__b18333019158">View Metric</strong>. On the displayed Cloud Eye page, you can view metrics of Kafka instances.</p>
<div class="fignone" id="kafka-ug-0004__fig2022775915315"><span class="figcap"><b>Figure 1 </b>Viewing disk usage</span><br><span><img id="kafka-ug-0004__image42281359133118" src="en-us_image_0000001377028284.png"></span></div>
</p></li></ol> </p></li></ol>
</div> </div>
</div> </div>

View File

@ -5,20 +5,60 @@
<div class="note" id="kafka-ug-0006__note16932250112213"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0006__p1593245052218">Changing the number of partitions does not restart the instance or affect services.</p> <div class="note" id="kafka-ug-0006__note16932250112213"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0006__p1593245052218">Changing the number of partitions does not restart the instance or affect services.</p>
</div></div> </div></div>
<p id="kafka-ug-0006__p481511371998">Methods for changing the partition quantity:</p> <p id="kafka-ug-0006__p481511371998">Methods for changing the partition quantity:</p>
<ul id="kafka-ug-0006__ul1521515294111"><li id="kafka-ug-0006__li621562931110"><a href="#kafka-ug-0006__section11349555102717">Method 1: By using Kafka console</a></li><li id="kafka-ug-0006__li965101814135"><a href="#kafka-ug-0006__section2227184716161">Method 2: By using Kafka CLI</a></li></ul> <ul id="kafka-ug-0006__ul1521515294111"><li id="kafka-ug-0006__li621562931110"><a href="#kafka-ug-0006__section11349555102717">Changing the Number of Topic Partitions (Console)</a></li><li id="kafka-ug-0006__li965101814135"><a href="#kafka-ug-0006__section2227184716161">Method 2: By using Kafka CLI</a></li></ul>
<div class="section" id="kafka-ug-0006__section11349555102717"><a name="kafka-ug-0006__section11349555102717"></a><a name="section11349555102717"></a><h4 class="sectiontitle">Method 1: By using Kafka console</h4><ol id="kafka-ug-0006__ol363518281765"><li id="kafka-ug-0006__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0006__li14905725134512"><span>Click <span><img id="kafka-ug-0006__image47311155134319" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0006__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0006__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0006__section11349555102717"><a name="kafka-ug-0006__section11349555102717"></a><a name="section11349555102717"></a><h4 class="sectiontitle">Changing the Number of Topic Partitions (Console)</h4><ol id="kafka-ug-0006__ol363518281765"><li id="kafka-ug-0006__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0006__li14905725134512"><span>Click <span><img id="kafka-ug-0006__image47311155134319" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0006__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0006__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0006__li076014201144"><span>Click <strong id="kafka-ug-0006__b4004497009576">Service List</strong> and choose <strong id="kafka-ug-0006__b7266307509576">Application</strong> &gt; <strong id="kafka-ug-0006__b15848465979576">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0006__li26520051765"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0006__li6318234617851"><span>In the navigation pane, choose <strong id="kafka-ug-0006__b12462383344">Topics</strong>.</span></li><li id="kafka-ug-0006__li1169275344516"><span>Modify the number of partitions using either of the following methods:</span><p><ul id="kafka-ug-0006__ul1146071715465"><li id="kafka-ug-0006__li104997486113">Select one or more topics and click <strong id="kafka-ug-0006__b216983043218">Edit Topic</strong> in the upper left corner.</li><li id="kafka-ug-0006__li53063508319">In the row containing the desired topic, click <strong id="kafka-ug-0006__b7161114013324">Edit</strong>.</li></ul> </p></li><li id="kafka-ug-0006__li076014201144"><span>Click <strong id="kafka-ug-0006__b4004497009576">Service List</strong> and choose <strong id="kafka-ug-0006__b7266307509576">Application</strong> &gt; <strong id="kafka-ug-0006__b15848465979576">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0006__li26520051765"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0006__li6318234617851"><span>In the navigation pane, choose <strong id="kafka-ug-0006__b12462383344">Topics</strong>.</span></li><li id="kafka-ug-0006__li1169275344516"><span>Modify the number of partitions using either of the following methods:</span><p><ul id="kafka-ug-0006__ul1146071715465"><li id="kafka-ug-0006__li104997486113">Select one or more topics and click <strong id="kafka-ug-0006__b216983043218">Edit Topic</strong> in the upper left corner.</li><li id="kafka-ug-0006__li53063508319">In the row containing the desired topic, click <strong id="kafka-ug-0006__b7161114013324">Edit</strong>.</li></ul>
</p></li><li id="kafka-ug-0006__li195891923113810"><span>In the <strong id="kafka-ug-0006__b20912661078">Edit Topic</strong> dialog box, enter the number of partitions and click <strong id="kafka-ug-0006__b49121361574">OK</strong>.</span><p><div class="note" id="kafka-ug-0006__note629814128341"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="kafka-ug-0006__ul490861418346"><li id="kafka-ug-0006__li590851414342">The number of partitions can only be increased.</li><li id="kafka-ug-0006__li165296265343">To ensure performance, the Kafka console allows a maximum of 200 partitions for each topic.</li><li id="kafka-ug-0006__li389811618143">The total number of partitions of all topics cannot exceed the maximum number of partitions allowed by the instance.</li></ul> </p></li><li id="kafka-ug-0006__li195891923113810"><span>In the <strong id="kafka-ug-0006__b20912661078">Edit Topic</strong> dialog box, enter the number of partitions and click <strong id="kafka-ug-0006__b49121361574">OK</strong>.</span><p><div class="note" id="kafka-ug-0006__note629814128341"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="kafka-ug-0006__ul490861418346"><li id="kafka-ug-0006__li590851414342">The number of partitions can only be increased.</li><li id="kafka-ug-0006__li165296265343">To ensure performance, the Kafka console allows a maximum of 200 partitions for each topic.</li><li id="kafka-ug-0006__li389811618143">The total partitions of all topics cannot exceed the maximum partitions of an instance. The maximum partitions of an instance varies by instance specifications. For details, see <a href="Kafka-specification.html">Specifications</a>.</li></ul>
</div></div> </div></div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0006__section2227184716161"><a name="kafka-ug-0006__section2227184716161"></a><a name="section2227184716161"></a><h4 class="sectiontitle">Method 2: By Using Kafka CLI</h4><p id="kafka-ug-0006__p168427588518">If your Kafka client version is later than 2.2, you can use <strong id="kafka-ug-0006__b20405425341">kafka-topics.sh</strong> to change the partition quantity.</p> <div class="section" id="kafka-ug-0006__section2227184716161"><a name="kafka-ug-0006__section2227184716161"></a><a name="section2227184716161"></a><h4 class="sectiontitle">Changing the Number of Topic Partitions (Client)</h4><p id="kafka-ug-0006__p168427588518">If your Kafka client version is later than 2.2, you can use <strong id="kafka-ug-0006__b20405425341">kafka-topics.sh</strong> to change the partition quantity.</p>
<div class="notice" id="kafka-ug-0006__note824621552414"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0006__p122461315192412">For an instance with ciphertext access enabled, if <strong id="kafka-ug-0006__b23791341124918">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0006__b83791041114919">false</strong>, topic partition quantity cannot be modified through the client.</p> <div class="notice" id="kafka-ug-0006__note824621552414"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0006__p122461315192412">For an instance with ciphertext access enabled, if <strong id="kafka-ug-0006__b23791341124918">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-0006__b83791041114919">false</strong>, topic partition quantity cannot be modified through the client.</p>
</div></div> </div></div>
<ul id="kafka-ug-0006__ul14955625613"><li id="kafka-ug-0006__li15955620614">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0006__b1025214246195">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0006__screen1719958142520">./kafka-topics.sh --bootstrap-server ${connection-address} --topic ${topic-name} --alter --partitions ${number-of-partitions}</pre> <ul id="kafka-ug-0006__ul14955625613"><li id="kafka-ug-0006__li15955620614">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0006__b1025214246195">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0006__screen1719958142520">./kafka-topics.sh --bootstrap-server ${connection-address} --topic ${topic-name} --alter --partitions ${number-of-partitions}</pre>
</li><li id="kafka-ug-0006__li2174501363">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0006__ol39441754276"><li id="kafka-ug-0006__li875065916200">(Optional) For the Kafka security protocol, is SASL_PLAINTEXT or SASL_SSL used?<ul id="kafka-ug-0006__ul2643717214"><li id="kafka-ug-0006__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. In other cases, create the <strong id="kafka-ug-0006__b188151684311296">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0006__b76876389111296">/config</strong> directory of the Kafka client. Add the username and password by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li><li id="kafka-ug-0006__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. In other cases, create the <strong id="kafka-ug-0006__b1947765606112926">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0006__b656175517112926">/config</strong> directory of the Kafka client. Add the username and password, and the SSL certificate configuration by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li></ul> <div class="p" id="kafka-ug-0006__p16123131016466">Parameter description:<ul id="kafka-ug-0006__ul171243103466"><li id="kafka-ug-0006__li412481004610"><strong id="kafka-ug-0006__b984182242104513">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0006__b1253653465104513">Connection</strong> area on the <strong id="kafka-ug-0006__b1394195604104513">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0006__li1812431011465"><strong id="kafka-ug-0006__b12345831123913">topic-name</strong>: topic name.</li><li id="kafka-ug-0006__li10124161017468"><strong id="kafka-ug-0006__b200775336910393">number-of-partitions</strong>: number of partitions in a topic.</li></ul>
</li><li id="kafka-ug-0006__li529219395271">Run the following command in the <strong id="kafka-ug-0006__b1843624341918">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0006__screen117611716133716">./kafka-topics.sh --bootstrap-server ${connection-address} --topic ${topic-name} --alter --partitions ${number-of-partitions} --command-config ./config/ssl-user-config.properties </pre> </div>
<p id="kafka-ug-0006__p13124010174612">Example:</p>
<pre class="screen" id="kafka-ug-0006__screen1012471012461">[root@ecs-kafka bin]# ./kafka-topics.sh --bootstrap-server 192.168.xx.xx:9092,192.168.xx.xx:9092,192.168.xx.xx:9092 --topic topic-01 --alter --partitions 6
[root@ecs-kafka bin]#</pre>
</li><li id="kafka-ug-0006__li2174501363">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0006__ol39441754276"><li id="kafka-ug-0006__li4759815496">(Optional) Modify the client configuration file.<div class="p" id="kafka-ug-0006__p1022613934910"><a name="kafka-ug-0006__li4759815496"></a><a name="li4759815496"></a>View <strong id="kafka-ug-0006__b950671517402">Security Protocol</strong> in the <strong id="kafka-ug-0006__b150613155404">Connection</strong> area on the <strong id="kafka-ug-0006__b145064156407">Basic Information</strong> page on the Kafka console. The configuration settings vary depending on the protocol.<ul id="kafka-ug-0006__ul2643717214"><li id="kafka-ug-0006__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. Otherwise, create the <strong id="kafka-ug-0006__b69866322811152">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0006__b16364102211152">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0006__screen34857258202">security.protocol=SASL_PLAINTEXT
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0006__kafka-ug-180604018_b883312781111">scram.</strong><strong id="kafka-ug-0006__kafka-ug-180604018_b1783311741112">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0006__kafka-ug-180604018_b128331377110">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0006__kafka-ug-180604018_b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0006__kafka-ug-180604018_b964813191391">PLAIN</strong></pre>
<p id="kafka-ug-0006__p117102681410">Parameter description: <strong id="kafka-ug-0006__b1904697958103923">username</strong> and <strong id="kafka-ug-0006__b770130983103923">password</strong> are the ones you set when enabling ciphertext access for the first time or when creating a user.</p>
</li><li id="kafka-ug-0006__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. Otherwise, create the <strong id="kafka-ug-0006__b176489501711152">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0006__b13659348411152">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0006__screen111158498205">security.protocol=SASL_SSL
ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0006__kafka-ug-180604018_b4657131681320">scram.</strong><strong id="kafka-ug-0006__kafka-ug-180604018_b20657171612138">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0006__kafka-ug-180604018_b15657121620131">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0006__kafka-ug-180604018_b0657101619133">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0006__kafka-ug-180604018_b1665720164136">PLAIN</strong></pre>
<p id="kafka-ug-0006__p08411946162017">Parameter description:</p>
<ul id="kafka-ug-0006__ul659001611211"><li id="kafka-ug-0006__kafka-ug-180604018_li9578173610155"><strong id="kafka-ug-0006__kafka-ug-180604018_b15940166202617">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-0006__kafka-ug-180604018_b1994056112615">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-0006__kafka-ug-180604018_li4578153611159"><strong id="kafka-ug-0006__kafka-ug-180604018_b02112214397">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-0006__kafka-ug-180604018_b3211521103916">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-0006__kafka-ug-180604018_li2057818362154"><strong id="kafka-ug-0006__kafka-ug-180604018_b163656567392">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-0006__kafka-ug-180604018_b4285516104010">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li><li id="kafka-ug-0006__kafka-ug-180604018_li194571669169"><strong id="kafka-ug-0006__kafka-ug-180604018_b16925191015415">username</strong> and <strong id="kafka-ug-0006__kafka-ug-180604018_b17925141034110">password</strong>: username and password you set when enabling ciphertext access for the first time or when creating a user.</li></ul>
</li></ul>
</div>
</li><li id="kafka-ug-0006__li529219395271">Run the following command in the <strong id="kafka-ug-0006__b1843624341918">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0006__screen117611716133716">./kafka-topics.sh --bootstrap-server ${connection-address} --topic ${topic-name} --alter --partitions ${number-of-partitions} --command-config ../config/ssl-user-config.properties </pre>
<div class="p" id="kafka-ug-0006__p1754112091313">Parameter description:<ul id="kafka-ug-0006__ul64101149812"><li id="kafka-ug-0006__li1338011599918"><strong id="kafka-ug-0006__b1773641427104513">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0006__b636077803104513">Connection</strong> area on the <strong id="kafka-ug-0006__b1435719161104513">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0006__li1541015142810"><strong id="kafka-ug-0006__b225693313457">topic-name</strong>: topic name.</li><li id="kafka-ug-0006__li814814139119"><strong id="kafka-ug-0006__b36053635310393">number-of-partitions</strong>: number of partitions in a topic.</li></ul>
</div>
<p id="kafka-ug-0006__p812620172424">Example:</p>
<pre class="screen" id="kafka-ug-0006__screen17506173954217">[root@ecs-kafka bin]# ./kafka-topics.sh --bootstrap-server 192.168.xx.xx:9093,192.168.xx.xx:9093,192.168.xx.xx:9093 --topic topic-01 --alter --partitions 6 --command-config ../config/ssl-user-config.properties
[root@ecs-kafka bin]#</pre>
<p id="kafka-ug-0006__p2898185714211"></p>
</li></ol> </li></ol>
</li></ul> </li></ul>
</div> </div>

File diff suppressed because it is too large Load Diff

View File

@ -9,7 +9,7 @@
</li> </li>
<li class="ulchildlink"><strong><a href="kafka_ug_0021.html">Querying the Kafka Consumer Group List</a></strong><br> <li class="ulchildlink"><strong><a href="kafka_ug_0021.html">Querying the Kafka Consumer Group List</a></strong><br>
</li> </li>
<li class="ulchildlink"><strong><a href="kafka-ug-0015.html">Viewing Kafka Consumer Details</a></strong><br> <li class="ulchildlink"><strong><a href="kafka-ug-0015.html">Viewing Kafka Consumer Information</a></strong><br>
</li> </li>
<li class="ulchildlink"><strong><a href="kafka-ug-0014.html">Viewing and Resetting Kafka Consumption Offsets</a></strong><br> <li class="ulchildlink"><strong><a href="kafka-ug-0014.html">Viewing and Resetting Kafka Consumption Offsets</a></strong><br>
</li> </li>

View File

@ -3,10 +3,10 @@
<h1 class="topictitle1">Deleting a Kafka Consumer Group</h1> <h1 class="topictitle1">Deleting a Kafka Consumer Group</h1>
<div id="body0000001285861801"><p id="kafka-ug-0012__p19718355594">You can delete a consumer group in either of the following ways:</p> <div id="body0000001285861801"><p id="kafka-ug-0012__p19718355594">You can delete a consumer group in either of the following ways:</p>
<ul id="kafka-ug-0012__ul136678571796"><li id="kafka-ug-0012__li1489914391011">Method 1: Delete a consumer group on the console.</li><li id="kafka-ug-0012__li96670571191">Method 2: Use <a href="https://cwiki.apache.org/confluence/display/KAFKA/Clients" target="_blank" rel="noopener noreferrer">Kafka CLI</a> to delete a consumer group. (Ensure that the Kafka instance version is the same as the CLI version.)</li></ul> <ul id="kafka-ug-0012__ul136678571796"><li id="kafka-ug-0012__li1489914391011">Method 1: Delete a consumer group on the console.</li><li id="kafka-ug-0012__li96670571191">Method 2: Use <a href="https://cwiki.apache.org/confluence/display/KAFKA/Clients" target="_blank" rel="noopener noreferrer">Kafka CLI</a> to delete a consumer group. (Ensure that the Kafka instance version is the same as the CLI version.)</li></ul>
<div class="section" id="kafka-ug-0012__section78321825104815"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0012__p0333193016482">The status of the consumer group to be deleted is <strong id="kafka-ug-0012__b16318504410">EMPTY</strong>.</p>
</div>
<div class="section" id="kafka-ug-0012__section43981032181116"><h4 class="sectiontitle">Constraints</h4><ul id="kafka-ug-0012__ul19524221159"><li id="kafka-ug-0012__li15524162141519">If <strong id="kafka-ug-0012__b15691557155319">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0012__b1610414115541">true</strong>, the consumer group status is <strong id="kafka-ug-0012__b587514618541">EMPTY</strong>, and no offset has been submitted, the system automatically deletes the consumer group 10 minutes later.</li><li id="kafka-ug-0012__li16747114201511">If <strong id="kafka-ug-0012__b1064494175417">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0012__b2032333915440">false</strong>, the system does not automatically delete consumer groups. You can manually delete them.</li><li id="kafka-ug-0012__li1356143703910">If a consumer group has never committed an offset, the group will be deleted after the Kafka instance restarts.</li></ul> <div class="section" id="kafka-ug-0012__section43981032181116"><h4 class="sectiontitle">Constraints</h4><ul id="kafka-ug-0012__ul19524221159"><li id="kafka-ug-0012__li15524162141519">If <strong id="kafka-ug-0012__b15691557155319">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0012__b1610414115541">true</strong>, the consumer group status is <strong id="kafka-ug-0012__b587514618541">EMPTY</strong>, and no offset has been submitted, the system automatically deletes the consumer group 10 minutes later.</li><li id="kafka-ug-0012__li16747114201511">If <strong id="kafka-ug-0012__b1064494175417">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0012__b2032333915440">false</strong>, the system does not automatically delete consumer groups. You can manually delete them.</li><li id="kafka-ug-0012__li1356143703910">If a consumer group has never committed an offset, the group will be deleted after the Kafka instance restarts.</li></ul>
</div> </div>
<div class="section" id="kafka-ug-0012__section78321825104815"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0012__p0333193016482">The status of the consumer group to be deleted is <strong id="kafka-ug-0012__b16318504410">EMPTY</strong>.</p>
</div>
<div class="section" id="kafka-ug-0012__section147341279161"><h4 class="sectiontitle">Method 1: Deleting a Consumer Group on the Console</h4><ol id="kafka-ug-0012__ol3215151213171"><li id="kafka-ug-0012__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0012__li14905725134512"><span>Click <span><img id="kafka-ug-0012__image187691835191911" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0012__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0012__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0012__section147341279161"><h4 class="sectiontitle">Method 1: Deleting a Consumer Group on the Console</h4><ol id="kafka-ug-0012__ol3215151213171"><li id="kafka-ug-0012__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0012__li14905725134512"><span>Click <span><img id="kafka-ug-0012__image187691835191911" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0012__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0012__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0012__li189561034172215"><span>Click <strong id="kafka-ug-0012__b194429960395716">Service List</strong> and choose <strong id="kafka-ug-0012__b63056350295716">Application</strong> &gt; <strong id="kafka-ug-0012__b186573218495716">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0012__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0012__li1063043712019"><span>In the navigation pane, choose the <strong id="kafka-ug-0012__b8238267010">Consumer Groups</strong> tab.</span></li><li id="kafka-ug-0012__li432114271306"><span>Delete consumer groups using either of the following methods:</span><p><ul id="kafka-ug-0012__ul54985481419"><li id="kafka-ug-0012__li104997486113">Select one or more consumer groups and click <strong id="kafka-ug-0012__b174279394017">Delete Consumer Group</strong> above the consumer group list.</li><li id="kafka-ug-0012__li53063508319">In the row containing the consumer group you want to delete, click <strong id="kafka-ug-0012__b169415571006">Delete</strong>.</li></ul> </p></li><li id="kafka-ug-0012__li189561034172215"><span>Click <strong id="kafka-ug-0012__b194429960395716">Service List</strong> and choose <strong id="kafka-ug-0012__b63056350295716">Application</strong> &gt; <strong id="kafka-ug-0012__b186573218495716">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0012__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0012__li1063043712019"><span>In the navigation pane, choose the <strong id="kafka-ug-0012__b8238267010">Consumer Groups</strong> tab.</span></li><li id="kafka-ug-0012__li432114271306"><span>Delete consumer groups using either of the following methods:</span><p><ul id="kafka-ug-0012__ul54985481419"><li id="kafka-ug-0012__li104997486113">Select one or more consumer groups and click <strong id="kafka-ug-0012__b174279394017">Delete Consumer Group</strong> above the consumer group list.</li><li id="kafka-ug-0012__li53063508319">In the row containing the consumer group you want to delete, click <strong id="kafka-ug-0012__b169415571006">Delete</strong>.</li></ul>
@ -17,15 +17,53 @@
</p></li><li id="kafka-ug-0012__li3295105062310"><span>In the displayed <strong id="kafka-ug-0012__b41051219196">Delete Consumer Group</strong> dialog box, click <strong id="kafka-ug-0012__b825117552713"></strong><strong id="kafka-ug-0012__b2237711172714">OK</strong>.</span></li></ol> </p></li><li id="kafka-ug-0012__li3295105062310"><span>In the displayed <strong id="kafka-ug-0012__b41051219196">Delete Consumer Group</strong> dialog box, click <strong id="kafka-ug-0012__b825117552713"></strong><strong id="kafka-ug-0012__b2237711172714">OK</strong>.</span></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0012__section119712262169"><h4 class="sectiontitle">Method 2: Using the CLI to Delete a Consumer Group</h4><p id="kafka-ug-0012__p1289365114509">The following uses Linux as an example.</p> <div class="section" id="kafka-ug-0012__section119712262169"><h4 class="sectiontitle">Method 2: Using the CLI to Delete a Consumer Group</h4><p id="kafka-ug-0012__p1289365114509">The following uses Linux as an example.</p>
<ol id="kafka-ug-0012__ol151131034144715"><li id="kafka-ug-0012__li3113834184715"><span>Download Kafka CLI <a href="https://archive.apache.org/dist/kafka/1.1.0/kafka_2.11-1.1.0.tgz" target="_blank" rel="noopener noreferrer">v1.1.0</a>, <a href="https://archive.apache.org/dist/kafka/2.3.0/kafka_2.11-2.3.0.tgz" target="_blank" rel="noopener noreferrer">v2.3.0</a>, or <a href="https://archive.apache.org/dist/kafka/2.7.2/kafka_2.12-2.7.2.tgz" target="_blank" rel="noopener noreferrer">v2.7.2</a>, or <a href="https://archive.apache.org/dist/kafka/3.4.0/kafka_2.12-3.4.0.tgz" target="_blank" rel="noopener noreferrer">v3.4.0</a>. Ensure that the Kafka instance and the CLI are of the same version.</span></li><li id="kafka-ug-0012__li717413501994"><span>Use the CLI to connect to the Kafka instance. For details, see <a href="kafka-ug-180604020.html">Connecting to Kafka Using the Client (Plaintext Access)</a> or <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</span></li><li id="kafka-ug-0012__li17703181513151"><span>In the <strong id="kafka-ug-0012__b194387418295">/bin</strong> directory of the Kafka client, run the following command:</span><p><pre class="screen" id="kafka-ug-0012__screen41607161270">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --delete --group ${consumer-group-name}</pre> <ul id="kafka-ug-0012__ul14955625613"><li id="kafka-ug-0012__li15955620614">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0012__b8877117132710">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0012__screen41607161270">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --delete --group ${consumer-group-name}</pre>
<p id="kafka-ug-0012__p86741581374">Example:</p> <p id="kafka-ug-0012__p143853199482">Parameter description:</p>
<pre class="screen" id="kafka-ug-0012__screen12971814192">[root@zk-server-1 bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.1.245:9091,192.168.1.86:9091,192.168.1.128:9091 --delete --group bbbb <ul id="kafka-ug-0012__ul2021063384518"><li id="kafka-ug-0012__li321063354514"><strong id="kafka-ug-0012__b1382184924104516">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0012__b61395969104516">Connection</strong> area on the <strong id="kafka-ug-0012__b236320280104516">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0012__li13143313464"><strong id="kafka-ug-0012__b189991456172713">consumer-group-name</strong>: consumer group name.</li></ul>
Note: This will not show information about old Zookeeper-based consumers. <p id="kafka-ug-0012__p103861619134812">Example:</p>
Deletion of requested consumer groups ('bbbb') was successful.</pre> <pre class="screen" id="kafka-ug-0012__screen618562312528">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9092,192.168.xx.xx:9092,192.168.xx.xx:9092 --delete --group group-01
<div class="note" id="kafka-ug-0012__note3326106122015"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0012__p193261612013">If ciphertext access is enabled for the Kafka instance, the <strong id="kafka-ug-0012__b1465913314122">--command-config <em id="kafka-ug-0012__i7988145613202">{consumer.properties file with SASL authentication}</em></strong> parameter must be added to the preceding commands. For details about the <strong id="kafka-ug-0012__b5517172117212">consumer.properties</strong> file, see <a href="kafka-ug-180801001.html">Connecting to Kafka Using the Client (Ciphertext Access)</a>.</p> Deletion of requested consumer groups ('group-01') was successful.
</div></div> [root@ecs-kafka bin]#</pre>
</p></li></ol> </li><li id="kafka-ug-0012__li2174501363">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0012__ol39441754276"><li id="kafka-ug-0012__li339418234494">(Optional) Modify the client configuration file.<div class="p" id="kafka-ug-0012__p10850192434916"><a name="kafka-ug-0012__li339418234494"></a><a name="li339418234494"></a>View <strong id="kafka-ug-0012__b180110748951321">Security Protocol</strong> in the <strong id="kafka-ug-0012__b28770223951321">Connection</strong> area on the <strong id="kafka-ug-0012__b49363624951321">Basic Information</strong> page on the Kafka console. The configuration settings vary depending on the protocol.<ul id="kafka-ug-0012__ul2643717214"><li id="kafka-ug-0012__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. Otherwise, create the <strong id="kafka-ug-0012__b77373690651331">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0012__b138544866851331">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0012__screen15787187202220">security.protocol=SASL_PLAINTEXT
<p id="kafka-ug-0012__p14187175991615"></p> # If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0012__kafka-ug-180604018_b883312781111">scram.</strong><strong id="kafka-ug-0012__kafka-ug-180604018_b1783311741112">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0012__kafka-ug-180604018_b128331377110">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0012__kafka-ug-180604018_b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0012__kafka-ug-180604018_b964813191391">PLAIN</strong></pre>
<p id="kafka-ug-0012__p117102681410">Parameter description: <strong id="kafka-ug-0012__b2118915561103929">username</strong> and <strong id="kafka-ug-0012__b596475292103929">password</strong> are the ones you set when enabling ciphertext access for the first time or when creating a user.</p>
</li><li id="kafka-ug-0012__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. Otherwise, create the <strong id="kafka-ug-0012__b152984663051331">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0012__b12634745651331">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0012__screen7661133992211">security.protocol=SASL_SSL
ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0012__kafka-ug-180604018_b4657131681320">scram.</strong><strong id="kafka-ug-0012__kafka-ug-180604018_b20657171612138">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0012__kafka-ug-180604018_b15657121620131">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0012__kafka-ug-180604018_b0657101619133">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0012__kafka-ug-180604018_b1665720164136">PLAIN</strong></pre>
<p id="kafka-ug-0012__p497913422220">Parameter description:</p>
<ul id="kafka-ug-0012__ul18362175202315"><li id="kafka-ug-0012__kafka-ug-180604018_li9578173610155"><strong id="kafka-ug-0012__kafka-ug-180604018_b15940166202617">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-0012__kafka-ug-180604018_b1994056112615">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-0012__kafka-ug-180604018_li4578153611159"><strong id="kafka-ug-0012__kafka-ug-180604018_b02112214397">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-0012__kafka-ug-180604018_b3211521103916">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-0012__kafka-ug-180604018_li2057818362154"><strong id="kafka-ug-0012__kafka-ug-180604018_b163656567392">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-0012__kafka-ug-180604018_b4285516104010">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li><li id="kafka-ug-0012__kafka-ug-180604018_li194571669169"><strong id="kafka-ug-0012__kafka-ug-180604018_b16925191015415">username</strong> and <strong id="kafka-ug-0012__kafka-ug-180604018_b17925141034110">password</strong>: username and password you set when enabling ciphertext access for the first time or when creating a user.</li></ul>
</li></ul>
</div>
</li><li id="kafka-ug-0012__li529219395271">In the <strong id="kafka-ug-0012__b426114863017">/bin</strong> directory of the Kafka client, run the following command:<pre class="screen" id="kafka-ug-0012__screen117611716133716">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --delete --group ${consumer-group-name} --command-config ../config/ssl-user-config.properties</pre>
<p id="kafka-ug-0012__p26601411816">Parameter description:</p>
<ul id="kafka-ug-0012__ul1555554105915"><li id="kafka-ug-0012__li75552411593"><strong id="kafka-ug-0012__b199138581104516">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0012__b834501062104516">Connection</strong> area on the <strong id="kafka-ug-0012__b768282750104516">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0012__li75551041598"><strong id="kafka-ug-0012__b1855617486289">consumer-group-name</strong>: consumer group name.</li></ul>
<p id="kafka-ug-0012__p10626666416">Example:</p>
<pre class="screen" id="kafka-ug-0012__screen16140191044820">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9093,192.168.xx.xx:9093,192.168.xx.xx:9093 --delete --group group-02 --command-config ../config/ssl-user-config.properties
Deletion of requested consumer groups ('group-02') was successful.
[root@ecs-kafka bin]#</pre>
<p id="kafka-ug-0012__p46116619489"></p>
</li></ol>
</li></ul>
</div> </div>
</div> </div>
<div> <div>

View File

@ -1,7 +1,7 @@
<a name="kafka-ug-0014"></a><a name="kafka-ug-0014"></a> <a name="kafka-ug-0014"></a><a name="kafka-ug-0014"></a>
<h1 class="topictitle1">Viewing and Resetting Kafka Consumption Offsets</h1> <h1 class="topictitle1">Viewing and Resetting Kafka Consumption Offsets</h1>
<div id="body0000001241621406"><p id="kafka-ug-0014__p11638355589">This section describes how to view and reset consumption offsets. Resetting consumption offsets is to change the consumption position for consumers.</p> <div id="body0000001241621406"><p id="kafka-ug-0014__p11638355589">A consumption offset indicates the consumption progress of a consumer. This section describes how to view and reset consumption offsets.</p>
<div class="notice" id="kafka-ug-0014__note228194010371"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0014__p1528154073712">Messages may be retrieved more than once after the offset is reset. Exercise caution when performing this operation.</p> <div class="notice" id="kafka-ug-0014__note228194010371"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-0014__p1528154073712">Messages may be retrieved more than once after the offset is reset. Exercise caution when performing this operation.</p>
</div></div> </div></div>
<div class="section" id="kafka-ug-0014__section8241820195010"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0014__p6328625145014">The consumer offset cannot be reset on the fly. You must first stop retrieval of the desired consumer group.</p> <div class="section" id="kafka-ug-0014__section8241820195010"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0014__p6328625145014">The consumer offset cannot be reset on the fly. You must first stop retrieval of the desired consumer group.</p>
@ -13,14 +13,79 @@
</p></li><li id="kafka-ug-0014__li62547586143"><span>Click <strong id="kafka-ug-0014__b187677460595717">Service List</strong> and choose <strong id="kafka-ug-0014__b146841523695717">Application</strong> &gt; <strong id="kafka-ug-0014__b160124893495717">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0014__li98548271981"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0014__li1285417275812"><span>In the navigation pane, choose <strong id="kafka-ug-0014__b16867605412">Consumer Groups</strong>.</span></li><li id="kafka-ug-0014__li188541727584"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0014__li186129567324"><span>On the <strong id="kafka-ug-0014__b23461221114119">Consumer Offset</strong> tab page, view the list of topics that the consumer group has subscribed to, total number of messages accumulated in the topic, message consumption progress in each partition of the topic (accumulated messages, offset, latest offset, consumer ID, consumer address, and client ID).</span></li><li id="kafka-ug-0014__li15501253173615"><span>(Optional) To query the consumer offsets of a specific topic, enter the topic name in the search box and press <strong id="kafka-ug-0014__b189013004614">Enter</strong>.</span></li></ol> </p></li><li id="kafka-ug-0014__li62547586143"><span>Click <strong id="kafka-ug-0014__b187677460595717">Service List</strong> and choose <strong id="kafka-ug-0014__b146841523695717">Application</strong> &gt; <strong id="kafka-ug-0014__b160124893495717">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0014__li98548271981"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0014__li1285417275812"><span>In the navigation pane, choose <strong id="kafka-ug-0014__b16867605412">Consumer Groups</strong>.</span></li><li id="kafka-ug-0014__li188541727584"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0014__li186129567324"><span>On the <strong id="kafka-ug-0014__b23461221114119">Consumer Offset</strong> tab page, view the list of topics that the consumer group has subscribed to, total number of messages accumulated in the topic, message consumption progress in each partition of the topic (accumulated messages, offset, latest offset, consumer ID, consumer address, and client ID).</span></li><li id="kafka-ug-0014__li15501253173615"><span>(Optional) To query the consumer offsets of a specific topic, enter the topic name in the search box and press <strong id="kafka-ug-0014__b189013004614">Enter</strong>.</span></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0014__section105713498316"><h4 class="sectiontitle">Viewing Consumer Offsets (Kafka CLI)</h4><ul id="kafka-ug-0014__ul551916226323"><li id="kafka-ug-0014__li11519112253212">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0014__b135492056291">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0014__screen1651912210321">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --offsets --describe --all-groups</pre> <div class="section" id="kafka-ug-0014__section105713498316"><h4 class="sectiontitle">Viewing Consumer Offsets (Kafka CLI)</h4><ul id="kafka-ug-0014__ul551916226323"><li id="kafka-ug-0014__li11519112253212">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0014__b135492056291">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0014__screen1651912210321">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --offsets --describe --all-groups</pre>
</li><li id="kafka-ug-0014__li16519132216327">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0014__ol13519182213216"><li id="kafka-ug-0014__li875065916200">(Optional) For the Kafka security protocol, is SASL_PLAINTEXT or SASL_SSL used?<ul id="kafka-ug-0014__ul2643717214"><li id="kafka-ug-0014__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. In other cases, create the <strong id="kafka-ug-0014__b205438282112910">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0014__b1959869613112910">/config</strong> directory of the Kafka client. Add the username and password by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li><li id="kafka-ug-0014__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. In other cases, create the <strong id="kafka-ug-0014__b1432059729112929">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0014__b1707347478112929">/config</strong> directory of the Kafka client. Add the username and password, and the SSL certificate configuration by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li></ul> <p id="kafka-ug-0014__p251111134315">Parameter description: <strong id="kafka-ug-0014__b134406338451251">connection-address</strong> indicates the Kafka instance address, which can be obtained in the <strong id="kafka-ug-0014__b150607531851251">Connection</strong> area on the <strong id="kafka-ug-0014__b200934741051251">Basic Information</strong> page on the Kafka console.</p>
</li><li id="kafka-ug-0014__li155191222323">Run the following command in the <strong id="kafka-ug-0014__b1134982215299">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0014__screen17519102263211">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --offsets --describe --all-groups --command-config ./config/ssl-user-config.properties </pre> <p id="kafka-ug-0014__p1968375217431">Example:</p>
<pre class="screen" id="kafka-ug-0014__screen1773018065718">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9092,192.168.xx.xx:9092,192.168.xx.xx:9092 --offsets --describe --all-groups
Consumer group '__consumer-group-dial-test' has no active members.
GROUP TOPIC PARTITION CURRENT-OFFSET LOG-END-OFFSET LAG CONSUMER-ID HOST CLIENT-ID
__consumer-group-dial-test __dms_dial_test 0 350 350 0 - - -
__consumer-group-dial-test __dms_dial_test 1 350 350 0 - - -
__consumer-group-dial-test __dms_dial_test 2 350 350 0 - - -
Consumer group 'test' has no active members.
GROUP TOPIC PARTITION CURRENT-OFFSET LOG-END-OFFSET LAG CONSUMER-ID HOST CLIENT-ID
test topic-01 0 5 5 0 - - -
test topic-01 1 3 3 0 - - -
test topic-01 2 10 10 0 - - -
[root@ecs-kafka bin]#</pre>
</li><li id="kafka-ug-0014__li16519132216327">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0014__ol13519182213216"><li id="kafka-ug-0014__li17434105674910">(Optional) Modify the client configuration file.<div class="p" id="kafka-ug-0014__p12707257114914"><a name="kafka-ug-0014__li17434105674910"></a><a name="li17434105674910"></a>View <strong id="kafka-ug-0014__b184286886251320">Security Protocol</strong> in the <strong id="kafka-ug-0014__b18163868051320">Connection</strong> area on the <strong id="kafka-ug-0014__b8655494751320">Basic Information</strong> page on the Kafka console. The configuration settings vary depending on the protocol.<ul id="kafka-ug-0014__ul2643717214"><li id="kafka-ug-0014__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. Otherwise, create the <strong id="kafka-ug-0014__b146568151330">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0014__b33993736351330">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0014__screen1431203505712">security.protocol=SASL_PLAINTEXT
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0014__kafka-ug-180604018_b883312781111">scram.</strong><strong id="kafka-ug-0014__kafka-ug-180604018_b1783311741112">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0014__kafka-ug-180604018_b128331377110">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0014__kafka-ug-180604018_b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0014__kafka-ug-180604018_b964813191391">PLAIN</strong></pre>
<p id="kafka-ug-0014__p2629183165718">Parameter description: <strong id="kafka-ug-0014__b1183042314103927">username</strong> and <strong id="kafka-ug-0014__b530357212103927">password</strong> are the ones you set when enabling ciphertext access for the first time or when creating a user.</p>
</li><li id="kafka-ug-0014__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. Otherwise, create the <strong id="kafka-ug-0014__b28057774151330">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0014__b94293072351330">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0014__screen1586842195817">security.protocol=SASL_SSL
ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0014__kafka-ug-180604018_b4657131681320">scram.</strong><strong id="kafka-ug-0014__kafka-ug-180604018_b20657171612138">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0014__kafka-ug-180604018_b15657121620131">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0014__kafka-ug-180604018_b0657101619133">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0014__kafka-ug-180604018_b1665720164136">PLAIN</strong></pre>
<p id="kafka-ug-0014__p574013714580">Parameter description:</p>
<ul id="kafka-ug-0014__ul179961085914"><li id="kafka-ug-0014__kafka-ug-180604018_li9578173610155"><strong id="kafka-ug-0014__kafka-ug-180604018_b15940166202617">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-0014__kafka-ug-180604018_b1994056112615">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-0014__kafka-ug-180604018_li4578153611159"><strong id="kafka-ug-0014__kafka-ug-180604018_b02112214397">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-0014__kafka-ug-180604018_b3211521103916">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-0014__kafka-ug-180604018_li2057818362154"><strong id="kafka-ug-0014__kafka-ug-180604018_b163656567392">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-0014__kafka-ug-180604018_b4285516104010">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li><li id="kafka-ug-0014__kafka-ug-180604018_li194571669169"><strong id="kafka-ug-0014__kafka-ug-180604018_b16925191015415">username</strong> and <strong id="kafka-ug-0014__kafka-ug-180604018_b17925141034110">password</strong>: username and password you set when enabling ciphertext access for the first time or when creating a user.</li></ul>
</li></ul>
</div>
</li><li id="kafka-ug-0014__li155191222323">Run the following command in the <strong id="kafka-ug-0014__b1134982215299">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0014__screen17519102263211">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --offsets --describe --all-groups --command-config ../config/ssl-user-config.properties </pre>
<p id="kafka-ug-0014__p126011419592">Parameter description: <strong id="kafka-ug-0014__b11963848351251">connection-address</strong> indicates the Kafka instance address, which can be obtained in the <strong id="kafka-ug-0014__b52932843851251">Connection</strong> area on the <strong id="kafka-ug-0014__b49028672951251">Basic Information</strong> page on the Kafka console.</p>
<p id="kafka-ug-0014__p1260194165918">Example:</p>
<pre class="screen" id="kafka-ug-0014__screen12471174925911">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9093,192.168.xx.xx:9093,192.168.xx.xx:9093 --offsets --describe --all-groups --command-config ../config/ssl-user-config.properties
Consumer group '__consumer-group-dial-test' has no active members.
GROUP TOPIC PARTITION CURRENT-OFFSET LOG-END-OFFSET LAG CONSUMER-ID HOST CLIENT-ID
__consumer-group-dial-test __dms_dial_test 0 347 347 0 - - -
__consumer-group-dial-test __dms_dial_test 1 347 347 0 - - -
__consumer-group-dial-test __dms_dial_test 2 347 347 0 - - -
Consumer group 'test' has no active members.
GROUP TOPIC PARTITION CURRENT-OFFSET LOG-END-OFFSET LAG CONSUMER-ID HOST CLIENT-ID
test topic-01 0 5 5 0 - - -
test topic-01 1 3 3 0 - - -
test topic-01 2 10 10 0 - - -
[root@ecs-kafka bin]#</pre>
</li></ol> </li></ol>
</li></ul> </li></ul>
</div> </div>
<div class="section" id="kafka-ug-0014__section149419481115"><h4 class="sectiontitle">Resetting Consumer Offsets</h4><ol id="kafka-ug-0014__ol1694563316919"><li id="kafka-ug-0014__li9945143318917"><span>Log in to the console.</span></li><li id="kafka-ug-0014__li994563315915"><span>Click <span><img id="kafka-ug-0014__image52905893" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0014__note394516330912"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0014__p1694512333917">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0014__section149419481115"><h4 class="sectiontitle">Resetting Consumer Offsets</h4><ol id="kafka-ug-0014__ol1694563316919"><li id="kafka-ug-0014__li9945143318917"><span>Log in to the console.</span></li><li id="kafka-ug-0014__li994563315915"><span>Click <span><img id="kafka-ug-0014__image906217797" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0014__note394516330912"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0014__p1694512333917">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0014__li13196447165814"><span>Click <strong id="kafka-ug-0014__b511257360">Service List</strong> and choose <strong id="kafka-ug-0014__b1553806509">Application</strong> &gt; <strong id="kafka-ug-0014__b1711814839">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0014__li494514336914"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0014__li1694510331918"><span>In the navigation pane, choose the <strong id="kafka-ug-0014__b1276914312567">Consumer Groups</strong> tab.</span></li><li id="kafka-ug-0014__li19451233495"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0014__li1149819404"><span>On the <strong id="kafka-ug-0014__b10592242182315">Consumer Offset</strong> tab page, you can perform the following operations:</span><p><ul id="kafka-ug-0014__ul2584134041616"><li id="kafka-ug-0014__li11584124011165">To reset the consumer offset of all partitions of a single topic, click <strong id="kafka-ug-0014__b11297185202512">Reset Consumer Offset</strong> in the row containing the desired topic.</li><li id="kafka-ug-0014__li7736134315194">To reset the consumer offset of a single partition of a single topic, click <strong id="kafka-ug-0014__b1522941814259">Reset Consumer Offset</strong> in the row containing the desired partition.</li><li id="kafka-ug-0014__li1472164312121">To reset the consumer offset of all partitions in all topics, click <strong id="kafka-ug-0014__b14893115120258">One-touch Reset Consumer Offset</strong> above the list.</li></ul> </p></li><li id="kafka-ug-0014__li13196447165814"><span>Click <strong id="kafka-ug-0014__b979836041">Service List</strong> and choose <strong id="kafka-ug-0014__b473603243">Application</strong> &gt; <strong id="kafka-ug-0014__b834426554">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0014__li494514336914"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0014__li1694510331918"><span>In the navigation pane, choose the <strong id="kafka-ug-0014__b1276914312567">Consumer Groups</strong> tab.</span></li><li id="kafka-ug-0014__li19451233495"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0014__li1149819404"><span>On the <strong id="kafka-ug-0014__b10592242182315">Consumer Offset</strong> tab page, you can perform the following operations:</span><p><ul id="kafka-ug-0014__ul2584134041616"><li id="kafka-ug-0014__li11584124011165">To reset the consumer offset of all partitions of a single topic, click <strong id="kafka-ug-0014__b11297185202512">Reset Consumer Offset</strong> in the row containing the desired topic.</li><li id="kafka-ug-0014__li7736134315194">To reset the consumer offset of a single partition of a single topic, click <strong id="kafka-ug-0014__b1522941814259">Reset Consumer Offset</strong> in the row containing the desired partition.</li><li id="kafka-ug-0014__li1472164312121">To reset the consumer offset of all partitions in all topics, click <strong id="kafka-ug-0014__b14893115120258">One-touch Reset Consumer Offset</strong> above the list.</li></ul>
</p></li><li id="kafka-ug-0014__li1950985117152"><span>In the displayed <strong id="kafka-ug-0014__b661694720253">Reset Consumer Offset</strong> dialog box, set the parameters by referring to <a href="#kafka-ug-0014__table13921162119239">Table 1</a>.</span><p> </p></li><li id="kafka-ug-0014__li1950985117152"><span>In the displayed <strong id="kafka-ug-0014__b661694720253">Reset Consumer Offset</strong> dialog box, set the parameters by referring to <a href="#kafka-ug-0014__table13921162119239">Table 1</a>.</span><p>
<div class="tablenoborder"><a name="kafka-ug-0014__table13921162119239"></a><a name="table13921162119239"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0014__table13921162119239" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters for resetting the consumer offset</caption><thead align="left"><tr id="kafka-ug-0014__row892110213237"><th align="left" class="cellrowborder" valign="top" width="23.21%" id="mcps1.3.6.2.8.2.1.2.3.1.1"><p id="kafka-ug-0014__p1092212214238">Parameter</p> <div class="tablenoborder"><a name="kafka-ug-0014__table13921162119239"></a><a name="table13921162119239"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0014__table13921162119239" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters for resetting the consumer offset</caption><thead align="left"><tr id="kafka-ug-0014__row892110213237"><th align="left" class="cellrowborder" valign="top" width="23.21%" id="mcps1.3.6.2.8.2.1.2.3.1.1"><p id="kafka-ug-0014__p1092212214238">Parameter</p>
</th> </th>

View File

@ -1,21 +1,66 @@
<a name="kafka-ug-0015"></a><a name="kafka-ug-0015"></a> <a name="kafka-ug-0015"></a><a name="kafka-ug-0015"></a>
<h1 class="topictitle1">Viewing Kafka Consumer Details</h1> <h1 class="topictitle1">Viewing Kafka Consumer Information</h1>
<div id="body0000001291897433"><p id="kafka-ug-0015__p181530565111">This section describes how to view the consumer list and consumer connection addresses.</p> <div id="body0000001291897433"><p id="kafka-ug-0015__p181530565111">If a consumer group has consumers who are accessing a Kafka instance, you can view their connection information.</p>
<div class="section" id="kafka-ug-0015__section1950093111817"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0015__p237943731810">The consumer list and connection address can be viewed only when consumers in a consumer group are connected to the Kafka instance (that is, the consumer group is in the <strong id="kafka-ug-0015__b9691133721512">STABLE</strong> state).</p> <div class="section" id="kafka-ug-0015__section1950093111817"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-0015__p237943731810">The consumer list and connection address can be viewed only when consumers in a consumer group are connected to the Kafka instance (that is, the consumer group is in the <strong id="kafka-ug-0015__b9691133721512">STABLE</strong> state).</p>
</div> </div>
<div class="section" id="kafka-ug-0015__section16740253152"><h4 class="sectiontitle">Viewing the Consumer List (Console)</h4><ol id="kafka-ug-0015__ol202972359157"><li id="kafka-ug-0015__li353314276616"><span>Log in to the console.</span></li><li id="kafka-ug-0015__li7534122712610"><span>Click <span><img id="kafka-ug-0015__image437122211711" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0015__note5534727065"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0015__p853411271611">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0015__section16740253152"><h4 class="sectiontitle">Viewing the Consumer List (Console)</h4><ol id="kafka-ug-0015__ol202972359157"><li id="kafka-ug-0015__li353314276616"><span>Log in to the console.</span></li><li id="kafka-ug-0015__li7534122712610"><span>Click <span><img id="kafka-ug-0015__image437122211711" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0015__note5534727065"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0015__p853411271611">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0015__li275385101417"><span>Click <strong id="kafka-ug-0015__b10971146101619">Service List</strong> and choose <strong id="kafka-ug-0015__b19972114641613">Application</strong> &gt; <strong id="kafka-ug-0015__b0972174616168">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0015__li1953462718613"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0015__li1153419278618"><span>In the navigation pane, choose <strong id="kafka-ug-0015__b12441556101614">Consumer Groups</strong>.</span></li><li id="kafka-ug-0015__li1829733518154"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0015__li9783112618516"><span>On the <strong id="kafka-ug-0015__b3587141191715">Consumers</strong> tab page, view the consumer list.</span><p><p id="kafka-ug-0015__p105492358618">In the consumer list, you can view the consumer ID, consumer address, and client ID.</p> </p></li><li id="kafka-ug-0015__li275385101417"><span>Click <strong id="kafka-ug-0015__b10971146101619">Service List</strong> and choose <strong id="kafka-ug-0015__b19972114641613">Application</strong> &gt; <strong id="kafka-ug-0015__b0972174616168">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0015__li1953462718613"><span>Click an instance to go to the instance details page.</span></li><li id="kafka-ug-0015__li1153419278618"><span>In the navigation pane, choose <strong id="kafka-ug-0015__b12441556101614">Consumer Groups</strong>.</span></li><li id="kafka-ug-0015__li1829733518154"><span>Click the name of the desired consumer group.</span></li><li id="kafka-ug-0015__li9783112618516"><span>On the <strong id="kafka-ug-0015__b3587141191715">Consumers</strong> tab page, view the consumer list.</span><p><p id="kafka-ug-0015__p105492358618">In the consumer list, you can view the consumer ID, consumer address, and client ID.</p>
</p></li><li id="kafka-ug-0015__li118161936183018"><span>(Optional) To query a specific consumer, enter the consumer ID in the search box and press <strong id="kafka-ug-0015__b11130141094410">Enter</strong>.</span></li></ol> </p></li><li id="kafka-ug-0015__li118161936183018"><span>(Optional) To query a specific consumer, enter the consumer ID in the search box and press <strong id="kafka-ug-0015__b11130141094410">Enter</strong>.</span></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0015__section7157144213304"><h4 class="sectiontitle">Viewing the Consumer List (Kafka CLI)</h4><ul id="kafka-ug-0015__ul145946914322"><li id="kafka-ug-0015__li8594993327">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0015__b4789723172811">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0015__screen35946911327">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --group ${group-name} --members --describe</pre> <div class="section" id="kafka-ug-0015__section7157144213304"><h4 class="sectiontitle">Viewing the Consumer List (Kafka CLI)</h4><ul id="kafka-ug-0015__ul145946914322"><li id="kafka-ug-0015__li8594993327">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-0015__b4789723172811">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0015__screen35946911327">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --group ${group-name} --members --describe</pre>
</li><li id="kafka-ug-0015__li135941897328">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0015__ol15959915327"><li id="kafka-ug-0015__li875065916200">(Optional) For the Kafka security protocol, is SASL_PLAINTEXT or SASL_SSL used?<ul id="kafka-ug-0015__ul2643717214"><li id="kafka-ug-0015__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. In other cases, create the <strong id="kafka-ug-0015__b199651478611299">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0015__b30595491311299">/config</strong> directory of the Kafka client. Add the username and password by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li><li id="kafka-ug-0015__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. In other cases, create the <strong id="kafka-ug-0015__b1846101217112929">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0015__b623808650112929">/config</strong> directory of the Kafka client. Add the username and password, and the SSL certificate configuration by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li></ul> <p id="kafka-ug-0015__p251111134315">Parameter description:</p>
</li><li id="kafka-ug-0015__li85951698326">Run the following command in the <strong id="kafka-ug-0015__b5188648122814">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0015__screen115959912326">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --group ${group-name} --members --describe --command-config ./config/ssl-user-config.properties </pre> <ul id="kafka-ug-0015__ul6641131564310"><li id="kafka-ug-0015__li536311374319"><strong id="kafka-ug-0015__b2015649543104515">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0015__b1604293376104515">Connection</strong> area on the <strong id="kafka-ug-0015__b947421403104515">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0015__li259419356438"><strong id="kafka-ug-0015__b1357143612176">group-name</strong>: consumer group name.</li></ul>
<p id="kafka-ug-0015__p1968375217431">Example:</p>
<pre class="screen" id="kafka-ug-0015__screen67215263469">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9092,192.168.xx.xx:9092,192.168.xx.xx:9092 --group test --members --describe
GROUP CONSUMER-ID HOST CLIENT-ID #PARTITIONS
test console-consumer-571a64fe-b0c4-47ce-833d-9e0da5a88d14 /192.168.0.215 console-consumer 3
[root@ecs-kafka bin]#</pre>
</li><li id="kafka-ug-0015__li135941897328">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-0015__ol15959915327"><li id="kafka-ug-0015__li1873184414916">(Optional) Modify the client configuration file.<div class="p" id="kafka-ug-0015__p14473184894916"><a name="kafka-ug-0015__li1873184414916"></a><a name="li1873184414916"></a>View <strong id="kafka-ug-0015__b181939147851319">Security Protocol</strong> in the <strong id="kafka-ug-0015__b149343931151319">Connection</strong> area on the <strong id="kafka-ug-0015__b56575751151319">Basic Information</strong> page on the Kafka console. The configuration settings vary depending on the protocol.<ul id="kafka-ug-0015__ul2643717214"><li id="kafka-ug-0015__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. Otherwise, create the <strong id="kafka-ug-0015__b134902710951329">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0015__b186088116451329">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0015__screen4598144192618">security.protocol=SASL_PLAINTEXT
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0015__kafka-ug-180604018_b883312781111">scram.</strong><strong id="kafka-ug-0015__kafka-ug-180604018_b1783311741112">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0015__kafka-ug-180604018_b128331377110">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0015__kafka-ug-180604018_b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0015__kafka-ug-180604018_b964813191391">PLAIN</strong></pre>
<p id="kafka-ug-0015__p117102681410">Parameter description: <strong id="kafka-ug-0015__b1398982651103926">username</strong> and <strong id="kafka-ug-0015__b690789222103926">password</strong> are the ones you set when enabling ciphertext access for the first time or when creating a user.</p>
</li><li id="kafka-ug-0015__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. Otherwise, create the <strong id="kafka-ug-0015__b195419116051329">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-0015__b39271852651329">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-0015__screen0832225182718">security.protocol=SASL_SSL
ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0015__kafka-ug-180604018_b4657131681320">scram.</strong><strong id="kafka-ug-0015__kafka-ug-180604018_b20657171612138">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0015__kafka-ug-180604018_b15657121620131">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-0015__kafka-ug-180604018_b0657101619133">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-0015__kafka-ug-180604018_b1665720164136">PLAIN</strong></pre>
<p id="kafka-ug-0015__p346462202711">Parameter description:</p>
<ul id="kafka-ug-0015__ul2355135542711"><li id="kafka-ug-0015__kafka-ug-180604018_li9578173610155"><strong id="kafka-ug-0015__kafka-ug-180604018_b15940166202617">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-0015__kafka-ug-180604018_b1994056112615">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-0015__kafka-ug-180604018_li4578153611159"><strong id="kafka-ug-0015__kafka-ug-180604018_b02112214397">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-0015__kafka-ug-180604018_b3211521103916">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-0015__kafka-ug-180604018_li2057818362154"><strong id="kafka-ug-0015__kafka-ug-180604018_b163656567392">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-0015__kafka-ug-180604018_b4285516104010">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li><li id="kafka-ug-0015__kafka-ug-180604018_li194571669169"><strong id="kafka-ug-0015__kafka-ug-180604018_b16925191015415">username</strong> and <strong id="kafka-ug-0015__kafka-ug-180604018_b17925141034110">password</strong>: username and password you set when enabling ciphertext access for the first time or when creating a user.</li></ul>
</li></ul>
</div>
</li><li id="kafka-ug-0015__li85951698326">Run the following command in the <strong id="kafka-ug-0015__b5188648122814">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-0015__screen115959912326">./kafka-consumer-groups.sh --bootstrap-server ${connection-address} --group ${group-name} --members --describe --command-config ../config/ssl-user-config.properties </pre>
<p id="kafka-ug-0015__p1912814541468">Parameter description:</p>
<ul id="kafka-ug-0015__ul1312885454618"><li id="kafka-ug-0015__li1312895494616"><strong id="kafka-ug-0015__b1504050626104515">connection-address</strong>: can be obtained from the <strong id="kafka-ug-0015__b1223230487104515">Connection</strong> area on the <strong id="kafka-ug-0015__b929205341104515">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-0015__li12128115416465"><strong id="kafka-ug-0015__b24601142121714">group-name</strong>: consumer group name.</li></ul>
<p id="kafka-ug-0015__p1323264474">Example:</p>
<pre class="screen" id="kafka-ug-0015__screen6183615144718">[root@ecs-kafka bin]# ./kafka-consumer-groups.sh --bootstrap-server 192.168.xx.xx:9093,192.168.xx.xx:9093,192.168.xx.xx:9093 --group test --members --describe --command-config ../config/ssl-user-config.properties
GROUP CONSUMER-ID HOST CLIENT-ID #PARTITIONS
test console-consumer-566d0c82-07d3-4d87-9a6e-f57a9bc9fc69 /192.168.0.215 console-consumer 3
[root@ecs-kafka bin]#</pre>
</li></ol> </li></ol>
</li></ul> </li></ul>
</div> </div>
<div class="section" id="kafka-ug-0015__section48018524714"><h4 class="sectiontitle">Viewing Consumer Connection Addresses (Console)</h4><ol id="kafka-ug-0015__ol3215151213171"><li id="kafka-ug-0015__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0015__li14905725134512"><span>Click <span><img id="kafka-ug-0015__image1548869665" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0015__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0015__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0015__section48018524714"><h4 class="sectiontitle">Viewing Consumer Connection Addresses (Console)</h4><ol id="kafka-ug-0015__ol3215151213171"><li id="kafka-ug-0015__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0015__li14905725134512"><span>Click <span><img id="kafka-ug-0015__image1681706343" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0015__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0015__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0015__li189561034172215"><span>Click <strong id="kafka-ug-0015__b31645067995717">Service List</strong> and choose <strong id="kafka-ug-0015__b27421515195717">Application</strong> &gt; <strong id="kafka-ug-0015__b70178647495717">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0015__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0015__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0015__b1011962162714">Consumer Groups</strong>.</span></li><li id="kafka-ug-0015__li578915528416"><span>Click the desired consumer group.</span></li><li id="kafka-ug-0015__li14266184912490"><span>On the <strong id="kafka-ug-0015__b39381724172718">Consumers</strong> tab page, view the consumer addresses.</span></li></ol> </p></li><li id="kafka-ug-0015__li189561034172215"><span>Click <strong id="kafka-ug-0015__b31645067995717">Service List</strong> and choose <strong id="kafka-ug-0015__b27421515195717">Application</strong> &gt; <strong id="kafka-ug-0015__b70178647495717">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0015__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0015__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0015__b1011962162714">Consumer Groups</strong>.</span></li><li id="kafka-ug-0015__li578915528416"><span>Click the desired consumer group.</span></li><li id="kafka-ug-0015__li14266184912490"><span>On the <strong id="kafka-ug-0015__b39381724172718">Consumers</strong> tab page, view the consumer addresses.</span></li></ol>
</div> </div>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -2,51 +2,51 @@
<h1 class="topictitle1">Modifying Kafka Topic Configurations</h1> <h1 class="topictitle1">Modifying Kafka Topic Configurations</h1>
<div id="body0000001514576990"><p id="kafka-ug-0038__p1798795754415">This section describes how to modify following configurations of a Kafka topic on the console.</p> <div id="body0000001514576990"><p id="kafka-ug-0038__p1798795754415">This section describes how to modify following configurations of a Kafka topic on the console.</p>
<div class="note" id="kafka-ug-0038__note1132533103712"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0038__p141321933173718">Modifying <strong id="kafka-ug-0038__b4865748101711">Synchronous Replication</strong>, <strong id="kafka-ug-0038__b128841154181710">Synchronous Flushing</strong>, <strong id="kafka-ug-0038__b9191958121710">Message Timestamp</strong>, or <strong id="kafka-ug-0038__b148221217180">Max. Message Size</strong> does not require instance restart.</p>
</div></div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0038__table19803102744620" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Kafka topic configuration parameters</caption><thead align="left"><tr id="kafka-ug-0038__row38031827134619"><th align="left" class="cellrowborder" valign="top" width="29.53%" id="mcps1.3.2.2.3.1.1"><p id="kafka-ug-0038__p1047510149494">Parameter</p> <div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0038__table19803102744620" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Kafka topic configuration parameters</caption><thead align="left"><tr id="kafka-ug-0038__row38031827134619"><th align="left" class="cellrowborder" valign="top" width="29.53%" id="mcps1.3.3.2.3.1.1"><p id="kafka-ug-0038__p1047510149494">Parameter</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="70.47%" id="mcps1.3.2.2.3.1.2"><p id="kafka-ug-0038__p8475171494912">Description</p> <th align="left" class="cellrowborder" valign="top" width="70.47%" id="mcps1.3.3.2.3.1.2"><p id="kafka-ug-0038__p8475171494912">Description</p>
</th> </th>
</tr> </tr>
</thead> </thead>
<tbody><tr id="kafka-ug-0038__row12328142141518"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p183282424159">Partitions</p> <tbody><tr id="kafka-ug-0038__row12328142141518"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p183282424159">Partitions</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><p id="kafka-ug-0038__p832814219152">Number of partitions in a topic. For details about how to change, see <a href="kafka-ug-0006.html">Changing Kafka Partition Quantity</a>.</p> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><p id="kafka-ug-0038__p832814219152">Number of partitions in a topic. For details about how to change, see <a href="kafka-ug-0006.html">Changing Kafka Partition Quantity</a>.</p>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-0038__row446833917155"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p946823981518">Aging Time (h)</p> <tr id="kafka-ug-0038__row446833917155"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p946823981518">Aging Time (h)</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><p id="kafka-ug-0038__p646833921513">Maximum message retention. For details about how to change, see <a href="kafka-ug-200506001.html">Changing Kafka Message Retention Period</a>.</p> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><p id="kafka-ug-0038__p646833921513">Maximum message retention. For details about how to change, see <a href="kafka-ug-200506001.html">Changing Kafka Message Retention Period</a>.</p>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-0038__row6993738174911"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p199312389490">Synchronous Replication</p> <tr id="kafka-ug-0038__row6993738174911"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p199312389490">Synchronous Replication</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><p id="kafka-ug-0038__p16993738164913">A message is returned to the client only after the message creation request has been received and the message has been acknowledged by all replicas.</p> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><p id="kafka-ug-0038__p16993738164913">A message is returned to the client only after the message creation request has been received and the message has been acknowledged by all replicas.</p>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-0038__row1849013366494"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p1349193604914">Synchronous Flushing</p> <tr id="kafka-ug-0038__row1849013366494"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p1349193604914">Synchronous Flushing</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><ul id="kafka-ug-0038__ul74988451913"><li id="kafka-ug-0038__li19498174201916">Enabled: A message is immediately flushed to disk once it is created, bringing higher reliability.</li><li id="kafka-ug-0038__li1172317615193">Disabled: A message is stored in the memory instead of being immediately flushed to disk once created.</li></ul> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><ul id="kafka-ug-0038__ul74988451913"><li id="kafka-ug-0038__li19498174201916">Enabled: A message is immediately flushed to disk once it is created, bringing higher reliability.</li><li id="kafka-ug-0038__li1172317615193">Disabled: A message is stored in the memory instead of being immediately flushed to disk once created.</li></ul>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-0038__row1803172715466"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p1680382754611">Message Timestamp</p> <tr id="kafka-ug-0038__row1803172715466"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p1680382754611">Message Timestamp</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><div class="p" id="kafka-ug-0038__p51151647124815">Timestamp type of a message. Options:<ul id="kafka-ug-0038__ul863644464811"><li id="kafka-ug-0038__li11689132103518"><strong id="kafka-ug-0038__b9810927173612">CreateTime</strong>: time when the producer created the message.</li><li id="kafka-ug-0038__li146361144204810"><strong id="kafka-ug-0038__b911331612611">LogAppendTime</strong>: time when the broker appended the message to the log.</li></ul> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><div class="p" id="kafka-ug-0038__p51151647124815">Timestamp type of a message. Options:<ul id="kafka-ug-0038__ul863644464811"><li id="kafka-ug-0038__li11689132103518"><strong id="kafka-ug-0038__b9810927173612">CreateTime</strong>: time when the producer created the message.</li><li id="kafka-ug-0038__li146361144204810"><strong id="kafka-ug-0038__b911331612611">LogAppendTime</strong>: time when the broker appended the message to the log.</li></ul>
</div> </div>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-0038__row15803142718467"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.2.2.3.1.1 "><p id="kafka-ug-0038__p4803027164618">Max. Message Size</p> <tr id="kafka-ug-0038__row15803142718467"><td class="cellrowborder" valign="top" width="29.53%" headers="mcps1.3.3.2.3.1.1 "><p id="kafka-ug-0038__p4803027164618">Max. Message Size</p>
</td> </td>
<td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.2.2.3.1.2 "><p id="kafka-ug-0038__p13355191384915">Maximum size of messages to be processed in batches. If message compression is enabled, this parameter indicates the size after compression.</p> <td class="cellrowborder" valign="top" width="70.47%" headers="mcps1.3.3.2.3.1.2 "><p id="kafka-ug-0038__p13355191384915">Maximum size of messages to be processed in batches. If message compression is enabled, this parameter indicates the size after compression.</p>
<p id="kafka-ug-0038__p12803192713468">If this value is increased and the consumer version is earlier than 0.10.2, the consumers' fetch size must also be increased so that they can obtain the latest value.</p> <p id="kafka-ug-0038__p12803192713468">If this value is increased and the consumer version is earlier than 0.10.2, the consumers' fetch size must also be increased so that they can obtain the latest value.</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
<div class="note" id="kafka-ug-0038__note1132533103712"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0038__p141321933173718">Modifying <strong id="kafka-ug-0038__b4865748101711">Synchronous Replication</strong>, <strong id="kafka-ug-0038__b128841154181710">Synchronous Flushing</strong>, <strong id="kafka-ug-0038__b9191958121710">Message Timestamp</strong>, or <strong id="kafka-ug-0038__b148221217180">Max. Message Size</strong> does not require instance restart.</p> <div class="section" id="kafka-ug-0038__section744968135110"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0038__ol174622555120"><li id="kafka-ug-0038__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0038__li14905725134512"><span>Click <span><img id="kafka-ug-0038__image635725454113727" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0038__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0038__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div>
<div class="section" id="kafka-ug-0038__section744968135110"><h4 class="sectiontitle">Modifying Topic Configurations</h4><ol id="kafka-ug-0038__ol174622555120"><li id="kafka-ug-0038__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0038__li14905725134512"><span>Click <span><img id="kafka-ug-0038__image635725454113727" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0038__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0038__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0038__li189561034172215"><span>Click <strong id="kafka-ug-0038__b1929346113711">Service List</strong> and choose <strong id="kafka-ug-0038__b152931565375">Application</strong> &gt; <strong id="kafka-ug-0038__b82933623719">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0038__li26520051765"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0038__li6318234617851"><span>In the navigation pane, choose <strong id="kafka-ug-0038__b106201746143419">Topics</strong>.</span></li><li id="kafka-ug-0038__li1169275344516"><span>Modify topic configurations in either of the following ways:</span><p><ul id="kafka-ug-0038__ul1146071715465"><li id="kafka-ug-0038__li104997486113">Select one or more topics and click <strong id="kafka-ug-0038__b2031113155385">Edit Topic</strong> above the topic list.</li><li id="kafka-ug-0038__li53063508319">In the row containing the desired topic, click <strong id="kafka-ug-0038__b15330181092115">Edit</strong>.</li></ul> </p></li><li id="kafka-ug-0038__li189561034172215"><span>Click <strong id="kafka-ug-0038__b1929346113711">Service List</strong> and choose <strong id="kafka-ug-0038__b152931565375">Application</strong> &gt; <strong id="kafka-ug-0038__b82933623719">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0038__li26520051765"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0038__li6318234617851"><span>In the navigation pane, choose <strong id="kafka-ug-0038__b106201746143419">Topics</strong>.</span></li><li id="kafka-ug-0038__li1169275344516"><span>Modify topic configurations in either of the following ways:</span><p><ul id="kafka-ug-0038__ul1146071715465"><li id="kafka-ug-0038__li104997486113">Select one or more topics and click <strong id="kafka-ug-0038__b2031113155385">Edit Topic</strong> above the topic list.</li><li id="kafka-ug-0038__li53063508319">In the row containing the desired topic, click <strong id="kafka-ug-0038__b15330181092115">Edit</strong>.</li></ul>
</p></li><li id="kafka-ug-0038__li18719038145020"><span>In the <strong id="kafka-ug-0038__b155271715192214">Edit Topic</strong> dialog box, change configurations and click <strong id="kafka-ug-0038__b16438111017227">OK</strong>.</span><p><div class="note" id="kafka-ug-0038__note151191028456"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="kafka-ug-0038__ul1730011261963"><li id="kafka-ug-0038__li173001526068">If there is only one replica, <strong id="kafka-ug-0038__b1441467102313">Synchronous Replication</strong> cannot be enabled.</li><li id="kafka-ug-0038__li16230162910616">After enabling synchronous replication, set <strong id="kafka-ug-0038__b42801018152417">acks</strong> to <strong id="kafka-ug-0038__b1728117182247">all</strong> or <strong id="kafka-ug-0038__b112811118112412">1</strong> on the client. Otherwise, this function will not take effect.</li></ul> </p></li><li id="kafka-ug-0038__li18719038145020"><span>In the <strong id="kafka-ug-0038__b155271715192214">Edit Topic</strong> dialog box, change configurations and click <strong id="kafka-ug-0038__b16438111017227">OK</strong>.</span><p><div class="note" id="kafka-ug-0038__note151191028456"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="kafka-ug-0038__ul1730011261963"><li id="kafka-ug-0038__li173001526068">If there is only one replica, <strong id="kafka-ug-0038__b1441467102313">Synchronous Replication</strong> cannot be enabled.</li><li id="kafka-ug-0038__li16230162910616">After enabling synchronous replication, set <strong id="kafka-ug-0038__b42801018152417">acks</strong> to <strong id="kafka-ug-0038__b1728117182247">all</strong> or <strong id="kafka-ug-0038__b112811118112412">1</strong> on the client. Otherwise, this function will not take effect.</li></ul>

View File

@ -1,23 +1,27 @@
<a name="kafka-ug-0041"></a><a name="kafka-ug-0041"></a> <a name="kafka-ug-0041"></a><a name="kafka-ug-0041"></a>
<h1 class="topictitle1">Creating a Kafka Consumer Group</h1> <h1 class="topictitle1">Creating a Kafka Consumer Group</h1>
<div id="body0000001531881958"><p id="kafka-ug-0041__p392182617121">Create a consumer group on the console.</p> <div id="body0000001531881958"><p id="kafka-ug-0041__p4813133071310">A consumer subscribes to a topic. A consumer group consists of one or more consumers. Within a consumer group, each consumer can consume multiple partitions at the same time. Each partition can be consumed by one consumer at a time.</p>
<p id="kafka-ug-0041__p24181035405"><strong id="kafka-ug-0041__b11175110182313">auto.create.groups.enable</strong>: a consumer group is automatically created when a consumer attempts to enter a group that does not exist.</p> <div class="fignone" id="kafka-ug-0041__fig12850830191912"><span class="figcap"><b>Figure 1 </b>Example consumption</span><br><span><img class="eddx" id="kafka-ug-0041__image3850930161920" src="en-us_image_0000001998520149.png"></span></div>
<ul id="kafka-ug-0041__ul298037709"><li id="kafka-ug-0041__li12981437401">This operation is optional when <strong id="kafka-ug-0041__b6805173172410">auto.create.groups.enable</strong> is <strong id="kafka-ug-0041__b452783312419">true</strong> in <a href="kafka-ug-0007.html">Configuring Parameters</a>.</li><li id="kafka-ug-0041__li1420070124">A consumer group is required before consuming messages when <strong id="kafka-ug-0041__b1293214013266">auto.create.groups.enable</strong> is <strong id="kafka-ug-0041__b1697634715261">false</strong> in <a href="kafka-ug-0007.html">Configuring Parameters</a>. Otherwise, consumption will fail.</li></ul> <p id="kafka-ug-0041__p16118217931"><strong id="kafka-ug-0041__b9894195984820">auto.create.groups.enable</strong>: a consumer group is automatically created when a consumer attempts to enter a group that does not exist.</p>
<div class="note" id="kafka-ug-0041__note134001224184617"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="kafka-ug-0041__ul19524221159"><li id="kafka-ug-0041__li15524162141519">If <strong id="kafka-ug-0041__b106252664419">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0041__b4625116204411">true</strong>, the consumer group status is <strong id="kafka-ug-0041__b1662513644413">EMPTY</strong>, and no offset has been submitted, the system automatically deletes the consumer group 10 minutes later.</li><li id="kafka-ug-0041__li16747114201511">If <strong id="kafka-ug-0041__b16256145441">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0041__b262614143444">false</strong>, the system does not automatically delete consumer groups. You can manually delete them.</li><li id="kafka-ug-0041__li128345294117">If a consumer group has never committed an offset, the group will be deleted after the Kafka instance restarts.</li><li id="kafka-ug-0041__li6799653144311">Creating a consumer group on the console does not require instance restart.</li></ul> <ul id="kafka-ug-0041__ul16436201812319"><li id="kafka-ug-0041__li44414215317">A consumer group is required before consuming messages when <strong id="kafka-ug-0041__b15302328184914">auto.create.groups.enable</strong> is <strong id="kafka-ug-0041__b8302528204917">false</strong> in <a href="kafka-ug-0007.html">Configuring Parameters</a>. Otherwise, consumption will fail.</li><li id="kafka-ug-0041__li8436121816313">A consumer group is created automatically before consuming messages when <strong id="kafka-ug-0041__b4532134104912">auto.create.groups.enable</strong> is <strong id="kafka-ug-0041__b853294134917">true</strong> in <a href="kafka-ug-0007.html">Configuring Parameters</a>.</li></ul>
<p id="kafka-ug-0041__p392182617121">Create a consumer group on the console.</p>
<div class="note" id="kafka-ug-0041__note134001224184617"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0041__p174541815125818">Creating a consumer group on the console does not require an instance restart.</p>
</div></div> </div></div>
<div class="section" id="kafka-ug-0041__section3276688267"><h4 class="sectiontitle">Creating a Kafka Consumer Group</h4><ol id="kafka-ug-0041__ol4406122513261"><li id="kafka-ug-0041__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0041__li14905725134512"><span>Click <span><img id="kafka-ug-0041__image14544135581" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0041__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0041__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0041__section16875161412563"><h4 class="sectiontitle">Notes and Constraints</h4><ul id="kafka-ug-0041__ul5125162916563"><li id="kafka-ug-0041__li15524162141519">If <strong id="kafka-ug-0041__b106252664419">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0041__b4625116204411">true</strong>, the consumer group status is <strong id="kafka-ug-0041__b1662513644413">EMPTY</strong>, and no offset has been submitted, the system automatically deletes the consumer group 10 minutes later.</li><li id="kafka-ug-0041__li16747114201511">If <strong id="kafka-ug-0041__b16256145441">auto.create.groups.enable</strong> is set to <strong id="kafka-ug-0041__b262614143444">false</strong>, the system does not automatically delete consumer groups. You can manually delete them.</li><li id="kafka-ug-0041__li17095293562">If a consumer group has never committed an offset, the group will be deleted after the Kafka instance restarts.</li></ul>
</div>
<div class="section" id="kafka-ug-0041__section3276688267"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0041__ol4406122513261"><li id="kafka-ug-0041__li10427115412419"><span>Log in to the console.</span></li><li id="kafka-ug-0041__li14905725134512"><span>Click <span><img id="kafka-ug-0041__image14544135581" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0041__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0041__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0041__li189561034172215"><span>Click <strong id="kafka-ug-0041__b167161136817">Service List</strong> and choose <strong id="kafka-ug-0041__b171715131185">Application</strong> &gt; <strong id="kafka-ug-0041__b177176132812">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0041__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0041__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0041__b1482215171889">Consumer Groups</strong>.</span></li><li id="kafka-ug-0041__li347518192814"><span>Click <strong id="kafka-ug-0041__b71613209810">Create Consumer Group</strong>.</span></li><li id="kafka-ug-0041__li9225205010284"><span>Set consumer group parameters by referring to <a href="#kafka-ug-0041__table1228103855815">Table 1</a> and click <strong id="kafka-ug-0041__b1281116488280">OK</strong>.</span><p> </p></li><li id="kafka-ug-0041__li189561034172215"><span>Click <strong id="kafka-ug-0041__b167161136817">Service List</strong> and choose <strong id="kafka-ug-0041__b171715131185">Application</strong> &gt; <strong id="kafka-ug-0041__b177176132812">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0041__li13248719142014"><span>Click the desired Kafka instance to view the instance details.</span></li><li id="kafka-ug-0041__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0041__b1482215171889">Consumer Groups</strong>.</span></li><li id="kafka-ug-0041__li347518192814"><span>Click <strong id="kafka-ug-0041__b71613209810">Create Consumer Group</strong>.</span></li><li id="kafka-ug-0041__li9225205010284"><span>Set consumer group parameters by referring to <a href="#kafka-ug-0041__table1228103855815">Table 1</a> and click <strong id="kafka-ug-0041__b1281116488280">OK</strong>.</span><p>
<div class="tablenoborder"><a name="kafka-ug-0041__table1228103855815"></a><a name="table1228103855815"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0041__table1228103855815" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Consumer group parameters</caption><thead align="left"><tr id="kafka-ug-0041__row1722973811583"><th align="left" class="cellrowborder" valign="top" width="28.76%" id="mcps1.3.5.2.7.2.1.2.3.1.1"><p id="kafka-ug-0041__p1122913875817">Parameter</p> <div class="tablenoborder"><a name="kafka-ug-0041__table1228103855815"></a><a name="table1228103855815"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0041__table1228103855815" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Consumer group parameters</caption><thead align="left"><tr id="kafka-ug-0041__row1722973811583"><th align="left" class="cellrowborder" valign="top" width="28.76%" id="mcps1.3.8.2.7.2.1.2.3.1.1"><p id="kafka-ug-0041__p1122913875817">Parameter</p>
</th> </th>
<th align="left" class="cellrowborder" valign="top" width="71.24000000000001%" id="mcps1.3.5.2.7.2.1.2.3.1.2"><p id="kafka-ug-0041__p1022923875812">Description</p> <th align="left" class="cellrowborder" valign="top" width="71.24000000000001%" id="mcps1.3.8.2.7.2.1.2.3.1.2"><p id="kafka-ug-0041__p1022923875812">Description</p>
</th> </th>
</tr> </tr>
</thead> </thead>
<tbody><tr id="kafka-ug-0041__row152295389588"><td class="cellrowborder" valign="top" width="28.76%" headers="mcps1.3.5.2.7.2.1.2.3.1.1 "><p id="kafka-ug-0041__p16229838155812">Consumer Group Name</p> <tbody><tr id="kafka-ug-0041__row152295389588"><td class="cellrowborder" valign="top" width="28.76%" headers="mcps1.3.8.2.7.2.1.2.3.1.1 "><p id="kafka-ug-0041__p16229838155812">Consumer Group Name</p>
</td> </td>
<td class="cellrowborder" valign="top" width="71.24000000000001%" headers="mcps1.3.5.2.7.2.1.2.3.1.2 "><p id="kafka-ug-0041__p622918388581">Enter 3 to 64 characters, starting with a letter or underscore (_). Use only letters, digits, periods (.), hyphens (-), and underscores (_).</p> <td class="cellrowborder" valign="top" width="71.24000000000001%" headers="mcps1.3.8.2.7.2.1.2.3.1.2 "><p id="kafka-ug-0041__p622918388581">Enter 3 to 64 characters, starting with a letter or underscore (_). Use only letters, digits, periods (.), hyphens (-), and underscores (_).</p>
<p id="kafka-ug-0041__p1765719502812">If a consumer group name starts with a special character, for example, an underscore (_) or a number sign (#), monitoring data cannot be displayed.</p> <p id="kafka-ug-0041__p1765719502812">If a consumer group name starts with a special character, for example, an underscore (_) or a number sign (#), monitoring data cannot be displayed.</p>
</td> </td>
</tr> </tr>

View File

@ -1,9 +1,8 @@
<a name="kafka-ug-0053"></a><a name="kafka-ug-0053"></a> <a name="kafka-ug-0053"></a><a name="kafka-ug-0053"></a>
<h1 class="topictitle1">Exporting the Kafka Instance List</h1> <h1 class="topictitle1">Exporting the Kafka Instance List</h1>
<div id="body0000001717874153"><div class="section" id="kafka-ug-0053__section115043214551"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-0053__p14534934105511">This section describes how to export the Kafka instance list from the console.</p> <div id="body0000001717874153"><p id="kafka-ug-0053__p1894095114010">You can export a list of instances on the DMS console.</p>
</div> <div class="section" id="kafka-ug-0053__section642363614552"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0053__ol376644915556"><li id="kafka-ug-0053__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-0053__li14905725134512"><span>Click <span><img id="kafka-ug-0053__image864291135715" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0053__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0053__p11964174020277">Select the region where your Kafka instance is located.</p>
<div class="section" id="kafka-ug-0053__section642363614552"><h4 class="sectiontitle">Exporting the Kafka Instance List</h4><ol id="kafka-ug-0053__ol376644915556"><li id="kafka-ug-0053__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-0053__li14905725134512"><span>Click <span><img id="kafka-ug-0053__image864291135715" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0053__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0053__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0053__li189561034172215"><span>Click <strong id="kafka-ug-0053__b546665647111826">Service List</strong> and choose <strong id="kafka-ug-0053__b1000692185111826">Application</strong> &gt; <strong id="kafka-ug-0053__b825406179111826">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0053__li1783212151133"><span>Export the instance list using either of the following methods:</span><p><ul id="kafka-ug-0053__ul1783111513133"><li id="kafka-ug-0053__li148313159134">Select the desired instances and choose <strong id="kafka-ug-0053__b5481951154012">Export</strong> &gt; <strong id="kafka-ug-0053__b84965113404">Export selected data to an XLSX file</strong> to export specified instances.</li><li id="kafka-ug-0053__li85896478133">Choose <strong id="kafka-ug-0053__b11176151344111">Export</strong> &gt; <strong id="kafka-ug-0053__b1917714131419">Export all data to an XLSX file</strong> to export all instances.</li></ul> </p></li><li id="kafka-ug-0053__li189561034172215"><span>Click <strong id="kafka-ug-0053__b546665647111826">Service List</strong> and choose <strong id="kafka-ug-0053__b1000692185111826">Application</strong> &gt; <strong id="kafka-ug-0053__b825406179111826">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0053__li1783212151133"><span>Export the instance list using either of the following methods:</span><p><ul id="kafka-ug-0053__ul1783111513133"><li id="kafka-ug-0053__li148313159134">Select the desired instances and choose <strong id="kafka-ug-0053__b5481951154012">Export</strong> &gt; <strong id="kafka-ug-0053__b84965113404">Export selected data to an XLSX file</strong> to export specified instances.</li><li id="kafka-ug-0053__li85896478133">Choose <strong id="kafka-ug-0053__b11176151344111">Export</strong> &gt; <strong id="kafka-ug-0053__b1917714131419">Export all data to an XLSX file</strong> to export all instances.</li></ul>
</p></li></ol> </p></li></ol>

View File

@ -1,9 +1,8 @@
<a name="kafka-ug-0056"></a><a name="kafka-ug-0056"></a> <a name="kafka-ug-0056"></a><a name="kafka-ug-0056"></a>
<h1 class="topictitle1">Exporting Kafka Consumer Groups</h1> <h1 class="topictitle1">Exporting Kafka Consumer Groups</h1>
<div id="body0000001682157488"><div class="section" id="kafka-ug-0056__section115043214551"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-0056__p14534934105511">Export the consumer group list from the console.</p> <div id="body0000001682157488"><p id="kafka-ug-0056__p1883582733919">You can export a list of consumer groups in a Kafka instance.</p>
</div> <div class="section" id="kafka-ug-0056__section4770324466"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-0056__ol376644915556"><li id="kafka-ug-0056__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-0056__li14905725134512"><span>Click <span><img id="kafka-ug-0056__image1679015300309" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0056__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0056__p11964174020277">Select the region where your Kafka instance is located.</p>
<div class="section" id="kafka-ug-0056__section4770324466"><h4 class="sectiontitle">Exporting Kafka Consumer Groups</h4><ol id="kafka-ug-0056__ol376644915556"><li id="kafka-ug-0056__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-0056__li14905725134512"><span>Click <span><img id="kafka-ug-0056__image1679015300309" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0056__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0056__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0056__li189561034172215"><span>Click <strong id="kafka-ug-0056__b17082115318">Service List</strong> and choose <strong id="kafka-ug-0056__b10708181143120">Application</strong> &gt; <strong id="kafka-ug-0056__b1370817163118">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0056__li13248719142014"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0056__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0056__b14271104818292">Consumer Groups</strong>.</span></li><li id="kafka-ug-0056__li171970247192"><span>Export consumer groups in either of the following ways:</span><p><ul id="kafka-ug-0056__ul6591332141918"><li id="kafka-ug-0056__li1259117323193">Select the desired consumer groups and choose <strong id="kafka-ug-0056__b14727125783010">Export</strong> &gt; <strong id="kafka-ug-0056__b843024973116">Export selected data to an XLSX file</strong> to export specified consumer groups.</li><li id="kafka-ug-0056__li101601555181911">Choose <strong id="kafka-ug-0056__b169001723210">Export</strong> &gt; <strong id="kafka-ug-0056__b0104164233219">Export all data to an XLSX file</strong> to export all consumer groups.</li></ul> </p></li><li id="kafka-ug-0056__li189561034172215"><span>Click <strong id="kafka-ug-0056__b17082115318">Service List</strong> and choose <strong id="kafka-ug-0056__b10708181143120">Application</strong> &gt; <strong id="kafka-ug-0056__b1370817163118">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0056__li13248719142014"><span>Click the desired Kafka instance to view its details.</span></li><li id="kafka-ug-0056__li1063043712019"><span>In the navigation pane, choose <strong id="kafka-ug-0056__b14271104818292">Consumer Groups</strong>.</span></li><li id="kafka-ug-0056__li171970247192"><span>Export consumer groups in either of the following ways:</span><p><ul id="kafka-ug-0056__ul6591332141918"><li id="kafka-ug-0056__li1259117323193">Select the desired consumer groups and choose <strong id="kafka-ug-0056__b14727125783010">Export</strong> &gt; <strong id="kafka-ug-0056__b843024973116">Export selected data to an XLSX file</strong> to export specified consumer groups.</li><li id="kafka-ug-0056__li101601555181911">Choose <strong id="kafka-ug-0056__b169001723210">Export</strong> &gt; <strong id="kafka-ug-0056__b0104164233219">Export all data to an XLSX file</strong> to export all consumer groups.</li></ul>
</p></li></ol> </p></li></ol>

View File

@ -10,7 +10,7 @@
<ul class="ullinks"> <ul class="ullinks">
<li class="ulchildlink"><strong><a href="kafka_ug_0044.html">Configuring Plaintext or Ciphertext Access to Kafka Instances</a></strong><br> <li class="ulchildlink"><strong><a href="kafka_ug_0044.html">Configuring Plaintext or Ciphertext Access to Kafka Instances</a></strong><br>
</li> </li>
<li class="ulchildlink"><strong><a href="kafka-ug-0003.html">Configuring Kafka Users</a></strong><br> <li class="ulchildlink"><strong><a href="kafka-ug-0003.html">Configuring Kafka ACL Users</a></strong><br>
</li> </li>
</ul> </ul>

View File

@ -0,0 +1,27 @@
<a name="kafka-ug-0065"></a><a name="kafka-ug-0065"></a>
<h1 class="topictitle1">Migrating Data Using Smart Connect</h1>
<div id="body0000001926355981"><p id="kafka-ug-0065__p8060118"></p>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="kafka_ug_0017.html">Enabling Smart Connect</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="kafka-ug-0034.html">Replicating Kafka Instance Data</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="kafka-ug-0035.html">Dumping Kafka Data to Object Storage Service (OBS)</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="kafka_ug_0018.html">Managing Smart Connect Tasks</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="kafka_ug_0041.html">Disabling Smart Connect</a></strong><br>
</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="kafka_ug_0016.html">Migrating Data</a></div>
</div>
</div>

View File

@ -1,13 +1,12 @@
<a name="kafka-ug-0069"></a><a name="kafka-ug-0069"></a> <a name="kafka-ug-0069"></a><a name="kafka-ug-0069"></a>
<h1 class="topictitle1">Process of Using Kafka</h1> <h1 class="topictitle1">Process of Using Kafka</h1>
<div id="body0000001928973933"><p id="kafka-ug-0069__p8060118">The following figure shows the process of using a Kafka instance to produce and consume messages.</p> <div id="body0000001928973933"><p id="kafka-ug-0069__p20279101215539">Distributed Message Service is a message queuing service that is based on the open-source Apache Kafka. It provides Kafka instances with isolated computing, storage, and bandwidth resources. The following figure shows the process of message production and consumption using a Kafka instance.</p>
<div class="fignone" id="kafka-ug-0069__fig1427053672820"><span class="figcap"><b>Figure 1 </b>Process of using Kafka</span><br><span><img class="eddx" id="kafka-ug-0069__image1027063652820" src="en-us_image_0000001921463342.png"></span></div> <div class="fignone" id="kafka-ug-0069__fig1427053672820"><span class="figcap"><b>Figure 1 </b>Process of using Kafka</span><br><span><img class="eddx" id="kafka-ug-0069__image1027063652820" src="en-us_image_0000001921463342.png"></span></div>
<ol id="kafka-ug-0069__ol14448153518319"><li id="kafka-ug-0069__li444823515317"><a href="CreateUserAndGrantPolicy.html">Creating a User and Granting DMS for Kafka Permissions</a><p id="kafka-ug-0069__p1622914242115">Create IAM users and grant them only the DMS for Kafka permissions required to perform a given task based on their job responsibilities.</p> <ol id="kafka-ug-0069__ol14448153518319"><li id="kafka-ug-0069__li444823515317"><a href="CreateUserAndGrantPolicy.html">Creating a User and Granting DMS for Kafka Permissions</a><p id="kafka-ug-0069__p1622914242115">Create IAM users and grant them only the DMS for Kafka permissions required to perform a given task based on their job responsibilities.</p>
</li><li id="kafka-ug-0069__li2388104012329"><a href="kafka-ug-180604013.html">Creating a Kafka Instance</a><p id="kafka-ug-0069__p107121628193113">Kafka instances are tenant-exclusive, and physically isolated in deployment.</p> </li><li id="kafka-ug-0069__li2388104012329"><a href="kafka-ug-180604013.html">Creating a Kafka Instance</a><p id="kafka-ug-0069__p107121628193113">Kafka instances are tenant-exclusive, and physically isolated in deployment.</p>
</li><li id="kafka-ug-0069__li55410505327"><a href="kafka-ug-180604018.html">Creating a Kafka Topic</a><p id="kafka-ug-0069__p6871137131919">Create a topic for storing messages so that producers can produce messages and consumers can subscribe to messages.</p> </li><li id="kafka-ug-0069__li55410505327"><a href="kafka-ug-180604018.html">Creating a Kafka Topic</a><p id="kafka-ug-0069__p6871137131919">Create a topic for storing messages so that producers can produce messages and consumers can subscribe to messages.</p>
</li><li id="kafka-ug-0069__li885955793210"><a href="kafka-ug190605003.html">Connecting to an Instance</a><p id="kafka-ug-0069__p199933243357">The client uses commands to connect to Kafka instances in a private or public network, and produces and consumes messages.</p> </li><li id="kafka-ug-0069__li885955793210"><a href="kafka-ug190605003.html">Connecting to an Instance</a><p id="kafka-ug-0069__p199933243357">The client uses commands to connect to Kafka instances in a private or public network, and produces and consumes messages.</p>
</li><li id="kafka-ug-0069__li67552016339"><a href="kafka-ug-0720002.html">Managing Messages</a><p id="kafka-ug-0069__p154651146163711">View messages on the console.</p>
</li></ol> </li></ol>
<p id="kafka-ug-0069__p1971835713107"></p> <p id="kafka-ug-0069__p1971835713107"></p>
</div> </div>

View File

@ -5,7 +5,7 @@
<p id="kafka-ug-0319001__p590831019535">If you no longer need public access to the instance, you can disable it as required.</p> <p id="kafka-ug-0319001__p590831019535">If you no longer need public access to the instance, you can disable it as required.</p>
<div class="section" id="kafka-ug-0319001__section1556632611215"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-0319001__ul43224461164"><li id="kafka-ug-0319001__li332214651616">You can change the public access setting only when the Kafka instance is in the <strong id="kafka-ug-0319001__b17981720192210">Running</strong> state.</li><li id="kafka-ug-0319001__li642554816162">Kafka instances only support IPv4 EIPs. IPv6 EIPs are not supported.</li></ul> <div class="section" id="kafka-ug-0319001__section1556632611215"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-0319001__ul43224461164"><li id="kafka-ug-0319001__li332214651616">You can change the public access setting only when the Kafka instance is in the <strong id="kafka-ug-0319001__b17981720192210">Running</strong> state.</li><li id="kafka-ug-0319001__li642554816162">Kafka instances only support IPv4 EIPs. IPv6 EIPs are not supported.</li></ul>
</div> </div>
<div class="section" id="kafka-ug-0319001__section834421617132"><h4 class="sectiontitle">Enabling Public Access</h4><ol id="kafka-ug-0319001__ol834461641319"><li id="kafka-ug-0319001__li63444163132"><span>Log in to the console.</span></li><li id="kafka-ug-0319001__li14344316151317"><span>Click <span><img id="kafka-ug-0319001__image1233930594" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0319001__note23441116171314"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0319001__p2034419161138">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0319001__section834421617132"><h4 class="sectiontitle">Enabling Public Access</h4><ol id="kafka-ug-0319001__ol834461641319"><li id="kafka-ug-0319001__li63444163132"><span>Log in to the console.</span></li><li id="kafka-ug-0319001__li14344316151317"><span>Click <span><img id="kafka-ug-0319001__image1137903587" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0319001__note23441116171314"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0319001__p2034419161138">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0319001__li189561034172215"><span>Click <strong id="kafka-ug-0319001__b20745368495658">Service List</strong> and choose <strong id="kafka-ug-0319001__b36021218395658">Application</strong> &gt; <strong id="kafka-ug-0319001__b86047356395658">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0319001__li193442016171316"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0319001__b1691512239429">Basic Information</strong> page.</span></li><li id="kafka-ug-0319001__li132685951512"><span>Click <span><img id="kafka-ug-0319001__image1011185594817" src="en-us_image_0000001605213324.png"></span> next to <strong id="kafka-ug-0319001__b1911455144812">Public Access</strong> to enable public access. For <strong id="kafka-ug-0319001__b205022215483">Elastic IP Address</strong>, select an EIP for each broker. If the number of EIPs is insufficient, click <strong id="kafka-ug-0319001__b148921145141411">Create Elastic IP</strong> to go to the <strong id="kafka-ug-0319001__b1589311456146">Create EIP</strong> page and create EIPs. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/eip/eip_0002.html" target="_blank" rel="noopener noreferrer">Assigning an EIP</a>. After the creation is complete, return to the page for enabling the public access. Click <span><img id="kafka-ug-0319001__image12893545121414" src="en-us_image_0000001540501562.png"></span> next to <strong id="kafka-ug-0319001__b88935455143">Elastic IP Address</strong>, select EIPs from the drop-down list. The number of EIPs must be the same as the number of brokers. Then click <span><img id="kafka-ug-0319001__image1327175911512" src="en-us_image_0000001654533309.png"></span> and the <strong id="kafka-ug-0319001__b629142415176">Background Tasks</strong> page is displayed.</span><p><div class="p" id="kafka-ug-0319001__p837010016169">If the status of the task turns to <strong id="kafka-ug-0319001__b1514701518558">Successful</strong>, public access is successfully enabled.<div class="fignone" id="kafka-ug-0319001__fig16734144115159"><span class="figcap"><b>Figure 1 </b>Enabling public access</span><br><span><img id="kafka-ug-0319001__image19734134131516" src="en-us_image_0000001756508438.png"></span></div> </p></li><li id="kafka-ug-0319001__li189561034172215"><span>Click <strong id="kafka-ug-0319001__b20745368495658">Service List</strong> and choose <strong id="kafka-ug-0319001__b36021218395658">Application</strong> &gt; <strong id="kafka-ug-0319001__b86047356395658">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0319001__li193442016171316"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0319001__b1691512239429">Basic Information</strong> page.</span></li><li id="kafka-ug-0319001__li132685951512"><span>Click <span><img id="kafka-ug-0319001__image1011185594817" src="en-us_image_0000001605213324.png"></span> next to <strong id="kafka-ug-0319001__b1911455144812">Public Access</strong> to enable public access. For <strong id="kafka-ug-0319001__b205022215483">Elastic IP Address</strong>, select an EIP for each broker. If the number of EIPs is insufficient, click <strong id="kafka-ug-0319001__b148921145141411">Create Elastic IP</strong> to go to the <strong id="kafka-ug-0319001__b1589311456146">Create EIP</strong> page and create EIPs. For details, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/eip/eip_0002.html" target="_blank" rel="noopener noreferrer">Assigning an EIP</a>. After the creation is complete, return to the page for enabling the public access. Click <span><img id="kafka-ug-0319001__image12893545121414" src="en-us_image_0000001540501562.png"></span> next to <strong id="kafka-ug-0319001__b88935455143">Elastic IP Address</strong>, select EIPs from the drop-down list. The number of EIPs must be the same as the number of brokers. Then click <span><img id="kafka-ug-0319001__image1327175911512" src="en-us_image_0000001654533309.png"></span> and the <strong id="kafka-ug-0319001__b629142415176">Background Tasks</strong> page is displayed.</span><p><div class="p" id="kafka-ug-0319001__p837010016169">If the status of the task turns to <strong id="kafka-ug-0319001__b1514701518558">Successful</strong>, public access is successfully enabled.<div class="fignone" id="kafka-ug-0319001__fig16734144115159"><span class="figcap"><b>Figure 1 </b>Enabling public access</span><br><span><img id="kafka-ug-0319001__image19734134131516" src="en-us_image_0000001756508438.png"></span></div>
</div> </div>
@ -50,7 +50,7 @@
</div> </div>
</p></li></ol> </p></li></ol>
</div> </div>
<div class="section" id="kafka-ug-0319001__section13340025121318"><h4 class="sectiontitle">Disabling Public Access</h4><ol id="kafka-ug-0319001__ol17340825171317"><li id="kafka-ug-0319001__li2340202591310"><span>Log in to the console.</span></li><li id="kafka-ug-0319001__li1634062591312"><span>Click <span><img id="kafka-ug-0319001__image832879447" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0319001__note19340125131313"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0319001__p93400257133">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-0319001__section13340025121318"><h4 class="sectiontitle">Disabling Public Access</h4><ol id="kafka-ug-0319001__ol17340825171317"><li id="kafka-ug-0319001__li2340202591310"><span>Log in to the console.</span></li><li id="kafka-ug-0319001__li1634062591312"><span>Click <span><img id="kafka-ug-0319001__image24996783" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-0319001__note19340125131313"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-0319001__p93400257133">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-0319001__li13792195210169"><span>Click <strong id="kafka-ug-0319001__b621311491208">Service List</strong> and choose <strong id="kafka-ug-0319001__b17213194919202">Application</strong> &gt; <strong id="kafka-ug-0319001__b8213194912014">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0319001__li103402256131"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0319001__b116867247343">Basic Information</strong> page.</span></li><li id="kafka-ug-0319001__li502341362"><span>Before disabling public access, disable <strong id="kafka-ug-0319001__b1263410126214">Plaintext Access</strong> and <strong id="kafka-ug-0319001__b385312157218">Ciphertext Access</strong> next to <strong id="kafka-ug-0319001__b2140122515211">Public Network Access</strong>. Then click <span><img id="kafka-ug-0319001__image18332174215537" src="en-us_image_0000001605533602.png"></span> next to <strong id="kafka-ug-0319001__b71301351623">Public Access</strong>.</span></li><li id="kafka-ug-0319001__li4435257113810"><span>Click <strong id="kafka-ug-0319001__b18123122914223">OK</strong>. The <strong id="kafka-ug-0319001__b5143182352217">Background Tasks</strong> page is displayed. If the status of the task turns to <strong id="kafka-ug-0319001__b166113382190">Successful</strong>, public access is successfully disabled.</span><p><div class="p" id="kafka-ug-0319001__p425613634119">After public access is disabled, configure security group rules listed in <a href="#kafka-ug-0319001__table19794123044119">Table 2</a> before attempting to access Kafka in a VPC. For details about accessing Kafka, see <a href="kafka-ug190605003.html">Connecting to an Instance</a>. </p></li><li id="kafka-ug-0319001__li13792195210169"><span>Click <strong id="kafka-ug-0319001__b621311491208">Service List</strong> and choose <strong id="kafka-ug-0319001__b17213194919202">Application</strong> &gt; <strong id="kafka-ug-0319001__b8213194912014">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-0319001__li103402256131"><span>Click a Kafka instance to go to the <strong id="kafka-ug-0319001__b116867247343">Basic Information</strong> page.</span></li><li id="kafka-ug-0319001__li502341362"><span>Before disabling public access, disable <strong id="kafka-ug-0319001__b1263410126214">Plaintext Access</strong> and <strong id="kafka-ug-0319001__b385312157218">Ciphertext Access</strong> next to <strong id="kafka-ug-0319001__b2140122515211">Public Network Access</strong>. Then click <span><img id="kafka-ug-0319001__image18332174215537" src="en-us_image_0000001605533602.png"></span> next to <strong id="kafka-ug-0319001__b71301351623">Public Access</strong>.</span></li><li id="kafka-ug-0319001__li4435257113810"><span>Click <strong id="kafka-ug-0319001__b18123122914223">OK</strong>. The <strong id="kafka-ug-0319001__b5143182352217">Background Tasks</strong> page is displayed. If the status of the task turns to <strong id="kafka-ug-0319001__b166113382190">Successful</strong>, public access is successfully disabled.</span><p><div class="p" id="kafka-ug-0319001__p425613634119">After public access is disabled, configure security group rules listed in <a href="#kafka-ug-0319001__table19794123044119">Table 2</a> before attempting to access Kafka in a VPC. For details about accessing Kafka, see <a href="kafka-ug190605003.html">Connecting to an Instance</a>.
<div class="tablenoborder"><a name="kafka-ug-0319001__table19794123044119"></a><a name="table19794123044119"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0319001__table19794123044119" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Security group rules (private network access)</caption><thead align="left"><tr id="kafka-ug-0319001__row579543019417"><th align="left" class="cellrowborder" valign="top" width="13.211321132113211%" id="mcps1.3.5.2.6.2.1.3.2.6.1.1"><p id="kafka-ug-0319001__p6795130144115">Direction</p> <div class="tablenoborder"><a name="kafka-ug-0319001__table19794123044119"></a><a name="table19794123044119"></a><table cellpadding="4" cellspacing="0" summary="" id="kafka-ug-0319001__table19794123044119" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Security group rules (private network access)</caption><thead align="left"><tr id="kafka-ug-0319001__row579543019417"><th align="left" class="cellrowborder" valign="top" width="13.211321132113211%" id="mcps1.3.5.2.6.2.1.3.2.6.1.1"><p id="kafka-ug-0319001__p6795130144115">Direction</p>

View File

@ -4,7 +4,7 @@
<div id="body1523586900988"></div> <div id="body1523586900988"></div>
<div> <div>
<ul class="ullinks"> <ul class="ullinks">
<li class="ulchildlink"><strong><a href="kafka-ug-190605001.html">Viewing Kafka Monitoring Metrics</a></strong><br> <li class="ulchildlink"><strong><a href="kafka-ug-190605001.html">Viewing Kafka Metrics</a></strong><br>
</li> </li>
<li class="ulchildlink"><strong><a href="kafka-ug-180413002.html">Kafka Metrics</a></strong><br> <li class="ulchildlink"><strong><a href="kafka-ug-180413002.html">Kafka Metrics</a></strong><br>
</li> </li>

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,7 @@
<a name="kafka-ug-180418002"></a><a name="kafka-ug-180418002"></a> <a name="kafka-ug-180418002"></a><a name="kafka-ug-180418002"></a>
<h1 class="topictitle1">Viewing Kafka Audit Logs</h1> <h1 class="topictitle1">Viewing Kafka Audit Logs</h1>
<div id="body1524043485987"><div class="section" id="kafka-ug-180418002__section1031133402612"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-180418002__p587716152815">With Cloud Trace Service (CTS), you can record operations associated with DMS for later query, audit, and backtrack operations.</p> <div id="body1524043485987"><p id="kafka-ug-180418002__p587716152815">With Cloud Trace Service (CTS), you can record operations associated with DMS for later query, audit, and backtrack operations.</p>
</div>
<div class="section" id="kafka-ug-180418002__section720623416284"><h4 class="sectiontitle">Prerequisite</h4><p id="kafka-ug-180418002__p17838164032815">CTS has been enabled.</p> <div class="section" id="kafka-ug-180418002__section720623416284"><h4 class="sectiontitle">Prerequisite</h4><p id="kafka-ug-180418002__p17838164032815">CTS has been enabled.</p>
</div> </div>
<div class="section" id="kafka-ug-180418002__section101653310583"><h4 class="sectiontitle">DMS Operations Supported by CTS</h4> <div class="section" id="kafka-ug-180418002__section101653310583"><h4 class="sectiontitle">DMS Operations Supported by CTS</h4>
@ -231,6 +230,34 @@
<td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p8573637181919">deleteDMSBackendJobFailure</p> <td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p8573637181919">deleteDMSBackendJobFailure</p>
</td> </td>
</tr> </tr>
<tr id="kafka-ug-180418002__row207648411218"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p191071119192211">Successfully enabling Smart Connect</p>
</td>
<td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p13107181912214">kafka</p>
</td>
<td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p3107161902212">createConnectorTaskSuccess</p>
</td>
</tr>
<tr id="kafka-ug-180418002__row456524612116"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p1844143172216">Successfully creating a Smart Connect task</p>
</td>
<td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p1584412310224">kafka</p>
</td>
<td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p1984414316221">createConnectorSinkTaskSuccess</p>
</td>
</tr>
<tr id="kafka-ug-180418002__row17571348142112"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p146862772213">Failing to enable Smart Connect</p>
</td>
<td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p1268162762218">kafka</p>
</td>
<td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p186872720222">createConnectorTaskFailure</p>
</td>
</tr>
<tr id="kafka-ug-180418002__row2069319313239"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p183971082319">Failing to create a Smart Connect task</p>
</td>
<td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p68393104235">kafka</p>
</td>
<td class="cellrowborder" valign="top" width="42.085791420857916%" headers="mcps1.3.3.2.2.4.1.3 "><p id="kafka-ug-180418002__p1483915105234">createConnectorSinkTaskFailure</p>
</td>
</tr>
<tr id="kafka-ug-180418002__row457533714194"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p175764371199">Successfully creating a topic for a Kafka instance</p> <tr id="kafka-ug-180418002__row457533714194"><td class="cellrowborder" valign="top" width="29.957004299570038%" headers="mcps1.3.3.2.2.4.1.1 "><p id="kafka-ug-180418002__p175764371199">Successfully creating a topic for a Kafka instance</p>
</td> </td>
<td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p1157653712197">kafka</p> <td class="cellrowborder" valign="top" width="27.957204279572046%" headers="mcps1.3.3.2.2.4.1.2 "><p id="kafka-ug-180418002__p1157653712197">kafka</p>

View File

@ -125,13 +125,14 @@
</tbody> </tbody>
</table> </table>
</div> </div>
<div class="section" id="kafka-ug-180524001__section1759104141720"><h4 class="sectiontitle">Configuring a Kafka Alarm Rule</h4><ol id="kafka-ug-180524001__ol17239137707"><li id="kafka-ug-180524001__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-180524001__li14905725134512"><span>Click <span><img id="kafka-ug-180524001__image285617106252" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180524001__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180524001__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-180524001__section1759104141720"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-180524001__ol17239137707"><li id="kafka-ug-180524001__li2186699118249"><span>Log in to the console.</span></li><li id="kafka-ug-180524001__li14905725134512"><span>Click <span><img id="kafka-ug-180524001__image285617106252" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180524001__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180524001__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-180524001__li189561034172215"><span>Click <strong id="kafka-ug-180524001__b77694730695721">Service List</strong> and choose <strong id="kafka-ug-180524001__b27811839395721">Application</strong> &gt; <strong id="kafka-ug-180524001__b120348996795721">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180524001__li192391371908"><span>In the row containing the desired instance, click <strong id="kafka-ug-180524001__b873340839">View Metric</strong>.</span><p><p id="kafka-ug-180524001__p154060881">You are redirected to the Cloud Eye console page displaying metrics of the selected instance.</p> </p></li><li id="kafka-ug-180524001__li189561034172215"><span>Click <strong id="kafka-ug-180524001__b77694730695721">Service List</strong> and choose <strong id="kafka-ug-180524001__b27811839395721">Application</strong> &gt; <strong id="kafka-ug-180524001__b120348996795721">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180524001__li957514511813"><span>Go to the monitoring page in either of the following ways:</span><p><ul id="kafka-ug-180524001__ul178068161622"><li id="kafka-ug-180524001__li8806101612211">Click <strong id="kafka-ug-180524001__b12644227153311">View Metric</strong> in the row containing the desired Kafka instance.</li><li id="kafka-ug-180524001__li288422614210">Click the desired Kafka instance to go to the instance details page. Choose <strong id="kafka-ug-180524001__b0215184963619">Monitoring</strong> in the navigation pane.</li></ul>
</p></li><li id="kafka-ug-180524001__li191611357124618"><span>Hover the mouse pointer over a metric and click <span><img id="kafka-ug-180524001__image348317414262" src="en-us_image_0000001160616010.png"></span> to create an alarm rule for the metric.</span></li><li id="kafka-ug-180524001__li98414351297"><span>Specify the alarm details.</span><p><p id="kafka-ug-180524001__p182478425581">For more information about creating alarm rules, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/ces/ces_01_0073.html" target="_blank" rel="noopener noreferrer">Creating an Alarm Rule</a>.</p> </p></li><li id="kafka-ug-180524001__li191611357124618"><span>Hover the mouse pointer over a metric and click <span><img id="kafka-ug-180524001__image348317414262" src="en-us_image_0000001160616010.png"></span> to create an alarm rule for the metric. The <strong id="kafka-ug-180524001__b8855173111380">Create Alarm Rule</strong> page is displayed.</span></li><li id="kafka-ug-180524001__li98414351297"><span>Specify the alarm details.</span><p><p id="kafka-ug-180524001__p182478425581">For more information about creating alarm rules, see <a href="https://docs.otc.t-systems.com/en-us/usermanual/ces/ces_01_0073.html" target="_blank" rel="noopener noreferrer">Creating an Alarm Rule</a>.</p>
<ol type="a" id="kafka-ug-180524001__ol197327529105"><li id="kafka-ug-180524001__li1748311341635">Set the alarm name and description.</li><li id="kafka-ug-180524001__li13296104219221">Specify the alarm policy and alarm severity.<p id="kafka-ug-180524001__p775615587474"><a name="kafka-ug-180524001__li13296104219221"></a><a name="li13296104219221"></a>As shown in the following figure, if the original disk capacity usage is equal to or higher than 85% for three consecutive periods, an alarm is generated. If the alarm is not handled on time, an alarm notification is sent.</p> <ol type="a" id="kafka-ug-180524001__ol197327529105"><li id="kafka-ug-180524001__li1748311341635">Set the alarm name and description.</li><li id="kafka-ug-180524001__li13296104219221">Set the alarm policy.<p id="kafka-ug-180524001__p775615587474"><a name="kafka-ug-180524001__li13296104219221"></a><a name="li13296104219221"></a>As shown in the following figure, if the original disk capacity usage is equal to or higher than 85% for three consecutive periods, an alarm is generated. If the alarm is not handled on time, an alarm notification is sent.</p>
<div class="fignone" id="kafka-ug-180524001__fig333415281009"><span class="figcap"><b>Figure 1 </b>Setting the alarm policy and alarm severity</span><br><span><img id="kafka-ug-180524001__image8334028404" src="en-us_image_0000001757257336.png"></span></div> <div class="fignone" id="kafka-ug-180524001__fig333415281009"><span class="figcap"><b>Figure 1 </b>Setting the alarm policy and alarm severity</span><br><span><img id="kafka-ug-180524001__image8334028404" src="en-us_image_0000001757257336.png"></span></div>
</li><li id="kafka-ug-180524001__li1729664242213">Set the alarm notification configurations. If you enable <strong id="kafka-ug-180524001__b10213462517">Alarm Notification</strong>, specify <strong id="kafka-ug-180524001__b18347105710445">Notification Window</strong>, <strong id="kafka-ug-180524001__b1517221384515">Notification Object</strong>, and <strong id="kafka-ug-180524001__b16176182813454">Trigger Condition</strong>.</li><li id="kafka-ug-180524001__li16296942182210">Click <strong id="kafka-ug-180524001__b731019812515">Create</strong>.</li></ol> </li><li id="kafka-ug-180524001__li1668317714230">Set the alarm notification configurations.<p id="kafka-ug-180524001__p157631387231"><a name="kafka-ug-180524001__li1668317714230"></a><a name="li1668317714230"></a>If you enable <strong id="kafka-ug-180524001__b490605615411">Alarm Notification</strong>, specify <strong id="kafka-ug-180524001__b13906185614113">Notification Window</strong>, <strong id="kafka-ug-180524001__b190645618415">Notification Object</strong>, and <strong id="kafka-ug-180524001__b17906756114116">Trigger Condition</strong>.</p>
</li><li id="kafka-ug-180524001__li16296942182210">Click <strong id="kafka-ug-180524001__b731019812515">Create</strong>.</li></ol>
</p></li></ol> </p></li></ol>
</div> </div>
</div> </div>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,13 +1,12 @@
<a name="kafka-ug-180604015"></a><a name="kafka-ug-180604015"></a> <a name="kafka-ug-180604015"></a><a name="kafka-ug-180604015"></a>
<h1 class="topictitle1">Restarting a Kafka Instance</h1> <h1 class="topictitle1">Restarting a Kafka Instance</h1>
<div id="body1526549638065"><div class="section" id="kafka-ug-180604015__section42474604"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-180604015__p13251620">Restart one or more Kafka instances at a time on the DMS console.</p> <div id="body1526549638065"><p id="kafka-ug-180604015__p17295155511393">You can restart one or more Kafka instances in batches on the DMS console.</p>
<div class="notice" id="kafka-ug-180604015__note17702590205"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604015__p1870959192010">When a Kafka instance is being restarted, message retrieval and creation requests of clients will be rejected.</p> <div class="notice" id="kafka-ug-180604015__note17702590205"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604015__p1870959192010">When a Kafka instance is being restarted, message retrieval and creation requests of clients will be rejected.</p>
</div></div> </div></div>
</div>
<div class="section" id="kafka-ug-180604015__section46727122"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-180604015__p63863782">The status of the Kafka instance you want to restart is either <strong id="kafka-ug-180604015__b13929162402917">Running</strong> or <strong id="kafka-ug-180604015__b1792917247293">Faulty</strong>.</p> <div class="section" id="kafka-ug-180604015__section46727122"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-180604015__p63863782">The status of the Kafka instance you want to restart is either <strong id="kafka-ug-180604015__b13929162402917">Running</strong> or <strong id="kafka-ug-180604015__b1792917247293">Faulty</strong>.</p>
</div> </div>
<div class="section" id="kafka-ug-180604015__section58551735104011"><h4 class="sectiontitle">Restarting a Kafka Instance</h4><ol id="kafka-ug-180604015__ol15486424193825"><li id="kafka-ug-180604015__li44405841193825"><span>Log in to the console.</span></li><li id="kafka-ug-180604015__li14905725134512"><span>Click <span><img id="kafka-ug-180604015__image1314334813216" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180604015__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604015__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-180604015__section58551735104011"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-180604015__ol15486424193825"><li id="kafka-ug-180604015__li44405841193825"><span>Log in to the console.</span></li><li id="kafka-ug-180604015__li14905725134512"><span>Click <span><img id="kafka-ug-180604015__image1314334813216" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180604015__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604015__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-180604015__li189561034172215"><span>Click <strong id="kafka-ug-180604015__b170078317595656">Service List</strong> and choose <strong id="kafka-ug-180604015__b12518131195656">Application</strong> &gt; <strong id="kafka-ug-180604015__b7633969895656">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180604015__li432114271306"><span>Restart Kafka instances using one of the following methods:</span><p><ul id="kafka-ug-180604015__ul54985481419"><li id="kafka-ug-180604015__li104997486113">Select one or more Kafka instances and click <strong id="kafka-ug-180604015__b631103920422">Restart</strong> in the upper left corner.</li><li id="kafka-ug-180604015__li53063508319">In the row containing the desired instance, click <strong id="kafka-ug-180604015__b18879155294217">Restart</strong>.</li><li id="kafka-ug-180604015__li139043441946">Click the desired Kafka instance to view its details. In the upper right corner, click <strong id="kafka-ug-180604015__b1855496194312">Restart</strong>.</li></ul> </p></li><li id="kafka-ug-180604015__li189561034172215"><span>Click <strong id="kafka-ug-180604015__b170078317595656">Service List</strong> and choose <strong id="kafka-ug-180604015__b12518131195656">Application</strong> &gt; <strong id="kafka-ug-180604015__b7633969895656">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180604015__li432114271306"><span>Restart Kafka instances using one of the following methods:</span><p><ul id="kafka-ug-180604015__ul54985481419"><li id="kafka-ug-180604015__li104997486113">Select one or more Kafka instances and click <strong id="kafka-ug-180604015__b631103920422">Restart</strong> in the upper left corner.</li><li id="kafka-ug-180604015__li53063508319">In the row containing the desired instance, click <strong id="kafka-ug-180604015__b18879155294217">Restart</strong>.</li><li id="kafka-ug-180604015__li139043441946">Click the desired Kafka instance to view its details. In the upper right corner, click <strong id="kafka-ug-180604015__b1855496194312">Restart</strong>.</li></ul>
</p></li><li id="kafka-ug-180604015__li59228727173014"><span>In the <strong id="kafka-ug-180604015__b117462441117">Restart Instance</strong> dialog box, click <strong id="kafka-ug-180604015__b1823914464170">Yes</strong> to restart the Kafka instance.</span><p><p id="kafka-ug-180604015__p1914614812452">It takes 3 to 15 minutes to restart a Kafka instance. After the instance is successfully restarted, its status should be <strong id="kafka-ug-180604015__b07531656133110">Running</strong>.</p> </p></li><li id="kafka-ug-180604015__li59228727173014"><span>In the <strong id="kafka-ug-180604015__b117462441117">Restart Instance</strong> dialog box, click <strong id="kafka-ug-180604015__b1823914464170">Yes</strong> to restart the Kafka instance.</span><p><p id="kafka-ug-180604015__p1914614812452">It takes 3 to 15 minutes to restart a Kafka instance. After the instance is successfully restarted, its status should be <strong id="kafka-ug-180604015__b07531656133110">Running</strong>.</p>

View File

@ -1,13 +1,12 @@
<a name="kafka-ug-180604016"></a><a name="kafka-ug-180604016"></a> <a name="kafka-ug-180604016"></a><a name="kafka-ug-180604016"></a>
<h1 class="topictitle1">Deleting Kafka Instances</h1> <h1 class="topictitle1">Deleting Kafka Instances</h1>
<div id="body1526549638065"><div class="section" id="kafka-ug-180604016__section33628036"><h4 class="sectiontitle">Scenario</h4><p id="kafka-ug-180604016__p1454750144612">Delete one or more Kafka instances at a time on the DMS console.</p> <div id="body1526549638065"><p id="kafka-ug-180604016__p1454750144612">Delete one or more Kafka instances at a time on the DMS console.</p>
<div class="notice" id="kafka-ug-180604016__note71649575205"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604016__p1173115742019">Deleting a Kafka instance will delete the data in the instance without any backup. Exercise caution when performing this operation.</p> <div class="notice" id="kafka-ug-180604016__note71649575205"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604016__p1173115742019">Deleting a Kafka instance will delete the data in the instance without any backup. Exercise caution when performing this operation.</p>
</div></div> </div></div>
</div>
<div class="section" id="kafka-ug-180604016__section34216874"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-180604016__p1370171222217">The status of the Kafka instance you want to delete is <strong id="kafka-ug-180604016__b833581213442">Running</strong> or <strong id="kafka-ug-180604016__b133516121447">Faulty</strong>.</p> <div class="section" id="kafka-ug-180604016__section34216874"><h4 class="sectiontitle">Prerequisites</h4><p id="kafka-ug-180604016__p1370171222217">The status of the Kafka instance you want to delete is <strong id="kafka-ug-180604016__b833581213442">Running</strong> or <strong id="kafka-ug-180604016__b133516121447">Faulty</strong>.</p>
</div> </div>
<div class="section" id="kafka-ug-180604016__section949205010406"><h4 class="sectiontitle">Deleting Kafka Instances</h4><ol id="kafka-ug-180604016__ol1182784334211"><li id="kafka-ug-180604016__li17827743164213"><span>Log in to the console.</span></li><li id="kafka-ug-180604016__li14905725134512"><span>Click <span><img id="kafka-ug-180604016__image1837215548219" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180604016__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604016__p11964174020277">Select the region where your Kafka instance is located.</p> <div class="section" id="kafka-ug-180604016__section949205010406"><h4 class="sectiontitle">Procedure</h4><ol id="kafka-ug-180604016__ol1182784334211"><li id="kafka-ug-180604016__li17827743164213"><span>Log in to the console.</span></li><li id="kafka-ug-180604016__li14905725134512"><span>Click <span><img id="kafka-ug-180604016__image1837215548219" src="en-us_image_0143929918.png"></span> in the upper left corner to select a region.</span><p><div class="note" id="kafka-ug-180604016__note596412409275"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604016__p11964174020277">Select the region where your Kafka instance is located.</p>
</div></div> </div></div>
</p></li><li id="kafka-ug-180604016__li189561034172215"><span>Click <strong id="kafka-ug-180604016__b46393823095657">Service List</strong> and choose <strong id="kafka-ug-180604016__b96690699895657">Application</strong> &gt; <strong id="kafka-ug-180604016__b193135338695657">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180604016__li432114271306"><span>Delete pay-per-use Kafka instances in either of the following ways:</span><p><ul id="kafka-ug-180604016__ul54985481419"><li id="kafka-ug-180604016__li104997486113">Select one or more Kafka instances and click <strong id="kafka-ug-180604016__b1828619416178">Delete</strong> in the upper left corner.</li><li id="kafka-ug-180604016__li53063508319">In the row containing the Kafka instance to be deleted, choose <strong id="kafka-ug-180604016__b66631756143414">More</strong> &gt; <strong id="kafka-ug-180604016__b1266385603410">Delete</strong>.</li><li id="kafka-ug-180604016__li139043441946">Click the desired Kafka instance to view its details. In the upper right corner, choose <strong id="kafka-ug-180604016__b1851532086">More</strong> &gt; <strong id="kafka-ug-180604016__b138581637810">Delete</strong>.</li></ul> </p></li><li id="kafka-ug-180604016__li189561034172215"><span>Click <strong id="kafka-ug-180604016__b46393823095657">Service List</strong> and choose <strong id="kafka-ug-180604016__b96690699895657">Application</strong> &gt; <strong id="kafka-ug-180604016__b193135338695657">Distributed Message Service</strong>. The Kafka instance list is displayed.</span></li><li id="kafka-ug-180604016__li432114271306"><span>Delete pay-per-use Kafka instances in either of the following ways:</span><p><ul id="kafka-ug-180604016__ul54985481419"><li id="kafka-ug-180604016__li104997486113">Select one or more Kafka instances and click <strong id="kafka-ug-180604016__b1828619416178">Delete</strong> in the upper left corner.</li><li id="kafka-ug-180604016__li53063508319">In the row containing the Kafka instance to be deleted, choose <strong id="kafka-ug-180604016__b66631756143414">More</strong> &gt; <strong id="kafka-ug-180604016__b1266385603410">Delete</strong>.</li><li id="kafka-ug-180604016__li139043441946">Click the desired Kafka instance to view its details. In the upper right corner, choose <strong id="kafka-ug-180604016__b1851532086">More</strong> &gt; <strong id="kafka-ug-180604016__b138581637810">Delete</strong>.</li></ul>
<div class="note" id="kafka-ug-180604016__note1544202793513"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604016__p1582824315426">Kafka instances in the <strong id="kafka-ug-180604016__b11358161811137">Creating</strong>, <strong id="kafka-ug-180604016__b136841142817">Changing</strong>, <strong id="kafka-ug-180604016__b8528916132813">Change failed</strong>, or <strong id="kafka-ug-180604016__b1358131871310">Restarting</strong> state cannot be deleted.</p> <div class="note" id="kafka-ug-180604016__note1544202793513"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604016__p1582824315426">Kafka instances in the <strong id="kafka-ug-180604016__b11358161811137">Creating</strong>, <strong id="kafka-ug-180604016__b136841142817">Changing</strong>, <strong id="kafka-ug-180604016__b8528916132813">Change failed</strong>, or <strong id="kafka-ug-180604016__b1358131871310">Restarting</strong> state cannot be deleted.</p>

File diff suppressed because it is too large Load Diff

View File

@ -16,8 +16,48 @@
<div class="notice" id="kafka-ug-180604019__note824621552414"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604019__p122461315192412">For an instance with ciphertext access enabled, if <strong id="kafka-ug-180604019__b1591945924813">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-180604019__b1791965954814">false</strong>, topics cannot be deleted through the client.</p> <div class="notice" id="kafka-ug-180604019__note824621552414"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180604019__p122461315192412">For an instance with ciphertext access enabled, if <strong id="kafka-ug-180604019__b1591945924813">allow.everyone.if.no.acl.found</strong> is set to <strong id="kafka-ug-180604019__b1791965954814">false</strong>, topics cannot be deleted through the client.</p>
</div></div> </div></div>
<ul id="kafka-ug-180604019__ul14955625613"><li id="kafka-ug-180604019__li15955620614">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-180604019__b336441392517">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-180604019__screen1719958142520">./kafka-topics.sh --bootstrap-server ${connection-address} --delete --topic ${topic-name}</pre> <ul id="kafka-ug-180604019__ul14955625613"><li id="kafka-ug-180604019__li15955620614">For a Kafka instance with ciphertext access disabled, run the following command in the <strong id="kafka-ug-180604019__b336441392517">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-180604019__screen1719958142520">./kafka-topics.sh --bootstrap-server ${connection-address} --delete --topic ${topic-name}</pre>
</li><li id="kafka-ug-180604019__li2174501363">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-180604019__ol39441754276"><li id="kafka-ug-180604019__li875065916200">(Optional) For the Kafka security protocol, is SASL_PLAINTEXT or SASL_SSL used?<ul id="kafka-ug-180604019__ul2643717214"><li id="kafka-ug-180604019__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. In other cases, create the <strong id="kafka-ug-180604019__b91598863111297">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-180604019__b109654795611297">/config</strong> directory of the Kafka client. Add the username and password by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li><li id="kafka-ug-180604019__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. In other cases, create the <strong id="kafka-ug-180604019__b1839921366112927">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-180604019__b163407620112927">/config</strong> directory of the Kafka client. Add the username and password, and the SSL certificate configuration by referring to <a href="kafka-ug-180801001.html#kafka-ug-180801001__li5414277457">3</a>.</li></ul> <p id="kafka-ug-180604019__p143853199482">Parameter description:</p>
</li><li id="kafka-ug-180604019__li529219395271">Run the following command in the <strong id="kafka-ug-180604019__b815623372515">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-180604019__screen117611716133716">./kafka-topics.sh --bootstrap-server ${connection-address} --delete --topic ${topic-name} --command-config ./config/ssl-user-config.properties</pre> <ul id="kafka-ug-180604019__ul16385161914482"><li id="kafka-ug-180604019__li738521934810"><strong id="kafka-ug-180604019__b106103729104514">connection-address</strong>: can be obtained from the <strong id="kafka-ug-180604019__b350616590104514">Connection</strong> area on the <strong id="kafka-ug-180604019__b514461327104514">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-180604019__li1038541912487"><strong id="kafka-ug-180604019__b1035378094104533">topic-name</strong>: topic name.</li></ul>
<p id="kafka-ug-180604019__p103861619134812">Example:</p>
<pre class="screen" id="kafka-ug-180604019__screen238612196481">[root@ecs-kafka bin]# ./kafka-topics.sh --bootstrap-server 192.168.xx.xx:9092,192.168.xx.xx:9092,192.168.xx.xx:9092 --delete --topic topic-01
[root@ecs-kafka bin]#</pre>
</li><li id="kafka-ug-180604019__li2174501363">For a Kafka instance with ciphertext access enabled, do as follows:<ol id="kafka-ug-180604019__ol39441754276"><li id="kafka-ug-180604019__li339418234494">(Optional) Modify the client configuration file.<div class="p" id="kafka-ug-180604019__p10850192434916"><a name="kafka-ug-180604019__li339418234494"></a><a name="li339418234494"></a>View <strong id="kafka-ug-180604019__b113956713611234">Security Protocol</strong> in the <strong id="kafka-ug-180604019__b43584021411234">Connection</strong> area on the <strong id="kafka-ug-180604019__b136720150111234">Basic Information</strong> page on the Kafka console. The configuration settings vary depending on the protocol.<ul id="kafka-ug-180604019__ul2643717214"><li id="kafka-ug-180604019__li4646711216">SASL_PLAINTEXT: Skip this step if the username and password are already set. Otherwise, create the <strong id="kafka-ug-180604019__b176891236011153">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-180604019__b199202251111153">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-180604019__screen15787187202220">security.protocol=SASL_PLAINTEXT
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180604019__kafka-ug-180604018_b883312781111">scram.</strong><strong id="kafka-ug-180604019__kafka-ug-180604018_b1783311741112">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-180604019__kafka-ug-180604018_b128331377110">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180604019__kafka-ug-180604018_b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-180604019__kafka-ug-180604018_b964813191391">PLAIN</strong></pre>
<p id="kafka-ug-180604019__p117102681410">Parameter description: <strong id="kafka-ug-180604019__b1634146171103924">username</strong> and <strong id="kafka-ug-180604019__b440110950103924">password</strong> are the ones you set when enabling ciphertext access for the first time or when creating a user.</p>
</li><li id="kafka-ug-180604019__li493632862118">SASL_SSL: Skip this step if the username, password, and SSL certificate are already set. Otherwise, create the <strong id="kafka-ug-180604019__b109602209911153">ssl-user-config.properties</strong> file in the <strong id="kafka-ug-180604019__b113920492811153">/config</strong> directory on the Kafka client and add the following content to the file:<pre class="screen" id="kafka-ug-180604019__screen7661133992211">security.protocol=SASL_SSL
ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=
# If the SASL mechanism is SCRAM-SHA-512, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180604019__kafka-ug-180604018_b4657131681320">scram.</strong><strong id="kafka-ug-180604019__kafka-ug-180604018_b20657171612138">ScramLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-180604019__kafka-ug-180604018_b15657121620131">SCRAM-SHA-512</strong>
# If the SASL mechanism is PLAIN, configure as follows:
sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180604019__kafka-ug-180604018_b0657101619133">plain.PlainLoginModule</strong> required \
username="**********" \
password="**********";
sasl.mechanism=<strong id="kafka-ug-180604019__kafka-ug-180604018_b1665720164136">PLAIN</strong></pre>
<p id="kafka-ug-180604019__p497913422220">Parameter description:</p>
<ul id="kafka-ug-180604019__ul18362175202315"><li id="kafka-ug-180604019__kafka-ug-180604018_li9578173610155"><strong id="kafka-ug-180604019__kafka-ug-180604018_b15940166202617">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-180604019__kafka-ug-180604018_b1994056112615">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-180604019__kafka-ug-180604018_li4578153611159"><strong id="kafka-ug-180604019__kafka-ug-180604018_b02112214397">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-180604019__kafka-ug-180604018_b3211521103916">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-180604019__kafka-ug-180604018_li2057818362154"><strong id="kafka-ug-180604019__kafka-ug-180604018_b163656567392">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-180604019__kafka-ug-180604018_b4285516104010">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li><li id="kafka-ug-180604019__kafka-ug-180604018_li194571669169"><strong id="kafka-ug-180604019__kafka-ug-180604018_b16925191015415">username</strong> and <strong id="kafka-ug-180604019__kafka-ug-180604018_b17925141034110">password</strong>: username and password you set when enabling ciphertext access for the first time or when creating a user.</li></ul>
</li></ul>
</div>
</li><li id="kafka-ug-180604019__li529219395271">Run the following command in the <strong id="kafka-ug-180604019__b815623372515">/bin</strong> directory of the Kafka client:<pre class="screen" id="kafka-ug-180604019__screen117611716133716">./kafka-topics.sh --bootstrap-server ${connection-address} --delete --topic ${topic-name} --command-config ../config/ssl-user-config.properties</pre>
<p id="kafka-ug-180604019__p26601411816">Parameter description:</p>
<ul id="kafka-ug-180604019__ul64101149812"><li id="kafka-ug-180604019__li1338011599918"><strong id="kafka-ug-180604019__b940267347104514">connection-address</strong>: can be obtained from the <strong id="kafka-ug-180604019__b1010811119104514">Connection</strong> area on the <strong id="kafka-ug-180604019__b1541215428104514">Basic Information</strong> page on the Kafka console.</li><li id="kafka-ug-180604019__li1541015142810"><strong id="kafka-ug-180604019__b81303253104533">topic-name</strong>: topic name.</li></ul>
<p id="kafka-ug-180604019__p10626666416">Example:</p>
<pre class="screen" id="kafka-ug-180604019__screen16140191044820">[root@ecs-kafka bin]# ./kafka-topics.sh --bootstrap-server 192.168.xx.xx:9093,192.168.xx.xx:9093,192.168.xx.xx:9093 --delete --topic topic-01 --command-config ../config/ssl-user-config.properties
[root@ecs-kafka bin]#</pre>
<p id="kafka-ug-180604019__p46116619489"></p>
</li></ol> </li></ol>
</li></ul> </li></ul>
</div> </div>

View File

@ -1,15 +1,14 @@
<a name="kafka-ug-180604020"></a><a name="kafka-ug-180604020"></a> <a name="kafka-ug-180604020"></a><a name="kafka-ug-180604020"></a>
<h1 class="topictitle1">Connecting to Kafka Using the Client (Plaintext Access)</h1> <h1 class="topictitle1">Connecting to Kafka Using the Client (Plaintext Access)</h1>
<div id="body8662426"><p id="kafka-ug-180604020__p15305294196">This section describes how to use an open-source Kafka client to access a Kafka instance in plaintext. Two scenarios: private network within a VPC and public network. To access a Kafka instance across VPCs, see <a href="kafka-ug-0001.html">Accessing Kafka Using a VPC Endpoint Across VPCs</a>. To access a Kafka instance using DNAT, see <a href="kafka-dnat.html">Accessing Kafka in a Public Network Using DNAT</a>. To access an instance in your service code, see the <a href="https://docs.otc.t-systems.com/en-us/devg/dms/Kafka-summary.html" target="_blank" rel="noopener noreferrer">Distributed Message Service Developer Guide</a>.</p> <div id="body8662426"><p id="kafka-ug-180604020__p15305294196">This section describes how to access a Kafka instance in plaintext on an open-source Kafka client. With plaintext access enabled, there is no authentication required in such connections, which is friendly to performance.</p>
<p id="kafka-ug-180604020__en-us_topic_0143117094_p56172279297">For details on how to use a Kafka client in different languages, visit <a href="https://cwiki.apache.org/confluence/display/KAFKA/Clients" target="_blank" rel="noopener noreferrer">https://cwiki.apache.org/confluence/display/KAFKA/Clients</a>.</p> <p id="kafka-ug-180604020__p123244216307">Each Kafka broker allows a maximum of 1000 connections from each IP address. Excess connections will be rejected. You can change the limit by referring to <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>, that is, to modify parameter <strong id="kafka-ug-180604020__b1281011319112">max.connections.per.ip</strong>.</p>
<div class="note" id="kafka-ug-180604020__en-us_topic_0143117094_note149271233123218"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180604020__p123244216307">Each Kafka broker allows a maximum of 1000 connections from each IP address. Excess connections will be rejected. You can change the limit by referring to <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>, that is, to modify parameter <strong id="kafka-ug-180604020__b1281011319112">max.connections.per.ip</strong>.</p> <div class="section" id="kafka-ug-180604020__en-us_topic_0143117094_section17830048113810"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-180604020__ul109051343125919"><li id="kafka-ug-180604020__li7349123464111">The network between the client and the Kafka instance has been established. For details about the network requirements, see <a href="kafka-ug-180604012.html">Kafka Network Connection Conditions</a>.</li><li id="kafka-ug-180604020__li1790584385910">Security group rules have been properly configured.<p id="kafka-ug-180604020__en-us_topic_0143117094_p3469174210215"><a name="kafka-ug-180604020__li1790584385910"></a><a name="li1790584385910"></a>Before accessing a Kafka instance with ciphertext access disabled on a client, configure proper security group rules for the instance. For details, see <a href="kafka-ug-180604012.html#kafka-ug-180604012__table161395381402">Table 2</a>.</p>
</div></div> </li><li id="kafka-ug-180604020__li139061643115913"><a name="kafka-ug-180604020__li139061643115913"></a><a name="li139061643115913"></a>The Kafka instance addresses have been obtained.<div class="p" id="kafka-ug-180604020__p15871839143111"><a name="kafka-ug-180604020__li139061643115913"></a><a name="li139061643115913"></a>Obtain the instance connection addresses in the <strong id="kafka-ug-180604020__b83119258569">Connection</strong> area on the <strong id="kafka-ug-180604020__b157941428135617">Basic Information</strong> page on the Kafka console. The addresses are displayed in two types on the Kafka console. The one is <strong id="kafka-ug-180604020__b1385015919582">Private Network Access</strong> or <strong id="kafka-ug-180604020__b1542712202582">Public Network Access</strong> and the other is <strong id="kafka-ug-180604020__b1031215175920">Address (Private Network, Plaintext)</strong> or <strong id="kafka-ug-180604020__b15293131765912">Address (Public Network, Plaintext)</strong>.<ul id="kafka-ug-180604020__ul38831154155314"><li id="kafka-ug-180604020__li1288205420534">For private access within a VPC, the Kafka connection addresses are shown as follows.<div class="fignone" id="kafka-ug-180604020__fig131241959125712"><span class="figcap"><b>Figure 1 </b>Kafka instance addresses for private access within a VPC</span><br><span><img id="kafka-ug-180604020__image1185192884812" src="en-us_image_0000001756356494.png"></span></div>
<div class="section" id="kafka-ug-180604020__en-us_topic_0143117094_section17830048113810"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-180604020__ul109051343125919"><li id="kafka-ug-180604020__li1790584385910">Security group rules have been properly configured.<p id="kafka-ug-180604020__en-us_topic_0143117094_p3469174210215"><a name="kafka-ug-180604020__li1790584385910"></a><a name="li1790584385910"></a>To access a Kafka instance with ciphertext access disabled, configure proper security group rules. For details about security group configuration requirements, see <a href="kafka-ug-180604012.html#kafka-ug-180604012__table161395381402">Table 2</a>.</p> </li><li id="kafka-ug-180604020__li1288317545536">For public access, the Kafka connection addresses are shown as follows.<div class="fignone" id="kafka-ug-180604020__fig17907101110599"><span class="figcap"><b>Figure 2 </b>Kafka instance addresses for public access</span><br><span><img id="kafka-ug-180604020__image11716185511562" src="en-us_image_0000001756206030.png"></span></div>
</li><li id="kafka-ug-180604020__li139061643115913"><a name="kafka-ug-180604020__li139061643115913"></a><a name="li139061643115913"></a>The Kafka instance address has been obtained.<ul id="kafka-ug-180604020__ul38831154155314"><li id="kafka-ug-180604020__li1288205420534">To access a Kafka instance in a private network within a VPC, use port 9092. Obtain the instance connection address in the <strong id="kafka-ug-180604020__b1490072461120">Connection</strong> section of the <strong id="kafka-ug-180604020__b14900024111120">Basic Information</strong> page, shown as follows.<div class="fignone" id="kafka-ug-180604020__fig131241959125712"><span class="figcap"><b>Figure 1 </b>Kafka instance addresses for private access within a VPC (in plaintext)</span><br><span><img id="kafka-ug-180604020__image1185192884812" src="en-us_image_0000001756356494.png"></span></div>
</li><li id="kafka-ug-180604020__li1288317545536">To access a Kafka instance in a public network, use port 9094. Obtain the instance connection address in the <strong id="kafka-ug-180604020__b14121346171519">Connection</strong> section of the <strong id="kafka-ug-180604020__b71212461150">Basic Information</strong> page, shown as follows.<div class="fignone" id="kafka-ug-180604020__fig17907101110599"><span class="figcap"><b>Figure 2 </b>Kafka instance addresses for public access (in plaintext)</span><br><span><img id="kafka-ug-180604020__image11716185511562" src="en-us_image_0000001756206030.png"></span></div>
</li></ul> </li></ul>
</li><li id="kafka-ug-180604020__li139061743125917">If automatic topic creation is not enabled for the Kafka instance, <a href="kafka-ug-180604018.html">create a topic</a> before connecting to the instance.</li><li id="kafka-ug-180604020__li21645523313">Kafka CLI <a href="https://archive.apache.org/dist/kafka/1.1.0/kafka_2.11-1.1.0.tgz" target="_blank" rel="noopener noreferrer">v1.1.0</a>, <a href="https://archive.apache.org/dist/kafka/2.3.0/kafka_2.11-2.3.0.tgz" target="_blank" rel="noopener noreferrer">v2.3.0</a>, <a href="https://archive.apache.org/dist/kafka/2.7.2/kafka_2.12-2.7.2.tgz" target="_blank" rel="noopener noreferrer">v2.7.2</a>, or <a href="https://archive.apache.org/dist/kafka/3.4.0/kafka_2.12-3.4.0.tgz" target="_blank" rel="noopener noreferrer">v3.4.0</a> is available. Ensure that the Kafka instance and the CLI use the same version.</li><li id="kafka-ug-180604020__li14451359174616">An ECS that has an EIP has been created. For intra-VPC access, ensure that its VPC, subnet, and security group configurations are the same as those of the Kafka instance. <a href="https://www.oracle.com/java/technologies/downloads/#java8" target="_blank" rel="noopener noreferrer">JDK v1.8.111 or later</a> has been installed on the ECS, and the <strong id="kafka-ug-180604020__b256718220919">JAVA_HOME</strong> and <strong id="kafka-ug-180604020__b5296315690">PATH</strong> environment variables have been configured as follows:<p id="kafka-ug-180604020__p1843010610473">Add the following lines to the <strong id="kafka-ug-180604020__b7292637141111">.bash_profile</strong> file in the home directory as an authorized user. In this command, <strong id="kafka-ug-180604020__b228410341817">/opt/java/jdk1.8.0_151</strong> is the JDK installation path. Change it to the path where you install JDK.</p> </div>
</li><li id="kafka-ug-180604020__li139061743125917">If automatic topic creation is not enabled for the Kafka instance, <a href="kafka-ug-180604018.html">create a topic</a> before connecting to the instance.</li><li id="kafka-ug-180604020__li21645523313">Kafka CLI <a href="https://archive.apache.org/dist/kafka/1.1.0/kafka_2.11-1.1.0.tgz" target="_blank" rel="noopener noreferrer">v1.1.0</a>, <a href="https://archive.apache.org/dist/kafka/2.3.0/kafka_2.11-2.3.0.tgz" target="_blank" rel="noopener noreferrer">v2.3.0</a>, <a href="https://archive.apache.org/dist/kafka/2.7.2/kafka_2.12-2.7.2.tgz" target="_blank" rel="noopener noreferrer">v2.7.2</a>, or <a href="https://archive.apache.org/dist/kafka/3.4.0/kafka_2.12-3.4.0.tgz" target="_blank" rel="noopener noreferrer">v3.4.0</a> is available. Ensure that the Kafka instance and the CLI use the same version.</li><li id="kafka-ug-180604020__li14451359174616"><a href="https://www.oracle.com/java/technologies/downloads/#java8" target="_blank" rel="noopener noreferrer">JDK v1.8.111 or later</a> has been installed on the server, and the <strong id="kafka-ug-180604020__b57888201330">JAVA_HOME</strong> and <strong id="kafka-ug-180604020__b1478892017311">PATH</strong> environment variables have been configured as follows:<p id="kafka-ug-180604020__p1843010610473">Add the following lines to the <strong id="kafka-ug-180604020__b7292637141111">.bash_profile</strong> file in the home directory as an authorized user. In this command, <strong id="kafka-ug-180604020__b228410341817">/opt/java/jdk1.8.0_151</strong> is the JDK installation path. Change it to the path where you install JDK.</p>
<pre class="screen" id="kafka-ug-180604020__screen41501234102313">export JAVA_HOME=/opt/java/jdk1.8.0_151 <pre class="screen" id="kafka-ug-180604020__screen41501234102313">export JAVA_HOME=/opt/java/jdk1.8.0_151
export PATH=$JAVA_HOME/bin:$PATH</pre> export PATH=$JAVA_HOME/bin:$PATH</pre>
<p id="kafka-ug-180604020__p1351474712463">Run the <strong id="kafka-ug-180604020__b1179653919814">source .bash_profile</strong> command for the modification to take effect.</p> <p id="kafka-ug-180604020__p1351474712463">Run the <strong id="kafka-ug-180604020__b1179653919814">source .bash_profile</strong> command for the modification to take effect.</p>
@ -24,7 +23,7 @@ export PATH=$JAVA_HOME/bin:$PATH</pre>
</p></li><li id="kafka-ug-180604020__li1533025012558"><span>Access the <strong id="kafka-ug-180604020__b9592153417620">/bin</strong> directory of the Kafka CLI.</span><p><p id="kafka-ug-180604020__p18506153814396">In Windows, you need to access the <strong id="kafka-ug-180604020__b733518291519">/bin/windows</strong> directory.</p> </p></li><li id="kafka-ug-180604020__li1533025012558"><span>Access the <strong id="kafka-ug-180604020__b9592153417620">/bin</strong> directory of the Kafka CLI.</span><p><p id="kafka-ug-180604020__p18506153814396">In Windows, you need to access the <strong id="kafka-ug-180604020__b733518291519">/bin/windows</strong> directory.</p>
</p></li><li id="kafka-ug-180604020__en-us_topic_0143117094_li530704718816"><span>Run the following command to create messages:</span><p><pre class="screen" id="kafka-ug-180604020__screen16474103913616">./kafka-console-producer.sh --broker-list <em id="kafka-ug-180604020__i186681022381">${connection-address}</em> --topic <em id="kafka-ug-180604020__i838311719385">${topic-name}</em></pre> </p></li><li id="kafka-ug-180604020__en-us_topic_0143117094_li530704718816"><span>Run the following command to create messages:</span><p><pre class="screen" id="kafka-ug-180604020__screen16474103913616">./kafka-console-producer.sh --broker-list <em id="kafka-ug-180604020__i186681022381">${connection-address}</em> --topic <em id="kafka-ug-180604020__i838311719385">${topic-name}</em></pre>
<p id="kafka-ug-180604020__en-us_topic_0143117094_p6580101145012">Parameter description:</p> <p id="kafka-ug-180604020__en-us_topic_0143117094_p6580101145012">Parameter description:</p>
<ul id="kafka-ug-180604020__en-us_topic_0143117094_ul89649253507"><li id="kafka-ug-180604020__li125151036165720"><em id="kafka-ug-180604020__i388601323615">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180604020__li139061643115913">Prerequisites</a>. For public access, use <strong id="kafka-ug-180604020__b1888617136366">Address (Public Network, Plaintext)</strong>. For intra-VPC access, use <strong id="kafka-ug-180604020__b48861913113614">Address (Private Network, Plaintext)</strong>.</li><li id="kafka-ug-180604020__en-us_topic_0143117094_li21741228155018"><em id="kafka-ug-180604020__i207844315415">{topic-name}</em>: the name of the topic created for the Kafka instance. If automatic topic creation has enabled for the Kafka instance, set this parameter to the name of a created topic or a topic that has not been created.</li></ul> <ul id="kafka-ug-180604020__en-us_topic_0143117094_ul89649253507"><li id="kafka-ug-180604020__li125151036165720"><em id="kafka-ug-180604020__i20356834247">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180604020__li139061643115913">Prerequisites</a>.</li><li id="kafka-ug-180604020__en-us_topic_0143117094_li21741228155018"><em id="kafka-ug-180604020__i207844315415">{topic-name}</em>: the name of the topic created for the Kafka instance. If automatic topic creation has enabled for the Kafka instance, set this parameter to the name of a created topic or a topic that has not been created.</li></ul>
<p id="kafka-ug-180604020__en-us_topic_0143117094_p977916615114">The following example uses connection addresses <strong id="kafka-ug-180604020__b16884111616365">10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094</strong>. After running the preceding command, you can send a message to the Kafka instance by writing it and pressing <strong id="kafka-ug-180604020__b142914418451">Enter</strong>. Each line of content is sent as a message.</p> <p id="kafka-ug-180604020__en-us_topic_0143117094_p977916615114">The following example uses connection addresses <strong id="kafka-ug-180604020__b16884111616365">10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094</strong>. After running the preceding command, you can send a message to the Kafka instance by writing it and pressing <strong id="kafka-ug-180604020__b142914418451">Enter</strong>. Each line of content is sent as a message.</p>
<pre class="screen" id="kafka-ug-180604020__en-us_topic_0143117094_screen185531728161815">[root@ecs-kafka bin]# ./kafka-console-producer.sh --broker-list 10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094 --topic topic-demo <pre class="screen" id="kafka-ug-180604020__en-us_topic_0143117094_screen185531728161815">[root@ecs-kafka bin]# ./kafka-console-producer.sh --broker-list 10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094 --topic topic-demo
&gt;Hello &gt;Hello
@ -34,7 +33,7 @@ export PATH=$JAVA_HOME/bin:$PATH</pre>
<p id="kafka-ug-180604020__en-us_topic_0143117094_p106479615362">To stop creating messages, press <strong id="kafka-ug-180604020__b14873911217">Ctrl</strong>+<strong id="kafka-ug-180604020__b388398210">C</strong> to exit.</p> <p id="kafka-ug-180604020__en-us_topic_0143117094_p106479615362">To stop creating messages, press <strong id="kafka-ug-180604020__b14873911217">Ctrl</strong>+<strong id="kafka-ug-180604020__b388398210">C</strong> to exit.</p>
</p></li><li id="kafka-ug-180604020__en-us_topic_0143117094_li5760194019915"><span>Run the following command to retrieve messages:</span><p><pre class="screen" id="kafka-ug-180604020__screen592317503100">./kafka-console-consumer.sh --bootstrap-server ${connection-address} --topic ${topic-name} --group ${consumer-group-name} --from-beginning</pre> </p></li><li id="kafka-ug-180604020__en-us_topic_0143117094_li5760194019915"><span>Run the following command to retrieve messages:</span><p><pre class="screen" id="kafka-ug-180604020__screen592317503100">./kafka-console-consumer.sh --bootstrap-server ${connection-address} --topic ${topic-name} --group ${consumer-group-name} --from-beginning</pre>
<p id="kafka-ug-180604020__p142281739101217">Parameter description:</p> <p id="kafka-ug-180604020__p142281739101217">Parameter description:</p>
<ul id="kafka-ug-180604020__ul11899751181211"><li id="kafka-ug-180604020__li208291424155914"><em id="kafka-ug-180604020__i1441310147367">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180604020__li139061643115913">Prerequisites</a>. For public access, use <strong id="kafka-ug-180604020__b641314147369">Address (Public Network, Plaintext)</strong>. For intra-VPC access, use <strong id="kafka-ug-180604020__b1141331415363">Address (Private Network, Plaintext)</strong>.</li><li id="kafka-ug-180604020__li17900115141210"><em id="kafka-ug-180604020__i142718218266">{topic-name}</em>: the name of the topic created for the Kafka instance</li><li id="kafka-ug-180604020__li26191623171518"><em id="kafka-ug-180604020__i1942714315267">{consumer-group-name}</em>: the consumer group name set based on your service requirements. <strong id="kafka-ug-180604020__b982053393620">If a consumer group name has been specified in the configuration file, ensure that you use the same name in the command line. Otherwise, consumption may fail.</strong> If a consumer group name starts with a special character, such as an underscore (_) or a number sign (#), the monitoring data cannot be displayed.</li></ul> <ul id="kafka-ug-180604020__ul11899751181211"><li id="kafka-ug-180604020__li208291424155914"><em id="kafka-ug-180604020__i1841319411456">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180604020__li139061643115913">Prerequisites</a>.</li><li id="kafka-ug-180604020__li17900115141210"><em id="kafka-ug-180604020__i142718218266">{topic-name}</em>: the name of the topic created for the Kafka instance.</li><li id="kafka-ug-180604020__li26191623171518"><em id="kafka-ug-180604020__i1942714315267">{consumer-group-name}</em>: the consumer group name set based on your service requirements. <strong id="kafka-ug-180604020__b982053393620">If a consumer group name has been specified in the configuration file, ensure that you use the same name in the command line. Otherwise, consumption may fail.</strong> If a consumer group name starts with a special character, such as an underscore (_) or a number sign (#), the monitoring data cannot be displayed.</li></ul>
<p id="kafka-ug-180604020__p55205710467">Example:</p> <p id="kafka-ug-180604020__p55205710467">Example:</p>
<pre class="screen" id="kafka-ug-180604020__en-us_topic_0143117094_screen1863314117170">[root@ecs-kafka bin]# ./kafka-console-consumer.sh --bootstrap-server 10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094 --topic topic-demo --group order-test --from-beginning <pre class="screen" id="kafka-ug-180604020__en-us_topic_0143117094_screen1863314117170">[root@ecs-kafka bin]# ./kafka-console-consumer.sh --bootstrap-server 10.xx.xx.45:9094,10.xx.xx.127:9094,10.xx.xx.103:9094 --topic topic-demo --group order-test --from-beginning
Kafka! Kafka!

View File

@ -1,23 +1,22 @@
<a name="kafka-ug-180801001"></a><a name="kafka-ug-180801001"></a> <a name="kafka-ug-180801001"></a><a name="kafka-ug-180801001"></a>
<h1 class="topictitle1">Connecting to Kafka Using the Client (Ciphertext Access)</h1> <h1 class="topictitle1">Connecting to Kafka Using the Client (Ciphertext Access)</h1>
<div id="body8662426"><p id="kafka-ug-180801001__en-us_topic_0143117217_p779964218338">If you enable ciphertext access when creating an instance, SASL authentication will be required when your client connects to a Kafka instance.</p> <div id="body8662426"><p id="kafka-ug-180801001__en-us_topic_0143117217_p779964218338">This section describes how to access a Kafka instance in ciphertext on an open-source Kafka client. Accessing in ciphertext requires SASL authentication. The protocol <strong id="kafka-ug-180801001__b4695104491116">SASL_SSL</strong> encrypts data transmission with high security.</p>
<p id="kafka-ug-180801001__p2027913483353">For security purposes, <strong id="kafka-ug-180801001__b1962914013111">TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256</strong> is supported.</p> <p id="kafka-ug-180801001__p2027913483353">For security purposes, <strong id="kafka-ug-180801001__b1962914013111">TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256</strong> is supported.</p>
<p id="kafka-ug-180801001__p876613271218">This section describes how to use an open-source Kafka client to access a Kafka instance if ciphertext access has been enabled for the instance. There are two scenarios. To access a Kafka instance across VPCs, see <a href="kafka-ug-0001.html">Accessing Kafka Using a VPC Endpoint Across VPCs</a>. To access a Kafka instance using DNAT, see <a href="kafka-dnat.html">Accessing Kafka in a Public Network Using DNAT</a>. To access an instance in your service code, see the <a href="https://docs.otc.t-systems.com/en-us/devg/dms/Kafka-summary.html" target="_blank" rel="noopener noreferrer">Distributed Message Service Developer Guide</a>.</p> <p id="kafka-ug-180801001__p1229775516377">Each Kafka broker allows a maximum of 1000 connections from each IP address by default. Excess connections will be rejected. You can change the limit by referring to <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>, that is, to modify parameter <strong id="kafka-ug-180801001__b26871940132719">max.connections.per.ip</strong>.</p>
<div class="note" id="kafka-ug-180801001__en-us_topic_0143117217_note1105345426"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="kafka-ug-180801001__p1229775516377">Each Kafka broker allows a maximum of 1000 connections from each IP address by default. Excess connections will be rejected. You can change the limit by referring to <a href="kafka-ug-0007.html">Modifying Kafka Instance Configuration Parameters</a>, that is, to modify parameter <strong id="kafka-ug-180801001__b26871940132719">max.connections.per.ip</strong>.</p> <div class="section" id="kafka-ug-180801001__en-us_topic_0143117217_section17830048113810"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-180801001__ul193401428183818"><li id="kafka-ug-180801001__li5271204313148">The network between the client and the Kafka instance has been established. For details about the network requirements, see <a href="kafka-ug-180604012.html">Kafka Network Connection Conditions</a>.</li><li id="kafka-ug-180801001__li8340152811386">Security group rules have been properly configured.<p id="kafka-ug-180801001__en-us_topic_0143117217_p3469174210215"><a name="kafka-ug-180801001__li8340152811386"></a><a name="li8340152811386"></a>Before accessing a Kafka instance with ciphertext access enabled on a client, configure proper security group rules for the instance. For details, see <a href="kafka-ug-180604012.html#kafka-ug-180604012__table161395381402">Table 2</a>.</p>
</div></div> </li><li id="kafka-ug-180801001__li10340528173815"><a name="kafka-ug-180801001__li10340528173815"></a><a name="li10340528173815"></a>The Kafka instance addresses have been obtained.<div class="p" id="kafka-ug-180801001__p3426649121511"><a name="kafka-ug-180801001__li10340528173815"></a><a name="li10340528173815"></a>Obtain the instance connection addresses in the <strong id="kafka-ug-180801001__b19897430363164">Connection</strong> area on the <strong id="kafka-ug-180801001__b4508511963164">Basic Information</strong> page on the Kafka console. The addresses are displayed in two types on the Kafka console. The one is <strong id="kafka-ug-180801001__b63716431712">Private Network Access</strong> or <strong id="kafka-ug-180801001__b83717461713">Public Network Access</strong> and the other is <strong id="kafka-ug-180801001__b6375441717">Address (Private Network, Ciphertext)</strong> or <strong id="kafka-ug-180801001__b123720413176">Address (Public Network, Ciphertext)</strong>.<ul id="kafka-ug-180801001__en-us_topic_0143117217_ul10580112315016"><li id="kafka-ug-180801001__en-us_topic_0143117217_li3824171913506">For private access within a VPC, the Kafka connection addresses are shown as follows.<div class="fignone" id="kafka-ug-180801001__fig7852164514206"><span class="figcap"><b>Figure 1 </b>Kafka instance addresses for private access within a VPC</span><br><span><img id="kafka-ug-180801001__image48723181267" src="en-us_image_0000001756372046.png"></span></div>
<div class="section" id="kafka-ug-180801001__en-us_topic_0143117217_section17830048113810"><h4 class="sectiontitle">Prerequisites</h4><ul id="kafka-ug-180801001__ul193401428183818"><li id="kafka-ug-180801001__li8340152811386">Security group rules have been properly configured.<p id="kafka-ug-180801001__en-us_topic_0143117217_p3469174210215"><a name="kafka-ug-180801001__li8340152811386"></a><a name="li8340152811386"></a>To access a Kafka instance with ciphertext access enabled, configure proper security group rules. For details about security group configuration requirements, see <a href="kafka-ug-180604012.html#kafka-ug-180604012__table161395381402">Table 2</a>.</p> </li><li id="kafka-ug-180801001__en-us_topic_0143117217_li1624628105018">For public access, the Kafka connection addresses are shown as follows.<div class="fignone" id="kafka-ug-180801001__fig35911827142220"><span class="figcap"><b>Figure 2 </b>Kafka instance addresses for public access</span><br><span><img id="kafka-ug-180801001__image8551101043" src="en-us_image_0000001803290001.png"></span></div>
</li><li id="kafka-ug-180801001__li10340528173815"><a name="kafka-ug-180801001__li10340528173815"></a><a name="li10340528173815"></a>The Kafka instance address has been obtained.<ul id="kafka-ug-180801001__en-us_topic_0143117217_ul10580112315016"><li id="kafka-ug-180801001__en-us_topic_0143117217_li3824171913506">For intra-VPC access, use port 9093. Obtain the instance connection address in the <strong id="kafka-ug-180801001__b17247149192219">Connection</strong> section of the <strong id="kafka-ug-180801001__b324739172218">Basic Information</strong> tab page.<div class="fignone" id="kafka-ug-180801001__fig7852164514206"><span class="figcap"><b>Figure 1 </b>Kafka instance addresses for private access within a VPC (in ciphertext)</span><br><span><img id="kafka-ug-180801001__image48723181267" src="en-us_image_0000001756372046.png"></span></div>
</li><li id="kafka-ug-180801001__en-us_topic_0143117217_li1624628105018">For public access, use port 9095. Obtain the instance connection address in the <strong id="kafka-ug-180801001__b15350132235910">Connection</strong> section of the <strong id="kafka-ug-180801001__b1335052210592">Basic Information</strong> tab page.<div class="fignone" id="kafka-ug-180801001__fig35911827142220"><span class="figcap"><b>Figure 2 </b>Kafka instance addresses for public access (in ciphertext)</span><br><span><img id="kafka-ug-180801001__image8551101043" src="en-us_image_0000001803290001.png"></span></div>
<p id="kafka-ug-180801001__p147171925181413"></p> <p id="kafka-ug-180801001__p147171925181413"></p>
</li></ul> </li></ul>
</div>
</li><li id="kafka-ug-180801001__li198901524125317"><a name="kafka-ug-180801001__li198901524125317"></a><a name="li198901524125317"></a>The SASL mechanism in use is known.<p id="kafka-ug-180801001__p182003795510"><a name="kafka-ug-180801001__li198901524125317"></a><a name="li198901524125317"></a>In the <strong id="kafka-ug-180801001__b5442131717334">Connection</strong> area on the Kafka instance details page, view <strong id="kafka-ug-180801001__b9442111715338">SASL Mechanism</strong>. If both SCRAM-SHA-512 and PLAIN are enabled, use either of them in connection configurations. For instances that were created much earlier, if <strong id="kafka-ug-180801001__b12306289209">SASL Mechanism</strong> is not displayed on the instance details page, PLAIN is used by default.</p> </li><li id="kafka-ug-180801001__li198901524125317"><a name="kafka-ug-180801001__li198901524125317"></a><a name="li198901524125317"></a>The SASL mechanism in use is known.<p id="kafka-ug-180801001__p182003795510"><a name="kafka-ug-180801001__li198901524125317"></a><a name="li198901524125317"></a>In the <strong id="kafka-ug-180801001__b5442131717334">Connection</strong> area on the Kafka instance details page, view <strong id="kafka-ug-180801001__b9442111715338">SASL Mechanism</strong>. If both SCRAM-SHA-512 and PLAIN are enabled, use either of them in connection configurations. For instances that were created much earlier, if <strong id="kafka-ug-180801001__b12306289209">SASL Mechanism</strong> is not displayed on the instance details page, PLAIN is used by default.</p>
<div class="fignone" id="kafka-ug-180801001__fig12654840602"><span class="figcap"><b>Figure 3 </b>SASL mechanism in use</span><br><span><img id="kafka-ug-180801001__image7279112915507" src="en-us_image_0000001655285129.png"></span></div> <div class="fignone" id="kafka-ug-180801001__fig12654840602"><span class="figcap"><b>Figure 3 </b>SASL mechanism in use</span><br><span><img id="kafka-ug-180801001__image7279112915507" src="en-us_image_0000001655285129.png"></span></div>
</li><li id="kafka-ug-180801001__li112817505498"><a name="kafka-ug-180801001__li112817505498"></a><a name="li112817505498"></a>The security protocol in use is known.<p id="kafka-ug-180801001__p7569185117495"><a name="kafka-ug-180801001__li112817505498"></a><a name="li112817505498"></a>In the <strong id="kafka-ug-180801001__b1527618101527">Connection</strong> area on the Kafka instance details page, view <strong id="kafka-ug-180801001__b1927617101627">Security Protocol</strong>. For instances that were created much earlier, if <strong id="kafka-ug-180801001__b18626758115512">Security Protocol</strong> is not displayed on the instance details page, SASL_SSL is used by default.</p> </li><li id="kafka-ug-180801001__li112817505498"><a name="kafka-ug-180801001__li112817505498"></a><a name="li112817505498"></a>The security protocol in use is known.<p id="kafka-ug-180801001__p7569185117495"><a name="kafka-ug-180801001__li112817505498"></a><a name="li112817505498"></a>In the <strong id="kafka-ug-180801001__b1527618101527">Connection</strong> area on the Kafka instance details page, view <strong id="kafka-ug-180801001__b1927617101627">Security Protocol</strong>. For instances that were created much earlier, if <strong id="kafka-ug-180801001__b18626758115512">Security Protocol</strong> is not displayed on the instance details page, SASL_SSL is used by default.</p>
</li><li id="kafka-ug-180801001__li83408282381">If automatic topic creation is not enabled for the Kafka instance, <a href="kafka-ug-180604018.html">create a topic</a> before connecting to the instance.</li><li id="kafka-ug-180801001__li1434072810384">The <strong id="kafka-ug-180801001__b63141176311">client.</strong><strong id="kafka-ug-180801001__b332021783112"></strong><strong id="kafka-ug-180801001__b1332041716312">jks</strong> certificate has been downloaded. Click the Kafka instance to go to the <strong id="kafka-ug-180801001__b1462118251206">Basic Information</strong> tab page. Click <strong id="kafka-ug-180801001__b10622102518200">Download</strong> next to <strong id="kafka-ug-180801001__b1662242582018">SSL Certificate</strong> in the <strong id="kafka-ug-180801001__b1262242542011">Connection</strong> area. Download and decompress the package to obtain the client certificate file <strong id="kafka-ug-180801001__b1260644815519">client.</strong><strong id="kafka-ug-180801001__b2060620481957"></strong><strong id="kafka-ug-180801001__b1460614489510">jks</strong>.<div class="notice" id="kafka-ug-180801001__note38439582184"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180801001__p06211717112710">Later instances use the new certificate <strong id="kafka-ug-180801001__b1141524914303">client.jks</strong>, and earlier ones use the old certificate <strong id="kafka-ug-180801001__b595820933118">client.truststore.jks</strong>. Later instances are incompatible with the old certificate, and earlier ones are incompatible with the new certificate.</p> </li><li id="kafka-ug-180801001__li83408282381">If automatic topic creation is not enabled for the Kafka instance, <a href="kafka-ug-180604018.html">create a topic</a> before connecting to the instance.</li><li id="kafka-ug-180801001__li1434072810384">The <strong id="kafka-ug-180801001__b63141176311">client.</strong><strong id="kafka-ug-180801001__b332021783112"></strong><strong id="kafka-ug-180801001__b1332041716312">jks</strong> certificate has been downloaded. Click the Kafka instance to go to the <strong id="kafka-ug-180801001__b1462118251206">Basic Information</strong> tab page. Click <strong id="kafka-ug-180801001__b10622102518200">Download</strong> next to <strong id="kafka-ug-180801001__b1662242582018">SSL Certificate</strong> in the <strong id="kafka-ug-180801001__b1262242542011">Connection</strong> area. Download and decompress the package to obtain the client certificate file <strong id="kafka-ug-180801001__b1260644815519">client.</strong><strong id="kafka-ug-180801001__b2060620481957"></strong><strong id="kafka-ug-180801001__b1460614489510">jks</strong>.<div class="notice" id="kafka-ug-180801001__note38439582184"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="kafka-ug-180801001__p06211717112710">Later instances use the new certificate, and earlier ones use the old certificate. Later instances are incompatible with the old certificate, and earlier ones are incompatible with the new certificate.</p>
<p id="kafka-ug-180801001__p17329102952311">To determine whether a certificate is new, download it on the console and check its name.</p> <p id="kafka-ug-180801001__p17329102952311">To determine whether a certificate is new, download the Zip file of the certificate on the console and see the file name. The earlier name is <strong id="kafka-ug-180801001__b1863521224619">kafka-certs.zip</strong> and the later one is <strong id="kafka-ug-180801001__b2059632714618">kafka-cert-otc.zip</strong>.</p>
</div></div> </div></div>
</li><li id="kafka-ug-180801001__li10470715963">Kafka CLI <a href="https://archive.apache.org/dist/kafka/1.1.0/kafka_2.11-1.1.0.tgz" target="_blank" rel="noopener noreferrer">v1.1.0</a>, <a href="https://archive.apache.org/dist/kafka/2.3.0/kafka_2.11-2.3.0.tgz" target="_blank" rel="noopener noreferrer">v2.3.0</a>, <a href="https://archive.apache.org/dist/kafka/2.7.2/kafka_2.12-2.7.2.tgz" target="_blank" rel="noopener noreferrer">v2.7.2</a>, or <a href="https://archive.apache.org/dist/kafka/3.4.0/kafka_2.12-3.4.0.tgz" target="_blank" rel="noopener noreferrer">v3.4.0</a> is available. Ensure that the Kafka instance and the CLI use the same version.</li><li id="kafka-ug-180801001__li6576733113117">An ECS that has an EIP has been created. For intra-VPC access, ensure that its VPC, subnet, and security group configurations are the same as those of the Kafka instance. <a href="https://www.oracle.com/java/technologies/downloads/#java8" target="_blank" rel="noopener noreferrer">JDK v1.8.111 or later</a> has been installed on the ECS, and the <strong id="kafka-ug-180801001__b256718220919">JAVA_HOME</strong> and <strong id="kafka-ug-180801001__b5296315690">PATH</strong> environment variables have been configured as follows:<p id="kafka-ug-180801001__p1843010610473">Add the following lines to the <strong id="kafka-ug-180801001__b319735681814">.bash_profile</strong> file in the home directory as an authorized user. In this command, <strong id="kafka-ug-180801001__b2020410575185">/opt/java/jdk1.8.0_151</strong> is the JDK installation path. Change it to the path where you install JDK.</p> </li><li id="kafka-ug-180801001__li10470715963">Kafka CLI <a href="https://archive.apache.org/dist/kafka/1.1.0/kafka_2.11-1.1.0.tgz" target="_blank" rel="noopener noreferrer">v1.1.0</a>, <a href="https://archive.apache.org/dist/kafka/2.3.0/kafka_2.11-2.3.0.tgz" target="_blank" rel="noopener noreferrer">v2.3.0</a>, <a href="https://archive.apache.org/dist/kafka/2.7.2/kafka_2.12-2.7.2.tgz" target="_blank" rel="noopener noreferrer">v2.7.2</a>, or <a href="https://archive.apache.org/dist/kafka/3.4.0/kafka_2.12-3.4.0.tgz" target="_blank" rel="noopener noreferrer">v3.4.0</a> is available. Ensure that the Kafka instance and the CLI use the same version.</li><li id="kafka-ug-180801001__li6576733113117"><a href="https://www.oracle.com/java/technologies/downloads/#java8" target="_blank" rel="noopener noreferrer">JDK v1.8.111 or later</a> has been installed on the server, and the <strong id="kafka-ug-180801001__b57838439132118">JAVA_HOME</strong> and <strong id="kafka-ug-180801001__b164297520232118">PATH</strong> environment variables have been configured as follows:<p id="kafka-ug-180801001__p1843010610473">Add the following lines to the <strong id="kafka-ug-180801001__b319735681814">.bash_profile</strong> file in the home directory as an authorized user. In this command, <strong id="kafka-ug-180801001__b2020410575185">/opt/java/jdk1.8.0_151</strong> is the JDK installation path. Change it to the path where you install JDK.</p>
<pre class="screen" id="kafka-ug-180801001__screen41501234102313">export JAVA_HOME=/opt/java/jdk1.8.0_151 <pre class="screen" id="kafka-ug-180801001__screen41501234102313">export JAVA_HOME=/opt/java/jdk1.8.0_151
export PATH=$JAVA_HOME/bin:$PATH</pre> export PATH=$JAVA_HOME/bin:$PATH</pre>
<p id="kafka-ug-180801001__p1351474712463">Run the <strong id="kafka-ug-180801001__b181651014192">source .bash_profile</strong> command for the modification to take effect.</p> <p id="kafka-ug-180801001__p1351474712463">Run the <strong id="kafka-ug-180801001__b181651014192">source .bash_profile</strong> command for the modification to take effect.</p>
@ -34,7 +33,7 @@ export PATH=$JAVA_HOME/bin:$PATH</pre>
<p id="kafka-ug-180801001__p10316372449">In the preceding command, <em id="kafka-ug-180801001__i1681555142614">[kafka_tar]</em> indicates the name of the CLI package.</p> <p id="kafka-ug-180801001__p10316372449">In the preceding command, <em id="kafka-ug-180801001__i1681555142614">[kafka_tar]</em> indicates the name of the CLI package.</p>
<p id="kafka-ug-180801001__p14316207124417">For example:</p> <p id="kafka-ug-180801001__p14316207124417">For example:</p>
<p id="kafka-ug-180801001__p6871739204911"><strong id="kafka-ug-180801001__b942820393497">tar -zxf kafka_2.12-2.7.2.tgz</strong></p> <p id="kafka-ug-180801001__p6871739204911"><strong id="kafka-ug-180801001__b942820393497">tar -zxf kafka_2.12-2.7.2.tgz</strong></p>
</p></li><li id="kafka-ug-180801001__li5414277457"><a name="kafka-ug-180801001__li5414277457"></a><a name="li5414277457"></a><span>Modify the Kafka CLI configuration file based on the <a href="#kafka-ug-180801001__li198901524125317">SASL mechanism</a>.</span><p><ul id="kafka-ug-180801001__ul13286127155"><li id="kafka-ug-180801001__li1828642141511"><strong id="kafka-ug-180801001__b0705264331">If PLAIN is used</strong>, find the <strong id="kafka-ug-180801001__b5701626133311">consumer.properties</strong> and <strong id="kafka-ug-180801001__b1770426163317">producer.properties</strong> files in the <strong id="kafka-ug-180801001__b2070102619338">/config</strong> directory of the Kafka CLI and add the following content to the files:<pre class="screen" id="kafka-ug-180801001__screen1464811916913">sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180801001__b166481219196">plain.PlainLoginModule</strong> required \ </p></li><li id="kafka-ug-180801001__li5414277457"><span>Modify the Kafka CLI configuration file based on the <a href="#kafka-ug-180801001__li198901524125317">SASL mechanism</a>.</span><p><ul id="kafka-ug-180801001__ul13286127155"><li id="kafka-ug-180801001__li1828642141511"><strong id="kafka-ug-180801001__b0705264331">If PLAIN is used</strong>, find the <strong id="kafka-ug-180801001__b5701626133311">consumer.properties</strong> and <strong id="kafka-ug-180801001__b1770426163317">producer.properties</strong> files in the <strong id="kafka-ug-180801001__b2070102619338">/config</strong> directory of the Kafka CLI and add the following content to the files:<pre class="screen" id="kafka-ug-180801001__screen1464811916913">sasl.jaas.config=org.apache.kafka.common.security.<strong id="kafka-ug-180801001__b166481219196">plain.PlainLoginModule</strong> required \
username="**********" \ username="**********" \
password="**********"; password="**********";
sasl.mechanism=<strong id="kafka-ug-180801001__b964813191391">PLAIN</strong></pre> sasl.mechanism=<strong id="kafka-ug-180801001__b964813191391">PLAIN</strong></pre>
@ -52,13 +51,13 @@ ssl.truststore.location={ssl_truststore_path}
ssl.truststore.password=dms@kafka ssl.truststore.password=dms@kafka
ssl.endpoint.identification.algorithm=</pre> ssl.endpoint.identification.algorithm=</pre>
<p id="kafka-ug-180801001__p11117455910">Parameter description:</p> <p id="kafka-ug-180801001__p11117455910">Parameter description:</p>
<ul id="kafka-ug-180801001__ul7111134512918"><li id="kafka-ug-180801001__li41111457911"><strong id="kafka-ug-180801001__b38920456717">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-180801001__b178910451714">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-180801001__li101112451295"><strong id="kafka-ug-180801001__b166540230">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-180801001__b1088754166">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-180801001__li711117451390"><strong id="kafka-ug-180801001__b1900188871">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-180801001__b29578143320">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li></ul> <ul id="kafka-ug-180801001__ul7111134512918"><li id="kafka-ug-180801001__li41111457911"><strong id="kafka-ug-180801001__b38920456717">ssl.truststore.location</strong>: path for storing the <strong id="kafka-ug-180801001__b178910451714">client.jks</strong> certificate. Even in Windows, you need to use slashes (/) for the certificate path. Do not use backslashes (\), which are used by default for paths in Windows. Otherwise, the client will fail to obtain the certificate.</li><li id="kafka-ug-180801001__li101112451295"><strong id="kafka-ug-180801001__b483437830">ssl.truststore.password</strong>: server certificate password, which must be set to <strong id="kafka-ug-180801001__b1055728161">dms@kafka</strong> and cannot be changed.</li><li id="kafka-ug-180801001__li711117451390"><strong id="kafka-ug-180801001__b372460844">ssl.endpoint.identification.algorithm</strong>: whether to verify the certificate domain name. <strong id="kafka-ug-180801001__b29578143320">This parameter must be left blank, which indicates disabling domain name verification</strong>.</li></ul>
</li><li id="kafka-ug-180801001__li12111154516914"><strong id="kafka-ug-180801001__b67445186316">SASL_PLAINTEXT</strong>: Find the <strong id="kafka-ug-180801001__b674441816312">consumer.properties</strong> and <strong id="kafka-ug-180801001__b107448181316">producer.properties</strong> files in the <strong id="kafka-ug-180801001__b97445186312">/config</strong> directory of the Kafka CLI and add the following content to the files:<pre class="screen" id="kafka-ug-180801001__screen21117451796">security.protocol=SASL_PLAINTEXT</pre> </li><li id="kafka-ug-180801001__li12111154516914"><strong id="kafka-ug-180801001__b67445186316">SASL_PLAINTEXT</strong>: Find the <strong id="kafka-ug-180801001__b674441816312">consumer.properties</strong> and <strong id="kafka-ug-180801001__b107448181316">producer.properties</strong> files in the <strong id="kafka-ug-180801001__b97445186312">/config</strong> directory of the Kafka CLI and add the following content to the files:<pre class="screen" id="kafka-ug-180801001__screen21117451796">security.protocol=SASL_PLAINTEXT</pre>
</li></ul> </li></ul>
</p></li><li id="kafka-ug-180801001__li1533025012558"><span>Access the <strong id="kafka-ug-180801001__b20371812193018">/bin</strong> directory of the Kafka CLI.</span><p><p id="kafka-ug-180801001__p18506153814396">In Windows, you need to access the <strong id="kafka-ug-180801001__b4253171315308">/bin/windows</strong> directory.</p> </p></li><li id="kafka-ug-180801001__li1533025012558"><span>Access the <strong id="kafka-ug-180801001__b20371812193018">/bin</strong> directory of the Kafka CLI.</span><p><p id="kafka-ug-180801001__p18506153814396">In Windows, you need to access the <strong id="kafka-ug-180801001__b4253171315308">/bin/windows</strong> directory.</p>
</p></li><li id="kafka-ug-180801001__en-us_topic_0143117217_li530704718816"><span>Run the following command to create messages:</span><p><pre class="screen" id="kafka-ug-180801001__screen19612101611422">./kafka-console-producer.sh --broker-list ${connection addr} --topic ${topic name} --producer.config ../config/producer.properties</pre> </p></li><li id="kafka-ug-180801001__en-us_topic_0143117217_li530704718816"><span>Run the following command to create messages:</span><p><pre class="screen" id="kafka-ug-180801001__screen19612101611422">./kafka-console-producer.sh --broker-list ${connection addr} --topic ${topic name} --producer.config ../config/producer.properties</pre>
<p id="kafka-ug-180801001__en-us_topic_0143117217_p6580101145012">Parameter description:</p> <p id="kafka-ug-180801001__en-us_topic_0143117217_p6580101145012">Parameter description:</p>
<ul id="kafka-ug-180801001__en-us_topic_0143117217_ul89649253507"><li id="kafka-ug-180801001__li168655714517"><em id="kafka-ug-180801001__i520313716393">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180801001__li10340528173815">Prerequisites</a>. For public access, use <strong id="kafka-ug-180801001__b1620310379396">Address (Public Network, Ciphertext)</strong>. For intra-VPC access, use <strong id="kafka-ug-180801001__b15203103713399">Address (Private Network, Ciphertext)</strong>.</li><li id="kafka-ug-180801001__en-us_topic_0143117217_li21741228155018"><em id="kafka-ug-180801001__i19156822132812">{topic-name}</em>: the name of the topic created for the Kafka instance. If automatic topic creation has enabled for the Kafka instance, set this parameter to the name of a created topic or a topic that has not been created.</li></ul> <ul id="kafka-ug-180801001__en-us_topic_0143117217_ul89649253507"><li id="kafka-ug-180801001__li168655714517"><em id="kafka-ug-180801001__i452525317211">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180801001__li10340528173815">Prerequisites</a>.</li><li id="kafka-ug-180801001__en-us_topic_0143117217_li21741228155018"><em id="kafka-ug-180801001__i19156822132812">{topic-name}</em>: the name of the topic created for the Kafka instance. If automatic topic creation has enabled for the Kafka instance, set this parameter to the name of a created topic or a topic that has not been created.</li></ul>
<p id="kafka-ug-180801001__en-us_topic_0143117217_p1834813277531">The following example uses connection addresses <strong id="kafka-ug-180801001__b3679194014394">10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095</strong>.</p> <p id="kafka-ug-180801001__en-us_topic_0143117217_p1834813277531">The following example uses connection addresses <strong id="kafka-ug-180801001__b3679194014394">10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095</strong>.</p>
<p id="kafka-ug-180801001__en-us_topic_0143117217_p333211521719">After running the preceding command, you can send a message to the Kafka instance by writing it and pressing <strong id="kafka-ug-180801001__b67915915713">Enter</strong>. Each line of content is sent as a message.</p> <p id="kafka-ug-180801001__en-us_topic_0143117217_p333211521719">After running the preceding command, you can send a message to the Kafka instance by writing it and pressing <strong id="kafka-ug-180801001__b67915915713">Enter</strong>. Each line of content is sent as a message.</p>
<pre class="screen" id="kafka-ug-180801001__en-us_topic_0143117217_screen185531728161815">[root@ecs-kafka bin]#./kafka-console-producer.sh --broker-list 10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095 --topic topic-demo --producer.config ../config/producer.properties <pre class="screen" id="kafka-ug-180801001__en-us_topic_0143117217_screen185531728161815">[root@ecs-kafka bin]#./kafka-console-producer.sh --broker-list 10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095 --topic topic-demo --producer.config ../config/producer.properties
@ -69,7 +68,7 @@ ssl.endpoint.identification.algorithm=</pre>
<p id="kafka-ug-180801001__en-us_topic_0143117217_p3517646158">To stop creating messages, press <strong id="kafka-ug-180801001__b011018127585">Ctrl</strong>+<strong id="kafka-ug-180801001__b11110112175815">C</strong> to exit.</p> <p id="kafka-ug-180801001__en-us_topic_0143117217_p3517646158">To stop creating messages, press <strong id="kafka-ug-180801001__b011018127585">Ctrl</strong>+<strong id="kafka-ug-180801001__b11110112175815">C</strong> to exit.</p>
</p></li><li id="kafka-ug-180801001__en-us_topic_0143117217_li5760194019915"><span>Run the following command to retrieve messages:</span><p><pre class="screen" id="kafka-ug-180801001__screen1723111523466">./kafka-console-consumer.sh --bootstrap-server ${connection-address} --topic ${topic-name} --group ${consumer-group-name} --from-beginning --consumer.config ../config/consumer.properties</pre> </p></li><li id="kafka-ug-180801001__en-us_topic_0143117217_li5760194019915"><span>Run the following command to retrieve messages:</span><p><pre class="screen" id="kafka-ug-180801001__screen1723111523466">./kafka-console-consumer.sh --bootstrap-server ${connection-address} --topic ${topic-name} --group ${consumer-group-name} --from-beginning --consumer.config ../config/consumer.properties</pre>
<p id="kafka-ug-180801001__p764125413474">Parameter description:</p> <p id="kafka-ug-180801001__p764125413474">Parameter description:</p>
<ul id="kafka-ug-180801001__ul1064185410472"><li id="kafka-ug-180801001__li27881644611"><em id="kafka-ug-180801001__i1735153814395">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180801001__li10340528173815">Prerequisites</a>. For public access, use <strong id="kafka-ug-180801001__b235938153911">Address (Public Network, Ciphertext)</strong>. For intra-VPC access, use <strong id="kafka-ug-180801001__b23533893910">Address (Private Network, Ciphertext)</strong>.</li><li id="kafka-ug-180801001__li106421854184714"><em id="kafka-ug-180801001__i1938515297286">{topic-name}</em>: the name of the topic created for the Kafka instance.</li><li id="kafka-ug-180801001__li14947167152410"><em id="kafka-ug-180801001__i1942714315267">{consumer-group-name}</em>: the consumer group name set based on your service requirements. <strong id="kafka-ug-180801001__b12539021183414">If a consumer group name has been specified in the configuration file, ensure that you use the same name in the command line. Otherwise, consumption may fail.</strong> If a consumer group name starts with a special character, such as an underscore (_) or a number sign (#), the monitoring data cannot be displayed.</li></ul> <ul id="kafka-ug-180801001__ul1064185410472"><li id="kafka-ug-180801001__li27881644611"><em id="kafka-ug-180801001__i837518172215">{connection-address}</em>: the address obtained in <a href="#kafka-ug-180801001__li10340528173815">Prerequisites</a>.</li><li id="kafka-ug-180801001__li106421854184714"><em id="kafka-ug-180801001__i1938515297286">{topic-name}</em>: the name of the topic created for the Kafka instance.</li><li id="kafka-ug-180801001__li14947167152410"><em id="kafka-ug-180801001__i1942714315267">{consumer-group-name}</em>: the consumer group name set based on your service requirements. <strong id="kafka-ug-180801001__b12539021183414">If a consumer group name has been specified in the configuration file, ensure that you use the same name in the command line. Otherwise, consumption may fail.</strong> If a consumer group name starts with a special character, such as an underscore (_) or a number sign (#), the monitoring data cannot be displayed.</li></ul>
<p id="kafka-ug-180801001__p1492494716459">Example:</p> <p id="kafka-ug-180801001__p1492494716459">Example:</p>
<pre class="screen" id="kafka-ug-180801001__en-us_topic_0143117217_screen1863314117170">[root@ecs-kafka bin]# ./kafka-console-consumer.sh --bootstrap-server 10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095 --topic topic-demo --group order-test --from-beginning --consumer.config ../config/consumer.properties <pre class="screen" id="kafka-ug-180801001__en-us_topic_0143117217_screen1863314117170">[root@ecs-kafka bin]# ./kafka-console-consumer.sh --bootstrap-server 10.xx.xx.45:9095,10.xx.xx.127:9095,10.xx.xx.103:9095 --topic topic-demo --group order-test --from-beginning --consumer.config ../config/consumer.properties
Hello Hello

File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More