Update Config.sys Section


UpdateCfgSys

[update-config-section]
Buffers=legal-dos-buffer-value
DelKey=key
DevAddDev=driver-name,configkeyword(,flag)(,param-string)
DevDelete=device-driver-name
DevRename=current-dev-name,new-dev-name
Files=legal-dos-files-value
PrefixPath=ldid(,ldid)
RemKey=key
Stacks=dos-stacks-values

Provides commands to add, delete, or rename commands in the CONFIG.SYS file.  The section name, update-config-section-name, must appear in the UpdateConfigSys item in an Install section of the INF file.

Not all item types shown in the syntax above are needed or required.  An Update Config.sys section may contain as many DevRename, DevDelete, DevAddDev, DelKey, and RemKey items as needed, but the Buffers, Files, and Stacks items may only be used once in a section.  When processing an Update Config.sys section, the Installer processes all DevRenames items first, all DevDelete items second, and all DevAddDev items last.  The syntax and meaning of each of the types of items that can be used in an Update Config.sys section are given later in this topic.

Buffers Item

Buffers=legal-dos-buffer-value
Sets the number of file buffers. As it does with the Stacks item, the Installer compares the existing value with the proposed value and always sets the file buffers to the larger of the two values.

DelKey Item

DelKey=key
Causes the CONFIG.SYS command with the specified key to be remarked out in the CONFIG.SYS file.  For example, the INF file item:

DelKey=Break

would cause a Break=on command to be remarked out in the CONFIG.SYS file.

The DelKey item has the same effect as the RemKey item.  There can be multiple DelKey and/or RemKey items in a section of the INF file.

key
The key of the CONFIG.SYS command to be remarked out.

DevAddDev Item

DevAddDev=driver-name,configkeyword(,flag)(,param-string)
Adds a device or install command to the CONFIG.SYS file.

driver-name
Name of the driver or executable file to add.  The installer validates the filename extension, ensuring that it is SYS or EXE.

configkeyword
Command name.  Can be device or install.

flag
Optional placement flag.  If 0, the command is placed at the bottom of the file.  If 1, it is placed at the top.  If flag is not given, 0 is used by default.

param-string
Optional command parameters.  Must be valid for the given device driver or executable file.

DevDelete Item

DevDelete=device-driver-name
Deletes any line containing the specified filename from the CONFIG.SYS file.

device-driver-name
Name of a file or device driver.  The Installer searches the CONFIG.SYS file for the name and deletes any line containing it.  Because MS-DOS does not permit implicit filename extensions in CONFIG.SYS, each device-driver-name must explicitly specify the filename extension.

This example DevDelete item in an Update Config.sys section deletes lines 1 and 3 but not line 2 of the example CONFIG.SYS file:

DevDelete=Foo.sys
;; lines in CONFIG.SYS
Device=Foo.sys ;; line #1
Install=foo.exe ;; line #2
Device=Foo.sys /d:b800 /I:3 ;; line #3

DevRename Item

DevRename=current-dev-name,new-dev-name
Renames a device driver in the CONFIG.SYS file.

current-dev-name
Name of the device driver or executable file to rename.  The installer looks for the name on the right side of a device or install command in the CONFIG.SYS.

new-dev-name
New name for driver or executable file.

Files Item

Files=legal-dos-files-value
Sets the maximum number of open files in the CONFIG.SYS file.  As it does with the Stacks item, the Installer compares the existing value with the proposed value and always sets the maximum number of open files to the larger of the two values.

legal-dos-files-value
A legal MS-DOS files value.

PrefixPath Item

PrefixPath=ldid(,ldid)...
Appends the path associated with the given LDID to the path command.

ldid
Can be any of the predefined LDID values or a new value defined in the INF.  For a definition of all the predefined LDID values, see the "Reference" topic about the DestinationDirs section.

RemKey Item

RemKey=key
Causes the CONFIG.SYS command with the specified key to be remarked out in the CONFIG.SYS file.  For example, the INF file item:

RemKey=Break

would cause a Break=on command to be remarked out in the CONFIG.SYS file.

The RemKey item has the same effect as the DelKey item.  There can be multiple RemKey and/or DelKey items in a section of the INF file.

key
The key of the CONFIG.SYS command to be remarked out.

Stacks Item

Stacks=dos-stacks-values
Sets the number and size of stacks in the CONFIG.SYS file.  The Installer compares the existing value with the proposed value and always sets the stacks to the larger of the two values.  For example, if CONFIG.SYS contains stacks=9,218 and an INF contains stacks=5,256, the installer sets to new value to stacks=9,256.