locked
Error with installation of AppFabric 1.1 on PSModulePath

    Question

  • Have several tries to install AppFabric Caching 1.1 but it keeps failing on the same line.

    Finally traced the problem down to this line in the log:

    22-2-2012 14:16:50 EXEPATH=powershell.exe PARAMS=-command "$str = [System.Environment]::GetEnvironmentVariable(\"PSModulePath\", [System.EnvironmentVariableTarget]::Machine); $str = $str+\";C:\Program Files\AppFabric 1.1 for Windows Server\PowershellModules\"; C:\Windows\system32\setx.exe /M PSModulePath \"$str\"" LOGFILE=C:\Users\Mike\AppData\Local\Temp\AppServerSetup1_1_CustomActions(2012-02-22 14-16-21).log

    Error: ERROR: Invalid syntax. Default option is not allowed more than '2' time(s).
    Error: Type "SETX /?" for usage.
    ExitCode=1

    This is my current PSModulePath:

    C:\Users\Mike\Documents\WindowsPowerShell\Modules;C:\Windows\system32\WindowsPowerShell\v1.0\Modules\;c:\Program Files
    (x86)\Microsoft SQL Server\110\Tools\PowerShell\Modules"

    How can i resolve this issue, kinda lost here. 

    Wednesday, February 22, 2012 1:41 PM

Answers

  • There seems to be trouble in escaping the stuff.

    C:\Windows\system32\setx.exe /M PSModulePath \"$str\""

    Can you please try both of the following and see if any works:

    C:\Windows\system32\setx.exe /M PSModulePath \""$str\""

    C:\Windows\system32\setx.exe /M PSModulePath \"$str\"

    Thanks,

    Laxmi


    Please hit "Yes", if my post answered your question(s). All postings are as-is and confer no rights.

    • Marked as answer by OnTheMike Tuesday, February 28, 2012 7:44 AM
    Monday, February 27, 2012 5:14 AM

All replies

  • There seems to be trouble in escaping the stuff.

    C:\Windows\system32\setx.exe /M PSModulePath \"$str\""

    Can you please try both of the following and see if any works:

    C:\Windows\system32\setx.exe /M PSModulePath \""$str\""

    C:\Windows\system32\setx.exe /M PSModulePath \"$str\"

    Thanks,

    Laxmi


    Please hit "Yes", if my post answered your question(s). All postings are as-is and confer no rights.

    • Marked as answer by OnTheMike Tuesday, February 28, 2012 7:44 AM
    Monday, February 27, 2012 5:14 AM
  • Thanks, you're reply solved the issue. After your remark i've noticed my PSModulePath did indeed contain a " at the end. Seems it was put there by SQL Server 2012. Removing the " solved the installation-issues.


    Tuesday, February 28, 2012 7:44 AM
  • i had similar issue, i had an ending " in the value of PSModulePath environment variable. Remove this " fixed appfabric installation.

    i had come across this thread yesterday when i search after AppFabric installation failed. However, i did not understand what is talking about here. It seemed unrelevant.

    Then, I followed http://technet.microsoft.com/en-us/library/cc535232.aspx to find out the follow error message. At last, i notice the ending quotation mark in PSModulePath which caused the problem (for how to manage environment variable: http://support.microsoft.com/kb/310519/en-us).

    MSI (s) (48:A0) [06:57:59:828]: Note: 1: 1722 2: Env_PSModulePath_powershell_i 3: c:\Program Files\AppFabric 1.1 for Windows Server\Microsoft.ApplicationServer.InstallHelper.exe 4: powershell.exe "-command \"$str = [System.Environment]::GetEnvironmentVariable(\\\"PSModulePath\\\", [System.EnvironmentVariableTarget]::Machine); $str = $str+\\\";c:\Program Files\AppFabric 1.1 for Windows Server\PowershellModules\\\"; c:\Windows\system32\setx.exe /M PSModulePath \\\"$str\\\"\"" "C:\Users\Administrator\AppData\Local\Temp\AppServerSetup1_1_CustomActions(2012-11-11 06-57-20).log"
    CustomAction Env_PSModulePath_powershell_i returned actual error code 1 (note this may not be 100% accurate if translation happened inside sandbox)
    MSI (s) (48:A0) [06:57:59:828]: Product: AppFabric 1.1 for Windows Server -- Error 1722. There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor.  Action Env_PSModulePath_powershell_i, location: c:\Program Files\AppFabric 1.1 for Windows Server\Microsoft.ApplicationServer.InstallHelper.exe, command: powershell.exe "-command \"$str = [System.Environment]::GetEnvironmentVariable(\\\"PSModulePath\\\", [System.EnvironmentVariableTarget]::Machine); $str = $str+\\\";c:\Program Files\AppFabric 1.1 for Windows Server\PowershellModules\\\"; c:\Windows\system32\setx.exe /M PSModulePath \\\"$str\\\"\"" "C:\Users\Administrator\AppData\Local\Temp\AppServerSetup1_1_CustomActions(2012-11-11 06-57-20).log"

    Error 1722. There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor.  Action Env_PSModulePath_powershell_i, location: c:\Program Files\AppFabric 1.1 for Windows Server\Microsoft.ApplicationServer.InstallHelper.exe, command: powershell.exe "-command \"$str = [System.Environment]::GetEnvironmentVariable(\\\"PSModulePath\\\", [System.EnvironmentVariableTarget]::Machine); $str = $str+\\\";c:\Program Files\AppFabric 1.1 for Windows Server\PowershellModules\\\"; c:\Windows\system32\setx.exe /M PSModulePath \\\"$str\\\"\"" "C:\Users\Administrator\AppData\Local\Temp\AppServerSetup1_1_CustomActions(2012-11-11 06-57-20).log"
    MSI (s) (48:A0) [06:57:59:833]: Note: 1: 2265 2:  3: -2147287035
    MSI (s) (48:A0) [06:57:59:833]: User policy value 'DisableRollback' is 0
    MSI (s) (48:A0) [06:57:59:833]: Machine policy value 'DisableRollback' is 0
    Action ended 6:57:59: InstallFinalize. Return value 3.


    Sunday, November 11, 2012 2:29 PM
  • Thanks ! :-) 

    C:\Windows\system32\setx.exe /M PSModulePath \"$str\""

    Friday, April 12, 2013 1:11 PM
  • thank you Laxmi

    I had the same issue, I checked my PSModulePath in environment variable and found it ended with ( " ), I removed it and AppFabric installed successfully...

    I think this happen after I installed SQL Server 2012.

    Tuesday, August 05, 2014 1:03 PM
  • Thank you maberth,

    Due to your post I have resolved my problem during a re-install of AppFabric

    I have removed the "  in my PSModulePath variable , like you .

    But me It's after remove old instalation of Appfabric .

     


    Séverine Capon

    Friday, December 05, 2014 3:41 PM