Sponsoring website: Emergency Boot Kit

 

This page contains an edited copy of KB Article Q 228.9.30
provided as a service ONLY to the users of my website;
You are NOT connected to a Microsoft domain!

Article ID: Q228930    Last Reviewed: February 11, 2001

Edited by The Starman: July 3, 2001.


How to Replace Currently Locked Files with Inuse.exe


The information in this article applies to:
  • Microsoft Windows NT Server version 4.0, on platform(s):
    • the hardware: Intel x86
  • Microsoft Windows NT Workstation version 4.0, on platform(s):
    • the hardware: Intel x86
  • Microsoft Windows NT Server, Enterprise Edition version 4.0, on platform(s):
    • the hardware: Intel x86
  • Microsoft Windows 2000 Professional
  • Microsoft Windows 2000 Server
  • Microsoft Windows 2000 Advanced Server


SUMMARY

Inuse.exe provides individuals and administrators with "on-the-fly" capability to replace files that are currenly in use by the operating system. Although this behavior is generally accomplished by running a program's setup program or a service pack's upgrade program, the setup and upgrade process tends to replace multiple files. However, for troubleshooting purposes, you may need to replace an individual file on your computer versus an entire set of files. The Inuse program provides this level of administrative flexibility.

    Click here to download the old InUse version 1.3


You can obtain InUse (1.31) from the following Microsoft Web site:
http://download.microsoft.com/download/winntsrv40/Utility/1.3/NT4/EN-US/inuse.exe

If you click on the link above, you'll most likely NOT get version 1.3, but rather a version 1.31 (which I have been told will not work with Windows NT)!  Yet the text below states that: "In Windows 2000 the version of the Inuse.exe program is 1.4"   So why did they change the old version 1.3 into a version 1.31 which appears to be simply a copy of 1.4? I have no idea at all...  Therefore, I'm making a copy of the original version 1.3 available again here!  As they state below, in the Disclaimer, "use at your own risk."



Disclaimer

Please understand that this is an unsupported utility and typical safeguards should be taken when using the utility, such as ensuring that you have a copy of the DLL from the original installation source. This is "use at your own risk" and support for the utility is not available from Microsoft at this time.

MORE INFORMATION

InUse is a Win32-based command-line utility that can be used by and within automated tasks, scripts, or other programs.


Obviously, neither of these two versions does any system version checking since both ran on a Win 95B computer (which I did only to read the 'usage' information at a DOS prompt). But this new version ( 1.31 ) has some rather strange statements in it:

 C:\TEMP>inuse

 InUse - version 1.31
 ---------------------------------------------------------------------------
 Copyright (c) 1994-1999 Microsoft Corporation. All rights reserved
 You are running Windows2000 - WFP is enforced

 INUSE  replacement  destination  [/y]

  replacement    Specifies the updated file
  destination    Specifies the existing file to be replaced
  /y             Suppresses confirmation prompt to replace file

 Source and destination must include the complete physical or UNC pathname
What does it mean by: "You _are_ running Windows2000 ?" [ No! I was running Win95B! So it's obviously not checking the OS version! ] If they're trying to say that I SHOULD be running Win2000 to use this utility, it's a VERY POOR way of saying so! (Also, since 'WFP enforced' means the "Windows File Protection" system of Win2k will try to keep its system files from being updated by anything other than an official MS update, I'd tend to agree that this version is NOT for Win NT 4.0!) A woman named Betsy from Canada wrote that she tried v.1.31 on a Win NT machine with fully qualified paths, but that it never 'took' for her. She added, "I suspect the utility is broken for non-W2K machines."
So, the folks up at Microsoft seem to have either blundered here, or decided that NT techs never needed an easier way to make a change in their Registry settings <grin>. So, this leads us to wonder: Has anyone ever had a bad experience with the old InUse (version 1.3) util, or did MS stop making it available for some other reason??




The following Syntax and examples deal with the original (version 1.3) InUse utility:

Syntax

c:\inuse.exe /?
InUse - version 1.3  [ For Windows NT! ] 
---------------------------------------------------------------------------
Copyright (c) 1994-1999 Microsoft Corporation. All rights reserved

Replaces files that are currently locked by the OS

INUSE  source  destination  [/y]

 source         Specifies the updated file
 destination    Specifies the existing file to be replaced
 /y             Suppresses confirmation prompt to replace file
 /?             Displays syntax help

 Source and destination must include the complete physical or UNC pathname 
*In Windows 2000 the version of the Inuse.exe program is 1.4. The tool works
the same way but the Help window has changed slightly. Instead of source
they use the term replacement.

Comments

The destination is the currently locked file that you want to replace on the local drive. Please note that after you commit INUSE to replace a file, you cannot run it again to reverse the transaction. This may be considered in a newer version.

Examples

Basic operation of INUSE is quite simple; just tell it the file you want to replace and where it's updated replacement is located. It also has an additional parameter that allows the supression of the actual copy comfirmation. This may be useful if you intend to use INUSE as part of some automated processes. The following examples shows simulated INUSE output as well as its operation in both a local and also a network-based file replacement scenario.

Example 1: Promptless Install

c:\tools\inuse.exe \\updates\prodmod.dll c:\program files\prodsys\prodmod.dll /y
InUse - version 1.3
--------------------------------------------------
InUse is about to replace the following file

Existing:    c:\program files\prodsys\prodmod.dll
Version:     1.31

Replacement: \\updates\prodmod.dll
Version:     1.34

\\updates\prodmod.dll is replacing --> c:\program files\prodsys\prodmod.dll

Changes do not take affect until you reboot<BR/> 

Example 2: Prompted Install

c:\tools\inuse.exe \\updates\prodmod.dll c:\program files\prodsys\prodmod.dll
InUse - version 1.3
--------------------------------------------------
InUse is about to replace the following file

Existing:    c:\program files\prodsys\prodmod.dll
Version:     1.31

Replacement: \\updates\prodmod.dll
Version:     1.34

Do you want to continue?(y/n)

\\updates\prodmod.dll is replacing --> c:\program files\prodsys\prodmod.dll

Changes will not take affect until you reboot 

You will notice the only difference with the examples is the fact the user will be prompted to confirm or cancel the operation on the latter.

Example 3: Batch Operation

The following example represents how an administrator can nest multiple updates in a single script:
batch.cmd
@echo off
inuse test.dll c:\winnt\system32\test.dll /y
inuse test2.dll c:\winnt\system32\test2.dll /y
inuse test3.dll c:\winnt\system32\test3.dll /y
Note that this executable actually does an edit to the registry to perform a "PendingFileRenameOperations" on the next reboot.

REFERENCES

For more information about the InUse utility, see the following Microsoft TechNet article:

http://www.microsoft.com/technet/inside/6-7-99.htm#inuse
 Note: This article is no longer available from their server ! 
   I have no idea why they removed this one either.  
However, you may be able to find it here at archive.org still.

Additional query words: ntsetup update install setup service pack

Keywords :
Issue type : kbinfo
Technology : kbWinNTsearch kbWinNTSsearch


Last Reviewed: February 11, 2001
© 2001 Microsoft Corporation.