This comprehensive guide demonstrates how to configure and mount an NTFS drive in read/write mode on Rocky Linux using the ntfs-3g driver. Originating from Tuxera, this driver provides an open-source solution for Linux and similar OS to interact with NTFS (New Technology File System). As it’s maintained within the FUSE (Filesystem in Userspace) framework, NTFS-3G facilitates streamlined data exchange between Linux and Windows environments. Its importance is paramount for users needing reliable access to NTFS-formatted drives, allowing for extensive file operations while ensuring data integrity. The continuous improvements to this driver ensure compatibility with evolving NTFS standards.
The ntfs-3g driver can be installed via the EPEL repository, which is accessible for all RHEL-based distributions. Below, you’ll find the detailed steps for enabling EPEL on Rocky Linux and installing ntfs-3g.
Step 1: Enable the EPEL Repository
To begin, enable the EPEL repository by executing the command below as a root user from the terminal:
dnf install epel-release
EPEL, which stands for Extra Packages for Enterprise Linux, is maintained by a Fedora Special Interest Group. It provides a collection of high-quality packages for Enterprise Linux, including popular distributions like Red Hat Enterprise Linux (RHEL) and Rocky Linux.
Step 2: Install the ntfs-3g Driver
Next, use the following command to install the ntfs-3g package via dnf:
dnf install ntfs-3g
After installation, you need to create a directory to mount the NTFS drive. Execute the command below:
mkdir /mnt/win
Mount the NTFS partition using:
mount -t ntfs-3g /dev/sdb1 /mnt/win
Note: In this example, /dev/sdb1 represents the NTFS partition. Replace it with your actual NTFS partition’s device name.
This mount will remain until a reboot or manual unmount via:
umount /mnt/win
Step 3: Mount NTFS Partition Permanently
For a permanent setup, modify the /etc/fstab file. Open it with an editor:
nano /etc/fstab
Add this line:
/dev/sdb1 /mnt/win ntfs-3g defaults 0 0
Adjust /dev/sdb1 to align with your device name. Upon saving and rebooting, the NTFS drive will auto-mount, ensuring seamless access.
FAQ
What is NTFS-3G?
NTFS-3G is an open-source driver that permits Linux and other Unix-like systems to read and write NTFS files, facilitating interoperability with Windows.
Why do I need to enable the EPEL repository?
The EPEL repository offers additional packages not included in the core Enterprise Linux distributions, such as the ntfs-3g driver.
How do I find out my NTFS partition’s device name?
Use the lsblk
or fdisk -l
command to list all available partitions and identify your NTFS partition.