t-wynnychenko@northwestern.edu
2007-Sep-22 02:04 UTC
[Samba] VFAT filesystem and large files
Hello I have used samba for many years, and it worked great (thanks!). Anyway, I recently decided to add a USB drive to the server. Currently running 2.6.29.2 linux kernel, debian etch. samba version 3.0.24 The USB drive is VFAT I am able to write small files remotely to the USB drive (a few Kb, 10's of Kb) without a problem. However, whenever I try to write something "larger" (like 1 Mb), the client machine "freezes" for a while (about 1 minute or so), then returns an error saying the file could not be written. However, if I look at the share under which the USB drive is mounted, a file exist, however, it is all "0"'s. If I log onto the server with ssh, i can cp large files from ext3 drive to the VFAT USB drive without problems. I found a post about this somewhere (I can't seem to find it again), which said this was a problem with the VFAT code, not samba. I was wondering, is this is the case? is the is a work-around? Basically, is there a way to write large files via samba to a VFAT USB drive? thanks bye - ted
On 9/22/07, t-wynnychenko@northwestern.edu <t-wynnychenko@northwestern.edu> wrote:> Hello > I have used samba for many years, and it worked great (thanks!). > Anyway, I recently decided to add a USB drive to the server. > Currently running 2.6.29.2 linux kernel, debian etch. > samba version 3.0.24 > The USB drive is VFAT > > I am able to write small files remotely to the USB drive (a few Kb, 10's of Kb) without a problem. > However, whenever I try to write something "larger" (like 1 Mb), the client machine "freezes" for a > while (about 1 minute or so), then returns an error saying the file could not be written. > However, if I look at the share under which the USB drive is mounted, a file exist, however, it is > all "0"'s. > If I log onto the server with ssh, i can cp large files from ext3 drive to the VFAT USB drive > without problems. > > I found a post about this somewhere (I can't seem to find it again), which said this was a problem > with the VFAT code, not samba. > > I was wondering, is this is the case? is the is a work-around? Basically, is there a way to write > large files via samba to a VFAT USB drive?Well, since it works via SSH, it would seem like a weird conclusion the problem lies with the file system. Samba is only a userspace program like cp. That said: vfat means Pain! PAIN!! *PAIN!!!* The design of the FAT files ystem is maybe 20 or 25 years old. It was simple and perfect in the days when the average computer had 20 MB hard drives with 50 files on them. It is not scalable. It is not suitable for large file systems (and nowadays every new computer comes with them). It is not suitable for large files. Besides, it's unreliable and slow. If you're hooking the drive to a Samba server anyway, just reformat it with a real file system, like ext3. -- Frank Van Damme A: Because it destroys the flow of the conversation Q: Why is it bad? A: No, it's bad. Q: Should I top post in replies to mails or on usenet?
t-wynnychenko@northwestern.edu
2007-Sep-22 15:21 UTC
[Samba] VFAT filesystem and large files
Hello I was trying to keep the USB drive as FAT so that I could easily move it a Windows machine if necessary. anyway, i found the reference (i don't know why i was having trouble last night) - ------ Gerald (Jerry) Carter jerry at samba.org Thu Aug 24 16:00:45 GMT 2006 Mattias Rönnblom wrote:> When copying large files from my Windows XP machine > to this share, smbd seem to "reserve" (by using ftruncate()) > the space needed on the USB disk before actually doing > any copying. This ftruncate() operation takes quite > a while when the file is large. It may even cause the > client to time out....> Would you consider this a problem in Samba or in > the VFAT filesystem driver?IIRC our stance is that it's a problem with the VFAT driver. This issue has some up before. ------ so, that is more than a year old - is there more information about this at this point. i tried specifying "strict allocate = no" - but that did not change anything. thanks bye - ted
t-wynnychenko@northwestern.edu
2007-Sep-22 23:21 UTC
[Samba] VFAT filesystem and large files
==============Original message text==============On Sat, 22 Sep 2007 11:49:06 pm +0100 "Daniel O'Connor" wrote: You could put ext2/3 on it and use this in Windows -> http://www.fs-driver.org/ I've never tested it though. ===========End of original message text========== At one point a year or so ago, i mounted a ext2 filesystem on a win2K machine. It did work. However, the reason I asked about VFAT is I wanted to have a USB drive that could be removed from the samba server and used on (pretty much) "any" windows/linux computer (without installing/modify the recipient computer). VFAT gives me that (unfortunately). thanks bye - ted
t-wynnychenko@northwestern.edu wrote:> > I found a post about this somewhere (I can't seem to find it again), which said this was a problem > with the VFAT code, not samba. > > I was wondering, is this is the case? is the is a work-around? Basically, is there a way to write > large files via samba to a VFAT USB drive? > > thanks >Hmm, I'm sorry, I don't have any great insights into this problem... I was wondering, however, if you might have some error message in your dmesg log of the server when the error occurs? that might be helpful. btw, usually, and people say large files, they are talking about 2G, or at least several hundred MB. I think if this is supported at all, you should be getting more than your 1 KB :)