How Linux changes the root and home partition size summary

Source: Internet
Author: User

1. Installed CentOS7.5 virtual machine but found inside the operating system home partition accounted for 400g root partition only 50g think not very good, so to change.

2. Methods. It seems to be an XFS file format that cannot be processed using RESIZE2FS, and it needs to be handled in a XFS_GROWFS way.

3. Method: Df-h View disk status

4. Then use


View the file format of the home partition

5. Uninstall the home section

Umount/home

6. Delete Home's LV

Lvremove/dev/centos/centos-home

Select Yes to operate

7. Expand the size of the root partition

Lvextend-l +350g/dev/mapper/centos-root

8. Conduct XFS_GROWFS

Xfs_growfs/dev/centos/root

9. Create the LV for home

Lvcreate-l 50gb-n Home CentOS

10. Creating a File system

Mkfs.xfs/dev/centos/home

11 Hanging on

Mount/dev/mapper/centos-home

Can

How Linux changes the root and home partition size summary

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.