Files
doc-exports/docs/ecs/umn/en-us_topic_0093492518.html
wanghuijuan738 8f01f116a5 ECS UMN 20260514 version. Added X1m instance specifications.
Reviewed-by: Pristromskaia, Margarita <margarita.pristromskaia@t-systems.com>
Co-authored-by: wanghuijuan738 <wanghuijuan738@huawei.com>
Co-committed-by: wanghuijuan738 <wanghuijuan738@huawei.com>
2026-05-18 09:03:42 +00:00

43 lines
10 KiB
HTML

<a name="EN-US_TOPIC_0093492518"></a><a name="EN-US_TOPIC_0093492518"></a>
<h1 class="topictitle1">Attaching a Network Interface</h1>
<div id="body1516164960187"><div class="section" id="EN-US_TOPIC_0093492518__section56491713122912"><h4 class="sectiontitle">Scenarios</h4><p id="EN-US_TOPIC_0093492518__p137925188372">If your <span id="EN-US_TOPIC_0093492518__text744811287229">ECS</span> requires multiple network interfaces, you can attach them to your <span id="EN-US_TOPIC_0093492518__text71851629112214">ECS</span>.</p>
</div>
<div class="section" id="EN-US_TOPIC_0093492518__section737852572918"><h4 class="sectiontitle">Procedure</h4><ol id="EN-US_TOPIC_0093492518__ol187946183379"><li id="EN-US_TOPIC_0093492518__li1151341720102">Log in to the management console.</li><li id="EN-US_TOPIC_0093492518__li464234814566">Click <span><img id="EN-US_TOPIC_0093492518__en-us_topic_0000001825604541_image9499446838" src="en-us_image_0000002188678994.png"></span> in the upper left corner and select a region and project.</li><li id="EN-US_TOPIC_0093492518__li079521816378">Under <strong id="EN-US_TOPIC_0093492518__b1729519104410"><span id="EN-US_TOPIC_0093492518__text772910198448">Computing</span></strong>, click <strong id="EN-US_TOPIC_0093492518__b572921915449">Elastic Cloud Server</strong>.</li><li id="EN-US_TOPIC_0093492518__li4796171815377">Click the name of the <span id="EN-US_TOPIC_0093492518__text198063114223">ECS</span> to which you want to attach a network interface.<p id="EN-US_TOPIC_0093492518__p1979631813379">The <span id="EN-US_TOPIC_0093492518__text6699161211106">ECS</span> details page is displayed.</p>
</li><li id="EN-US_TOPIC_0093492518__li147961818103717">On the <strong id="EN-US_TOPIC_0093492518__b13482135514168">Network Interfaces</strong> tab, click <strong id="EN-US_TOPIC_0093492518__b730621991715">Attach Network Interface</strong>.</li><li id="EN-US_TOPIC_0093492518__li10645185715258">Select either of the following methods to attach the network interface.<ul id="EN-US_TOPIC_0093492518__ul81651734152817"><li id="EN-US_TOPIC_0093492518__li199481119133316">Use an existing network interface.<ol type="a" id="EN-US_TOPIC_0093492518__ol0330122713312"><li id="EN-US_TOPIC_0093492518__li15433173311344">(Optional) Search for the network interface by name, ID, or private IP address.</li><li id="EN-US_TOPIC_0093492518__li9330122793311">In the network interface list, select the target one.</li></ol>
</li><li id="EN-US_TOPIC_0093492518__li152351845102818">Create a new network interface.<p id="EN-US_TOPIC_0093492518__p1956274814509"><a name="EN-US_TOPIC_0093492518__li152351845102818"></a><a name="li152351845102818"></a>Set the subnet and security group for the network interface to be attached.</p>
<div class="fignone" id="EN-US_TOPIC_0093492518__fig95275135171"><span class="figcap"><b>Figure 1 </b>Configuring the subnet and security group</span><br><span><img id="EN-US_TOPIC_0093492518__image99541497171" src="en-us_image_0000002351500708.png" title="Click to enlarge" class="imgResize"></span></div>
<ul id="EN-US_TOPIC_0093492518__ul1692821602315"><li id="EN-US_TOPIC_0093492518__li7551659185311"><strong id="EN-US_TOPIC_0093492518__b1604135418261">Subnet</strong>: the subnet that the network interface belongs to.</li><li id="EN-US_TOPIC_0093492518__li1392831652316"><strong id="EN-US_TOPIC_0093492518__b842352706171251">New Private IP Address</strong>: If you want to add a network interface with a specified IP address, enter an IP address into the <strong id="EN-US_TOPIC_0093492518__b84235270613839">New Private IP Address</strong> field.</li><li id="EN-US_TOPIC_0093492518__li1066310424541"><strong id="EN-US_TOPIC_0093492518__b34951249112618">Security Group</strong>: You can select multiple security groups. In such a case, the access rules of all the selected security groups will apply to the ECS.</li></ul>
</li></ul>
</li><li id="EN-US_TOPIC_0093492518__li2080091816377">Click <strong id="EN-US_TOPIC_0093492518__b842352706165945">OK</strong>.</li></ol>
</div>
<div class="section" id="EN-US_TOPIC_0093492518__section10882163016340"><h4 class="sectiontitle">Follow-up Procedure</h4><p id="EN-US_TOPIC_0093492518__p58011418123717">Some OSs cannot identify newly attached network interfaces. In this case, you need to manually activate the network interfaces. The following uses Ubuntu as an example to show how to activate network interfaces. Operations may vary depending on the operating system. You can refer to the corresponding OS documentation for assistance.</p>
<ol id="EN-US_TOPIC_0093492518__ol294910985212"><li id="EN-US_TOPIC_0093492518__li1660416195112">Log in to the management console.</li><li id="EN-US_TOPIC_0093492518__li146041191915">Click <span><img id="EN-US_TOPIC_0093492518__en-us_topic_0000001825604541_image9499446838_1" src="en-us_image_0000002188678994.png"></span> in the upper left corner and select a region and project.</li><li id="EN-US_TOPIC_0093492518__li156041819112">Under <strong id="EN-US_TOPIC_0093492518__b12133172194417"><span id="EN-US_TOPIC_0093492518__text01331421194419">Computing</span></strong>, click <strong id="EN-US_TOPIC_0093492518__b1013419217447">Elastic Cloud Server</strong>.</li><li id="EN-US_TOPIC_0093492518__li2949109175218">Locate the row containing the target <span id="EN-US_TOPIC_0093492518__text5179194961112">ECS</span> and click <strong id="EN-US_TOPIC_0093492518__b1618414921114">Remote Login</strong> in the <strong id="EN-US_TOPIC_0093492518__b20184204921117">Operation</strong> column.<p id="EN-US_TOPIC_0093492518__p895016975220">Log in to the <span id="EN-US_TOPIC_0093492518__text13837141531213">ECS</span>.</p>
</li><li id="EN-US_TOPIC_0093492518__li595089165210"><a name="EN-US_TOPIC_0093492518__li595089165210"></a><a name="li595089165210"></a>Run the following command to view the network interface name:<p id="EN-US_TOPIC_0093492518__p29507910525"><a name="EN-US_TOPIC_0093492518__li595089165210"></a><a name="li595089165210"></a><strong id="EN-US_TOPIC_0093492518__b1895019135217">ifconfig -a</strong></p>
<p id="EN-US_TOPIC_0093492518__p595049165214">In this example, the network interface name is <strong id="EN-US_TOPIC_0093492518__b74038287116">eth2</strong>.</p>
</li><li id="EN-US_TOPIC_0093492518__li16950129115211">Run the following command to switch to the target directory:<p id="EN-US_TOPIC_0093492518__p79505914522"><a name="EN-US_TOPIC_0093492518__li16950129115211"></a><a name="li16950129115211"></a><strong id="EN-US_TOPIC_0093492518__b11950109135219">cd /etc/network</strong></p>
</li><li id="EN-US_TOPIC_0093492518__li1195010935216">Run the following command to open the <strong id="EN-US_TOPIC_0093492518__b65355832314">interfaces</strong> file:<p id="EN-US_TOPIC_0093492518__p139511798525"><strong id="EN-US_TOPIC_0093492518__b095189145213">vi interfaces</strong></p>
</li><li id="EN-US_TOPIC_0093492518__li1595109105220">Add the following information to the <strong id="EN-US_TOPIC_0093492518__b14531158102316">interfaces</strong> file:<p id="EN-US_TOPIC_0093492518__p1195189205212"><strong id="EN-US_TOPIC_0093492518__b2109538724151041">auto</strong> <em id="EN-US_TOPIC_0093492518__i252375614151041">eth2</em></p>
<p id="EN-US_TOPIC_0093492518__p79512915217"><strong id="EN-US_TOPIC_0093492518__b431581062151056">iface</strong> <em id="EN-US_TOPIC_0093492518__i1414543114151056">eth2</em> <strong id="EN-US_TOPIC_0093492518__b420694667151056">inet dhcp</strong></p>
</li><li id="EN-US_TOPIC_0093492518__li695217913525">Run the following command to save and exit the <strong id="EN-US_TOPIC_0093492518__b6556586233">interfaces</strong> file:<p id="EN-US_TOPIC_0093492518__p8952119125210"><strong id="EN-US_TOPIC_0093492518__b1795214985217">:wq</strong></p>
</li><li id="EN-US_TOPIC_0093492518__li119522099529">Run either the <strong id="EN-US_TOPIC_0093492518__b1661014506114">ifup eth</strong><em id="EN-US_TOPIC_0093492518__i1561135010117"><strong id="EN-US_TOPIC_0093492518__b361025015114">X</strong></em> command or the <strong id="EN-US_TOPIC_0093492518__b1861217501811">/etc/init.d/networking restart</strong> command to make the newly added network interface take effect.<p id="EN-US_TOPIC_0093492518__p99528919528"><em id="EN-US_TOPIC_0093492518__i842352697155956">X</em> in the preceding command indicates the serial number of the network interface, for example, <strong id="EN-US_TOPIC_0093492518__b124938701017837">ifup eth2</strong>.</p>
</li><li id="EN-US_TOPIC_0093492518__li99534916522">Run the following command to check whether the network interface name obtained in step <a href="#EN-US_TOPIC_0093492518__li595089165210">5</a> is displayed in the command output:<p id="EN-US_TOPIC_0093492518__p1795314917527"><strong id="EN-US_TOPIC_0093492518__b179534910525">ifconfig</strong></p>
<p id="EN-US_TOPIC_0093492518__p189531393529">For example, check whether <strong id="EN-US_TOPIC_0093492518__b082154212104">eth2</strong> is displayed in the command output.</p>
<ul id="EN-US_TOPIC_0093492518__ul1395313913522"><li id="EN-US_TOPIC_0093492518__li59531915213">If yes, the newly added network interface has been activated. No further action is required.</li><li id="EN-US_TOPIC_0093492518__li995449145216">If no, the newly added network interface failed to be activated. Go to step <a href="#EN-US_TOPIC_0093492518__li1695469165210">12</a>.</li></ul>
</li><li id="EN-US_TOPIC_0093492518__li1695469165210"><a name="EN-US_TOPIC_0093492518__li1695469165210"></a><a name="li1695469165210"></a>Log in to the management console. On the ECS list page, locate the row that contains the target <span id="EN-US_TOPIC_0093492518__text13225163662219">ECS</span> and choose <strong id="EN-US_TOPIC_0093492518__b1530710341139">More</strong> &gt; <strong id="EN-US_TOPIC_0093492518__b1380019432315">Restart</strong> in the <strong id="EN-US_TOPIC_0093492518__b14694489312">Operation</strong> column.</li><li id="EN-US_TOPIC_0093492518__li1954199175219">Run <strong id="EN-US_TOPIC_0093492518__b1559266161117">ifconfig</strong> again to check whether the network interface name obtained in step <a href="#EN-US_TOPIC_0093492518__li595089165210">5</a> is displayed in the command output.<ul id="EN-US_TOPIC_0093492518__ul1695559125214"><li id="EN-US_TOPIC_0093492518__li795514975220">If yes, no further action is required.</li><li id="EN-US_TOPIC_0093492518__li79551191526">If no, contact customer service.</li></ul>
</li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="en-us_topic_0092497777.html">Elastic Network Interfaces</a></div>
</div>
</div>
<script language="JavaScript">
<!--
image_size('.imgResize');
var msg_imageMax = "view original image";
var msg_imageClose = "close";
//--></script>