# suggestion on which filesystem for usb storage



## fluca1978 (Sep 30, 2011)

Hi,
having to share a set of USB disks around with FreeBSD, Windows and Linux, which filesystem do you suggest me to use? fat/dos seems a good choice, but I have also the need for storing large files (10GB each) on such disks, so NTFS could be better, but I'm not comfortable with its performance.
Thanks


----------



## hedgehog (Sep 30, 2011)

This is an interesting question. I'm about to try UDF, but as far as I know, WinXP can't write to it.


----------



## fluca1978 (Sep 30, 2011)

When I was using only linux and windows, ext was a good choice, since I can read it from linux and it goes well under linux that was the system I was using the much. Nowdays I pretty always use freebsd, than linux, and last windows.


----------



## gkontos (Sep 30, 2011)

Your options are limited by 2 factors. 

1) Windows (NTFS + FAT32)

2) Large files (NTFS, UFS2, ZFS, EXT2)

So, your only option would be NTFS


----------



## aragon (Sep 30, 2011)

Ext2.  There are Windows drivers for it that have worked flawlessly for me, and FreeBSD's support is good.

(I've only tried ext2 on Windows XP)


----------



## ikreos (Sep 30, 2011)

I concur with aragon. When I used Linux I had an ext2 driver for Win XP that worked very well.


----------



## Beastie (Oct 1, 2011)

Use FAT32 and split your files into x GB chunks (maximum 4GB-1byte).


----------



## fluca1978 (Oct 2, 2011)

Beastie said:
			
		

> Use FAT32 and split your files into x GB chunks (maximum 4GB-1byte).



It is not that simple, since among the others, large files for me are truecrypt volumes that are about 15 GB each....I cannot split them and rebuild each time I need to access them.
So I guess the solution is NTFS or ext2.


----------



## hedgehog (Oct 2, 2011)

Excuse me for repeating my question: what do you think about the UDF? BSD/Linux/Mac supports read/write access to UDF partitions (with udftools package installed), Windows XP can only read the data and Windows Vista/7 have full access support just out of the box.


----------



## Beastie (Oct 2, 2011)

fluca1978 said:
			
		

> I guess the solution is NTFS or ext2.


NTFS has a read-only native support on FreeBSD. You can have read/write support through the FUSE module. But I personally wouldn't trust any non-Microsoft NTFS driver (for writing that is) as they can have serious bugs causing data loss. Hence why I proposed FAT32 since it's better documented, technically much simpler than NTFS (thus leaving less chances to error) and has been supported natively for many years.

I can't say anything about ext as I've never used it. People here and elsewhere seem to like it though.


----------



## ikreos (Oct 2, 2011)

As another option, if these machines are networked you could just leave the drive plugged into one system and mount it as a NFS.


----------



## wblock@ (Oct 2, 2011)

hedgehog said:
			
		

> Excuse me for repeating my question: what do you think about the UDF? BSD/Linux/Mac supports read/write access to UDF partitions (with udftools package installed), Windows XP can only read the data and Windows Vista/7 have full access support just out of the box.



UDF isn't used very much, giving it a greater chance for undiscovered bugs.  NTFS is closed code.  If I had to pick from the three, I'd pick ext2.

For some applications, doing as ikreos suggests works--just set up another computer as a NAS and use native filesystems on it.  It need not be a fast computer, or even have a display.  FreeNAS is very popular for that, and based on FreeBSD.  Or you can just set up your own with a basic FreeBSD install plus Samba or NFS.  Think of it as a big external drive.  With Ethernet.  And sshd.


----------



## fluca1978 (Oct 3, 2011)

Thank you all for your opinions! Unluckily having a NAS system is too much for what I'm doing, I just like to have an USB storage to plug into my home computer, my office computer, my daddy computer and so on. Of course, if all these are on the same network the work is pretty straightforward: just use any kind of share (samba, nfs, appletalk). But being all the above computers on different networks (and some even not in a network at all), and given that using a cloud storage is not available for all, I still need to use a simple USB mass storage. Any chance there is a zfs driver for windows?


----------



## wblock@ (Oct 3, 2011)

One approach is to install a VM on the Windows machine.  Windows copies files to the VM, the VM copies them to the ZFS drive.  It's a device driver, just a big one.  FreeBSD pass-through USB drivers for VirtualBox are probably not fast enough at present for this to be practical.  Maybe on vmWare or something else, though.
The FreeNAS site has a video of installing FreeNAS on vmWare.


----------



## fluca1978 (Oct 4, 2011)

wblock@ said:
			
		

> One approach is to install a VM on the Windows machine.  Windows copies files to the VM, the VM copies them to the ZFS drive.  It's a device driver, just a big one.  FreeBSD pass-through USB drivers for VirtualBox are probably not fast enough at present for this to be practical.  Maybe on vmWare or something else, though.
> The FreeNAS site has a video of installing FreeNAS on vmWare.



Of course this is a special case of the networking machines, where the server is on the "localhost" itself. Again, this is not  a very portable solution, because I have to install a virtual machine on each client host I want to read/write my usb drive.


----------



## vermaden (Oct 4, 2011)

I have tried to use ext2 as a shared filesystem between Windows and FreeBSD and that idea is quite ok as long as its size is less then several GBs, mine has had more then 100GB and guess how great it was to watch fsck every time the machine was not closed properly (laptop), its way, way too long.

I currently use FAT32 on my 1TB external disks and use split(1) for files larger then 4GB but I admit it's a PITA.

My buddy uses NTFS on his external 1TB drive and from time to time I copy some files to his drive using NTFS-3G @ FUSE and the whole system feels like its on its knees (while CPU usage is very low and system 'load' is very low), its hard to explain that without numbers or benchmarks of course, but it feels like the system was struggling with FUSE to copy that data.

I havent tried UDF yet, I will with sysutils/udfclient from _ports_ and will post the results.

*EDIT:*

Nope, *udfclient* is useless (at least on FreeBSD).


```
# newfs_udf /dev/md0

(...)

Got error executing SCSI command, assuming IDE disc
 UDF: no explicit support for disc devices yet for this operating system.
: No such file or directory
Trying readonly access...
: No such file or directory

(...)

Can't create filingsystem on a non recordable disc
Closing disc
```


----------



## nixbsd (Oct 10, 2011)

Why FreeBSD hasn't supported ExFAT yet?
ExFAT support in FreeBSD 9 would be nice..


----------



## DutchDaemon (Oct 10, 2011)

Donate money to the FreeBSD Foundation and ask them to hire a developer to do it, or code it yourself and donate it.

Because that's how it works.


----------



## vermaden (Oct 10, 2011)

DutchDaemon said:
			
		

> Donate money to the FreeBSD Foundation and ask them to hire a developer to do it, or code it yourself and donate it.
> 
> Because that's how it works.



So You will have to pay TWICE, once for someone to write the code, twice for _'just using it'_ 
http://us.generation-nt.com/exfat-microsoft-license-fat-file-system-flash-news-1951491.html


----------

