Problem description
- After you set the hostname in the ECS console, restarting the host does not take effect. The hostname is displayed on the host.
- ECS by cloud-init the host name of the check
cloud-init
has been installed butcloud-init --versions
command prompt after the following informationNo module named 'requests.packages.urllib3'
Cause
According to the error positioning is Python's requests
and urllib3
modules contribute to The.
Solution
Alibaba Cloud reminds you that:
- Before you perform operations that may cause risks, such as modifying instance configurations or data, we recommend that you check the disaster recovery and fault tolerance capabilities of the instances to ensure data security.
- You can modify the configurations and data of instances including but not limited to Elastic Compute Service (ECS) and Relational Database Service (RDS) instances. Before the modification, we recommend that you create snapshots or enable RDS log backup.
- If you have authorized or submitted sensitive information such as the logon account and password in the Alibaba Cloud Management Console, we recommend that you modify such information in a timely manner.
- Run the following command .
pip install urllib3 --upgrade
pip install requests --upgrade - Modify hostnames in the console and restart the instance to apply the changes.
Application scope
- Elastic Compute Service