Subject: kern/17929: mkdir takes > 40 s to complete on a 60 GB disk
To: None <gnats-bugs@gnats.netbsd.org>
From: Dr. Lex Wennmacher <wennmach@geo.Uni-Koeln.DE>
List: netbsd-bugs
Date: 08/13/2002 17:30:13
>Number: 17929
>Category: kern
>Synopsis: mkdir takes > 40 s to complete on a 60 GB disk
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: kern-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Aug 13 08:58:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Lex Wennmacher
>Release: NetBSD 1.5.3
>Organization:
>Environment:
System: NetBSD cassius.geo.Uni-Koeln.DE 1.5.3 NetBSD 1.5.3 (IGM) #0: Fri Aug 9 14:17:25 MEST 2002 root@cassius.geo.Uni-Koeln.DE:/usr/src/sys/arch/i386/compile/IGM i386
Architecture: i386
Machine: i386
>Description:
Filesystem on /dev/wd2d (entire disk, mounted at /d1) is on the following disk:
Aug 9 14:36:50 cassius /netbsd: wd2 at pciide0 channel 1 drive 1: <Maxtor 4W060 H4>
Aug 9 14:36:50 cassius /netbsd: wd2: drive supports 16-sector pio transfers, lba addressing
Aug 9 14:36:50 cassius /netbsd: wd2: 58644 MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 120103200 sectors
Aug 9 14:36:50 cassius /netbsd: wd2: 32-bit data port
Aug 9 14:36:50 cassius /netbsd: wd2: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5
The filesystem was created with newfs on 1.5.2, but left empty.
Under NetBSD-1.5.3, data were written to the filesystem, using 'tar'.
Once the disk is ca. 80 % full, the times for mkdir (not on top-level,
in a subdirectory) increase drastically:
% df -ki /d1
Filesystem 1K-blocks Used Avail Capacity iused ifree %iused Mounted on
/dev/wd2d 58085459 45809408 9371778 83% 4332 14770514 0% /d1
% pwd
/d1/wennmach
% time mkdir test
0.0u 0.2s 0:40.51 0.6% 0+0k 5847+6io 0pf+0w
Note the > 40 s elapsed time and the enormous 5847+6io value.
Writing data to the disk is fast:
% time cp /netbsd .
0.0u 0.0s 0:00.01 100.0% 0+0k 0+177io 0pf+0w
% ls -s netbsd
1544 netbsd
Creating directories on the top-level is fast, too:
# pwd
/d1
# time mkdir test1
0.0u 0.0s 0:00.01 0.0% 0+0k 3+4io 0pf+0w
# time mkdir test2
0.0u 0.0s 0:00.02 0.0% 0+0k 2+5io 0pf+0w
# time mkdir test3
0.0u 0.0s 0:00.01 0.0% 0+0k 2+5io 0pf+0w
A dumpfs (size: 2.7 MB) of the file system /d1 is available at:
ftp://gutemine.geo.Uni-Koeln.DE/pub/NetBSD/d1-dumpfs
>How-To-Repeat:
see above.
>Fix:
Unknown. Probably a problem with ffs_dirpref().
>Release-Note:
>Audit-Trail:
>Unformatted: