New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vswhere hangs on Windows 2008 R2 #87
Comments
Probably not the same as #72 since it sounds like you're using released versions. I'll see if I can repro this on a VM, but it would help if you uploaded a dump of the hung process. However, I will point out that Visual Studio 2017 is not supported on Windows Server 2008 R2. See the System Requirement, so that query would never find anything anyway. If you were searching for the Build Tools 2017 (which are supported on 2008 R2 SP1, you will need to add |
I'll take a look at the requirements. When it does run, it does find it.
|
I am not familiar with dumping hung processes. If you can point me to a howto, I'd be glad to provide one. |
Assuming Visual Studio 2017 even runs on 2008 R2 (it's not supported),
|
It works like a champ. Here is the dump: |
There's a deadlock in the loader:
These seems enough like #72 to make me wonder if our CI build is uses the wrong CRT. We may have to hardcode it in the vcxproj project. |
@randellhodges can you verify that vswhere.exe in https://ci.appveyor.com/api/buildjobs/srdnp2g8g5a504b1/artifacts/bin%2FRelease.zip works for you? |
Sadly, it eventually hangs. The first loop of 100 worked fine. I changed it to go up to 1000 and a few dozen runs into it, it hung. I tried the recommendation over on the linked issue. I am not a C++ developer but I went ahead and grabbed the master version, installed C++ and pulled down the 10.0.14393.0 SDK and tried. It too hung. |
Just in case it's different, can you take and upload another dump? I'm working with the Visual C++ team to determine why this seemingly known issue in an older UCRT is not fixed by the rebuild. |
In order to see if the problem is fixed, I really need you to try https://ci.appveyor.com/api/buildjobs/srdnp2g8g5a504b1/artifacts/bin%2FRelease.zip. I don't build an official, recommended version until we know a bug is fixed. |
Is that not the same one I posted the dump for 3 days ago? The post right above it that says "new dump"? Or did I dump the wrong version or something? |
You said you tested on the version from "master". That's not the fixed version. |
The first dump The second dump (which I said New Dump) Maybe I should not have said "New Dump". |
You said,
That doesn't sound like you used the built binary which contains the fix that should prevent the deadlock. The new dump you provided does not contain the symbol while the EXE does. |
I had many more comments after that. Let's just chalk it up to a misunderstanding and move on. I guess that last dump I provided was not against the correct version. My apologies. I thought it was against the one you requested. I am confident that I have now tested the correct one and, while it took a while longer to hang, it still eventually hung. Here is the dump you requested: |
We believe we have identified the problem but cannot reproduce it. Please extra the contents (at least the DLL, but should symbols be necessary the PDB as well) of https://1drv.ms/u/s!AjCAGrsc9hWUgZiMIeKFXZBzVRXdrZI to |
@heaths Sorry, I still got the hang. I tried it against both v2.0.2 and the appveyor build you had me try. Here is a the latest dump: Sometimes I could get it to run 100 fine but then the next time I tried 100 it would hang. If I increase it to 1000, on my machine, no version would ever get thru a 1000 run loop. Anything else I can provide for you? |
I sincerely apologize. I gave you the wrong file that did not include the fix. Please do the same with https://1drv.ms/u/s!AjCAGrsc9hWUgZiMIeKFXZBzVRXdrZI (same link - just replaced the binaries). |
Good news, the latest ones seem to solve the issue! I did multiple loops of 1000 and not a single hang! |
Thank you for the help! Unfortunately, this is a problem in the DLL (as you probably noticed) that ships with Visual Studio 2017 and will be in the next update after Visual Studio 2017 version 15.3 ships, i.e. Visual Studio 2017 version 15.4 preview. We're in final testing for version 15.3 and with a single report of this deadlock it doesn't meet the bar. But if this is blocking you currently, you're welcome to use those private bits which will be replaced by the official build version when released. |
Just had this same issue with VS2017 15.8.3 and VS2015 installed, combined with the latest VSTS packaged version of the build agent (2.140.0, vswhere v1.0.62) plus an updated vswhere (2.5.2). Only thing that would fix it was the patched version of the DLL above (previously had 1.17.1230). Thanks for keeping the download available. And +1 to the reports :) |
Which version of vswhere were you running? A newer, 2.x version against any DLL version 1.13 or newer that we released shouldn't repro this. Both binaries had to be recompiled against a new UCRT. |
I believe all this information was in my original comment, however, putting it another way... Initially I was using vswhere v1.0.62, then having done some research, updated vswhere to 2.5.2, which had the same issue. It was only by downloading an updating the patched DLL that I was able to fix the issue. Previously I'd had version 1.17.1230. |
You said,
Which one were you running? You list at least two locations of vswhere that are different versions. The "patched DLL" is older - I figured the deadlock in the COM server DLL long before 1.17, but it also required a change to vswhere. The two must go together. So a 1.0 version of vswhere - if you were running the build agent one - could be the problem. If using a 2.0 version with 1.17, I'd need to see a minidump or at least the stack to confirm it's somehow the same issue, or a new one. |
Yes, I mentioned multiple versions because it failed with both (i.e. I tried running both), and I tried to give a hint of why I'd tried the different versions (normally more information is better than less?) In short, the 1.0 version failed, which it sounds like you would have expected and which was what made me try a later version. I then tried 2.5.2, which still failed. |
The patched version is older and does not support many things on which VS and partner applications depend. By not helping to identify why a similar behavior still occurs on your system (the original problem was a deadlock in the CRT), this system is made brittle for everyone. At the very least, your system does not have the required version for all features to work correctly and will subsequently get updated at some later date when we add more features to the query API on which new VS features may depend. |
I first reported my issues over on vsts-agent, but I'm fairly sure it belongs here.
microsoft/azure-pipelines-agent#1090
Windows 2008 R2 server with the latest windows updates.
for /L %n in (1,1,100) do "vswhere.exe" -version [15.0,15.1) -latest -format json
If I run this, it will eventually hang. I might have to run that a couple times, but on my machine I can always get it to hang.
I ran it a few times on a Windows 2016 server and I never got a hang.
I tried v1.0.62 and v2.0.2
The text was updated successfully, but these errors were encountered: