NetSoft Computer Networks
Last Updated
March 10th
1997

Mirror Sites
NetSoft LAN
Download the
Software

Network Card
Drivers

Secure
Features
User's Guide
Help
VeriSign

Search
Distribution
Rights

Listserv
Shareware Links
Order Now
Order the
Software

Help Us
Promote
NetSoft LAN

Dealer
Enquires
Welcome

Home Page
http://www.netsoft.ie/
CHAPTER 13

The DOS SHARE Command



File and Record Locking

The SHARE.EXE program is part of the DOS operating system (versions 3.1 and above), and may be found on your DOS master diskette, or in your DOS directory on your hard disk.

Share must be loaded if you require file and record locking, file sharing, or you are using multi-user, or multi-tasking software. Share loads the code that supports file sharing and locking in these environments. Once you install share, DOS uses the code loaded by share to validate all read and write requests from programs.

It is preferable to load SHARE.EXE before any of the NetSoft LAN network program files.

SHARE command line parameters

If your applications use file sharing or file and record locking, you must load SHARE.EXE. You can do this from your CONFIG.SYS file (using the INSTALL=\DOS\SHARE.EXE command), or from your AUTOEXEC.BAT file.

SHARE.EXE has two parameters associated with file and record locking. They are as follows:

Syntax: SHARE /F:space /L:locks

The /F parameter

/F:Space Allocates file space (in bytes) for the DOS storage area used to record file-sharing information. The default value for /F:Space is 2048 bytes.

The /L parameter

/L:Locks Allocates the number of locks that you desire . The default value for /L:Locks is 35 locks.

The following command increases the file space to 3072 bytes, and the locks to 50:

SHARE /F:3072 /L:50

You should increase these values if you receive the error message: 24h Sharing buffer overflow.


NOTE When deciding how many bytes to allocate for file sharing, note that each open file requires enough space for the length of the full pathname (including drive specification) plus 11 bytes for the filename. The average pathname is 20 bytes in length.
[Chapter 14] [Chapter 12]
[Table of Contents] [Home Page]

Prices and World Wide Ordering Information

Copyright © 1997 NetSoft Computer Networks. All Rights Reserved.
20 Sea Road, Galway, Ireland.
Tel (353)+91-529607.