From: alan@nabeth.enet.dec.com (Alan Rollow - Alan's Home for Wayward Tumbleweeds.)
Subject: Re: DEC 3.0Gb drive ok w/ Ultrix {4.2a, 4.3}? 
Reply-To: alan@nabeth.enet.dec.com (Alan Rollow - Alan's Home for Wayward Tumbleweeds.)
Organization: Digital Equipment Corporation
Date: Thu, 8 Oct 1992 00:02:40 GMT


In article <1992Oct7.214413.10862@olaf.wellesley.edu>, lhawkins@olaf.wellesley.edu (Lee Hawkins) writes:
>
>
>
>Hi all:
>I have responsabilty for buying hard drives & such for several
>DECstation 5000/200's that do lots of image processing, and I have a
>two questions about the maximum size partition Ultrix can support:
>
>	1) What is the largest possible partition under Ultrix 4.2a? 4.3?

The largest useful size is 4,194,303 512 byte blocks.  If you want
to put a file system on it, the useful size gets a little smaller,
because the file system insists on full blocks.  Even then there
might be some wasted at the end.

>	2) If the answer to 1) is less than the maximum theoretical
>		partition size, why did DEC not make the maximum
>		partition size equal to the theoretical maximum
>		partition size when they fixed the >1.2 Gb bug in
>		4.2?

Because the 2 GB limit on file system size isn't related in any
way to the SCSI-1 problem fixed in V4.2.

The offset within a file is limited to an signed 32 bit integer.
See the lseek(2) manual page and sizeof(off_t).  The negitive
parts of the offset are used to indicate an error.  While it
is sufficient to only use -1 as the error, how many times have
you seen:

	if( system_call(args...) < 0 )
		/* error */

The file system contains a few limits that restrict it to 
8 GB, but the 2 GB limit comes from the programs like newfs(8)
and fsck(8) that use read/write/lseek to move around within
a FILE and scribble or read data structures that end up
looking like a file system.  Other programs that would have
trouble with larger than 2 GB file systems are dump(8),
icheck(8) and ncheck(8).  There are probably others, but
these are ones that come to mind.

>
>The whole point of this is that I am about to buy another couple of
>large hard drives that I want to set up as one big partition.  I'm
>probably going to buy DEC 3.0 Gb drives when they come out, but need
>to know if I need to break this space up into two partitions until Ultrix
>can support 3.0 Gb partitions.

I doubt that ULTRIX will ever support larger than 2 GB partition.  Any
work-around of the limitation almost certain to break thousands of
existing programs, or at best not allow them to use file systems that
are larger than 2 GB.  Most customers would not appreciate being told
"We broke the world, but all you need to do is recompile to fix it".

OSF on the Alpha systems shouldn't have the problem because off_t is
likely to be 64 bits.  That will have it's own set of problems.
For OSF on MIPS I'm not sure.  It seems unlikely because of the
backward compatibility problem.

>If Ultrix can't do this at the moment by
>itself, but can with SCSI/CAM, that's great, but I'd really prefer not
>to use SCSI/CAM if I don't have to.  Then again, if SCSI/CAM is the only
>way to get Ultrix to like a 3.0 Gb partition, I'd love some hints on
>exactly how to do it.

You might be able to do it with SCSI CAM, but probably not with
file systems.  SCSI CAM give you the ability to send I/O commands
directly through the subsystem.  For a sufficiently specialized
application you could probably arrange to send LBN based commands
rather than byte offset based lseek(2) system calls.  The only way
it would work on file system like things is if somebody lies about
the file offset to the appropriate layer.

>
>
>Thanks in advance,
>--Lee
>
>________________________________________________________________________________
>R. Lee Hawkins					 lhawkins@annie.wellesley.edu
>Department of Astronomy				 lhawkins@lucy.wellesley.edu
>Whitin Observatory
>Wellesley College                                   Ph. 617-283-2708
>Wellesley, MA 02181                                 FAX 617-283-3642
>________________________________________________________________________________
>
--
Alan Rollow				alan@nabeth.cxo.dec.com

Newsgroups: comp.unix.ultrix