This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Call to extractor fails from PowerShell

I've got a PowerShell script to decrypt LieSpeed backups but the call to extractor fails.  My script looks like this:

$localpath="H:\Download\SQL_Backups"
$LS_Decrypt_list= "APSGP", "DYNAMICS", "TSTGP"

#
# Get the LiteSpeed password without echoing it to the screen
#
$encrypted_pw = read-host 'Enter the LiteSpeed password' -AsSecureString
$litespeed_pw=[Runtime.InteropServices.Marshal]::PtrToStringAuto(
    [Runtime.InteropServices.Marshal]::SecureStringToBSTR($encrypted_pw))

# Decrypt each backup on that list
$LS_Decrypt_List | ForEach {
  write-output "     Processing Database: $_"
  $backup_file = Get-ChildItem -Path $localpath\NEXP-DB1_*$_* -name
  $CMD  = 'D:\PROGRA~2\Dell\LiteSpeed\SQLSER~1\extractor.exe'
  $args = "-F $localpath\$backup_file -E $localpath\$backup_file -K $litespeed_pw"
  write-output "     $CMD $args"
  & $CMD $args
  }

The script outputs the following to the screen:

D:\PROGRA~2\Dell\LiteSpeed\SQLSER~1\extractor.exe -F H:\Download\For_Morneau\NEXP-DB1_APSGP_FULL_20170907_025914.bak -E H:\Download\For_Morneau\NEXP-DB1_APSGP_FULL_20170907_025914.bak -K pass_w[ord

But the actual execution of extractor fails with the following message:

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

In addition, a popup window appears that provides the following details:

Problem signature:
  Problem Event Name: APPCRASH
  Application Name: extractor.exe
  Application Version: 8.0.3.40
  Application Timestamp: 54d21c81
  Fault Module Name: extractor.exe
  Fault Module Version: 8.0.3.40
  Fault Module Timestamp: 54d21c81
  Exception Code: 40000015
  Exception Offset: 00000000000cf856
  OS Version: 6.1.7601.2.1.0.274.10
  Locale ID: 1033
  Additional Information 1: c057
  Additional Information 2: c0572302a4a2508e44f5a1db7be46db4
  Additional Information 3: eef6
  Additional Information 4: eef6b1879834487d8734f9f29979fa13

Frustratingly, if I copy and paste the command that is echoed to the screen to a command prompt, the backup decrypts normally.  Does anyone have any recommendation on what is wrong?

Ken

Parents Reply Children
No Data