How to mount and unmount drives on Linux

Answered
Jan 05, 2026 1835 views 1 answers
15

I connected a new drive. How do I mount it and access the files?

C
Asked by cloud_arch
Platinum 776 rep

1 Answer

22
# List available drives
lsblk
fdisk -l

# Create mount point
sudo mkdir /mnt/mydrive

# Mount drive
sudo mount /dev/sdb1 /mnt/mydrive

# Unmount
sudo umount /mnt/mydrive

# Auto-mount on boot (add to /etc/fstab)
/dev/sdb1 /mnt/mydrive ext4 defaults 0 2
A
Answered by ahmed_tech 1 week, 2 days ago
Platinum 151 rep

Your Answer

You need to be logged in to answer questions.

Log In to Answer

Hot Questions

No hot questions available.