Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to mount disk in Linux

2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

This article will explain in detail how to mount a disk in Linux. The content of the article is of high quality, so the editor shares it for you as a reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.

1. View the disk:

Lsblk

NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT

Xvda 202:0 0 40G 0 disk

└─ xvda1 202:1 0 40G 0 part /

Xvdf 202:80 0 4G 0 disk

2. View the disk file type:

File-s / dev/xvdf

3. Format the disk:

Mkfs-t ext4 / dev/xvdf

4. Create a mount point:

Mkdir / ip2location

5. Mount: Mount the disk / dev/xvdf to the / ip2location directory

Mount / dev/xvdf / ip2location

6. Add boot mount: (please backup: cp / etc/fstab / etc/fstab.bak)

Vi / etc/fstab

# uuid is not recommended

/ dev/xvdf / ip2location ext4 defaults,nofail 0 2

7. Check the mount:

Mount-a

8. Uninstall the disk:

Umount-d / dev/xvdf

About how to mount the disk in Linux to share here, I hope the above content can be of some help to you, you can learn more knowledge. If you think the article is good, you can share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report