Last updated:2021-08-04 11:26:32
This topic describes how to purchase and use Linux KEC instances, including purchase, login, and data disk mounting.
Log in to the KEC instance console.
On the Instance page that appears, click Create Instance.
In the Basic Configuration step, select a Linux image, complete relevant configuration, and then click Next.
In the Network Configuration step, set Bind EIP to Buy New EIP or Purchase EIP Later in the EIP Console.
Note that the number of EIPs to be purchased must be the same as the number of KEC instances.
Set other parameters such as the VPC and click Next.
In the System Configuration step, enter the system information and click Buy Now.
Confirm the information and click Submit Order.
If your account balance is insufficient, click Recharge, enter the corresponding amount, and then click Confirm.
Click Instance in the left navigation pane, and check the KEC instance you have purchased in the list of KEC instances.
The KEC instance is automatically started and is in the Running state.
A Linux KEC instance supports WebVNC login and SSH login.
The default username is ubuntu for the Ubuntu operating system and root for all other Linux operating systems. If you forget the password, you can reset the password in the console.
Log in to the KEC instance console.
On the Instance page that appears, find the instance that you want to log in, and click Connect Instance in the Operation column.
Note that the instance must be in the Running state.
Enter the password and press Enter.
Before you log in to an instance by using SSH, add an inbound rule in which port 22 is enabled to the security group to which the instance belongs. For more information about how to configure a security group, see Configure a security group.
This example uses the PuTTY tool in Windows as the SSH client.
Start the PuTTY tool.
Set the following parameters in the PuTTY Configuration dialog box:
Click Open.
Enter the password and press Enter. The following figure shows the screen displayed after a successful login.
Run the fdisk -l
command to view the data disks mounted to the KEC instance.
Partition data disks. This example uses the data disk named vdb.
a. Run the fdisk /dev/vdb
command to partition the data disk.
b. Enter n
to create partitions.
c. Enter p
to create a single partition or e
to create multiple partitions.
d. Enter the partition number. Value values: 1 to 4.
e. Select the first sector of the partition. If you press the Enter key, the value 2048 is used by default.
f. Select the last sector of the partition. If you press the Enter key, the maximum value is used by default.
g. Enter w
to complete partitioning and exit.
Note: For more information about the method of formatting a data disk over 2 TB, see Partitioning and formatting of data disk of over 2 TB.
Format the new data disk partition vdb1. This example uses the ext4 file system. Run the mkfs.ext4 /dev/vdb1
command.
Create a mount point. This example uses the mount point named data. Run the mkdir /data
command.
Run the mount /dev/vdb1 /data
command to manually mount the data disk vdb to the mount point data.
Enable automatic mounting at startup for the disk vdb. Otherwise, the file system will not be displayed after startup.
Did you find the above information helpful?
Please give us your feedback.
Thank you for your feedback.