xfs-masters
[Top] [All Lists]

[xfs-masters] [Bug 724] New: ENOSPC flushing broken (at least on loopba

To: xfs-master@xxxxxxxxxxx
Subject: [xfs-masters] [Bug 724] New: ENOSPC flushing broken (at least on loopback?)
From: bugzilla-daemon@xxxxxxxxxxx
Date: Mon, 23 Oct 2006 13:03:30 -0700
Reply-to: xfs-masters@xxxxxxxxxxx
Sender: xfs-masters-bounce@xxxxxxxxxxx
http://oss.sgi.com/bugzilla/show_bug.cgi?id=724

           Summary: ENOSPC flushing broken (at least on loopback?)
           Product: Linux XFS
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XFS kernel code
        AssignedTo: xfs-master@xxxxxxxxxxx
        ReportedBy: sandeen-xfs@xxxxxxxxxxx


[root@link-07 tmp]# uname -a
Linux link-07 2.6.18 #5 SMP Fri Oct 20 23:48:17 CDT 2006 x86_64 x86_64 x86_64
GNU/Linux

make a 100M filesystem and mount it loopback:

[root@link-07 tmp]# mkfs.xfs -f -dfile,name=fsfile,size=100m
meta-data=fsfile                 isize=512    agcount=6, agsize=4096 blks
         =                       sectsz=512   attr=0
data     =                       bsize=4096   blocks=24576, imaxpct=25
         =                       sunit=0      swidth=0 blks, unwritten=1
naming   =version 2              bsize=4096
log      =internal log           bsize=4096   blocks=1200, version=1
         =                       sectsz=512   sunit=0 blks
realtime =none                   extsz=65536  blocks=0, rtextents=0
[root@link-07 tmp]# dd if=/dev/zero of=4kfile bs=4k count=1
1+0 records in
1+0 records out
[root@link-07 tmp]# mount -o loop fsfile mnt/

copy a bunch of 4k files to it in a loop, things start failing....

[root@link-07 tmp]# for I in `seq 1 20000`; do cp 4kfile mnt/$I; done
...
cp: cannot create regular file `mnt/5186': No space left on device
cp: cannot create regular file `mnt/5187': No space left on device
cp: cannot create regular file `mnt/5188': No space left on device
cp: writing `mnt/5869': No space left on device
cp: writing `mnt/5870': No space left on device
...
cp: cannot create regular file `mnt/20000': No space left on device
[root@link-07 tmp]# sync
[root@link-07 tmp]# sync
[root@link-07 tmp]# sync

ok but we have 18M left!

[root@link-07 tmp]# df -h /tmp/mnt
Filesystem            Size  Used Avail Use% Mounted on
/tmp/fsfile            92M   75M   18M  82% /tmp/mnt

and inodes free too?

[root@link-07 tmp]# df -i /tmp/mnt/
Filesystem            Inodes   IUsed   IFree IUse% Mounted on
/tmp/fsfile            49152   17024   32128   35% /tmp/mnt

The last file that got written was on iteration 19550...

[root@link-07 tmp]# ls /tmp/mnt | sort -n | tail -n 3
19549
19550
19551

.. but there are only 17021 files written, so some files got written and others
didn't, i.e. it issued ENOSPC, then wrote some more, then ENOSPC, then wrote
some more...

[root@link-07 tmp]# ls /tmp/mnt | wc --lines
17021

This probably isn't behaving as expected...?  I suppose I should test it on
non-loopback too.

-- 
Configure bugmail: http://oss.sgi.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


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