doc-exports/docs/cce/umn/cce_bestpractice_0059.html
Dong, Qiu Jian 86fb05065f CCE UMN for 24.2.0 version -20240428
Reviewed-by: Eotvos, Oliver <oliver.eotvos@t-systems.com>
Co-authored-by: Dong, Qiu Jian <qiujiandong1@huawei.com>
Co-committed-by: Dong, Qiu Jian <qiujiandong1@huawei.com>
2024-06-10 08:19:07 +00:00

26 lines
5.1 KiB
HTML

<a name="cce_bestpractice_0059"></a><a name="cce_bestpractice_0059"></a>
<h1 class="topictitle1">Migrating Resources Outside a Cluster</h1>
<div id="body0000001171862344"><p id="cce_bestpractice_0059__p578123012334">If your migration does not involve resources outside a cluster listed in <a href="cce_bestpractice_0307.html#cce_bestpractice_0307__table1126932541820">Table 1</a> or you do not need to use other services to update resources after the migration, skip this section.</p>
<div class="section" id="cce_bestpractice_0059__section143771859185618"><h4 class="sectiontitle">Migrating Container Images</h4><p id="cce_bestpractice_0059__p4241514164217">To ensure that container images can be properly pulled after cluster migration and improve container deployment efficiency, you are advised to migrate private images to SoftWare Repository for Container (SWR). CCE works with SWR to provide a pipeline for automated container delivery. Images are pulled in parallel, which greatly improves container delivery efficiency.</p>
<p id="cce_bestpractice_0059__p19850219181320">Manually migrate container images.</p>
<ol id="cce_bestpractice_0059__en-us_topic_0264575651_ol4754151523913"><li id="cce_bestpractice_0059__en-us_topic_0264575651_li5754315133911"><span>Remotely log in to any node in the source cluster and run the <strong id="cce_bestpractice_0059__b123531411920">docker pull</strong> command to pull all images to the local host.</span></li><li id="cce_bestpractice_0059__li54208378229"><span>Log in to the SWR console, click <strong id="cce_bestpractice_0059__b710016262913">Login Command</strong> in the upper right corner of the page, and copy the command.</span></li><li id="cce_bestpractice_0059__li14501174119258"><span>Run the copied login command on the node.</span><p><p id="cce_bestpractice_0059__p1936514421259">The message "Login Succeeded" will be displayed upon a successful login.</p>
</p></li><li id="cce_bestpractice_0059__li1088171782619"><span>Add tags to all local images.</span><p><pre class="screen" id="cce_bestpractice_0059__screen1354353544915">docker tag <em id="cce_bestpractice_0059__i713342215465">[Image name 1</em>:<em id="cce_bestpractice_0059__i1113482214619">tag 1]</em> <em id="cce_bestpractice_0059__i21342229464">[Image repository address]</em>/<em id="cce_bestpractice_0059__i1513462213464">[Organization name]</em>/<em id="cce_bestpractice_0059__i413522213467">[Image name 2</em>:<em id="cce_bestpractice_0059__i1013532284617">tag 2]</em></pre>
<ul id="cce_bestpractice_0059__ul11488154018279"><li id="cce_bestpractice_0059__li84881840172716"><em id="cce_bestpractice_0059__i1778785720460">[Image name 1</em>:<em id="cce_bestpractice_0059__i187871557124610">tag 1]</em>: name and tag of the local image to be pulled.</li><li id="cce_bestpractice_0059__li948844016276"><em id="cce_bestpractice_0059__i41140121478">[Image repository address]</em>: You can obtain the image repository address on the SWR console.</li><li id="cce_bestpractice_0059__li2488144072718"><em id="cce_bestpractice_0059__i11199103854715">[Organization name]</em>: Enter the name of the organization you created on the SWR console.</li><li id="cce_bestpractice_0059__li4488940142715"><em id="cce_bestpractice_0059__i106852023104820">{Image name 2</em>:<em id="cce_bestpractice_0059__i17685132311484">Tag 2}</em>: image name and tag displayed on the SWR console.</li></ul>
<p id="cce_bestpractice_0059__p1948824042717">The following is an example:</p>
<pre class="screen" id="cce_bestpractice_0059__screen1338255424513">docker tag nginx:v1 swr.eu-de.otc.t-systems.com/cloud-develop/mynginx:v1</pre>
</p></li><li id="cce_bestpractice_0059__en-us_topic_0264575651_li10318626203915"><span>Run the <strong id="cce_bestpractice_0059__b3346477115">docker push</strong> command to upload all local container image files to SWR.</span><p><pre class="screen" id="cce_bestpractice_0059__screen17237344194914">docker push <em id="cce_bestpractice_0059__i3187105764818">[Image repository address]</em>/<em id="cce_bestpractice_0059__i1187135724812">[Organization name]</em>/<em id="cce_bestpractice_0059__i121871757154820">[Image name</em> 2:<em id="cce_bestpractice_0059__i61881857124819">tag 2]</em></pre>
<p id="cce_bestpractice_0059__p28065557311">The following is an example:</p>
<pre class="screen" id="cce_bestpractice_0059__screen1513693694612">docker push swr.eu-de.otc.t-systems.com/cloud-develop/mynginx:v1</pre>
</p></li></ol>
</div>
<div class="section" id="cce_bestpractice_0059__section395172934618"><h4 class="sectiontitle">Migrating Databases and Storage (On-Demand)</h4><p id="cce_bestpractice_0059__p59552934610">You can determine whether to use <strong id="cce_bestpractice_0059__b148311014171516">Relational Database Service (RDS)</strong> and <strong id="cce_bestpractice_0059__b15604151861511">Object Storage Service (OBS)</strong> based on your production requirements. After the migration is complete, reconfigure the database and storage for applications in the target CCE cluster.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="cce_bestpractice_0326.html">Procedure</a></div>
</div>
</div>