[comp.sys.ibm.pc] Hard Drive Characteristics

rzh@lll-lcc.UUCP (Roger Hanscom) (03/19/89)

Does anybody know where a hard drive's parameters are known (or
determined) ??  You do a low-level format of the drive by entering
firmware on the controller card....does the controller have some
sort of an internal table that gives these parameters.  When you
run FORMAT, how does it know (for example) how many heads are in
the hard drive??  Is any of this controlled by the BIOS??  Why does
DOS refuse to deal with FORMAT C:/N:xx , where xx is less than the
drive's xx-max??  Is the set of hard drives a controller will work
with closed??  (By that I mean will a controller that was built
when there were no 13-head drives with 2000 cylinders be able to
handle a drive with these characteristics??  Or is the limitation
more a function of raw number of sectors on the entire device??)
One frequently encounters comments about the "32 MByte" limit --
what dictates this "limit" (is it as I suspect, the size and # of
bits per entry in the FAT) ??

Enough questions for today!  Thanks for your attention.

===================================================================

Roger         rzh@lll-lcc.llnl.gov
              {ucbvax,ames,....}!lll-lcc!rzh

davis@clocs.cs.unc.edu (Mark Davis) (03/19/89)

In article <2369@lll-lcc.UUCP> rzh@lll-lcc.UUCP (Roger Hanscom) writes:
>Does anybody know where a hard drive's parameters are known (or
>determined) ??  ...

Lots of places.  It depends on ...

DOS seems to get the geomtry, like number of heads from the BIOS, which
may get it from CMOS drive type, or from the disk itself or ROM, but
the size of the disk (even logical disks) from the partition table
recorded on the first physical sector on the disk.

> ...  You do a low-level format of the drive by entering
>firmware on the controller card....does the controller have some
>sort of an internal table that gives these parameters.  ...
Sometimes ...

It depends on the controller.  I have a WD 27X controller that gets the
parameters for drive 0 from ROM  (as controlled by a strap), but for
drive 1, it always asks for the drive geometry.  The Premier 1000 that
I work with came supplied with a WDFMT program that always asks for all
of the geometry although I have other programs that are smart enough to
ask the same hardware.  AT's and compatibles save the drive type number
in the memory on the clock chip: a type 44 drive is an ST 251, a type
35 is an ST 4096, a type 32 is an ST 4053, etc.  After boot, these
computers reference the CMOS and then the ROM to give the BIOS the
proper drive geometry.  Some controllers actually record the drive
information on the drive in proprietary format.  This is also the
popular method amoung third party drivers.

> ...  When you
>run FORMAT, how does it know (for example) how many heads are in
>the hard drive??  ...
It gets the information from DOS (unlike FDISK, which gets the
information from BIOS).

> ...  Is any of this controlled by the BIOS??  ...
It is mostly controlled by bios or indirectly by DOS.  Logical drives
are handled by DOS, and you can control some things through DOS.  For
example, when I put an ST 4096 on a PS/2, I had to talk to the BIOS (int
13, 0Dh reset hard disk) to get FDISK to work properly, but I had to
use DOS (int 21h, func 44h, sub  func 0Dh) to get FORMAT to work properly.

Be careful about saying BIOS.  Some of the BIOS is in ROM, some of it
is on disk with the rest of the operationg system.

> ...  Why does
>DOS refuse to deal with FORMAT C:/N:xx , where xx is less than the
>drive's xx-max??  ...
My PC-DOS manual says that /n and /t are only applicable to floppy's.

> ...  Is the set of hard drives a controller will work
>with closed??  (By that I mean will a controller that was built
>when there were no 13-head drives with 2000 cylinders be able to
>handle a drive with these characteristics??  ...
Controllers of various types seem to be limited to:
	a. 20 Megabytes (very old, may be myth)
	b. 8 heads (somewhat old)
	c. 1024 cylinders (also somewhat old)
I don't know specific controller combinations except the only 20 meg
limit was very old IBM controllers.

Of course, there are always SCSI and ESDI controllers and drives, but
...

In general, reasably modern (after 1982) controllers are not too
limited, but be careful of the above limits.

> ...  Or is the limitation
>more a function of raw number of sectors on the entire device??)
The controller limitations are considerably muddied by the fact that DOS has:
	a. 1024 cylinder limit  (somewhat corrected by third party
	   drivers)
	b. one DOS 32 Meg partion per physical device (until 3.3)
	c. 32 Meg limit from 16 bit sector count
	   (overcome by 4.0 or Compac 3.3+)
All of the above DOS limits can be overcome by appropriate 3rd party
drivers (like Disk manager or Speedstor).  Be careful, though, for
example, a sales person from Ontrack told me that they had not
mastered greater than 1024 cylinders on PS/2's.

Also, there seems to be a 64 Meg file size limit that is not helped by
the third party software.

>One frequently encounters comments about the "32 MByte" limit --
>what dictates this "limit" (is it as I suspect, the size and # of
>bits per entry in the FAT) ??

Until DOS 4.0 (or COMPAC 3.3+ or other drivers), this was a "logical
disk" limit, but you could have 4 logical disks on a physical disk.  I
have a 32, 32, and 16 Meg partitions on a PC/DOS 3.3 80 Meg disk.  32
meg comes from 16 bits (64 K) times .5 meg (512 byte) sectors to give
the number of logical sectors on a disk.  In fact with 16 bit (64K) *
clusters of 2K each could handle 128Meg.  (12 bit fats (4 Meg)  * with
4K clusters handles 16 Meg disks.)

OK.  Now for the summary.  If you have a relatively recent controller,
you can do much of what you ask.  But you may need software.  All
Seagate drives come with Disk Manager 3.5, which will do fine for AT's
and XT's and compatibles.  Other vendors do similar things.  A couple
of mail order vendors ship Speedstor with every Maxtor Drive.  If you
really want a big drive, call somebody with your specifics, and make
sure the drive they ship you will work with your system.

If you want more specifics, either tell us the hardware combination
that you are working from (type of computer, type of controller and DOS
version), and what you want to add.  Or you could buy a good DOS book.

Hope this helps - Mark (davis@cs.unc.edu or uunet!mcnc!davis)

jwright@atanasoff.cs.iastate.edu (Jim Wright) (03/23/89)

In article <7313@thorin.cs.unc.edu> davis@cs.unc.edu (Mark Davis) writes:
| Controllers of various types seem to be limited to:
| 	a. 20 Megabytes (very old, may be myth)
| 	b. 8 heads (somewhat old)
| 	c. 1024 cylinders (also somewhat old)
| I don't know specific controller combinations except the only 20 meg
| limit was very old IBM controllers.
| 
| In general, reasably modern (after 1982) controllers are not too
| limited, but be careful of the above limits.
 
You might be surprised, but this isn't really true.  IBM has been
selling these brain-damaged controllers quite recently.  Someone here
bought two of the last IBM PC XT's (the last model to be dropped other
than the XT-286).  The hard drive controllers in these were limited
to four drive types, 3 of about 20M and 1 about 10M.  These controllers
had to be junked to add an RLL drive -- the original controller would
not work at all in conjunction with a second controller.  So the upgrade
cost not only an RLL drive and RLL controller, but a new MFM controller
as well.

Remember, buy a computer, not three letters.  Who needs a hard drive
controller that locks you into a very few low-end drives?  Or a CGA
card that is incapable of resolving memory conflicts?  Or an EGA card
with only 64K of memory?  Or...

-- 
Jim Wright
jwright@atanasoff.cs.iastate.edu