Mounting NTFS Drives on TrueNAS Using Ubuntu Docker Container¶
Overview¶
TrueNAS does not natively support NTFS drives for mounting and data transfer. Additionally, TrueNAS SCALE does not have apt
package management to install ntfs-3g
. However, you can work around this limitation by running an Ubuntu Docker container, granting it access to the physical disk, mounting the NTFS drive inside the container, and copying the data over.
Step 1: Identify the NTFS Drive in TrueNAS¶
- Connect the NTFS drive to your TrueNAS server via USB or SATA.
- Log into TrueNAS via SSH or use the Web UI Shell.
- List available drives:
lsblk
- Find your NTFS drive (e.g.,
/dev/sdb
).
Step 2: Deploy an Ubuntu Docker Container¶
To mount the NTFS drive, we need to run an Ubuntu-based container with access to the raw disk.
- Run the Docker container:
docker run --rm -it \ --privileged \ --device=/dev/sdb:/dev/sdb \ --mount type=bind,source=/mnt,target=/mnt \ ubuntu bash
Explanation:
- --rm
→ Removes the container after exiting (temporary usage).
- --privileged
→ Allows full device access to mount the NTFS drive.
- --device=/dev/sdb:/dev/sdb
→ Grants the container access to the NTFS disk.
- --mount type=bind,source=/mnt,target=/mnt
→ Provides access to TrueNAS storage.
Step 3: Install NTFS-3G Inside the Container¶
Once inside the running container:
apt update && apt install -y ntfs-3g
Step 4: Mount the NTFS Drive¶
-
Create a mount point:
mkdir -p /mnt/ntfs_drive
-
Mount the NTFS drive:
mount -t ntfs-3g /dev/sdb /mnt/ntfs_drive
-
Verify the mount:
df -h
You should see the NTFS drive mounted at /mnt/ntfs_drive
.
Step 5: Copy Data to TrueNAS Storage¶
- Determine the TrueNAS storage location (mounted at
/mnt/
inside the container). - Copy the files:
(Replace
cp -r /mnt/ntfs_drive/* /mnt/destination_folder/
/mnt/destination_folder/
with the actual storage pool location.)
Step 6: Unmount and Cleanup¶
- Unmount the drive inside the container:
umount /mnt/ntfs_drive
- Exit the container:
exit
- Physically disconnect the NTFS drive if needed.
Conclusion¶
Since TrueNAS does not natively support NTFS, this Ubuntu Docker container method provides a workaround by temporarily mounting the drive and copying files over. This method ensures data transfer without modifying the TrueNAS system itself.
Let me know if you need additional refinements!