Windows Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsWindows Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old May 5th, 2003, 09:06 PM
a.koepke's Avatar
a.koepke a.koepke is offline
Second highest poster :p
Dev Shed God 5th Plane (7000 - 7499 posts)
 
Join Date: Jul 2001
Posts: 7,323 a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 8 h 11 m 27 sec
Reputation Power: 27
Replace MSVCRT.DLL on WinNT System

I am currently trying to manually replace the MSVCRT.DLL (Microsoft Visual C Runtime Library) on a Windows NT 4.0 SP6 machine. I have obtained a new version of the DLL since Xerces (http://xml.apache.org) doesn't run with the old/current version of the library.

I tried renaming the file while windows was running will all programs and extensions/processes killed and it was still being used by some program (possibly Windows itself was using it).

The next setup I tried was to create a batch file, which contained the copy function, and went into the system registry and entered it into \HKEY_LOCAL_MACHINE\Software\Microsoft\Current_Version\RunOnce. The batch file ran upon startup but still reported the file was in use.

I am not that savvy with NT 4.0 and have tried rebooting the machine to see if there is any way to get into a command-line only mode. With Win2K I know you can start in 'safe-mode: command prompt only' mode which you can use to do things like this. I cannot figure out how to get into the equivalent mode in NT4.0. I have read suggestions of using an MS-DOS boot disk but the file-system is NTFS and cannot be read by MS DOS disks. I have thought of using Knoppix to boot the system but then I remembered it only has read access to NTFS partitions.

Does anyone know how I can get into the system so I can replace this file.
__________________
- Andreas Koepke

I have photos for sale at RedBubble


Reply With Quote
  #2  
Old May 6th, 2003, 02:51 AM
MJEggertson MJEggertson is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jan 2002
Location: Seattle WA
Posts: 863 MJEggertson User rank is Corporal (100 - 500 Reputation Level)MJEggertson User rank is Corporal (100 - 500 Reputation Level)MJEggertson User rank is Corporal (100 - 500 Reputation Level)MJEggertson User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 22 sec
Reputation Power: 8
Can you boot from the install CD? Otherwise, it's likely there's always going to be something using the C RTL, any sort of hard disk boot is likely going to have the file in use.

There's got to be a way to do it though. Someone in the Xerces community must have encountered it before, maybe some hardcore searching in their community/lists may bring something up?

Reply With Quote
  #3  
Old May 6th, 2003, 03:15 AM
a.koepke's Avatar
a.koepke a.koepke is offline
Second highest poster :p
Dev Shed God 5th Plane (7000 - 7499 posts)
 
Join Date: Jul 2001
Posts: 7,323 a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 8 h 11 m 27 sec
Reputation Power: 27
Have been looking around and thinking of different things and found a couple of programs that allow mounting of NTFS drives under MS DOS. The first one I found, NTFSDOS, was free but is read only, not useful in my case. I did some more searching and found NTFSDOS Pro offering read/write access but costing US$299. I did some further searching and have found a copy of it that I am going to try out. I only need it once and can't justify spending US$299 for a one-time usage.

Reply With Quote
  #4  
Old May 9th, 2003, 12:22 PM
M.Hirsch M.Hirsch is offline
Contributing User
Dev Shed God 1st Plane (5500 - 5999 posts)
 
Join Date: Oct 2000
Location: Back in the real world.
Posts: 5,969 M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 22 h 42 m 50 sec
Reputation Power: 184
MoveFileEx()

Hi koepke!

Here´s a WinAPI function that could be useful for that:
BOOL MoveFileEx(LPCTSTR lpExistingFileName, LPCTSTR pNewFileName, DWORD dwFlags);
Quote:
[...]
If dwFlags specifies MOVEFILE_DELAY_UNTIL_REBOOT and lpNewFileName is NULL, MoveFileEx registers the lpExistingFileName file to be deleted when the system restarts.
[...]


Not sure if NT boots without the file though. I am not responsible for any harm it does to you, your computer or anybody´s g0ats
__________________
--
Manuel Hirsch - Linux, FreeBSD, programming, administration articles, tutorials and more.

Reply With Quote
  #5  
Old June 10th, 2003, 01:48 AM
cparlanti cparlanti is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Posts: 5 cparlanti User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Follow this procedure

Choose Start>Programs>Command Prompt or Start>Programs>Accessories>Command Prompt and use the following commands (assuming the old DLL is located in C:\Temp):

----------------------------------------------------------------------------------
C:\Documents and Settings\Administrator>cd c:\winnt\system32

C:\WINNT\system32>rename msvcrt.dll msvcrt.old

C:\WINNT\system32>copy c:\temp\msvcrt.dll
Overwrite C:\WINNT\system32\msvcrt.dll? (Yes/No/All): y
1 file(s) copied.

C:\WINNT\system32>
----------------------------------------------------------------------------------

If you use the Command Prompt to rename the DLL NT/2000 lets you do it altough it simply creats a copy of the file because of the lock.

The lock gets moved on the copied file so it's now possible to restore the needed version of the DLL (still using the Command Prompt).

Reply With Quote
  #6  
Old December 11th, 2003, 08:00 PM
umdesch4 umdesch4 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2003
Posts: 4 umdesch4 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
The above doesn't work, for the same reason as everything else, the msvcrt.dll is in use, at least on the serviced pack-applied version of NT I tried it on.

On Windows 2000, it's even in use if you boot to command prompt only.

So I thought I'd be smart, boot from a boot CD with NTFSPRO on it, and copy in the new version of the dll.

Bad idea! The next reboot came up with a Blue screen telling me that there was a checksum error with msvcrt.dll, it was possibly corrupt, blah blah blah. (again, this is on Win2K)

Oh, the misery...be careful folks...

umdesch4

Last edited by umdesch4 : December 11th, 2003 at 08:07 PM.

Reply With Quote
  #7  
Old December 11th, 2003, 10:21 PM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 12th Plane (10500 - 10999 posts)
 
Join Date: Jun 2003
Posts: 10,973 Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 17 h 34 m 20 sec
Reputation Power: 802
You could try renaming the existing msvcrt dll and then copy the new one into the same directory, and reboot. Oops, I guess you tried that.

You could install a 2nd instance of NT4 to another folder (or better, another disk partition) and change the file whil booted into the 2nd instance.

There is a good chance you will cause other problems in other software if you change the dll to a non-standard version.

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsWindows Help > Replace MSVCRT.DLL on WinNT System


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT