Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* Slow disk writes to new hard drive
@ 2000-05-10  4:00 Steve Cousins
  2000-05-19  4:00 ` Marco Conti
  2000-05-24  4:00 ` Frank Durda IV
  0 siblings, 2 replies; 4+ messages in thread
From: Steve Cousins @ 2000-05-10  4:00 UTC (permalink / raw)


I have just added an 18 Gig IBM Ultrastar SCSI drive to our Alpha Server
800.  When I access the drive it sometimes takes a very long time.  For
instance, if I

    du -sk

it will just sit there and then finally after a couple of minutes it
will report the disk usage.  This on a directory that has only a couple
hundred megabytes of large files.

Another clue is that when I copy something to the drive it not only
takes a very long time Memory usage goes way up.  The machine has 512
Megabytes of RAM.  Before I start a copy of 150 MB it was using 67 MB.
During the copy, RAM usage shoots up to 320 MB!  Very strange!

The drive is mounted inside using the second Qlogic controller using the
68 Pin connector.

Thanks for your help.

Steve
_____________________________________________________________
 Steve Cousins                 Email: cousins@umit.maine.edu
 Research Associate            Phone: (207) 581-4302
 Ocean Modeling Group
 School of Marine Sciences     208 Libby Hall
 University of Maine           Orono, Maine 04469





^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Slow disk writes to new hard drive
  2000-05-10  4:00 Slow disk writes to new hard drive Steve Cousins
@ 2000-05-19  4:00 ` Marco Conti
  2000-05-24  4:00 ` Frank Durda IV
  1 sibling, 0 replies; 4+ messages in thread
From: Marco Conti @ 2000-05-19  4:00 UTC (permalink / raw)





Firmware release ?

O.S. release ?

					Mac



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Slow disk writes to new hard drive
  2000-05-10  4:00 Slow disk writes to new hard drive Steve Cousins
  2000-05-19  4:00 ` Marco Conti
@ 2000-05-24  4:00 ` Frank Durda IV
  2000-05-25  4:00   ` Steve Cousins
  1 sibling, 1 reply; 4+ messages in thread
From: Frank Durda IV @ 2000-05-24  4:00 UTC (permalink / raw)


Steve Cousins wrote:
> I have just added an 18 Gig IBM Ultrastar SCSI drive to our Alpha Server
> 800.  When I access the drive it sometimes takes a very long time.  For
> instance, if I
> 
>     du -sk
> 
> it will just sit there and then finally after a couple of minutes it
> will report the disk usage.  This on a directory that has only a couple
> hundred megabytes of large files.

Sounds like you are using UFS filesystems and are encountering the
OSF 3.2/4.x/5.0 "we deleted disksort()" bug.  Reported over three years
ago, (C970207-3290) and there is still no real fix yet.  (Putting the
disksort() call back in or, as a better-than-nothing substitute, giving
disk reads priority is apparently too hard.) The quote "solution" that
appeared after two years was to use "smoothsync" which has been modified
to work UFS filesystems now. You will find it in 4.0F PK3 and later.
It helps a little, but the basic bug is still there and will still bite.

Because of the missing disksort() call in their diskstrategy layer,
the result is that the system accumulates many megabytes of stuff to
write and when sync occurs, any read request (like the load of your
du executable) you then issue ends-up at the very back of the list
of block write operations to perform.  Re-writes of the same block
are not sorted-out, nor is sorting done to reduce head movement,
reducing performance further and extended the time it takes all those
blocks to be written-out.

The result is that the system appears to stall until all the pending
disk writes are completed.  On a machine with a couple of GB of RAM
of which UBC has easily grabbed 75% for bufs, writing all that could
take a couple of minutes before it gets to I/O requests after update
ran before you get a response back.  Programs that got any portion of
their address space paged-out or never paged-in can also block until
every single write operation in the bufcache has been written to disk.
If you happen to start "vmstat 1", you will notice that all of sudden
cpu goes 99% idle and then vmstat stops responding for a period of
time.

We used to demonstrate this by running INNs makehistory, the old
pathalias, or even mkpasswd with a several thousand entries, anything
that would generate a lot of disk writes with no disk reads in a
short span of time.  Then on another terminal, wait and then as soon as
update comes by, on the other session do a  ls -al or something similar. 
Now wait. And wait.   Eventually the ls -al will respond.  Even if
the current directory is empty it will take a while.  To repeat,
change directories before doing another ls as the needed blocks are
now cached.

Note that it takes no privs to stall the entire system, an effective
denial-of-service attack method. 

The Compaq/Digital argument #2* against putting the disksort() back in
is that everybody is using disk controllers now that are smart enough
to do all that sorting for efficient disk operation, so there is no
need for the OS to do it.  Not everybody has HSZ-80s as their only
disk device, and even then, re-writes of inode blocks and other
repeatedly written blocks don't get optimized-out if the controller
is having to do the work.

(* Argument #1 was that UFS sucked and that everybody should use ADVFS.
   They have since stopped using this argument as ADVFS has its own
   problems.)

Adding more RAM to your system simply makes the bug even more
noticible since UBC will simply grow bigger and be able to
accumulate more stuff before it is finally forced to start
writing it all to disk.

All the "smoothsync" does is issue a series of mini sync() calls, so
that the I/O queue doesn't go from zero to thousands of dirty blocks
all at once.  Blocks get synced exactly N seconds after a program
issued a write call instead on a scheduled interval.  Obviously,
this really doesn't address the real problem, but if you don't have
a source license you are stuck with what Compaq offers.


Frank Durda IV - only this address works:|"The Knights who say "LETNi"
   <uhclem.jul00%nemesis.lonestar.org>   | demand... A SEGMENT REGISTER!!!"
                                         |"A what?"
This Anti-spam address expires Jul  31st |"LETNi! LETNi! LETNi!" - 1983
Copr. 2000, ask before reprinting.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Slow disk writes to new hard drive
  2000-05-24  4:00 ` Frank Durda IV
@ 2000-05-25  4:00   ` Steve Cousins
  0 siblings, 0 replies; 4+ messages in thread
From: Steve Cousins @ 2000-05-25  4:00 UTC (permalink / raw)


Thanks for the information.  I tried many things and the only thing that
I found that worked all of the time was to make it into an external drive.  I
don't know what the difference is of it being external vs. internal but it
works so I'm not complaining.

Many thanks to Alan from DEC (Compaq) for his many emails that were quite
informative.

Steve

--
_____________________________________________________________
 Steve Cousins                 Email: cousins@umit.maine.edu
 Research Associate            Phone: (207) 581-4302
 Ocean Modeling Group
 School of Marine Sciences     208 Libby Hall
 University of Maine           Orono, Maine 04469






^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2000-05-25  4:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-05-10  4:00 Slow disk writes to new hard drive Steve Cousins
2000-05-19  4:00 ` Marco Conti
2000-05-24  4:00 ` Frank Durda IV
2000-05-25  4:00   ` Steve Cousins

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox