home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 8 Other / 08-Other.zip / svd118.zip / SVDISK.DOC < prev    next >
Text File  |  1996-01-18  |  46KB  |  1,195 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.                                                       Super Virtual Disk
  9.  
  10.                                Swappable/Lockable/Removable Virtual Disk
  11.                                                                 for OS/2
  12.  
  13.                                                                   SVDISK
  14.                                                             Version 1.18
  15.                                                                 01/18/96
  16.  
  17.  
  18.  
  19.                                   TABLE OF CONTENTS
  20.        _________________________________________________________________
  21.  
  22.             1.0. INTRODUCTION TO Super Virtual Disk ..................3
  23.                  1.1. What is Super Virtual Disk? ....................3
  24.                  1.2. Features of SVDisk .............................3
  25.             2.0. SYSTEM REQUIREMENTS .................................4
  26.             3.0. COPYRIGHT NOTICE ....................................4
  27.             4.0. WARRANTY ............................................4
  28.             5.0. COST OF Super Virtual Disk ..........................4
  29.             6.0. CONTENTS OF THIS PACKAGE ............................5
  30.             7.0. INSTALLATION ........................................6
  31.                  7.1. Quick start ....................................6
  32.                       7.1.1 Manual installation ......................6
  33.                       7.1.2 Drive letter arrangement with CD-ROM
  34.                       drive ..........................................7
  35.                  7.2. SVDisk.sys parameters ..........................7
  36.             8.0. CONTROLLING Super Virtual Disk ......................9
  37.                  8.1. Super Virtual Disk Control help screen .........9
  38.                  8.2. Options for SVDC ...............................10
  39.                  8.3. PM Super Virtual Disk Control ..................12
  40.                  8.4. Using XDF VFloppy for XDF image files ..........12
  41.                  8.5. Formatting SVDisk as HPFS ......................13
  42.                       8.4.1 HPFS Diskettes ...........................15
  43.                       8.4.2 HPFS386 on IBM LAN Server Advanced
  44.                       Edition ........................................17
  45.                  8.6. Diskette boot bypass using VFloppy .............17
  46.             9.0. PROGRAMMING INFORMATION .............................18
  47.             10.0. EXAMPLES ...........................................19
  48.                  10.1. Example 1: Locking non-swappable memory and
  49.                  querying status .....................................19
  50.                  10.2. Example 2: Ejecting virtual media .............19
  51.                  10.3. Example 3: Reconfiguring VFloppy device .......20
  52.                  10.4. Example 4: Inserting virtual media ............20
  53.                  10.5. Example 5: Multiple operations ................20
  54.             11.0. ERROR MESSAGES .....................................21
  55.                  11.1. List of error messages ........................21
  56.             12.0. BACKGROUND INFORMATION .............................21
  57.             13.0. ACKNOWLEDGMENTS ....................................21
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.  
  74.                                                                        2
  75.  
  76.  
  77.  
  78.        1.0. INTRODUCTION TO Super Virtual Disk
  79.        _________________________________________________________________
  80.  
  81.        1.1. What is Super Virtual Disk?
  82.  
  83.        Super Virtual Disk (SVDisk) is a 32-bit OS/2 device driver that
  84.        emulates either a removable Virtual Disk (VDisk) or a removable
  85.        Virtual Floppy (VFloppy) drive.  By using OS/2's virtual memory
  86.        management facility, SVDisk allows the entire contents of the
  87.        disk to be swapped out via the paging mechanism.  If the SVDisk
  88.        is frequently accessed, OS/2 will keep the most recently used
  89.        memory pages in RAM, and SVDisk will essentially behave like a
  90.        RAM Disk.
  91.  
  92.        1.2. Features of SVDisk
  93.  
  94.        -  Emulates multiple VDisk devices up to 16MB each even on a 4MB
  95.           system.  Cluster size is maintained at 512 bytes by varying
  96.           the size of the File Allocation Table (FAT) to reduce file
  97.           slack.
  98.        -  Emulates multiple VFloppy devices, ranging from 360KB to
  99.           2.88MB.  Virtual media support ranges from 160KB to 1.2MB for
  100.           5.25" VFloppy device, and from 720K to 2.88MB for 3.5" VFloppy
  101.           device.  If the VFloppy is a 3.5" device, automatic media
  102.           sensing is supported.
  103.        -  eXtended Density Format (XDF) support for OS/2 Warp V3 XDF
  104.           diskette image files.  This includes 1.52MB, 1.84MB and 3.68MB
  105.           XDF diskettes.  Utility is included to transfer XDF image file
  106.           to and from XDF VFloppy.
  107.        -  Removable media support.  This allows SVDisk to release all
  108.           memory used by the device back to the system.
  109.        -  Dynamic device reconfiguration is supported for the VFloppy
  110.           device.  A VFloppy device can be reconfigured (without
  111.           rebooting) to any other VFloppy drive or XDF drive.
  112.        -  HPFS formatting program for SVDisk.  Mounting and unmounting
  113.           of HPFS onto SVDisks are supported.  HPFS diskette support
  114.           (diskette imaging program such as Disk eXPress is required.)
  115.        -  Special boot sector on VFloppy device to allow bypassing of
  116.           floppy boot if the image of the VFloppy is transferred to a
  117.           real diskette using DISKCOPY.
  118.        -  Formatting and sector/track read/write are supported.
  119.        -  SVDisk allows locking of swappable memory into non-swappable
  120.           memory.  Once memory is locked, SVDisk will behave like a RAM
  121.           drive without paging delay.  The size of the lock can be
  122.           specified by the user, since locking the entire disk as non-
  123.           swappable can have serious performance impact to OS/2's
  124.           virtual memory operation.
  125.        -  A 32-bit command line utility and a 32-bit PM application are
  126.           included to provide complete control of all the capabilities
  127.           of SVDisk.
  128.  
  129.  
  130.  
  131.  
  132.  
  133.                                                                        3
  134.  
  135.  
  136.  
  137.        2.0. SYSTEM REQUIREMENTS
  138.        _________________________________________________________________
  139.  
  140.        Machines equipped with an Intel 386SX compatible or higher
  141.        processor.  OS/2 2.1 or higher, with minimum 4MB of memory.
  142.  
  143.  
  144.        3.0. COPYRIGHT NOTICE
  145.        _________________________________________________________________
  146.  
  147.        SVDisk (Super Virtual Disk)  Version 1.18  01/18/95
  148.        (C) Copyright 1994-96 by Albert J. Shan.  All Rights Reserved.
  149.  
  150.        No part of this program may be disassembled, modified or altered
  151.        by any means.
  152.  
  153.  
  154.        4.0. WARRANTY
  155.        _________________________________________________________________
  156.  
  157.        I, Albert J. Shan, make no warranties, expressed or implied,
  158.        including, but not limited to, merchantability or fitness for any
  159.        particular purpose.  In no event shall Albert J. Shan be liable
  160.        for indirect or consequential damages arising from the use of the
  161.        software program.
  162.  
  163.        You are free to redistribute this shareware package in its
  164.        entirety.  No part of this package may be included as part of a
  165.        commercial package.  If you have any questions about commercial
  166.        distribution of Super Virtual Disk, I can be contacted via:
  167.  
  168.        CompuServe, ID 70730,401
  169.        or Internet, 70730.401@compuserve.com
  170.  
  171.  
  172.        5.0. COST OF Super Virtual Disk
  173.        _________________________________________________________________
  174.  
  175.        The user is granted a 30 days trial period, after which he or she
  176.        is required to register or discontinue the use of the product.
  177.        The cost of a single machine license is $30 U.S.  Please refer to
  178.        the file ORDER.FRM for details.
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.                                                                        4
  193.  
  194.  
  195.  
  196.        6.0. CONTENTS OF THIS PACKAGE
  197.        _________________________________________________________________
  198.  
  199.        The following files are included in this package:
  200.  
  201.            INSTALL.CMD     - Installation command file
  202.            SVDISK.SYS      - Super Virtual Disk device driver
  203.            SVDC.EXE        - Super Virtual Disk Control
  204.            PMSVDC.EXE      - PM version of SVDC
  205.            HFORMAT.EXE     - SVDisk HPFS formatting utility
  206.            HMOUNT.EXE      - HPFS mounting/unmounting utility for SVDisk
  207.            REREGSVD.EXE    - SVDisk re-registration program
  208.            XDFSVD.EXE      - XDF Copier for SVDisk
  209.            KWIKTOOL.MSG    - English error message file, common to all
  210.                              EXE files.
  211.            SVDISK.MSG      - English message file for SVDISK.SYS and
  212.                              SVDC.EXE
  213.            PMSVDC.MSG      - English message file for PMSVDC.EXE
  214.            HFORMAT.MSG     - English message file for HFORMAT.EXE
  215.            HMOUNT.MSG      - English message file for HMOUNT.EXE
  216.            XDFSVD.MSG      - English message file for XDFSVD.EXE
  217.            KWIKTOOL.GER    - German error message file, common to all
  218.                              EXE files.
  219.            SVDISK.GER      - German message file for SVDISK.SYS and
  220.                              SVDC.EXE
  221.            PMSVDC.GER      - German message file for PMSVDC.EXE
  222.            HFORMAT.GER     - German message file for HFORMAT.EXE
  223.            HMOUNT.GER      - German message file for HMOUNT.EXE
  224.            XDFSVD.GER      - German message file for XDFSVD.EXE
  225.            SVDISK.DOC      - This documentation
  226.            SVDISK.HST      - History of SVDisk
  227.            LICENSE.DOC     - License agreement for registered users
  228.            WARRANTY.DOC    - Warranty information for registered users
  229.            ORDER.FRM       - Order form
  230.            README          - Last minute information
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.                                                                        5
  252.  
  253.  
  254.  
  255.        7.0. INSTALLATION
  256.        _________________________________________________________________
  257.  
  258.        7.1. Quick start
  259.  
  260.        For automatic installation, please run INSTALL.CMD from an OS/2
  261.        command prompt.
  262.  
  263.  
  264.        7.1.1 Manual installation
  265.  
  266.        To manually install SVDisk, make a subdirectory called SVDISK,
  267.        and copy all the SVDisk files into \SVDISK.  Then edit your OS/2
  268.        CONFIG.SYS to include a line:
  269.  
  270.          DEVICE=D:\SVDISK\SVDISK.SYS
  271.  
  272.        Where D: is the drive where you created the SVDISK subdirectory.
  273.  
  274.        Add SVDISK to the path and dpath by appending D:\SVDISK at the
  275.        end of the PATH= and DPATH= statement in CONFIG.SYS.
  276.  
  277.        English language message files are used by default.  To use the
  278.        German language message files, rename all *.MSG files to *.ENG,
  279.        and rename all *.GER files to *.MSG.
  280.  
  281.        When you load SVDisk without any parameter as in the above
  282.        example, it will create a 1.44MB VFloppy device after you reboot
  283.        the system.
  284.  
  285.        When SVDisk is loaded, it does not put a media in the virtual
  286.        drive.  You have to manually insert it with SVDC or PMSVDC.  To
  287.        insert a virtual media after the system is booted, you type:
  288.  
  289.          SVDC X: /i:720
  290.  
  291.        Where X: is the drive letter of the SVDisk after boot.
  292.  
  293.        This will insert a 720KB virtual media into the drive.  If you
  294.        specify /i without any parameter, SVDC will insert a media with
  295.        the maximum capacity as defined by the SVDisk.sys device in
  296.        CONFIG.SYS.  To make media insertion automatic, simply edit
  297.        STARTUP.CMD on your OS/2 boot drive and add the SVDC line to it.
  298.  
  299.        Alternatively, you can insert the virtual media by using the
  300.        CALL= statement in CONFIG.SYS:
  301.  
  302.          CALL=D:\SVDISK\SVDC.EXE X: /i:720
  303.  
  304.        If you want to install a 8MB VDisk type device, edit your
  305.        CONFIG.SYS by adding a line:
  306.  
  307.          DEVICE=D:\SVDISK\SVDISK 8192 512
  308.  
  309.  
  310.                                                                        6
  311.  
  312.  
  313.  
  314.  
  315.        This will create a 8MB VDisk device with 512 root directory
  316.        entries after you reboot the system.
  317.  
  318.  
  319.        7.1.2 Drive letter arrangement with CD-ROM drive
  320.  
  321.        Starting with OS/2 2.1, a DASD (Direct Access Storage Device)
  322.        Manager Driver (DMD) can be loaded as a device driver.  This is
  323.        the case for the CD-ROM device driver (OS2CDROM.DMD.)  This
  324.        arrangement allows another disk device driver to be positioned
  325.        before or after the CD-ROM drive.  To load a SVDisk with drive
  326.        letter preceeding the CD-ROM drive, locate the DEVICE= statement
  327.        containing OS2CDROM.DMD, and insert the SVDISK.SYS DEVICE=
  328.        statement before it.  To load a SVDisk after the CD-ROM, add the
  329.        SVDISK.SYS DEVICE= statement after OS2CDROM.DMD.
  330.  
  331.  
  332.        7.2. SVDisk.sys parameters
  333.  
  334.        SVDisk.sys can be loaded with no parameter to up to two
  335.        parameters.  To load SVDisk as a VFloppy device, you must specify
  336.        the size of the VFloppy device in KB.  For example:
  337.  
  338.          REM *** Load a 1.44MB VFloppy device ***
  339.          DEVICE=\SVDISK\SVDISK.SYS 1440
  340.  
  341.          REM *** Load a 2.88MB VFloppy device ***
  342.          DEVICE=\SVDISK\SVDISK.SYS 2880
  343.  
  344.          REM *** Load a 360KB VFloppy device ***
  345.          DEVICE=\SVDISK\SVDISK.SYS 360
  346.  
  347.          REM *** Load a 1.84MB XDF VFloppy device ***
  348.          DEVICE=\SVDISK\SVDISK.SYS 1840
  349.  
  350.        The possible values for VFloppy device are: 360, 720, 1200, 1440,
  351.        and 2880.  Use 1520, 1840 and 3680 for XDF VFloppy.  Since SVDisk
  352.        defaults to a 1.44MB VFloppy device, the 1440 parameter can be
  353.        omitted.
  354.  
  355.        To load SVDisk as a VDisk device, you can specify up to two
  356.        parameters:
  357.  
  358.          DEVICE=\SVDISK\SVDISK.SYS ssss eeee
  359.  
  360.        Where ssss is the size of the VDisk device, and eeee is the root
  361.        directory entries for the device.  eeee is optional, and if you
  362.        do not specify it, SVDisk will default to 64 root directory
  363.        entries.
  364.  
  365.        The possible values for ssss are from 16 to 16384 (16KB to 16MB.)
  366.        The VDisk device will always round up the size into 16KB
  367.  
  368.  
  369.                                                                        7
  370.  
  371.  
  372.  
  373.        boundary.  If you specify a 250KB VDisk device, it will be loaded
  374.        as 256KB.
  375.  
  376.        The possible values for eeee are from 16 to 1024.  This value is
  377.        also rounded up in multiple of 16.
  378.  
  379.        If you load a VDisk device near the size of 4MB, it will attempt
  380.        to resolve the File Allocation Table (FAT) size as either 12-bit
  381.        or 16-bit.  In the case of conflict due to a large root directory
  382.        entries specification, SVDisk will slightly reduce the VDisk size
  383.        in favor of a 12-bit FAT for lower disk sector overhead in the
  384.        system area on the virtual media.
  385.  
  386.        SVDisk distinguishes a VDisk device from a VFloppy device solely
  387.        by the ssss (size) parameter.  If ssss is one of the possible
  388.        values for a VFloppy device, it will load itself as a VFloppy
  389.        device, and the second parameter is ignored.
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.  
  404.  
  405.  
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.                                                                        8
  429.  
  430.  
  431.  
  432.        8.0. CONTROLLING Super Virtual Disk
  433.        _________________________________________________________________
  434.  
  435.        Two programs are provided to control the SVDisks: SVDC.EXE and
  436.        PMSVDC.EXE.  PMSVDC.EXE is the Presentation Manager version of
  437.        SVDC.EXE.
  438.  
  439.  
  440.        8.1. Super Virtual Disk Control help screen
  441.  
  442.        Type SVDC at the OS/2 command prompt to receive this help screen:
  443.  
  444.        Super Virtual Disk Control (32-bit) Version 1.18  SHAREWARE VERSION
  445.        (C) Copyright 1994-96 Albert J. Shan.  All Rights Reserved.
  446.  
  447.        For use with Super Virtual Disk driver (SVDISK.SYS)
  448.  
  449.        Usage: SVDC [options] Drive:
  450.          [options]  /c        Fake a disk change.
  451.                     /e[f]     Eject media [f = forced eject].
  452.                     /i[:size] Insert media (if size is not specified, default
  453.                               to max. drive capacity.)  Size can only be
  454.                               specified for the VFloppy device.  Valid sizes
  455.                               are: 160, 180, 320, 360, 1.2, 720, 1.44, 2.88,
  456.                               1.52, 1.84, 3.68.
  457.                     /l:size   Lock SVDisk in non-swappable memory.  Size
  458.                               is anywhere from 0 (KB) to the max. media size.
  459.                     /q        Query SVDisk status
  460.                     /r[:size] Reconfigure VFloppy device capacity (if size is
  461.                               not specified, default to max. drive capacity.)
  462.                               Valid sizes are: 360, 1.2, 720, 1.44, 2.88,
  463.                               1.52, 1.84, 3.68.
  464.                     /u        Unlock non-swappable memory used by the SVDisk.
  465.                     Drive:    Drive letter of the Super Virtual Disk.
  466.  
  467.        NOTE: The drive must not contain any media before reconfiguring with /r.
  468.  
  469.        *** Note: parameters within [] are optional.
  470.  
  471.        If you specify the drive letter of a SVDisk and without
  472.        specifying any other options, SVDC will report the current status
  473.        of the SVDisk drive as if the Query Status switch (/q) is
  474.        specified.  For example:
  475.  
  476.           [C:\SVDISK]svdc j:
  477.  
  478.                    SVDISK.SYS Version:  1.18
  479.                   Default device size:  2.88MB
  480.                   Current device size:  2.88MB
  481.                    Current media size:  1.44MB
  482.           Non-swappable memory locked:   128KB
  483.  
  484.  
  485.  
  486.  
  487.                                                                        9
  488.  
  489.  
  490.  
  491.        8.2. Options for SVDC
  492.  
  493.        /c        Fake a disk change.  This command will cause the SVDisk
  494.                  specified to appear as if it has been changed (ejected
  495.                  then reinserted.)  This is accomplished by changing the
  496.                  Volume Serial on the SVDisk.  If the program in
  497.                  question is looking for a change in Volume Label or a
  498.                  DOS program is looking for a change line bit in
  499.                  hardware, /c will not work.
  500.  
  501.        /e[f]     Eject media.  This will eject the media in the SVDisk,
  502.                  thereby releasing all memory, including locked memory
  503.                  (see /l and /u below) back to the system.  If a program
  504.                  is currently running off the SVDisk, you must specify
  505.                  /ef to force the disk to eject.  Further access to the
  506.                  SVDisk drive will cause a drive not ready error.
  507.  
  508.        /i[:size] Insert media.  If size is not specified, it will insert
  509.                  a media with exactly the same size as the SVDisk
  510.                  device.  For example, if the VFloppy is 2.88MB,
  511.                  specifying /i alone will insert a 2.88MB media into the
  512.                  SVDisk drive.  The optional size parameter is only
  513.                  applicable for a VFloppy device.  This allows different
  514.                  size media to be inserted into the VFloppy drive.  If
  515.                  the VFloppy is a 5.25" 360KB device, the possible
  516.                  values are: 160, 180, 320, and 360.  If the VFloppy is
  517.                  a 3.5" 1.44MB device, the possible values are: 720 and
  518.                  1.44.  Depending on the type of VFloppy device, the
  519.                  possible values are: 160, 180, 320, 360, 1.2, 720, 1.44
  520.                  and 2.88.  For XDF media, the possible values are:
  521.                  1.52, 1.84, and 3.68.  When the VFloppy device is an
  522.                  XDF device, only XDF media are supported.
  523.  
  524.        /l:size   Lock virtual disk in non-swappable memory.  This will
  525.                  cause the virtual memory allocated by SVDisk to be
  526.                  locked in real memory pages, and they will be precluded
  527.                  from swapping out by the system.  The starting location
  528.                  of the lock is fixed at the beginning of the disk, at
  529.                  logical sector 0.  The size parameter is anywhere from
  530.                  0 to the maximum size of the media in the SVDisk.  It
  531.                  will be rounded up in 4KB in size as OS/2 can only lock
  532.                  memory in 4KB page boundary.  A size of 0 is equivalent
  533.                  to unlocking all the memory (see /u switch below.)  If
  534.                  a lock already exists on the SVDisk, it will be
  535.                  released, and the new lock size will be installed.  If
  536.                  there is not enough real memory for the lock, /l will
  537.                  fail, and at the same time, releasing any memory
  538.                  previously locked.
  539.  
  540.                  The OS/2 kernel will swap out other processes in order
  541.                  to make room for the lock.  This may take a while as
  542.                  pages are being swapped out.  The system will not be
  543.  
  544.  
  545.  
  546.                                                                       10
  547.  
  548.  
  549.  
  550.                  responsive when the kernel is into heavy paging
  551.                  activities.
  552.  
  553.                  WARNING: Locking memory as non-swappable has the same
  554.                  effect as removing system memory on the hardware level.
  555.                  If you have an 8MB system, locking a few mega bytes of
  556.                  memory will make your system appear as if it has 4MB
  557.                  total system memory or less.  If the lock succeeds in
  558.                  locking large amount of memory, and the remaining non-
  559.                  swappable memory is extremely low, the OS/2 virtual
  560.                  memory paging mechanism will thrash.  Although the
  561.                  system is not crashed, it will be paging in and out so
  562.                  frequently that the system can no longer respond to the
  563.                  user's input.  You will need to press Ctrl-Alt-Del to
  564.                  recover in this case.  In general, it is recommended
  565.                  not to lock more that one quarter of total system
  566.                  memory as non-swappable for all SVDisk devices
  567.                  combined.  PMSVDC.EXE will limit the maximum of the
  568.                  lock to half of total system memory or the maximum disk
  569.                  size, whichever is less.  On the other hand, SVDC.EXE
  570.                  is designed to be flexible, so any lock size is
  571.                  possible.
  572.  
  573.        /q        Query SVDisk Status.  The following is a typical SVDisk
  574.                  report:
  575.  
  576.                           SVDISK.SYS Version:  1.18
  577.                          Default device size:  2.88MB
  578.                          Current device size:  2.88MB
  579.                           Current media size:  1.44MB
  580.                  Non-swappable memory locked:   128KB
  581.  
  582.        /r[:size] Reconfigure VFloppy device capacity.  This switch is
  583.                  only applicable to the VFloppy device.  It allows
  584.                  dynamic device reconfiguration while the system is
  585.                  running.  Before you can reconfigure the VFloppy
  586.                  device, the media must be ejected first via the /e
  587.                  switch.  Specifying /r alone will reconfigure the
  588.                  VFloppy device to the initial capacity as loaded by the
  589.                  device driver.  The VFloppy device can be reconfigured
  590.                  to any other valid type of VFloppy device.  For XDF
  591.                  device, the possible values are: 1.52, 1.84, and 3.68.
  592.  
  593.        /u        Unlock non-swappable memory used by the SVDisk.  This
  594.                  is the same as specifying /l:0.  Locked memory is
  595.                  released as being swappable.
  596.  
  597.  
  598.  
  599.  
  600.  
  601.  
  602.  
  603.  
  604.  
  605.                                                                       11
  606.  
  607.  
  608.  
  609.        8.3. PM Super Virtual Disk Control
  610.  
  611.        The Presentation Manager version of Super Virtual Disk Control
  612.        (PMSVDC.EXE) provides identical functions as SVDC.EXE with one
  613.        exception.  The lock function will limit the maximum available
  614.        memory for the lock as half of total system memory or maximum
  615.        media size, whichever is less.  This means if you have 16MB of
  616.        memory, and your VDisk device is 16MB, the largest memory size
  617.        you can lock is 8MB.  Many system boards reserve up to 384K of
  618.        memory for shadow ROM and other purposes.  This effectively
  619.        reduces your total system memory.  Instead of 16MB (16384KB), you
  620.        get 16000KB total system memory under OS/2 and the maximum size
  621.        for the lock in this case is 8000KB.  The lock function also
  622.        warns you if you are locking more than one quarter of the total
  623.        system memory.  If you have multiple SVDisk devices, PMSVDC will
  624.        add up all memory locked by all SVDisk devices, subtract the
  625.        existing lock size on the current device, then add the new
  626.        requested size to see if it exceeds one quarter total system
  627.        memory limit.  In general, the total memory locked by all SVDisk
  628.        devices should be less than one quarter of the total system
  629.        memory to prevent OS/2 pager from thrashing.
  630.  
  631.  
  632.        8.4. Using XDF VFloppy for XDF image files
  633.  
  634.        In order to use an XDF (eXtended Density Format) image file on a
  635.        VFloppy device, the VFloppy device must be reconfigured to one of
  636.        the XDF type VFloppies.  The available capacities for XDF
  637.        diskettes are as follows:
  638.  
  639.            5.25" 1.2MB media:   1520KB XDF (1.52MB)
  640.            3.5" 1.44MB media:   1840KB XDF (1.84MB)
  641.            3.5" 2.88MB media:   3680KB XDF (3.68MB)
  642.  
  643.        For example, if your VFloppy has drive letter J:, you can
  644.        reconfigure it to 1.84MB XDF VFloppy as follows:
  645.  
  646.            SVDC J: /e
  647.            SVDC J: /r:1.84 /i
  648.  
  649.        The included program, XDFSVD.EXE (XDF Copier for SVDisk) is
  650.        designed for transferring XDF diskette images to and from an XDF
  651.        VFloppy.  XDFCOPY.EXE included in OS/2 Warp Version 3 is designed
  652.        to transfer XDF images to and from a real diskette drive (A: or
  653.        B:.)  XDFCOPY.EXE cannot be used on an XDF VFloppy.  And
  654.        likewise, XDFSVD.EXE cannot be used on a real diskette drive.
  655.  
  656.        To transfer an XDF Image file to an XDF VFloppy:
  657.  
  658.            XDFSVD DISK5.DSK J:
  659.  
  660.  
  661.  
  662.  
  663.  
  664.                                                                       12
  665.  
  666.  
  667.  
  668.        To transfer an XDF VFloppy to an XDF Image file:
  669.  
  670.            XDFSVD J: DISK5.DSK
  671.  
  672.        Here is a typical screen when you run XDFSVD:
  673.  
  674.        XDF Image file -> XDF SVDisk
  675.  
  676.        Press Enter to continue, Ctrl-C to stop...
  677.  
  678.         75% written to SVDisk J:
  679.  
  680.        The "Press Enter to contiune..." prompt can be bypassed by
  681.        specifying the /s switch (type XDFSVD by itself to see the help
  682.        screen.)
  683.  
  684.        NOTE: When a VFloppy is used in XDF mode, it does not try to
  685.              emulate the actual mechanism used by a real XDF diskette.
  686.              It does not have the special boot sector and file system
  687.              information of a real XDF diskette.  The following
  688.              scenario is not a valid way to create a real XDF diskette:
  689.  
  690.                  - Reconfigure a VFloppy to an XDF VFloppy
  691.                  - Create files on the XDF VFloppy
  692.                  - Use XDFSVD to create an XDF image file
  693.                  - Use XDFCOPY to transfer the XDF image file to a real
  694.                    diskette
  695.  
  696.              The proper way for editing the contents of an XDF diskette
  697.              via XDF VFloppy is as follows:
  698.  
  699.                  - Reconfigure a VFloppy to an XDF VFloppy
  700.                  - Use XDFCOPY to create an XDF image file from a real
  701.                    XDF diskette
  702.                  - Use XDFSVD to transfer the XDF image file to the XDF
  703.                    VFloppy
  704.                  - Edit the contents of the XDF VFloppy
  705.                  - Use XDFSVD to create the new XDF image file
  706.                  - Use XDFCOPY to create the new XDF diskette
  707.  
  708.  
  709.        8.5. Formatting SVDisk as HPFS
  710.  
  711.        NOTE: Using the High-Performance File System (HPFS) on SVDisk
  712.              requires special considerations and understanding of OS/2
  713.              and the HPFS file system.  THE ONLY SUPPORTED HPFS.IFS
  714.              DRIVERS ARE THE ONES IN OS/2 2.1 AND OS/2 WARP VERSION 3.
  715.              HPFS.IFS in OS/2 2.11 (ServicePak XR06200) is not
  716.              supported due to a severe bug in the HPFS driver.  If you
  717.              are using OS/2 2.11, you must copy the HPFS.IFS driver
  718.              from the original OS/2 2.1 installation diskettes
  719.              (diskette 1).  FAILURE TO USE THE CORRECT HPFS DRIVER WILL
  720.              CAUSE SYSTEM CRASH WHEN DATA IS COPIED TO A HPFS SVDISK.
  721.  
  722.  
  723.                                                                       13
  724.  
  725.  
  726.  
  727.  
  728.        Two utilities are included for handling HPFS on SVDisk:
  729.        HFORMAT.EXE and HMOUNT.EXE.  HFORMAT formats any SVDisk into HPFS
  730.        file system format.  It does it by temporary reconfiguring SVDisk
  731.        to appear as a non-removable disk, and then calls the OS/2
  732.        FORMAT.COM program to perform the HPFS formatting.  HFORMAT will
  733.        verify the drive to make sure it is a SVDisk before proceeding
  734.        with FORMAT.COM.  Once a SVDisk is formatted as HPFS, HFORMAT
  735.        will reconfigure SVDisk back to a removable disk device.  HFORMAT
  736.        requires the SVDisk media to be at least 1MB in size.  Since HPFS
  737.        requires approximately 200KB for the file system structures, it
  738.        is not pratical to have HPFS on a low capacity media.
  739.  
  740.        Before you can format a SVDisk as HPFS, the HPFS.IFS driver must
  741.        be installed.  If you are not using HPFS, you can install the
  742.        HPFS driver using Selective Install in the System Setup folder.
  743.        HPFS is usually installed as the first line in CONFIG.SYS.  A
  744.        typical HPFS.IFS line in CONFIG.SYS looks like the following:
  745.  
  746.            IFS=C:\OS2\HPFS.IFS /CACHE:128 /CRECL:4 /AUTOCHECK:C
  747.  
  748.        This specifies the HPFS Installable File System (IFS) with 128KB
  749.        cache; a caching threshold of 4KB, and automatic CHKDSK of C:
  750.        drive upon boot.  For performance reason, HPFS is not recommended
  751.        for system with 4MB of system memory.
  752.  
  753.        Once HPFS is installed, you can format a SVDisk into HPFS.  To do
  754.        so, type:
  755.  
  756.            HFORMAT D:
  757.  
  758.        where D: is the drive letter of the SVDisk drive.
  759.  
  760.        You can specify a volume label with HFORMAT:
  761.  
  762.            HFORMAT D: /v:SUPERDISK
  763.  
  764.        This will format the SVDisk D: as HPFS and assign SUPERDISK as
  765.        the volume label.
  766.  
  767.        If you want to format a HPFS SVDisk back to FAT, the easiest way
  768.        is to eject the media (/e), and insert (/i) a new one.  If you
  769.        wish to use FORMAT.COM to do the formatting, you must first
  770.        unmount HPFS from the SVDisk.
  771.  
  772.        Since HPFS is not designed for removable media, special media
  773.        handling is necessary to prevent HPFS from crashing.  HPFS is
  774.        mounted to the OS/2 File System whenever OS/2 detects a HPFS
  775.        drive during boot or after a successful HPFS disk format with
  776.        FORMAT.COM.  However, OS/2 does not provide a way for unmounting
  777.        a HPFS drive.  If you eject a HPFS media from a removable drive,
  778.        the HPFS driver will crash when it attempts to flush the disk
  779.        cache later, or when you shutdown the operating system.  Since
  780.  
  781.  
  782.                                                                       14
  783.  
  784.  
  785.  
  786.        the majority of the diskette drives have a mechanical eject
  787.        button; the media can be ejected without the control of the file
  788.        system driver.  This is the primary reason why HPFS is not
  789.        supported for the diskette drive.
  790.  
  791.        SVDC.EXE and PMSVDC.EXE have built-in HPFS unmounting capability.
  792.        When you eject a HPFS SVDisk, it will unmount the HPFS file
  793.        system before the disk is ejected, thereby preventing HPFS from
  794.        crashing.  If your HPFS SVDisk drive is in use by another process
  795.        (such as open files, or a process running off the HPFS SVDisk),
  796.        SVDC and PMSVDC eject function will disallow the removal of the
  797.        media.  This is done to prevent HPFS from crashing since there is
  798.        no way to flush or unmount HPFS if a process is running off of
  799.        that disk.
  800.  
  801.        If you wish to manually unmount HPFS off a SVDisk, you can do so
  802.        with HMOUNT.EXE.  HMOUNT has two modes of operation: mounting and
  803.        unmounting HPFS.  To unmount a HPFS SVDisk, do the following:
  804.  
  805.            HMOUNT D: /u
  806.  
  807.        Where D: is the drive letter of the HPFS SVDisk drive.
  808.  
  809.        Once HPFS is unmounted from the SVDisk, you can no longer access
  810.        the drive's contents.  At this point, OS/2 believes the current
  811.        file system on the SVDisk drive is FAT, and will not display the
  812.        contents of the drive correctly.  You can mount the drive back
  813.        with HMOUNT by typing:
  814.  
  815.            HMOUNT D:
  816.  
  817.        You can force HPFS to flush the cache by unmounting and then
  818.        remounting the disk.
  819.  
  820.        NOTE: It is the user's responsibility to make sure nothing is
  821.              written to an unmounted HPFS media before it is mounted as
  822.              HPFS again.  HPFS may crash if the file system structures
  823.              are severely damaged.
  824.  
  825.              Since HPFS provides superlative caching performace, the
  826.              use of non-swappable memory locking (/l in SVDC) is
  827.              unnecessary and should be avoided to conserve system
  828.              memory.
  829.  
  830.  
  831.        8.4.1 HPFS Diskettes
  832.  
  833.        Since a VFloppy can be formatted as HPFS, you can transfer, for
  834.        example, a 1.44MB HPFS VFloppy onto a real diskette.  The
  835.        supported HPFS diskette sizes are: 1.2MB, 1.44MB, and 2.88MB.
  836.        HFORMAT cannot format a real diskette as HPFS because the
  837.        IBM1FLPY.ADD/IBM2FLPY.ADD driver prevents the change of one
  838.  
  839.  
  840.  
  841.                                                                       15
  842.  
  843.  
  844.  
  845.        critical diskette parameter which is needed by HFORMAT.EXE and
  846.        OS/2's FORMAT.COM.
  847.  
  848.        DISKCOPY cannot be used to transfer HPFS VFloppy to a real
  849.        diskette because it expects both the source and target file
  850.        systems to be FAT.  You will need to use a Diskette Imaging
  851.        program such as Disk eXPress (DXP.)  Disk eXPress Version 2.33 or
  852.        later is required.  Shareware version of Disk eXPress can be
  853.        found on most major OS/2 BBSes.  To image a HPFS VFloppy, you
  854.        will need to save the entire contents of the disk.  With Disk
  855.        eXPress, you can do this by:
  856.  
  857.            DXP32 D: HPFS1440 /a
  858.  
  859.        Where D: is the 1.44MB HPFS SVDisk drive (VFloppy device), and
  860.        HPFS1440 is the self-extracting diskette image file.  The /a
  861.        switch (read the entire diskette) is not really required, as Disk
  862.        eXPress detects the HPFS VFloppy as a non-DOS media, and will
  863.        automatically read the entire diskette.
  864.  
  865.        Once the diskette image is created, you can restore it onto a
  866.        real diskette.  You can do this by typing:
  867.  
  868.            HPFS1440 A:  (if the diskette is formatted)
  869.  
  870.        OR
  871.  
  872.            DXP32 HPFS1440.EXE A: /f  (if the diskette is unformatted)
  873.  
  874.        In order to use a HPFS diskette, you must first mount the media
  875.        for use.  This is accomplished with HMOUNT.
  876.  
  877.            HMOUNT A:
  878.  
  879.        Normally, OS/2 will mount a HPFS disk if it detects it to be HPFS
  880.        when you first access it.  This means if a HPFS diskette is
  881.        inserted into the drive and accessed without HMOUNT, OS/2 will
  882.        recognize it, and access the contents correctly.  However, this
  883.        is only true when you are dealing with 1.2MB and 1.44MB drives.
  884.        With the 2.88MB drives, it is imperative that you use HMOUNT to
  885.        mount a 1.44MB HPFS diskette.  HMOUNT will temporary reconfigure
  886.        your floppy hardware to appear as a 1.44MB diskette drive.  This
  887.        is necessary to allow HPFS to function correctly for the 1.44MB
  888.        media in the 2.88MB diskette drive.  When you unmount a 1.44MB
  889.        HPFS diskette from a 2.88MB drive, the drive parameter is not
  890.        restored, and OS/2 believes you still have a 1.44MB diskette
  891.        drive.  In order to restore diskette hardware parameters to
  892.        2.88MB, a 2.88MB HPFS diskette must be prepared in advance using
  893.        a 2.88MB HPFS SVDisk.  To restore the 2.88MB hardware status, you
  894.        must mount then unmount a 2.88MB HPFS diskette.  To do so, insert
  895.        the 2.88MB HPFS diskette, perform a HMOUNT to mount the diskette
  896.        and then perform a HMOUNT /u to unmount HPFS from the drive.
  897.  
  898.  
  899.  
  900.                                                                       16
  901.  
  902.  
  903.  
  904.        CAUTION:  Make sure a HPFS diskette is unmounted with HMOUNT /u
  905.                  before ejecting it from the diskette drive.  Failure to
  906.                  do so will cause HPFS to crash when it attempts to
  907.                  flush the cache or during a system shutdown.  If you
  908.                  accidentially ejected a HPFS diskette, you must
  909.                  reinsert it into the drive immediately, and execute
  910.                  HMOUNT /u to unmount HPFS.  Failure to do so before
  911.                  HPFS has a chance to update the media will lead to
  912.                  system crash.
  913.  
  914.  
  915.        8.4.2 HPFS386 on IBM LAN Server Advanced Edition
  916.  
  917.        SVDisk does not support HPFS386 on IBM LAN Server Advanced
  918.        Edition.  This particular version of HPFS requires Scatter/Gather
  919.        support in the device driver level.  SVDisk currently does not
  920.        support Scatter/Gather.  Formatting SVDisk as HPFS under HPFS386
  921.        will lead to system crash.
  922.  
  923.  
  924.        8.6. Diskette boot bypass using VFloppy
  925.  
  926.        SVDisk contains a special boot sector under FAT which can be used
  927.        to bypass a real floppy boot.  You can do this by transferring
  928.        the image of a VFloppy device with DISKCOPY to a real diskette.
  929.        If you leave the diskette in drive A:, upon system reboot, you
  930.        will get the following message on the screen:
  931.  
  932.        Transferring system boot from diskette to hard drive...
  933.  
  934.        And the boot sequence will be transferred to the hard drive.  If
  935.        you have OS/2 Boot Manager installed, you will see the Boot
  936.        Manager at this point.
  937.  
  938.  
  939.  
  940.  
  941.  
  942.  
  943.  
  944.  
  945.  
  946.  
  947.  
  948.  
  949.  
  950.  
  951.  
  952.  
  953.  
  954.  
  955.  
  956.  
  957.  
  958.  
  959.                                                                       17
  960.  
  961.  
  962.  
  963.        9.0. PROGRAMMING INFORMATION
  964.        _________________________________________________________________
  965.  
  966.        When SVDisk is used as a VFloppy device, it tries to emulate a
  967.        real floppy drive as much as possible.  However, this emulation
  968.        is not 100%.  If you write a program against the behavior of a
  969.        real floppy drive, it will almost certainly work with SVDisk.
  970.        The converse is not always true.  This is because SVDisk makes
  971.        certain assumptions to simplify many of the internal operations
  972.        which are true for a virtual device.  The common pitfall is to
  973.        assume reading and writing to a floppy device are always slower
  974.        than other computational threads.  If a multithreaded OS/2
  975.        application is designed with the above assumption, it will almost
  976.        certainly fail because the disk read/write operations are much
  977.        faster than the program has expected.
  978.  
  979.        SVDisk supports the following IOCtl Category 8 logical disk
  980.        commands (in hex):
  981.  
  982.        00   Lock drive
  983.        01   Unlock drive
  984.        02   Redetermine media
  985.        04   Begin format
  986.        20   Block removable
  987.        21   Query logical map
  988.        43   Set device parameters (the changing the BPB of the device is
  989.             not supported)
  990.        44   Read track
  991.        64   Write track
  992.        65   Verify track
  993.        45   Format and verify track
  994.        60   Query media sense
  995.        63   Query device parameters
  996.  
  997.        Please refer to OS/2 2.x SDK (Software Development Kit) on
  998.        programming the IOCtl interface.
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.  
  1007.  
  1008.  
  1009.  
  1010.  
  1011.  
  1012.  
  1013.  
  1014.  
  1015.  
  1016.  
  1017.  
  1018.                                                                       18
  1019.  
  1020.  
  1021.  
  1022.        10.0. EXAMPLES
  1023.        _________________________________________________________________
  1024.  
  1025.        The following examples assume you have the following lines
  1026.        installed in CONFIG.SYS:
  1027.  
  1028.        DEVICE=D:\SVDISK\SVDISK.SYS 8192 512
  1029.        DEVICE=D:\SVDISK\SVDISK.SYS 2880
  1030.        CALL=D:\SVDISK\SVDC.EXE H: /i
  1031.        CALL=D:\SVDISK\SVDC.EXE I: /i:1.44
  1032.  
  1033.        The first SVDisk is an 8MB VDisk device with 512 root directory
  1034.        entries, with drive letter 'H' assigned to it by OS/2.  The
  1035.        second SVDisk is a 2.88MB VFloppy device, initially loaded with a
  1036.        1.44MB virtual media, and is assigned as drive 'I'.
  1037.  
  1038.  
  1039.        10.1. Example 1: Locking non-swappable memory and querying status
  1040.  
  1041.        You would like to lock the first 600K of SVDisk H: in non-
  1042.        swappable memory, and query the status at the same time:
  1043.  
  1044.          SVDC H: /l:600 /q
  1045.  
  1046.        And you get the following report:
  1047.  
  1048.                 SVDISK.SYS Version:  1.18
  1049.                Default device size:  8192KB
  1050.                Current device size:  8192KB
  1051.                 Current media size:  8192KB
  1052.        Non-swappable memory locked:   600KB
  1053.  
  1054.  
  1055.        10.2. Example 2: Ejecting virtual media
  1056.  
  1057.        You can eject the virtual media in SVDisk so that all memory used
  1058.        (including locked memory) is returned to the operating system:
  1059.  
  1060.          SVDC I: /e
  1061.  
  1062.        If the SVDisk is in used by a process (ie: a running program,
  1063.        open files, etc.), you'll receive an error message:
  1064.  
  1065.          KWT0131: Drive I: is not ready or in use by another process.
  1066.  
  1067.        You can force eject the virtual media by specifying /ef:
  1068.  
  1069.          SVDC I: /ef
  1070.  
  1071.  
  1072.  
  1073.  
  1074.  
  1075.  
  1076.  
  1077.                                                                       19
  1078.  
  1079.  
  1080.  
  1081.        10.3. Example 3: Reconfiguring VFloppy device
  1082.  
  1083.        You want to change the VFloppy drive I: into a 1.2MB 5.25"
  1084.        device:
  1085.  
  1086.          SVDC I: /r:1.2
  1087.  
  1088.  
  1089.        10.4. Example 4: Inserting virtual media
  1090.  
  1091.        You want to insert a 360KB virtual media into drive I:, which has
  1092.        just been reconfigured to a 1.2MB VFloppy drive:
  1093.  
  1094.          SVDC I: /i:360
  1095.  
  1096.  
  1097.        10.5. Example 5: Multiple operations
  1098.  
  1099.        You can combine example 3 and 4 plus locking and querying all in
  1100.        one step:
  1101.  
  1102.          SVDC I: /r:1.2 /i:360 /l:180 /q
  1103.  
  1104.        And you'll receive this status report:
  1105.  
  1106.                 SVDISK.SYS Version:  1.18
  1107.                Default device size:  2.88MB
  1108.                Current device size:   1.2MB
  1109.                 Current media size:   360KB
  1110.        Non-swappable memory locked:   180KB
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.  
  1129.  
  1130.  
  1131.  
  1132.  
  1133.  
  1134.  
  1135.  
  1136.                                                                       20
  1137.  
  1138.  
  1139.  
  1140.        11.0. ERROR MESSAGES
  1141.        _________________________________________________________________
  1142.  
  1143.        11.1. List of error messages
  1144.  
  1145.        The following is a list of major error messages returned by
  1146.        SVDC.EXE.  The error return code is also displayed as part of the
  1147.        prefix in the error message:
  1148.  
  1149.        SVDnnnn: Error message text
  1150.  
  1151.        Where nnnn is the error return code.
  1152.  
  1153.        SVD0016: Drive X: is not a Super Virtual Disk.
  1154.        SVD0017: SVDISK.SYS has a higher revision level.
  1155.        SVD0018: Invalid media size.
  1156.        SVD0019: Cannot eject because the file system on drive is HPFS and
  1157.                 is currently in use by another process.
  1158.        SVD0020: Unable to eject Super Virtual Disk due to memory deallocation
  1159.                 error.
  1160.        SVD0021: Unable to insert Super Virtual Disk due to memory allocation
  1161.                 error.
  1162.        SVD0022: No media in drive.
  1163.        SVD0023: You cannot insert two media in the drive.
  1164.        SVD0024: Incorrect size specified.
  1165.        SVD0025: System failed to lock memory as non-swappable.
  1166.        SVD0026: System failed to unlock non-swappable memory.
  1167.        SVD0027: No non-swappable memory locked by the Super Virtual Disk.
  1168.        SVD0028: Cannot reconfigure Super Virtual Disk with a media in the Drive.
  1169.        SVD0029: Only VFloppy type device can be reconfigured.
  1170.  
  1171.  
  1172.        12.0. BACKGROUND INFORMATION
  1173.        _________________________________________________________________
  1174.  
  1175.        The Super Virtual Disk device driver is written in 386 assembly
  1176.        language.  The source files consist of over 2500 lines of
  1177.        assembly code, and over 3600 lines of C code.  32-bit
  1178.        instructions are used extensively in the device driver, with
  1179.        critical memory transfer loop in double word (32-bit) alignment.
  1180.        All the utilities programs are 32-bit executables.  The device
  1181.        driver interface is 16-bit, as limited by the OS/2 kernel.  Media
  1182.        is made removable to allow unrestricted virtual memory
  1183.        allocation.  It is not possible to allocate 16MB virtual memory
  1184.        during device driver initialization.
  1185.  
  1186.  
  1187.        13.0. ACKNOWLEDGMENTS
  1188.        _________________________________________________________________
  1189.  
  1190.        German message files translation was performed by Peter Freitag.
  1191.  
  1192.  
  1193.  
  1194.  
  1195.                                                                       21