Enable xfs on Linux

Source: Internet
Author: User
Enable the xfs File System on Linux-general Linux technology-Linux technology and application information. The following is a detailed description. XFS file system Introduction: xfs is a high-performance Log File System on the IRIX system developed by sgi. It is transplanted to linux and open-source with GPL protocol.


Linux: CentOS 5 does not support xfs by default.

1. Use yum to upgrade kernel and xfs module.
Edit/etc/yum. repos. d/CentOS-Base.repo
[Centosplus]
Enabled = 1
2. Use yum to upgrade and install the relevant rpm
Yum update kernel-2.6.18-8.1.15.el5.centos.plus xfsprogs kmod-xfs-0.4-1.2.6.18_8.1.15.el5.centos.plus

3. modeprobe xfs
Lsmod | grep xfs
Xfs 481240 1
Dmesg
If the following information is displayed, the xfs module is loaded successfully.
Sgi xfs with ACLs, security attributes, realtime, large block numbers, no debug enabled
Sgi xfs Quota Management subsystem

4. format the xfs file system. Assume that sda3 in the original system is/opt.

Stop and/opt partition related applications and back up
Cp-a/opt/*/bakcup/opt
Umount/opt

Mkfs. xfs-f/dev/sda3
The prompt is as follows:
Meta-data =/dev/sda3 isize = 256 agcount = 16, agsize = 789067 blks
= Sectsz= 512 attr = 0
Data = bsize = 4096 blocks = 12625072, imaxpct = 25
= Sunit = 0 swidth = 0 blks, unwritten = 1
Naming = version 2 bsize = 4096
Log = internal log bsize = 4096 blocks = 6164, version = 1
= Sectsz= 512 sunit = 0 blks, lazy-count = 0
Realtime = none extsz = 4096 blocks = 0, rtextents = 0

5. Modify/etc/fstab
# LABEL =/opt ext3 defaults 1 2
/Dev/sda3/opt xfs defaults 1 1

6. Manually mount
Mount? T xfs/dev/sda3/xfs
Restore backup files

7. After reboot. The system automatically mount/opt to ask xfs
You can use mount to view details.

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.