Image Management ServiceImage Management Service

Compute
Elastic Cloud Server
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
Domain Name Service
VPC Endpoint
Cloud Connect
Enterprise Switch
Security & Compliance
Anti-DDoS
Web Application Firewall
Host Security Service
Data Encryption Workshop
Database Security Service
Advanced Anti-DDoS
Data Security Center
Container Guard Service
Situation Awareness
Managed Threat Detection
Compass
Cloud Certificate Manager
Anti-DDoS Service
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GaussDB NoSQL
GaussDB(for MySQL)
Distributed Database Middleware
GaussDB(for openGauss)
Developer Services
ServiceStage
Distributed Cache Service
Simple Message Notification
Application Performance Management
Application Operations Management
Blockchain
API Gateway
Cloud Performance Test Service
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
DevCloud
ProjectMan
CodeHub
CloudRelease
CloudPipeline
CloudBuild
CloudDeploy
Cloud Communications
Message & SMS
Cloud Ecosystem
Marketplace
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP License Service
Support Plans
Customer Operation Capabilities
Partner Support Plans
Professional Services
enterprise-collaboration
Meeting
IoT
IoT
Intelligent EdgeFabric
DeveloperTools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Updated at: Feb 22, 2022 GMT+08:00

(Optional) Installing Cloudbase-Init

To configure the ECS created from an image (for example, changing the ECS password), you are advised to install Cloudbase-Init. If you do not install it, the ECS cannot be configured and you can log in to the ECS only with the image password.

Install Cloudbase-Init

  1. Download the Cloudbase-Init installation package.

    The version of Cloudbase-Init may vary depending on the OS bit. The downloaded package must be saved to a local shared folder (download path: http://www.cloudbase.it/cloud-init-for-windows-instances/).

  2. On the VirtualBox Windows VM, choose Computer > Network > VBOXSVR.
  3. Double-click the shared folder, copy the Cloudbase-Init installation package to the newly created VM, and double-click the installation package.

    In this section, CloudbaseInitSetup_0_9_11_x64 is used as an example.

Configure Cloudbase-Init

  1. Edit the configuration file C:\Program Files\Cloudbase Solutions\Cloudbase-Init\conf\cloudbase-init.conf in the Cloudbase-Init installation path.
    1. Add netbios_host_name_compatibility=false to the last line of the file so that the hostname supports a maximum of 63 characters.

      NetBIOS contains no more than 15 characters due to Windows system restrictions.

    2. Add metadata_services=cloudbaseinit.metadata.services.httpservice.HttpService to enable the agent to access the IaaS OpenStack data source.
    3. (Optional) Add the following configuration items to configure the number of retry times and interval for obtaining metadata:
      retry_count=40
      retry_count_interval=5
    4. (Optional) Add the following configuration item to prevent metadata network disconnections caused by the default route added by Windows:
      [openstack]
      add_metadata_private_ip_route=False
    5. (Optional) When the Cloudbase-Init version is 0.9.12 or later, you can customize the length of the password.

      Change the value of user_password_length to customize the password length.

    6. (Optional) Add the configuration item first_logon_behaviour=no to the cloudbase-init.conf configuration file in the C:\Program Files\Cloudbase Solutions\Cloudbase-Init\conf\ directory to disable password changing.

      Add first_logon_behaviour=no.

  2. Release the current DHCP address so that the created ECSs can obtain correct addresses.

    In the Windows command line, run the following command to release the current DHCP address:

    ipconfig /release

    This operation will interrupt network connection and adversely affect ECS use. The network will automatically recover after the ECSs are started again.

  3. When creating an image using a Windows ECS, you need to change the SAN policy of the ECS to OnlineAll. Otherwise, EVS disks attached to the ECSs created from the image may be offline.

    Windows has three types of SAN policies: OnlineAll, OfflineShared, and OfflineInternal.

    Table 1 SAN policies

    Type

    Description

    OnlineAll

    All newly detected disks are automatically brought online.

    OfflineShared

    All disks on sharable buses, such as iSCSI and FC, are left offline by default, while disks on non-sharable buses are kept online.

    OfflineInternal

    All newly detected disks are left offline.

    1. Execute cmd.exe and run the following command to query the current SAN policy of the ECS using DiskPart:

      diskpart

    2. Run the following command to view the SAN policy of the ECS:
      san
      • If the SAN policy is OnlineAll, run the exit command to exit DiskPart.
      • If the SAN policy is not OnlineAll, go to 3.c.
    3. Run the following command to change the SAN policy of the ECS to OnlineAll:

      san policy=onlineall

Did you find this page helpful?

Failed to submit the feedback. Please try again later.

Which of the following issues have you encountered?







Please complete at least one feedback item.

Content most length 200 character

Content is empty.

OK Cancel