UFS and Debian: Migrating from FreeNAS to OpenMediaVault

I have been trying to migrate away from freeNAS for the past 2 years now since the advent of Open Media Vault. I’ve come across the issue of accessing data from my UFS filesystem drives ( freeNAS uses has the option to use UFS being based on BSD platform). Suffice it to say it was difficult to access the drive since I did not have any computers loaded with BSD. I had windows/mac and Linux (ubuntu). Scouring the web, there were many options, but I did not have the free time or spare computers to fully explore how to do this. I remember last year I found some info how to do this but did not have the time to follow through. Today I was determined to do it.

Basically, I needed to access and transfer files from an UFS drive and back it up  to either an NTFS or EXT-4 drive, then I could re-purpose the old UFS drive.

Simplest way for me was to mount the UFS drive on my Ubuntu computer, and then move the files. Ubuntu does not support UFS out of box, but with the help of this post, I was able to get things working in a Jiffy.

Mounting UFS file systems in Ubuntu should be straight forward. Follow these simple steps to make sure that your are mounting your FreeNAS disks properly in Ubuntu:

Load the UFS module (or make sure its loaded)

sudo modprobe ufs

Make a directory where to mount the files on

mkdir ~/ufs_mount

To find out which device holds your UFS file system use the command fdisk -l, note which device you intend to mount.

Mount the file system to the directory your previously created

sudo mount -r -t ufs -o ufstype=ufs2 /dev/sdb1 /home/<your_username>/ufs_mount

(where: sdb1 is the UFS partition you want to mount and <your_username> is the your current username where the intended mounting point was created previously.

(Credits to Bruno Pereira user on AskUbuntu.com)

The “fdisk -l” did not seem to output what I was looking for, but I just used Gparted to figure out the partition name in question.

Just wanted to share this tid bit.