home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 36 Tips / 36-Tips.zip / osdihpft.txt < prev    next >
Text File  |  1996-10-25  |  9KB  |  196 lines

  1. OSDIHPFT - HPFS AND FAT FILE SYSTEMS
  2. 01/29/96
  3.  
  4. =======================================================================
  5.              HPFS and FAT File Systems--All OS/2 Releases
  6. =======================================================================
  7.  
  8. Please Read Entire Document for Full Explanation of Procedures
  9. --------------------------------------------------------------
  10.  
  11. DESCRIPTION
  12.  
  13. This document explains the differences between a high performance file 
  14. system (HPFS) and a file allocation table (FAT) file system and how 
  15. they interface with each other under OS/2.
  16.  
  17. RESOLUTION
  18.  
  19. The following is an excerpt from A Technical Guide to OS/2 2.0, by 
  20. Martin McElroy, IBM United Kingdom.
  21.  
  22. OS/2 offers superior file system support, leading to increased 
  23. performance. The OS/2 architecture allows other file systems to be 
  24. installed in a modular fashion (Installable File System or IFS). It is 
  25. more flexible in design to accommodate future enhancements; for example,
  26. now OS/2 includes CD-ROM support via an IFS.
  27.  
  28. OS/2 also provides support for very large disks, a consideration
  29. particularly relevant to server environments. OS/2 supports hard disks 
  30. up to 2 GB in size. In Windows 3.1 the limit is only 1 GB. In addition,
  31. OS/2 provides file I/O services not only to OS/2 applications but to 
  32. DOS and Windows applications running in VDMs. Therefore, DOS and 
  33. Windows applications can take advantage of advanced functions, without 
  34. having to be modified, since the DOS emulation of MVDM provides a 
  35. compatible interface to the file system for DOS applications.
  36.  
  37. Both major OS/2 file systems have been improved under OS/2, allowing 
  38. better performance not only for applications, but also in paging 
  39. performed by systems when using virtual memory.
  40.  
  41.  
  42. High Performance File System (HPFS)
  43. -----------------------------------
  44. The following is an excerpt from A Technical Guide to OS/2 2.0, by 
  45. Martin McElroy, IBM United Kingdom.
  46.  
  47. HPFS was first introduced to OS/2 Version 1.2, and is an example of the 
  48. kind of advanced function that has not yet been implemented in less 
  49. sophisticated systems like DOS. It was introduced as an alternative to 
  50. the File Allocation Table (FAT) system which came from DOS. HPFS is 
  51. particularly good for managing large disks, partitions, and large 
  52. files. It provides fast and consistent performance, outperforming 
  53. DOS-based FAT systems in nearly all cases. OS/2 implements an enhanced 
  54. FAT system that uses similar caching features as HPFS, which also give 
  55. high performance in many circumstances--see below.
  56.  
  57. HPFS is particularly good in disk utilization compared to FAT. It uses 
  58. a highly contiguous file allocation system, which results in good 
  59. performance (relative to FAT) in accessing files or data in a cluttered 
  60. or full partition. It implements a B-Tree directory structure and 
  61. search algorithm, as opposed to sequential under FAT. HPFS also allows 
  62. for multi-threaded I/O, caching of directory pointers in memory for 
  63. quicker access of last directories used, and read-ahead and lazy write 
  64. (lazy write buffers up write requests from applications and commits 
  65. them to disk after a given time or during disk inactivity.) These
  66. advanced features allow for substantial performance increases and
  67. greater tuning. HPFS can provide write error recovery on the fly with 
  68. 'hotfix' facilities.
  69.  
  70. Since it is FAT-compatible at the API level, applications running under 
  71. OS/2 can use either system, and do not have to be written specifically 
  72. for one or the other. It presents a consistent interface to other 
  73. components of OS/2 like MVDM, to allow DOS and Windows to use HPFS 
  74. volumes as if they were FAT. HPFS supports the use of long file names, 
  75. for greater usability, instead of using LJS1290.TXT you can have a file 
  76. name, LETTER TO JOHN SMITH SEPTEMBER 90. Accordingly, applications need 
  77. to be coded with this in mind. DOS and Windows applications use the 8.3 
  78. naming system on HPFS without any difficulty.
  79.  
  80. HPFS has been enhanced in OS/2 to add performance-related features such 
  81. as command chaining (providing a list of contiguous sector requests 
  82. required to fulfill an I/O request) and scatter/gather facilities that 
  83. are supported in Small Computer Systems Interface (SCSI) adapters to 
  84. gather physically discontiguous pages in a data buffer, and perform I/O 
  85. in a single operation.
  86.  
  87.  
  88. High Performance File System Changes
  89. ------------------------------------
  90. The following is an excerpt from Chapter 6 of the IBM OS/2 Version 2.0 
  91. Technical Redbooks, Volume 1: Control Program (Document Number 
  92. GG24-3730-00), published by the IBM Corporation.
  93.  
  94. The following changes have been made to the High Performance File System
  95. (HPFS) driver under OS/2. At initialization time, the level of support 
  96. provided by the device driver is determined using the new device command 
  97. 1DH-GetDeviceSupport.
  98.  
  99. The HPFS driver passes physical addresses for data pointers, in the 
  100. appropriate request format, to the device driver. The HPFS driver now 
  101. supports command chaining, calling the volume manager with a list of 
  102. all contiguous sector requests required to fulfill an I/O request. This 
  103. function is supported for all DASD types.
  104.  
  105. The HPFS driver supports scatter/gather by passing physical pointers to 
  106. each page in the data buffer (physically discontiguous) as part of the 
  107. I/O request. This allows I/O controllers such as the IBM SCSI adapters 
  108. which support the scatter/gather capability to perform the I/O in a 
  109. single operation.
  110.  
  111. * The HPFS driver supports disk caching in the IFS driver, rather than
  112.   in the device driver.
  113.  
  114. * The HPFS driver is able to recognize devices which have outboard
  115.   caches (non-system memory), and incorporates them into the total
  116.   caching scheme.
  117.  
  118. * The HPFS file system under OS/2 supports a maximum file size of 2 GB.
  119.   The maximum size for an HPFS volume is 512 GB.
  120.  
  121.  
  122. Enhanced FAT (Super FAT) File System
  123. ------------------------------------
  124. The following is an excerpt from A Technical Guide to OS/2 2.0,by 
  125. Martin McElroy, IBM United Kingdom.
  126.  
  127. OS/2 includes an enhanced version of the FAT file system which is 
  128. completely compatible with the FAT system under DOS. This gives greater 
  129. performance but full compatibility with existing FAT systems. It adds 
  130. features such as lazy write and improves caching to FAT. This means 
  131. that DOS applications running with a FAT file system under OS/2 will be 
  132. substantially faster for disk-based operations than under DOS. All the 
  133. benefits can be obtained without having to reformat your hard disk. The 
  134. OS/2 enhanced FAT driver works with existing DOS FAT volumes.
  135.  
  136.  
  137. FAT File System Changes
  138. -----------------------
  139. The following is an excerpt from Chapter 6 of the IBM OS/2 Version 2.0 
  140. Technical Redbooks, Volume 1: Control Program (Document Number 
  141. GG24-3730-00), published by IBM Corporation.
  142.  
  143. Changes have been made to the FAT file system driver under OS/2, to 
  144. provide improved performance and enhanced support for disk hardware 
  145. devices.
  146.  
  147. * The FAT driver supports command chaining.
  148.  
  149. * The FAT driver attempts to call the volume manager with a list of all
  150.   contiguous sector requests required to fulfill an I/O request, thus
  151.   allowing multiple page-in and page-out requests in a single logical
  152.   operation.
  153.  
  154.  * The FAT driver provides faster allocation of free space on the
  155.    logical drive, using a bit map to track free clusters on the disk.
  156.  
  157. Disk caching is now supported within the FAT driver, and has been 
  158. removed from the device driver. A cache buffer is provided to support 
  159. disk caching with the following features:
  160.  
  161.  * Lazy writing.
  162.  
  163.  * Lazy reading on writes. Meaning, the ability to write to the cache
  164.    and flush the cache to disk, then, to read the updated information
  165.    from the cache rather than requiring a physical disk read operation.
  166.  
  167.  * Asynchronous read-ahead through a multi-purpose asynchronous read
  168.    thread.
  169.  
  170.  * Large cache size (theoretical maximum of 64 MB, although practical
  171.    limitations will necessitate a smaller cache).
  172.  
  173.  * The ability to dynamically enable and disable the cache in response
  174.    to a user command.
  175.  
  176.  * Bad sectors are automatically bypassed on reads.
  177.  
  178. There are several advantages in performing caching in the FAT driver 
  179. rather than the device driver; more operating-system kernel services 
  180. are available at this level, and intelligent read-ahead operations are 
  181. more easily performed. Lazy writing is easily implemented at the file 
  182. system level than at the device driver level.
  183.  
  184. The FAT file system under OS/2 supports a maximum file size of 2 GB. 
  185. The maximum supported size for a FAT volume is also 2 GB.
  186.  
  187. ______________________________________________________________________
  188. IBM disclaims all warranties, whether express or implied, including 
  189. without limitation, warranties of fitness and merchantability with 
  190. respect to the information in this document. By furnishing this 
  191. document, IBM grants no licenses to any related patents or copyrights.  
  192. Copyright (c) 1994, 1996 IBM Corporation. Any trademarks and product 
  193. or brand names referenced in this document are the property of their 
  194. respective owners. Consult your product manuals for complete trademark 
  195. information. 
  196.