From: J. Ole Kaven on
HI everybody
I'm converting waveform file formats and am doing some light signal processing in MATLAB. The computations aren't very heavy but the file volume is large. I'm reading files from one external HD and writing the output files to another (with 1TB space). While this may not be the smartest/fastest way of doing it, there is plenty of cheap space available. The external harddrive I'm writing to is formated as VFAT (I'm using linux x86_64).
When I reach 21844 files written within one function call, I get the following error:
"??? Error using ==> save
Unable to write file /media/Elements/coso/MAT/2001/2001.02/CE4.G1N.20010226071452.mat:
No space left on device.

Error in ==> sacwaveform_reformat02 at 135
fclose('all');"

The external harddrive is 3% full when this error occurs.

Does anybody have any suggestions as to what may cause this? Is this a MATLAB problem or does it have to do with the partitioning/fs of the external harddrive?
Thanks in advance for any help!
Ole
From: Rune Allnor on
On 8 Jan, 17:06, "J. Ole Kaven" <oleka...(a)gmail.com> wrote:
> HI everybody
> I'm converting waveform file formats and am doing some light signal processing in MATLAB. The computations aren't very heavy but the file volume is large. I'm reading files from one external HD and writing the output files to another (with 1TB space). While this may not be the smartest/fastest way of doing it, there is plenty of cheap space available. The external harddrive I'm writing to is formated as VFAT (I'm using linux x86_64).
> When I reach 21844 files written within one function call, I get the following error:
> "??? Error using ==> save
> Unable to write file /media/Elements/coso/MAT/2001/2001.02/CE4.G1N.20010226071452.mat:
> No space left on device.
>
> Error in ==> sacwaveform_reformat02 at 135
>             fclose('all');"
>
> The external harddrive is 3% full when this error occurs.
>
> Does anybody have any suggestions as to what may cause this? Is this a MATLAB problem or does it have to do with the partitioning/fs of the external harddrive?

The disk drive is the first suspect to check. I have no idea
how those kinds of things work, but you should first of all
verify that you are writing to the correct disk.

If the data through-put is large, you might want to write
the data in small batches (make sure file sizes are less
than 2GBytes) and also pause the data stream every now and
then. As I understand it, the actual USB I/O between the PC
and the disk is verys slow, so there might be caches in the
system that overflow if the data stream is too fast - which
might explain the observed behaviour.

There is no reason to expect any of this to have anything to
do with matlab. In that case, the error messagewould be expected
to mention 'memory', not 'device'.

Rune

From: Andy on
There may be a limitation on the size of an individual file. Even if the HD has plenty of space, the VFAT format may limit individual files to a certain size. What is the size of your .mat file at the time this error occurs?
From: J. Ole Kaven on
Thanks Rune and Andy for your replies!
It seems to me that the problem is not a MATLAB problem as Rune pointed out, but rather one due to the file system.

Apparently VFAT isn't happy with large number of files (see the following threat http://forum.soft32.com/linux/USB-vfat-space-left-device-ftopict425876.html ). I tried saving to the internal harddrive (EXT3) and had no problems.

Although I haven't tested my NTFS formated external harddrive, I suspect that it may work also.
Thanks for your quick help.
Best,
Ole