From: Xavier Date: 2004-03-25T20:59:27+09:00 Subject: Re: File.stat.size errors with file sizes over 2Gigs. On Thu, 25 Mar 2004 07:38:34 +0900, walter wrote: > >> I'm not sure about windows, but on unix[1] the file size usually is > an >> off_t, which is a signed value[2], and traditionally was 32bit (i.e. >> +/- 2Gig). >> >> Following, some unices (namely solaris comes to mind) offered 'large >> file versions' of many of their calls, others (e.g. BSDs) just >> switched to a signed 64 bit value for off_t. I think the latter is >> called for in the windows compat layer (as I assume there is one, >> implementing stat) to really solve your problem. >> >> [1] -- in stat(2)'s struct stat that is >> [2] -- to seek(2) backwards It's not a ruby issue. You need to compile it (and your system as well) with large file support. In my case, I just did # emerge ruby (I Love My Gentoo) e.g. File.stat("/distribs/debian/sid/dvd/debian-20040129-i386-binary-1.iso") => # Hth, Xavier