xfs
[Top] [All Lists]

tcsh/linux bug with large files

To: <linux-xfs@xxxxxxxxxxx>
Subject: tcsh/linux bug with large files
From: "Jarrod Smith" <jsmith@xxxxxxxxxxxxxxxxxxxxxxxx>
Date: Thu, 26 Apr 2001 09:43:33 -0500
Organization: Vanderbilt University
Sender: owner-linux-xfs@xxxxxxxxxxx
I ran into a bug with tcsh under linux when using the 0.10 prerelease of
XFS.
I'm using RedHat 7.0 with all the updates installed (as of 3 weeks ago,
using up2date).  Here's my uname -a:

58 moby:/export/moby/backups/tar% uname -a
Linux moby 2.4.2-XFS #1 SMP Tue Mar 27 18:12:26 CST 2001 i686 unknown

The bug is that wildcards in tcsh don't pick up large files.  Here's a
demonstration:

59 moby:/export/moby/backups/tar% ls -lS
total 16022968
-rw-r--r--    1 root     root     7172331520 Apr 25 12:33
idefix_full_25Apr01.tar
-rw-r--r--    1 root     root     4562227200 Apr 25 13:29
moray_full_25Apr01.tar
-rw-r--r--    1 root     root     2206259200 Apr 25 12:48
lemming_full_25Apr01.tar
-rw-r--r--    1 root     root     1641768960 Apr 25 13:17
asterix_full_25Apr01.tar
-rw-r--r--    1 root     root     824893440 Apr 25 13:40
mimine_full_25Apr01.tar
-rw-r--r--    1 root     root        10240 Apr 25 13:29
degas_full_25Apr01.tar
-rw-r--r--    1 root     root        10240 Apr 25 13:17
manta_full_25Apr01.tar
60 moby:/export/moby/backups/tar% ls -lS *
-rw-r--r--    1 root     root     1641768960 Apr 25 13:17
asterix_full_25Apr01.tar
-rw-r--r--    1 root     root     848855040 Apr 25 13:40
mimine_full_25Apr01.tar
-rw-r--r--    1 root     root        10240 Apr 25 13:29
degas_full_25Apr01.tar
-rw-r--r--    1 root     root        10240 Apr 25 13:17
manta_full_25Apr01.tar

You can see that the output from the second invocation of ls (the one that
uses a wildcard) is missing all the files bigger than the 1.64G file
'asterix_full_25Apr01.tar'.  It doesn't appear to be a problem with ls,
because if I do this with bash, all the files are shown.

The tcsh developers looked at this and determined that the cause was that
on RH 7.0 (and it seems to affect 7.1, too), <bits/stat.h> and
<sys/stat.h> don't have __USE_FILE_OFFSET64 or __USE_LARGEFILE64 defined.
When one defines them in the tcsh includes, the problem goes away.  A
patch to tcsh is forthcoming.

But I wonder what else this might be affecting on these systems.  I also
wonder if other distros besides RH suffer from this.  I don't have the
knowledge or skills to find out myself, so I thought I'd ask here.  Is
this a known problem?  What else depends on these defines?

Thanks

Jarrod A. Smith
Research Asst. Professor, Biochemistry
Asst. Director, Center for Structural Biology
Computation and Molecular Graphics
Vanderbilt University

jsmith@xxxxxxxxxxxxxxxxxxxxxxxx





<Prev in Thread] Current Thread [Next in Thread>