How Can I Use a Ubuntu Image Source (x86_64) Provided by HUAWEI CLOUD?
When you are required to update the OS or software of an ECS, you can access the ECS to the Internet and use an external Ubuntu image source. However, if your ECS cannot access the Internet, or the external Ubuntu image source cannot provide services stably, you can use the Ubuntu image source provided by HUAWEI CLOUD.
- Make sure that the intranet DNS server provided by HUAWEI CLOUD has been configured. For instructions about how to obtain an intranet DNS server, see What Are the Private DNS Server Addresses Provided by the DNS Service?
- The operations described in this section apply to ECSs deployed on x86_64 servers.
- Log in to the ECS.
- Run the following command to back up the sources.list file:
mv /etc/apt/sources.list /etc/apt/sources.list.bak
- Select a suitable wget command according to the Ubuntu image source version, run the command to download the sources.list file, and save the file into /etc/apt/:
Table 1 lists the mapping between Ubuntu versions and version names.
Table 1 Mapping between Ubuntu versions and version names
apt Source Configuration File
Ubuntu 16.04 LTS
Ubuntu 14.04 LTS
Ubuntu 12.04 LTS
Take Ubuntu 14.04 as an example. Its apt source configuration file is sources.list.trusty. The configurations are as follows:
wget -O /etc/apt/sources.list http://mirrors.myhuaweicloud.com/repo/sources.list.trusty
- Run the following command to update the software library: