2014-11-06

TeraStation Pro TS-HTGL/R5 Hard Drive replacement / upgrade

These are the steps I followed to replace the hard drives and upgrade the capacity on a TeraStation Pro TS-HTGL/R5. 

Note that I was completely replacing the drives for greater capacity, and deleted all the data from the array.  This scenario is for a TeraStation with 4 drives that are configured as RAID 5.  I used Western Digital Red drives with a capacity of 2.0TB and it worked fine.  I believe you can use even higher capacity (3+ TB) if you use Western Digital Red drives, but I have not confirmed this.  Please leave comments if you have any experience with larger drives in this unit.

First, I used Robocopy to archive the data from the TeraStation to a temporary backup location.  The options I used were "robocopy L:\Share D:\backup /E /B /R:2 /W:5"  Note that this will skip open files, so you need to make sure that no files are open on the TeraStation before doing this.  You MUST back up your data first when following this procedure or you will lose it all!

I updated the firmware by downloading the current firmware from the Buffalo web site.  Note that I had to update to version 1.33-1.32 first, then to the current firmware, 1.35-1.39.

After the files were backed up and the firmware was updated, I performed the following steps:
  1. Shut down the TeraStation from the web interface.
  2. Remove the 2nd - 4th drives.  You must leave the 1st drive in place for now in order to boot the TeraStation.
  3. Turn the TeraStation back on and connect to the web interface.
  4. Click on "Disk Management", then "Raid Setup" and click on any arrays that are defined.  Click "Delete Raid Array", and confirm it.
  5. Click on "Disk Management", then "Disk Format".  Format the newly installed drives.  This will place the system files on the new drives, allowing it to boot when the 1st drive is replaced.
  6. Shut down the TeraStation from the web interface.
  7. Replace the 1st drive with the new one.
  8. Turn the TeraStation back on.
  9. Format the first drive using the same method for the previous drives.
  10. Click "Disk Management", then "Raid Setup", then the icon for Raid Array 1.  Click the button to create a Raid 5 array.
  11. Go to Shared Folders and re-create your shares.  It might take a while before it allows you to do this while it is initialized the new array.
After that, you can copy your files back using the reverse of the robocopy command, "robocopy D:\backup L:\Share /E /B /XC /XN /R:2 /W:5".  The XC and XN options prevent it from overwriting files that you might change on the TeraStation while it is still copying files (if you have to stop and restart robocopy for some reason).

The TeraStation will be slow for some time while it checks the array, this could take a few days if you are copying files and using it at the same time.

Mercedes E350 Air Conditioning compressor replacement

This is for a 2008 Mercedes E350. 
When I started driving the car one day, I had the A/C on full, but there was hot air coming out of the vents.  No other indications or flashing lights indicating trouble.  I looked under the hood at the A/C compressor and noticed that the plate that attaches the pulley to the compressor shaft was completely shredded.  This is by design, if the compressor freezes the plate shears and the pulley is able to continue to rotate without causing damage to any other components.

I found a compressor on Amazon that cost $392 including shipping.  If I had done some additional research, I would have found a shop in downtown LA that rebuilds them for $200.  I haven't used them yet, but if I have this problem again I intend to take it to them.  This is their info, and I believe they do most A/C compressors:

Power Cylinder Exchange

OPEN NOW
Today8:00 am - 5:00 pm
8634 S Main St,
 
Los Angeles, CA 90003










Before doing this, you should take the car to a shop and have the A/C system evacuated (remove all the R134 from the system).  Keep reading for more info on why this is a bit of a problem...

The A/C compressor is located on the lower left side of the engine (right side when facing the car).
 

First I removed the serpentine belt - just put a 17 mm socket with a breaker bar on the tensioner and rotate it counter-clockwise to release the belt.  There is also a hole in the tensioner that you can place a finishing nail in to hold it.  I just hold the tensioner in place and slip the belt off one of the pulleys and let it go back into position.  I also removed the cowlings on the bottom of the car.

The bolts are somewhat difficult to reach, I had to use a socket with a universal on it to get to 2 of them.  The other one is blocked by the stabilizer bar.  I removed the bolts attaching the stabilizer bar to the links and was able to rotate it enough to get at the bolt.  The fittings that connect the hoses to the compressor and the electrical connector were much easier to get to with the compressor detached from the car.  I removed the compressor by moving it forward where the belt had been.


There is a plate on top of the compressor held by two bolts.  Remove that plate and turn it upside down over a container.  That is the amount of A/C system oil you want to add into the system when you charge it.  The 2008 E350 uses PAG-46.  It should be about 120cc, + 10cc for a new compressor + 10cc for the receiver/dryer, for a total of 140cc of oil.

I also replaced the receiver-drier as part of this procedure, as that should be replaced any time the A/C system is opened up.  The receiver-drier is located below the condenser in front of the radiator.  The retaining bolt that holds the lines in the receiver-drier on mine was frozen so badly that it twisted the torx head bit and I had to use a vice grip to break it loose.

I replaced the compressor and attached the lines and electrical connector before re-attaching the compressor to the vehicle.  I then bolted the compressor back into position and then re-attached the stabilizer bar links.  Next I replaced the serpentine belt.  I didn't put the lower cowlings back until I had completed everything, just in case.

For the next steps I used an A/C R134a manifold gauge set and air vacuum pump from Harbor Freight.  I used the air vacuum pump that uses a compressor and venturi effect to create the vacuum and it actually worked much better than I expected.  Also, it was CHEAP.  I connected the vacuum to the hose on the manifold gauge set and applied vacuum for 15 minutes.  I then closed the valves and let it sit for another 15 minutes to ensure that the vacuum stayed the same and there were no leaks.  Next I added the oil to the hose on the manifold that attaches to the R134a can (just carefully poured it in there prior to connecting the R134a can.  Note that you have to loosen the connection to the manifold gauge set to allow it to flow into the hose).  Add as much refrigerant as it will take prior to turning the system on.  You can add more by turning the can upside down to get the liquid into the system, but if you do that, you must let it equalize for at least 15 minutes prior to turning it on. 
  1. Tighten the hose to the manifold set that was loosened to add the oil, then attach the refrigerant can and turn the can upside down. 
  2. Open the valves on the manifold gauge set to add the refrigerant.  After no more refrigerant will got into the system, close the valves and wait 15 minutes. 
  3. Turn the can right side up, open the valves on the manifold gauge set, and start the car.  Turn on the A/C.
  4. If the compressor comes on and refrigerant is flowing, keep adding until the correct amount has been added (see below).
  5. If the compressor does not come on, you will need to take the car to a shop and have the A/C system reset as mentioned below.

I used 2 14 ounce cans of R134a, and a partial can to fill the system.  It called for 33.6 ounces of R134a, so I used 2 full 14 ounce cans and used a postal scale to measure the weight of the partial can.  I put the can on the scale while it was connected to the hose and just checked the weight until it had gone down by 5.6 ounces.

The problem I encountered was that once the system detects low refrigerant level, it shuts down the compressor and will not turn back on until the computer is reset using a STAR compatible system.  There is a setting that needs to be activated by the technician that activates the compressor and will leave it active until the refrigerant level is back to normal.  This costs about $50 at an indie shop with that capability.  I used German Auto Specialists in Santa Clarita - http://www.yelp.com/biz/german-auto-specialists-santa-clarita.  I added as much refrigerant as it would take, then took it to the shop to get the computer reset, then went back and completed the fill.  I think that if you leave the A/C completely off after it has been evacuated, then fill it as much as possible prior to turning the A/C on it might work without resetting it.







2014-08-19

Mercedes E350 Transmission problem - stuck in 2nd gear limp mode in C / stuck in 2 gears at the same time in P

I have a 2008 Mercedes E350 with the 7 speed automatic transmission (722.9).
I recently had a problem with my E350 where it started shifting hard between 2nd-3rd gears, then wouldn't move at all because it seemed to be stuck in 2 different gears at the same time.  I found that by setting the transmission to Comfort Mode (C) with the engine at operating temperature, it would go into 2nd gear but would not shift.  When it was in Performance Mode (P) it had 2 gears engaged at the same time and would move if I really stepped on the gas and one of the gears slipped (not good)!  When I got the car going over about 25 MPH in C mode 2nd gear, I could put the selector in neutral and then back to drive, and it appeared to go into 6th gear.

Hmmm...  Sounds like a major transmission problem, right?  I decided that it was most likely something to do with the valve body or the transmission computer, which is built into the valve body.  I drained the transmission fluid and removed the valve body.  The bolts that hold the valve body on are the ones on both ends of the body.  I also disconnected the electrical connector that connects to the valve body.  I then dropped the valve body onto some clean shop clothes that were on my chest as the car was on jack stands and I was directly under it.  I wanted to be very careful not to drop it or to get ANY dirt or contamination on it.

After removing the valve body, I removed the solenoids, and lo and behold, one of them had a broken o-ring, as seen below: 

Pieces of the o-ring had actually gone into the valve body and required me to remove the plates that contain the valves in order to clean the bores and valves.  I took pictures of all the valves and springs as I removed the plates to ensure that I got them back in the right way.
 

The contacts and everything on the conductor plate appeared to be fine, so I cleaned everything very well with brake cleaner (I used brake cleaner to clean the valve body, valves, and bores as well).

Mercedes does not sell the O-rings specific to this application, they will sell you an entire valve body.  I went to Harbor Freight and got a set of metric O-rings which contained about 250 assorted O-rings for $3.00 and replaced all of the O-rings on the solenoids with those.

The total cost was still quite expensive as I replaced the transmission fluid that I had drained and the filter.  I didn't drain the fluid from the torque converter this time as I had done a fluid change recently.  The fact that I had changed the fluid recently leads me to believe that the previous owner had not changed the fluid because this is the kind of thing that happens when you change the fluid in a car that hasn't been serviced for some time.  The total cost was about $135 for everything.  I use Redline D6 full synthetic transmission fluid, not an endorsement, but I have used their fluid with good results in the past in other cars.

I will describe the method I use for changing the transmission fluid in another post.  I hope this helps someone!  It saved me a lot of money over taking it to the dealer and getting stuck with either a new valve body or even a new transmission...

2012-07-18

1999 Honda Accord V6 Transmission Rebuild (B7XA)

My 1999 Accord started having major problems with the transmission, so I pulled it out of the car and started getting quotes for a rebuild.  For reputable shops the price was around $2,000!  Just for the rebuild, not including the labor of replacing it in the car.  I couldn't see spending $2,000 for a rebuild that might or might not be done right, so I decided to do it myself.  Here is a description of what I did and some references to helpful information I found online about the project.  I took pictures of EVERYTHING as I worked, in case there was any question of how something was supposed to be when putting it back together.  I also put all the parts from all of the components in Ziplock bags and labeled which component it was from.  All parts were cleaned in a solvent tank and rinsed off with WD-40, then Ziplocked if possible.  All parts were coated in ATF prior to reassembly, and the friction plates were soaked in ATF overnight prior to installation.


I obtained the diagnosis and overhaul manual from http://www.drivetrain.com/ for $40 (they carry the parts as well).  I obtained the overhaul parts from http://www.transmissionpartsusa.com/ for $270 including the Bench Buddy valve polishing tools.  I made sure I got the complete overhaul kit, including the steel clutch plates (which turned out to be a very good decision!). I obtained a rebuilt torque converter from a local shop in Los Angeles for $85.  After it was finished, I decided to use Redline D4 synthetic transmission fluid instead of the Honda fluid ($150 for 3 gallons!).  I also installed a second transmission cooler after the stock cooler (free from a neighbor), and a magnefine filter after the second cooler (http://magnefinefilters.com) ($16).


This video has some very helpful pointers on the B7XA transmission:
http://www.youtube.com/watch?v=nuv9UZumqWI&feature=related

This is a good post on the design of the B7XA, describing the design and issues with it:
http://www.driveaccord.net/forums/archive/index.php/t-2025.html

Anyone who has one of these Accords or Odysseys ('99-'02) probably knows about the problems with this transmission.  The design was bad, and they fail prematurely.  I have read that one of the reasons for this is that previous generations of Honda transmissions shifted hard and people were complaining about it, so to smooth out the shifting Honda designed these transmissions so that when they shift, the transmission partially engages the gear that it is shifting to, while the gear that it is shifting from is still partially engaged.  This results in a smoother shift, at the expense of severe wear on the clutch packs.  I have not confirmed this, but it makes sense.  I might have more on this in the future, I will try and confirm it and possibly find a way to lock it out so it can only engage one gear at a time.  In addition to this behavior, there is no replaceable filter element.  The filter is located inside the transmission and cannot be changed without disassembling the entire transmission.  There are some other issues I found, such as valves getting stuck due to particles and contamination.

The transmission sitting on the work bench

With the cover removed
The pressurized fluid to engage the clutches is delivered through the holes in the tops of the shafts.  I did not have the tool to hold the main shaft for removing the nuts on the shafts, so I engaged the parking brake pawl and applied shop air to the top of the main shaft to engage the clutches on that shaft and remove the nut on the secondary shaft, then apply shop air to the secondary shaft to remove the nut on the main shaft.  I had a friend hold a tire inflator to the hole on top of the shafts while I wrenched on the nuts.  When I put it back together I used the same method to hold the shafts on installation.  Note that I bolted it to the bench for most of this process to hold it in place.


With the housing removed
There are protrusions on the housing that I was able to pry to separate the housing (sorry, no pictures).  Note the black filter in the back of the second picture.  Yep, you have to take it apart this far to change it!

With all the shafts and differential removed, exposing the valve bodies.

The shafts and idler gears.
Note that I had to replace the needle bearing on the top of the secondary shaft.  When I disassembled it and tried to remove that bearing it came apart and the needles came out of the holder.  That was the only bearing I had to replace.  All the other ones looked good on visual inspection.

Oil pump

3rd gear clutch pack
Now we get to the real problem.  The 3rd gear clutch pack.  The picture above shows the exposed friction plate.  Note that there is no friction material material, just steel.  The splines on the plates were blue, and basically fused to the inner splines.  I had to pry the friction plates off.  It looks like they had heated up to the point where they softened and expanded.  There was some minor wear on the outer housing that I had to clean up prior to reassembly.
3rd gear steel & friction plates.  No friction material on any of the friction plates...
The 2nd gear clutch pack was getting fairly worn.  Some of the friction plates had bare metal showing.

The steel plates for the clutch packs came in a package with no labeling.  I had to mic the old plates and the new ones to sort them out and which plates go in which clutch pack.  It's a good thing I kept all of the steel & friction plates together and labeled which clutch they came out of...  The friction plates appeared to be all the same, even though the friction pattern on the old plates varied for each clutch.  The kit that I purchased had the same number of plates as the original, but the Honda parts stores show a different number of plates in the clutches.  I think they might have changed the design and made them thicker with fewer plates.  Not sure.

Note that the manual calls for measuring the clearance between the clutch end plate and top disc using a dial indicator.  I do not have a dial indicator, so I measured the distance from the clutch end plate to the groove for the snap ring...same thing.

Regulator valve body 

Servo body 

Main valve body 

Main valve body 

Main valve body 

Regulator valve body.  Note the small hole drilled in the torque converter circuit, as mentioned in the YouTube video I listed above.

The housing after finally getting all of the old gasket off.  I had to scrape the gasket off with a blade, which resulted in some minor scratches.  I cleaned up the scratches with #600 wet/dry sandpaper and WD-40.  The new gasket was applied dry...There is some controversy over whether to coat the gasket with ATF prior to installation.  Dry works.  No leaks.

Here we go...The good part!  It's coming back together. 

Housing on, shaft nuts installed using the shop air to lock the clutches method.  The clutches are good, they held with no slippage up to the 166 foot pounds required to seat the gears.  I think that's a good sign. 

It's starting to look the way I want it to... I don't see any leftover parts!

Finally back where it belongs.  My neighbor, Manny, was nice enough to come over and help me get it into position in the car.  With a floor jack supporting the transmission it was still difficult to get the right angle and everything lined up so that it would slide in without forcing it.

Installed!  Now to put all the other pieces back together.  

Thanks to Mr. Bill & Manny for the help and lending me some tools I didn't have to make this easier.  And thanks to Rick for the cooler that was exactly what I was looking for!

I have since put about 500 miles on the car and it works great.  Wow!

2012-05-09

NEW Web Based ITrac

It's here.  It does virtually everything the old ITrac does, except there is no software to install, it works in a web browser, and it works on Windows, Mac, and Linux!  In future posts I will be going through some of the new features that are available, and how to use the new ITrac.  The new version integrates everything in one package, one web site.  Office users, Clients, and Investigators sign on to the same web site and get the same user interface that varies the content based on the user account type.  This allows Management to view all aspects of all cases, office users and managers to access the information they need to work their cases, Clients are able to view approved finished work products for their cases, and Investigators can retrieve work assignments, upload media (video/audio), create & upload case reports, and enter time & expenses for their assigned cases.
You can get more information on the DAS web site.

2008-04-11

Current projects at Digital Aerospace Solutions

The last few months have been extremely busy here. We have some exciting projects in the works, including a web site for one of our clients that provides great Private Investigative services, including surveillance, background checks, bug sweeps and counter surveillance, and a host of other services. The owner is Gene Iovino, you can find their new web site at http://www.iovinoips.com.

One of the other great projects that is still being refined is ITrac Web Access, which provides your clients with access to critical case information, including case reports, notes, and video clips. ITrac Web Access is an extension of the ITrac software that provides an easy to use web based interface for your clients and investigators.

2008-03-19

ICM problem

One of the Terminal Servers that I manage has a program called ICM installed on it. They called yesterday claiming that the Notes were missing, then this morning when they opened ROs it would completely close.
I logged on and confirmed that it did exactly that. This fix was fairly simple:
1. Log on as an ICM administrator.
2. Click Utilities > Clean up Local Data
3. Click Utilities > Clean up Server Data

ICM makes a backup of the dbf files before it does that repairs, but I am paranoid, so I also saved another copy of them before running this utility. The utility probably just checks the dbf files and re-indexes them.

This did solve the problem (sigh of relief).

Microsoft Access 2003 Runtime on Windows Vista

Isn't Vista proving to be very entertaining? Windows Vista is certainly Genuine Microsoft...Genuine garbage.
I have a client that is running Vista and a program that I developed that runs on MS Access. He installed the runtime version of Access 2003, and every time he opens the application he gets the Windows Installer Dialog: "please wait while windows configures microsoft access 2003 runtime".
When it opens, several errors are logged and then Vista shuts it down.
I tried all the usual Vista things...Turn off UAC, run in compatibility mode, turn off Aero Glass. Tried re-installing several times and with various installations of Office SP2 & SP3. Nothing would make it work, it always gave the "Please wait while windows configures Microsoft Access 2003 Runtime".

I looked in the error log, and found some entries for the msiinstaller:
Detection of product '{901C0409-6000-11D3-8CFE-0150048383C9}', feature 'ProductNonBootFiles' failed during request for component '{22056900-C842-11D1-A0DD-00A0C9054277}'

Also:
The resource 'HKEY_CLASSES_ROOT\.pip\' does not exist.

I tried the resolution for this error:

a.) go to the actual terminal server console
b.) go to start\run command line and key in the following:
regedt32
c.) check the permissions to the following registry keys:


HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer
System and Admins - Full Control
Everyone- Read


HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\Comp­o
nents
System and Admins - Full Control
Everyone- Read


HKEY_CLASSES_ROOT
System and Admins - Full Control
Everyone- Read


HKEY_CLASSES_ROOT\.pip
System and Admins - Full Control
Everyone- Read


HKEY_CLASSES_ROOT\Installer
System and Admins - Full Control
Everyone- Read


HKEY_CLASSES_ROOT\Installer\Components
System and Admins - Full Control
Everyone- Read


HKEY_CURRENT_USER\Software\Classes
System and Admins - Full Control
Everyone- Read

After updating the permissions, it worked. Note that HKEY_CLASSES_ROOT\.pip was completely denied, even to admins, so I had to take ownership of that one and then add permissions to it. Some program must have taken ownership of the key and then locked everyone out.

2007-12-11

Windows Vista / Office 2007 / Adobe Reader BUG!

This problem has actually happened to multiple clients of mine.
The issue is that the user will accidently try to open a Microsoft Word document with Adobe Reader. After that, it seems that Windows just does not know what to do with Word documents anymore, even after you tell it to open the documents with Word every time in the Open With dialog. (Although, now that I think of it, I did not confirm this to be true, I took the user's word for it. Something to check next time).
The thing that appears to have fixed the problem is to change the following value in the registry:
HKCR\.doc
Change the (default) value from word_auto_doc (or something like that) to Word.Document.8
Then right-click on a word document and select Open With, Select Program, select Microsoft Word, and check the Open with this program every time box.
Yet another annoyance with Vista / Office 2007. I will rant more about these in another blog, because there is soooo much to say...

2007-04-06

Volume Shadow Copy / Backups

I have spent the last few days working on implementing a new backup strategy for my servers. I thought I would share the fruits of my efforts so that others who are trying to attain the same goals might work a bit less than I did.

My goals for the new backup plan:
1. A homogenous environment (don't need to use different software on each machine)
2. Easy to use
3. Preferably would use differencing technology that only uploads the bytes that have been changed in each file to the server on incremental backups.
4. Client-Server design would be nice (install server software on a backup server, client software on other machines and backup to a central location).
5. Able to backup ALL files on the selected drives as a consistent snapshot that could ideally be restored to a new hard drive, inserted in a new machine, and...be ready to go (no re-installing everything, setting everything up, and restoring the files to the correct locations!).

I found some sosftware that meets most of the requirements from Vembu called StoreGrid. It is a client-server solution that is VERY easy to configure. It backs up to a central server location. It meets all of my goals except for the consistent snapshot one. This software can even do remote backups over the Internet, so it is also going to help me with the clients that I support outside of my own office. They have a solutions that allows you to backup files that are in use, but that caused me major grief on my servers and did not provide a consistent snapshot of the drive.

I found a way to make it work by using Volume Shadow Service on Windows XP & Windows Server 2003. I found some posts that allowed me to create a snapshot of a drive and then mount the snapshot to a drive letter in the computer. The drawback? It took a bit of work to get everything set up, and for the XP machines, I had to tweak the scripts to get it to work. I also had a bit of trouble finding some of the executables that I needed for the scripts.

The scripts came from Adi at Microsoft.

vshadow.exe for Windows Server 2003 and for Windows XP is included with the Volume Shadow Copy Service SDK 7.2 from Microsoft:
Shadow Copy Service SDK 7.2 from Microsoft
The vshadow file extracts to (pick the correct one, they are different):
C:\Program Files\Microsoft\VSSSDK72\TestApps\vshadow\bin\release-server
C:\Program Files\Microsoft\VSSSDK72\TestApps\vshadow\bin\release-xp

You only need dosdev for the Windows XP setup. dosdev was a bit harder to find, but I found it in the Microsoft Product Support Reporting Tools (MPSRPT), the one I used was the Exchange version, I think some of the other ones have it, too. When you run this, it will place the dosdev file in the C:\WINDOWS\MPSReports\Exchange\bin folder.

The tools are here:
MPSReports for exchange

After you have the executables and the scripts, set your backup in Vembu to use Pre & Post commands.
Pre Command:
COMMAND: C:/some folder/createshadow.cmd
ARGUMENTS: c: b:
WORKING PATH: C:/some folder
TIME OUT: 60

Post Command:
COMMAND: C:/some folder/removeshadow.cmd
TIME OUT: 60

*Note that removeshadow is not included in the scripts listed below, it is created by the createshadow.cmd script when it runs.

Here is what is required...
**********************
***Windows XP***
dosdev.exe
vshadow.exe
createshadow.cmd
wait.bat

The contents of the scripts are here:
createshadow.cmd:
-----------------------------------------------------------------
REM BEGIN SCRIPT
setlocal
if NOT "%CALLBACK_SCRIPT%"=="" goto :IS_CALLBACK
set SOURCE_VOLUME=%1
set DESTINATION_VOLUME=%2
set CALLBACK_SCRIPT=%~dpnx0
set TEMP_GENERATED_SCRIPT=GeneratedVarsTempScript.cmd
%~dp0vshadow.exe -script=%TEMP_GENERATED_SCRIPT% -exec=%CALLBACK_SCRIPT% %SOURCE_VOLUME%
del /f %TEMP_GENERATED_SCRIPT%
@goto :EOF

:IS_CALLBACK
setlocal
call %TEMP_GENERATED_SCRIPT%
%~dp0dosdev.exe %DESTINATION_VOLUME% %SHADOW_DEVICE_1%

REM ***This drive will only be available until this script exits***

@echo. >%~dp0RemoveShadow.cmd
@echo %~dp0dosdev -r -d %DESTINATION_VOLUME%>>%~dp0RemoveShadow.cmd
@echo %~dp0\VSHADOW.EXE -ds=%SHADOW_ID_1%>>%~dp0RemoveShadow.cmd
@echo del /f %~dp0RemoveShadow.cmd>>%~dp0RemoveShadow.cmd

REM echo off

:Loop
@CALL wait.bat 10
fsutil fsinfo volumeinfo %DESTINATION_VOLUME%>%~dp0shadow_drive_details.txt
@if errorlevel 1 goto :EndS
@goto :Loop

:EndS

REM END SCRIPT
----------------------------------------------------------------------

wait.bat:
----------------------------------------------------------------------
REM BEGIN SCRIPT wait.bat
@ping 127.0.0.1 -n 2 -w 1000 > nul
@ping 127.0.0.1 -n %1% -w 1000> nul
REM END SCRIPT
----------------------------------------------------------------------
***********************


***********************
For Windows Server 2003:

vshadow.exe
createshadow.cmd

createshadow.cmd:
----------------------------------------------------------------------
REM BEGIN SCRIPT createshadow.cmd
setlocal
if NOT "%CALLBACK_SCRIPT%"=="" goto :IS_CALLBACK
set SOURCE_VOLUME=%1
set DESTINATION_VOLUME=%2
set CALLBACK_SCRIPT=%~dpnx0
set TEMP_GENERATED_SCRIPT=GeneratedVarsTempScript.cmd
%~dp0\vshadow.exe -nw -p -script=%TEMP_GENERATED_SCRIPT% -exec=%CALLBACK_SCRIPT% %SOURCE_VOLUME%
del /f %TEMP_GENERATED_SCRIPT%
@goto :EOF

:IS_CALLBACK
setlocal
call %TEMP_GENERATED_SCRIPT%
%~dp0\vshadow.exe -el=%SHADOW_ID_1%,%DESTINATION_VOLUME%
@echo.
@echo *******************************************
@echo To delete the shadow copy, run the command:
@echo VSHADOW.EXE -ds=%SHADOW_ID_1%
@echo *******************************************
@echo.
@echo.>%~dp0\RemoveShadow.cmd
@echo REM ******************************************* >>%~dp0\RemoveShadow.cmd
@echo REM To delete the shadow copy, run the command: >>%~dp0\RemoveShadow.cmd
@echo REM VSHADOW.EXE -ds=%SHADOW_ID_1% >>%~dp0\RemoveShadow.cmd
@echo REM ******************************************* >>%~dp0\RemoveShadow.cmd
@echo REM This will remove the Shadow Volume %DESTINATION_VOLUME% >>%~dp0\RemoveShadow.cmd
@echo REM This message will self destruct.>>%~dp0\RemoveShadow.cmd

@echo. >>%~dp0\RemoveShadow.cmd
echo %~dp0\VSHADOW.EXE -ds=%SHADOW_ID_1%>>%~dp0\RemoveShadow.cmd
echo %~dp0\VSHADOW.EXE -ds=%SHADOW_ID_1%>%~dp0\ShadowCleanup.cmd
echo del /f %~dp0\RemoveShadow.cmd>>%~dp0\RemoveShadow.cmd

REM END SCRIPT
------------------------------------------------------------------------