Before using an ECS to create a private image, you need to change disk identifiers to UUID in the fstab file of the ECS.
blkid
The following information is displayed:
/dev/xvda2: UUID="4eb40294-4c6f-4384-bbb6-b8795bbb1130"/dev/xvda2: UUID="4eb40294-4c6f-4384-bbb6-b8795bbb1130" TYPE="xfs"/dev/xvda1: UUID="2de37c6b-2648-43b4-a4f5-40162154e135"/dev/xvda1: UUID="2de37c6b-2648-43b4-a4f5-40162154e135" TYPE="swap"
cat /etc/fstab
The following information is displayed:
[root@CTU1000028010 ~]# cat /etc/fstab/dev/xvda2/dev/xvda2 / xfs defaults 0 0/dev/xvda1/dev/xvda1 swap swap defaults 0 0
vi /etc/fstab
blkid
/dev/xvda2: UUID="4eb40294-4c6f-4384-bbb6-b8795bbb1130" TYPE="xfs"/dev/xvda1: UUID="2de37c6b-2648-43b4-a4f5-40162154e135" TYPE="swap"
Before the change:
[root@CTU1000028010 ~]# cat /etc/fstab/dev/xvda2 / xfs defaults 0 0/dev/xvda1 swap swap defaults 0 0
After the change:
[root@CTU1000028010 ~]# cat /etc/fstabUUID=4eb40294-4c6f-4384-bbb6-b8795bbb1130 / xfs defaults 0 0UUID=2de37c6b-2648-43b4-a4f5-40162154e135 swap swap defaults 0 0
cat /etc/fstab
The change is successful if information similar to the following is displayed:
[root@CTU1000028010 ~]# cat /etc/fstabUUID=4eb40294-4c6f-4384-bbb6-b8795bbb1130UUID=4eb40294-4c6f-4384-bbb6-b8795bbb1130 / xfs defaults 0 0UUID=2de37c6b-2648-43b4-a4f5-40162154e135UUID=2de37c6b-2648-43b4-a4f5-40162154e135 swap swap defaults 0 0