I am creating a Windwos Installer project just for the use of installing our third party assemblies into the gac of the users computer. The problem i am running into, is when i make an update to the assemblie and increment it's version number, i get an error saying:
"Another version of this product is already installed. Installation of this version cannot continue..." I would have figured that windows installer would update the local machine with the new assemblie. Am i doing something wrong?
It sounds to me like you're updating the version number of the assemblies, and you're updating the version number of the MSI package, but you're not changing the ProductCode.
If you change the ProductCode, you will enable a "Major Upgrade", and this error message will go away.
If you don't change the ProductCode, then you'll need to run a command-line like:
msiexec.exe -i mymsifile.msi REINSTALL=ALL REINSTALLMODE=vomus
This is known as a "Minor Upgrade".
See the MSDN articles on Minor Upgrade and Major Upgrade for clarification.
Related
I've been working with AWS lambdas for a few months. I was working with a lambda and it was fine at the end of the day. I came back to work on it the next day, and I can't get Visual Studio to even start the application using the Mock Lambda Test Tool.
I ended up creating an empty lambda that just returns the input (the standard project code that AWS gives you as a template) and that won't even run. I hit the play button to star the Mock Lambda Test Tool, it looks like it will run for a couple seconds, then it closes down. The command window does not even pop up.
This is the code from the template project.
public string FunctionHandler(string input, ILambdaContext context)
{
return input?.ToUpper();
}
This is all I get in the output window of VS:
The target process exited without raising a CoreCLR started event.
Ensure that the target process is configured to use .NET Core. This
may be expected if the target process did not run on .NET Core. The
program '[16700] dotnet-lambda-test-tool-2.1.exe: Program Trace' has
exited with code 0 (0x0). The program '[16700]
dotnet-lambda-test-tool-2.1.exe' has exited with code -2147450726
(0x8000809a).
I have tried re-installing the AWS toolkit, and also tried re-installing Visual Studio. This is an issue with VS 2017 and VS 2019. I just installed 2019 to see if that would fix the issue. Any help would be appreciated.
I came to this question having the very same issue. After installing AWS Toolkit I found that the lambda test tool was not installed and therefore I got the same error just as the OP. The only difference is that I was targeting .Net Core 3.1 and therefore I needed amazon.lambda.testool-3.1. However this answer should work for both scenarios.
Unfortunately I did not have the same luck as the OP of having a nice co-worker that could give me the files I needed. So, if this is also your case please continue reading.
In the official project site, which can be found here, there are the instructions to install the tools. It also says that installing the latest version of AWS Toolkit should be enough to have the tools installed (it was not in my case and probably in yours).
It says that in order to install the tools you should run the following commands:
dotnet tool install -g Amazon.Lambda.TestTool-3.1
or
dotnet tool install -g Amazon.Lambda.TestTool-2.1
depending on which tool you need.
However, running these commands fails with the following message:
The tool package could not be restored.
Tool 'amazon.lambda.testtool-2.1' failed to install. This failure may have been caused by:
* You are attempting to install a preview release and did not use the --version option to specify the version.
* A package by this name was found, but it was not a .NET Core tool.
* The required NuGet feed cannot be accessed, perhaps because of an Internet connection problem.
* You mistyped the name of the tool.
For more reasons, including package naming enforcement, visit https://aka.ms/failure-installing-tool
And since the project is still in preview I just had to find the latest stable version in order to specify it in the command. For .net core 3.1 here is the nuget site, there I found version 0.10 to be the latest, so the command should look like:
dotnet tool install -g --version 0.10 Amazon.Lambda.TestTool-3.1
I have faced the same issue and when i tried to install dotnet-lambda-test-tool-3.1.exe using command prompt I got this issue:
Failed to create shell shim for tool 'amazon.lambda.testtool-3.1': Command 'dotnet-lambda-test-tool-3.1' conflicts with an existing command from another tool.
Tool 'amazon.lambda.testtool-3.1' failed to install.
And I did the following to fix issue
Deleted the dotnet-lamda-test-tool-3.1.exe from the installed folder (C:\Users%USERNAME%.dotnet\tools\dotnet-lambda-test-tool-3.1.exe)
Run dotnet tool install -g --version 0.10 Amazon.Lambda.TestTool-3.1 on cmd.
I have faced the same issue and got errors like "dotnet-lamda-test-tool-2.1.exe has exited with code.."
I did the following to fix the issue
Removed the dotnet-lamda-test-tool-2.1.exe from the installed folder
(C:\Users%USERNAME%.dotnet\tools\dotnet-lambda-test-tool-2.1.exe)
Removed the [amazon.lambda.testtool-2.1] folder as well
(C:\Users%USERNAME%.dotnet\tools\tools.store\amazon.lambda.testtool-2.1)
Installed dotnet tool from Developer command prompt using the command
[install -g Amazon.Lambda.TestTool-2.1]
Run the project. It is working
I have seen this issue many time on my system with dotnet-lambda-test-tool-6.0. Only one fix work for me
Remove dotnet-lambda-test-tool-6.0.exe from C:\Users\username.dotnet\tools
Open Command prompt from C:\Users\username.dotnet\tools
run command dotnet tool install -g Amazon.Lambda.TestTool-6.0
For anyone else that hits this same issue, it had to do with the the AWS toolkit install. I did not modify it, but somehow it was no longer working. I tried un-installing and re-installing, but it was still having issues running it. A co-worker sent me the exe and subdirectory that was setup on his machine under C:\Users\%user%.dotnet\tools. The exe is located in this directory, and there is another folder under .store for amazon.lambda.testtool-2.1. That directory had different folders and files than what I was able to install. So I copied in what he had and it worked. There might be a profile file associated to the tools install that points to these folders and files that might need to be modified. Since I was able to fix it with this, I didnt look any further into that.
I had the same issue with my .NET 6.0 lambda project. I installed the tool by executing dotnet tool install --global Amazon.Lambda.TestTool-6.0 --version 0.12.6 as suggested on https://www.nuget.org/packages/Amazon.Lambda.TestTool-6.0
Just ensure it is installed at %USERPROFILE%\.dotnet\tools\dotnet-lambda-test-tool-6.0.exe
I got the same issue with VS2019 with lambda design in 3.1 version and in Output window getting error
The target process exited without raising a CoreCLR started event. Ensure that the target process is configured to use .NET Core. This may be expected if the target process did not run on .NET Core.
Then checked the folder having multiple version of lambda-test-tool in path
C:\Users{username}.dotnet\tools
I removed all the lambda-test-tool and installed the required tool only with version 3.1 by command in developer command prompt:
dotnet tool install -g --version 0.10 Amazon.Lambda.TestTool-3.1
Then I can able to debug the lambda
Whenever I try to install the Visual Studio SDK I get the following error:
Windows Program Compatibility mode is on. Turn it off and then try Setup again.
I have checked and Compatibility mode is not turned on. From what I've read, renaming the installer to vssdk_full.exe should help. That hasn't had any impact.
I got the installer from Microsoft's website.
What do I need to do to get this to install?
Are you installing on Windows 10? If so, then I have the same problem and it seems as though the current SDK setup is checking the Windows version and 10 isn't currently supported. See https://social.technet.microsoft.com/Forums/en-US/77c61be0-1303-4040-a587-62843d321159/visual-studio-2013-sdk?forum=WinPreview2014General for more info
I have managed to get it to install on windows 10, download the sdk, it will download vssdk_full.exe, run this with /layout path which will extract the actual setup file.
Then set compatibility on the new file to win 8 and it will install just fine.
You might not need to do the/layout thing but that is what I did.
ed
I had the same problem. I downloaded .iso file with install package form the internet. Then I mounted it using PowerISO and tried to start it from virtual CD drive. It ended up in the same message as above.
I looked it up and thought that in Properties of .exe install file, it's enough to uncheck some boxes compability section. But nothing was checked.
Soon afterwards I unzipped the package to a temporary directory with PowerISO and installed Visual from there. Worked without problems.
I had this problem, I renamed the instalation file to "vssdk_full.exe" and it installed without problems.
From an admin prompt, I'm trying to install MSVC 2013 Express (Desktop):
cinst VisualStudioExpress2013WindowsDesktop
but its failing. Digging through the failure, I see that the installer returned exit code 3010. I'm not sure what this means, or why the Chocolatey script isn't handling it properly.
The full error output is in a gist here.
This is a standard error code that most Windows installation packages can issue (mode details can be found here).
Basically, this means that in order to install this package, you need to first reboot your machine. This is the same error message that you would get if you were to run the MSI/EXE yourself.
I suspect that what you did was to first install Chocolatey, and then immediately start installing packages. Due to the dependency of Chocolatey on the .Net Framework 4.0, immediately installing packages is not really advisable, as depending on the state of your machine, you are likely going to immediately need a reboot.
You should really install Chocolatey, reboot, and then start installing packages.
One thing that you have to remember is that Chocolatey is a Package Manager, it works with individual packages. It doesn't understand, and nor should it, the interaction of multiple packages. As a result, it doesn't know about the requirements of reboots, it simply installs the package.
There are other tools, like Boxstarter, that provide functionality to detect whether a reboot is required, and this handles that requirement.
I haven't seen this problem when browsing the web, so here it is:
I used the .msi file (vs. right click -> Install, option on the setup project) to install "Version 1.0.7" product onto my computer.
I then changed my "Version" to 1.0.8 , and all projects Assembly Version/AssemblyFileVersion properties to 1.0.8.0. I deleted the old Primary Output, and added a new one where I made sure the version was correct under the KeyOutput expanded list. I did this because it didn't update after I changed all Assembly Versions to 1.0.8.0, and it stayed at 1.0.7.0 (the previous version).
I built my Setup project and went to my folder that contained the new 1.0.8 .msi file. I double-clicked and got the "Application already exists, remove existing in Add/Remove Programs" (or similar) dialog, and it stopped installation.
So I checked my: ProductCode-they were the same between new/old versions, UpgradeCode-also the same, RemovePreviousVersion property-set to True between both versions. This is what I checked because I usually found as a solution in all my other searches, but it wasn't working.
So I unistalled the 1.0.7 version, installed 1.0.8 and all worked fine. Still didn't fix my problem where I shouldn't get the unistall first prompt. Note: I've been installing on "Everyone".
I unistalled 1.0.8 again (at this point, no versions exist/are installed), and tried this:
1. Install 1.0.7 from .msi file or Install 1.0.7 by right clicking it's setup project and using the "Install" option.
2. Right clicked 1.0.8 setup project and used the Install option from there.
3. No errors/dialogs pop up, the old version seems to have been unistalled first, then I continued with installation and new version was on the computer. This is what I want!
As you can see here, I need to beable to use 1.0.7 .msi file to install, then when I need to patch/fix/update, I need to be able to 1.0.8 .msi to not display a "Already exists" prompt and just overwrite/merge, but this isn't happening unless I use VS2010 Right Click>Install on the Setup project.
Any help is appreciated.
edit added bolding
Change the ProductCode between the two versions. Read more on major upgrades
Installing a minor upgrade (which is the case when you change the ProductVersion but not ProductCode) requires specifying REINSTALL if and only if a previous version is present on the machine. There are ways to do this for explorer-launched scenarios by specifying it in the Property table and clearing it with a custom action, but it's much more common to handle it with a launcher or by using a major upgrade.
If setup is installed on machine and if I try to install it again on the same machine than it exits installation with the message "Already installed". In this case, what I want is that if application is already installed then the installer will repair it.
How can we do this?
If the installation is actually broken (like a file is missing) then when you re-run the installer it should give you the repair option. Otherwise, if it thinks the installation is normal then it will say it's already installed.
I think there's always a repair option in the add/remove program entry. However, that won't work if your install files were in a temp location and are now gone.