Re-building a media library the hard way

Ok so now I have TrueNAS set up properly and have been migrated some files over from a dying QNAP via SMB - I find a large chunk of the files on the QNAP are “gone”

(This is precisely why I have moved back to a TrueNAS NAS set up in the first place!)

Talk about learning the hard way!

Further investigation reveals I had set up this QNAP QFS file system in the dim dark ages (like 20 years ago) when I didn’t really understand data protection - as a 4x HDD JBOD. In other words no raid or disc redundancy and I am getting a disc deterioration warning on QNAP disc 1.

Obviously I am going to try recover the lost files from that disc before I go thru the laborious task of re backup the media etc but this leads me to my question.

What is actually the best way to move large volumes of data into a ZFS pool?

Is SMB really the only option for file transfer these days or is there still a way to mount an NTFS or EXT4 drive in TrueNAS and copy the files into the ZFS pool manually?

If direct file transfer is an option which of EXT4 or NTFS is the best format option?

I am on the current TrueNAS Scale CE firmware

I don’t want to format the HDD for the archiving then find I have done all the backuping on the wrong type of formatted drive.

Thanks!

It’s not the only option. You could sftp/scp them. You could rsync them. Probably others I am not thinking of. All depends what options you have on the QNAP. If the system is functioning, I’d probably just use scp if I didn’t want to mess with SMB. I don’t think Truenas has ext4 drivers off hand.

If you had a QNAP backup somewhere, might be a way to read it from the backup depending on what that is.

1 Like

Thanks for the reply. I think you have misunderstood the question.
I am not asking about moving files from the QNAP, I am asking about the best way to move new data from a usb mountable HDD… :slightly_smiling_face:

Ok, but same answer. Whatever system that is on, if any. You cannot mount it unless it is zfs as far as I know. There is no ext4 driver in Truenas.

You could probably generate a Linux live (with ZFS) boot disk and boot into that and then mount whatever format drives you have and copy them.

1 Like

Ok cheers. Very familiar with SMB. I think I’ll stick to that.

Just thought I’d ask if direct transfer via EXT4 was an option (given TrueNAS scale had moved to Linux)

Pity it isn’t I guess - but what can you do?!

Thanks for the help.

1 Like

Yeah, that’s what most people do, SMB. It actually is a pity, used to be you could mount ext4.

1 Like

I’d be surprised if the ext4 driver was excised from
The kernel, but there certainly is no alternate fs support baked into the gui/middleware.

So, in theory, you may be able to manually mount drives, in practise you are supposed to use a Network protocol to access your storage on your Network Attached Storage device.

And SMB is generally the best of these when going from Windows or macOS

Rsync can be a good option to sync an old NAS… especially if its flaky.

And you can have the two devises directly communicate that way.

1 Like

Ok, so, prepare to be surprised then!

Here are the filesystems on Eel available for mounting:

cat /proc/filesystems
nodev	sysfs
nodev	tmpfs
nodev	bdev
nodev	proc
nodev	cgroup
nodev	cgroup2
nodev	cpuset
nodev	devtmpfs
nodev	debugfs
nodev	tracefs
nodev	securityfs
nodev	sockfs
nodev	bpf
nodev	pipefs
nodev	ramfs
nodev	hugetlbfs
nodev	devpts
	fuseblk
nodev	fuse
nodev	fusectl
nodev	virtiofs
nodev	mqueue
nodev	resctrl
nodev	pstore
nodev	efivarfs
nodev	zfs
nodev	autofs
nodev	configfs
nodev	binfmt_misc
nodev	rpc_pipefs
nodev	overlay
	squashfs

You’ll note all of the ext systems are missing now. Try it on a non Truenas Debian system, they are not missing of course! And if you still don’t believe it, attach an external ext4 drive and go ahead, try that mount. I’ve done it, fails.

I don’t understand WHY they did that, but they did quite some time back. Maybe it makes the kernel smaller, a goal of theirs. I suspect they did it at the time they removed the old import option, or whatever it was called. But am not sure when, just been a while.

1 Like

You fire up a Core installation? Muhhahaha. (that’s an evil laugh)

Oh, you can just install a VM, then pass through the raw device :wink:

Still, best approach is SMB or Rsync.

1 Like
root@titan[~]# truncate -s 1G ext4.img
root@titan[~]# ll ext4.img 
-rw-r--r-- 1 root 1073741824 Jul 22 11:28 ext4.img
root@titan[~]# mkfs.ext4 ./ext4.img 
mke2fs 1.47.0 (5-Feb-2023)
Discarding device blocks: done                            
Creating filesystem with 262144 4k blocks and 65536 inodes
Filesystem UUID: 0a9b7839-438f-4766-ade5-d67c21d16978
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (8192 blocks): done
Writing superblocks and filesystem accounting information: done

root@titan[~]# mkdir mnt
root@titan[~]# mount -t ext4 ./ext4.img mnt
root@titan[~]# ll mnt
total 29
drwxr-xr-x  3 root  4096 Jul 22 11:29 ./
drwx------ 10 root    22 Jul 22 11:29 ../
drwx------  2 root 16384 Jul 22 11:29 lost+found/
root@titan[~]# umount ./mnt 
root@titan[~]# blkid ext4.img 
ext4.img: UUID="0a9b7839-438f-4766-ade5-d67c21d16978" BLOCK_SIZE="4096" TYPE="ext4"
root@titan[~]# uname -a
Linux titan 6.6.44-production+truenas #1 SMP PREEMPT_DYNAMIC Fri Jul 11 12:56:00 UTC 2025 x86_64 GNU/Linux
root@titan[~]# cat /proc/filesystems | grep ext4
	ext4

:man_shrugging:

1 Like

So, I tested it on Fangtooth too.

root@fangtooth[~]# cat /proc/filesystems | grep ext4 
root@fangtooth[~]# mount -t ext4 ./ext4.img mnt
root@fangtooth[~]# cat /proc/filesystems | grep ext4 
	ext4
root@fangtooth[~]# uname -a
Linux fangtooth 6.12.25-production+truenas #1 SMP PREEMPT_DYNAMIC Mon Jun  9 07:07:55 UTC 2025 x86_64 GNU/Linux

Like i said, I’d be surprised if they excised it from the kernel

Is that on Fangtooth, they brought it back!?

Mine still says no ext4 on Eel.

I tested on both EE and FT.

(my production systems are on EE)

It appears in /proc/filesystem AFTER I use mount.

1 Like

Ahem, I do see that (now), my understanding of /proc/filesystem was clearly not what I thought.

But I really did try and mount an ext4 volume I had in some previous version. Could be I made a typo so a false memory.

Thanks, it’s actually good to know and may help the OP.

EDIT, this is funny, how do you read this doc page:

Maybe it doesn’t apply to Debian so maybe that’s why I relied on that memory from redhat days. The doc is likely missing a key piece. I think the ext4 module is being dynamically loaded and isn’t in the kernel perhaps. That’s what the Debian docs say about /proc/filesystems

Definitely appreciate the correction.

1 Like

Yes. It may not work with devices. Or it may not work auto-magically.

but, you can mount ext4 imgs, and incus would require the kernel to have support for the containers to work properly too, because the kernel is shared.