[comp.sys.apple2] Optimizing

z@pro-fishunt.cts.com (Jim Ziogas) (05/29/90)

I have two questions-

1) I have heard that a periodic re-formatting of a hard drive will improve its
performance. Well, I use ProSel-16 to optimize hy hard drive often. So, is
anything else besides optimization achieved by re-formatting? Do I really need
to re-format the drive?

2) I have two equal partitions on my 60 meg drive. The first contains all of
the GS/OS boot stuff and gs-specific stuff, while the second contains all
8-bit stuff. Well, about 6 months ago, I ran the ProSel-16 bad block scan and
lockout. I came across 230+ bad blocks on the second partition. I just got the
drive a year ago, but it wasn't until 6 months ago that I ran the bad block
scan. I don't know if these bad blocks were always there or if the appeared
after some use. No more have popped up, but those 230+ are still there. My
question is this- are these blocks anything to worry about? Are bad blocks
normal? It seemed to be a very routine step in ProSel-16, so I don't know what
to think.

Also, could number 2 be related to number 1 at all? The dealer formatted the
drive (which is a GCC Technologies FX/60 drive), so I'm not really sure how he
did it. Both partitions are 32 megs, so the whole hard drive is recognized.
The bad blocks are at the end of the second partion. Could the software be
reading more than what's there?

Thanks for any help.

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
My name is Z, dammit.

Pro-Line: Z@pro-fishunt
Internet: crash!z@pro-fishunt.cts.com
    UUCP: crash!pro-fishunt!z@nosc.mil
 Bitnet:  z%pro-fishunt.cts.com@nosc.mil

I have only one question- if a cow sneezes, does she get milk in HER nose?

Disclaimer: Forgive me, for I know nothing.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

gwyn@smoke.BRL.MIL (Doug Gwyn) (06/01/90)

In article <357.apple.info-apple@pro-fishunt> z@pro-fishunt.cts.com (Jim Ziogas) writes:
>1) I have heard that a periodic re-formatting of a hard drive will improve its
>performance. Well, I use ProSel-16 to optimize hy hard drive often. So, is
>anything else besides optimization achieved by re-formatting? Do I really need
>to re-format the drive?

Assuming you really mean reformatting rather than reinitializing, there
is no reason to do so unless new unusable blocks have turned up since
the last time you formatted it.  Restoring a backup to a freshly
initialized filesystem improves performance simply because the files
are reallocated contiguously; under normal operation (creating and
deleting files) the disk becomes "fragmented", meaning that a single
file may be stored in several noncontiguous sections scattered across
the disk.  Presumably ProSel-16 "optimization" reallocates files
contiguously by moving their pieces around.

>2) I have two equal partitions on my 60 meg drive. The first contains all of
>the GS/OS boot stuff and gs-specific stuff, while the second contains all
>8-bit stuff. Well, about 6 months ago, I ran the ProSel-16 bad block scan and
>lockout. I came across 230+ bad blocks on the second partition. I just got the
>drive a year ago, but it wasn't until 6 months ago that I ran the bad block
>scan. I don't know if these bad blocks were always there or if the appeared
>after some use. No more have popped up, but those 230+ are still there. My
>question is this- are these blocks anything to worry about? Are bad blocks
>normal? It seemed to be a very routine step in ProSel-16, so I don't know what
>to think.

I don't know exactly what ProSel-16 is doing, but indeed large hard
disks usually have some bad blocks (locations that cannot be reliably
used for storage).  Under normal circumstances these are detected
when the low-level formatting is performed, and a "bad block table"
is recorded on the disk, along with corresponding good blocks to be
used as surrogates for the bad ones.  If the GS/OS "verify disk"
operation reports no bad blocks, then all the actually bad blocks are
not used for data storage, in which case they are probably remapped
via the bad block list.  (By the way, most hard disks have a factory-
determined bad block list, to which other bad blocks may be appended
as they are discovered.)  Defects in disk surfaces occasionally spread
to encompass formerly usable blocks, so it is a good idea to scan for
bad blocks from time to time.

>Also, could number 2 be related to number 1 at all?

Only slightly, in that revectored bad blocks require the disk head to
be repositioned onto the spare block track occasionally, which adds
extra seek time over that which would be required if all actual data
blocks were contiguous.  (This is the same phenomenon that makes
fragmentation adversely affect performance.)

>The bad blocks are at the end of the second partion. Could the software be
>reading more than what's there?

Again, run "verify disk" and if it succeeds you're in good shape.

brownfld@ux1.cso.uiuc.edu (06/01/90)

     On a related topic, does CPU speed effect the optimum interleave of
your harddrive?  In other words, if you went from a IIe to a IIgs, would
a new interleave be necessary?  This comes down to the question of "Do
the slots speed up when the CPU does?"
     On a not-so-related topic, does anyone know who to call at Apple for
university purchases?  I'm interested in getting some info on their policy
towards universities in relation to machine grants, discounts, and so on.
     Thanks for any info.  Email would be preferred, but posting is fine.
Thanks again.
							Ken.
Kenneth R. Brownfield				   ken-b@uiuc.edu
University of Illinois, Urbana-Champaign
Junior, Computer Science/Engineering.

toddpw@tybalt.caltech.edu (Todd P. Whitesel) (06/02/90)

brownfld@ux1.cso.uiuc.edu writes:

>     On a related topic, does CPU speed effect the optimum interleave of
>your harddrive?  In other words, if you went from a IIe to a IIgs, would
>a new interleave be necessary?  This comes down to the question of "Do
>the slots speed up when the CPU does?"

The best answer you can get on that one is "it depends."

When using a DMA SCSI card (any kind, Apple's or not) CPU speed should make
virtually no difference because all the time critical stuff is handled by
the card. The driver itself makes more difference because it may or may not be
designed to handle 1:1 interleaves.

When the card is being passive (i.e. DMA not in use or unavailable) then the
CPU is doing the work and the speed makes a _big_ difference.

My preferred solution to the question is 'buy a card that either coprocesses or
has optimized drivers.' Apple's card, with (to my sense of aesthetics at least)
proper drivers, is the most cost-effective solution for the GS since the track
buffer and cache can be pulled from the system memory pool. Coprocessed cards
are better in the //e because they support 1:1 interleave drives out of the box
and Apple's card needs more buffer memory to really perform under everyday use.

Todd Whitesel
toddpw @ tybalt.caltech.edu

mikeu@pro-magic.cts.com (Mike Ungerman) (06/02/90)

In-Reply-To: message from z@pro-fishunt.cts.com

A low level format usually only needs to be done once.  As a part of the low
level format, most formatting software also does a check for bad blocks and
locks them out.

ProSel's bad block scan is a good thing to do anyway.  Right at first to check
to see if the formatting software did it's job properly, and periodically to
make sure that some blocks/sectors that might be "weak" haven't now gone bad.

In the IBM world there's a software package called OPTUNE which I run when I
have formatted an IBM drive.  It writes patterns many times over to each
sector on the drive and if there is a weak sector that would pass on a quick
check, it eventually locks it out.  I usually run this software for about
24-48 hours continuously.  I'm not aware of any software like this for the
Apple.

If you get bad blocks later in the life of the hard drive, and continue to get
new ones periodically, you may want to re-do a low level format again.  I have
done this a couple of times when troubleshooting crashed hard drives.  As long
as the drive is not physically bad (ie., crashed head or other mechanical
failure) it has usually salvaged the drive.

As for optimizing, I optimize using ProSel's Beachcomber every week.  But then
I'm running a bbs system that extensively shuffles around files all day. 
After optimizing you can definately see the access time improve.

The bad blocks you say you have sound like a lot.  If you have plenty of space
available and don't get any new ones, you may just want to leave it alone. 
But if it bugs you, back up your system, re-low level format and run the bad
block scan again and see if they're still there.
______________________________________________________________________________
Mike Ungerman                      |Proline:mikeu@pro-magic
Pro-Magic BBS: 407-366-0156        |uucp:crash!pnet01!pro-magic!mikeu
300/1200/2400/9600 Baud 24hrs      |arpa:crash!pnet01!pro-magic!mikeu@nosc.mil
Apple Tree of Central Florida, Inc |Internet:mikeu@pro-magic.cts.com
Orlando, Florida|Voice:407-366-0060|Compuserve:71326,31 Prodigy: JSNP58A