官术网_书友最值得收藏!

6.4 Mounting the New Partition

Next, we need to mount the new partition. In this example we will mount it in a directory named /data. You are free, however, to mount the new partition using any valid mount point you desire or to use it as part of a logical volume (details of which are covered in the chapter entitled “Adding a New Disk to an Ubuntu Volume Group and Logical Volume”). First we need to create the directory to act as the mount point:

# mkdir /data

Secondly, we need to edit the mount table in /etc/fstab so that the partition is automatically mounted each time the system starts. At the bottom of the /etc/fstab file, add the following line to mount the new partition (modifying the /dev/sda1 device to match your environment):

/dev/sda1 /data xfs defaults 0 0

Finally, we can manually mount the new partition (note that on subsequent reboots this will not be necessary as the partition will automount as a result of the setting we added to the /etc/fstab file above).

# mount /data

To check the partition, run the following command to display the available space:

# df -h /data

Filesystem Size Used Avail Use% Mounted on

/dev/sda1 29G 62M 29G 1% /data

主站蜘蛛池模板: 错那县| 澜沧| 当阳市| 嵩明县| 腾冲县| 赤水市| 平南县| 马山县| 宁都县| 桐庐县| 阿勒泰市| 广南县| 舞阳县| 鄂托克旗| 通许县| 游戏| 沈丘县| 保定市| 广东省| 五莲县| 曲阳县| 应城市| 满洲里市| 当阳市| 海口市| 保靖县| 论坛| 天镇县| 霍林郭勒市| 贵港市| 法库县| 安阳市| 云阳县| 金沙县| 改则县| 思茅市| 修水县| 安吉县| 西盟| 莎车县| 枣阳市|