What happens when a virtual machine increases disk space and the swap partition can't mount?

Source: Internet
Author: User
Tags uuid

Solve virtual machine Linux increase disk space after the swap partition can not automatically mount the issue, the use of Linux for this article is Lubuntu, not guaranteed to be applicable to other distributions Linux

1, into the Linux graphical interface, in the System tool to find Disk Management tools, LUBUTNU Disk Management tool is disc, open the mouse click on the swap partition, found that this partition is MOT mount State

2, click on the lower left gear shape icon, select the first item Format,type select EXT4, the format is completed after entering the next step

3, the same click on the Gear Shape button, select Edit Partition,type Select for swap 0x82, OK, close the dialog box

4, enter terminal tool, input command: Ls-l/dev/sda/by-uuid, view the UUID of the swap partition, and copy this UUID

5, first enter the command chmod u+w/etc/fstab, give disk file Write permission, and then enter the command vi/etc/fstab, open the file, copy the UUID replace the original UUID, save, restart the virtual machine, found that the swap partition automatically mount.

6, if you still do not have automatic mount, you can enter the command line: MKSWAP/DEV/SDA5, after the completion of the command after the execution of steps 4th and 5th respectively can also implement the partition automatic mount.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.