15

Approx. once or twice a day, after working for several hours with an instance of Visual Studio 2015, the application hangs when performing a file operation (like rename or delete).

This well-known message appears:

Microsoft Visual Studio is busy…

Then only solution I found so far is to kill the process via Task Manager.

When starting Visual Studio again, In most of the cases the file operation was actually performed before the hang.

For the next few hours, all file operations work again.

My question

Any idea on how to narrow this down and ideally solve it?

Extensions

Some of the extensions I've installed are:

  • ReSharper 9
  • Visual SVN
  • Web Essentials 2015

Too broad

I've found similar questions (like this) for previous versions of Visual Studio that were closed as too broad.

I've decided to still ask my question since I've found no questions specific to the 2015 version. Maybe there are better ways to find the reason for the behaviour in this version?

Community
  • 1
  • 1
Uwe Keim
  • 39,551
  • 56
  • 175
  • 291
  • 1
    One possiblility is a ReSharper memory leak. Try enabling monitoring of memory usage for ReSharper. ReSharper -> Options -> Environment (General) -> Check "Show managed memory usage in status bar". Now the memory usage will display in the bottom right hand corner of Visual Studio. More importantly, you can actually right click on it and select "Collect Garbage" to free up some of that memory. – alan Oct 08 '15 at 12:34
  • 1
    Install this update: https://support.microsoft.com/en-us/kb/3093266 which includes a GC fix – magicandre1981 Oct 08 '15 at 15:35
  • @magicandre1981 I'm on the "Fast Ring". So I've already got that update. – Uwe Keim Oct 08 '15 at 18:02
  • try the R#10 EAP and look if this makes VS faster. If this also doesn't help, create a dump (process explorer) of the hanging devenv.exe, open it in Windbg, fix symbols (http://stackoverflow.com/a/30019890/1466046), and run **!analyze -v -hang** or load the dmp in DebugDiag Analyzer. Does this show you where VS hangs? – magicandre1981 Oct 09 '15 at 04:07
  • 2
    an update on this? Have you looked at the hang dump? – magicandre1981 Oct 14 '15 at 04:02
  • where able to solve it? – magicandre1981 Oct 24 '15 at 05:52
  • have you captured a dump during the freeze? have you analyzed the dump? – magicandre1981 Oct 24 '15 at 06:08
  • have you tried the RC of the update 1 for VS2015? – magicandre1981 Nov 01 '15 at 06:50
  • 1
    the tech support from ms said it should be fixed in RTM Update 1 VS2015. Its because this bug:https://github.com/dotnet/roslyn/pull/6154 – EnemyArea Nov 20 '15 at 14:07
  • Have you tried the VS2015 Update 1? Was this issues solved? – magicandre1981 Dec 01 '15 at 05:53
  • @magicandre1981 Just downloading from [this URL](https://www.visualstudio.com/en-us/news/vs2015-update1-vs.aspx). Thanks for your info! – Uwe Keim Dec 01 '15 at 08:00
  • 1
    have you finished installation of the update1? does it fix your issue or not? – magicandre1981 Dec 04 '15 at 05:17
  • @magicandre1981 I'll have to wait a few days to see whether it still occurs or not. – Uwe Keim Dec 04 '15 at 07:23
  • Just stepped into another hang. So my conclusion ist: Update 1 did _not_ fix this for me. – Uwe Keim Dec 04 '15 at 10:10
  • contact the Microsoft support for an more detailed help – magicandre1981 Dec 05 '15 at 07:11
  • 1
    Same issue here. Any luck solving it? – Chris Hynes Jan 27 '16 at 13:37
  • 2
    This is really annoying issue. I do NOT have Resharper or Visual SVN or Web Essentials. Its not an extension issue I think. – user99999991 Jul 16 '16 at 00:18
  • 1
    Good question but no answer. – Ali.Rashidi Jan 15 '17 at 11:12
  • I've had this same issue with no fancy extensions beyond the python stuff. – Pharap May 02 '17 at 08:22
  • 1
    I disabled reshaper with Tools -> Options -> Reshaper Ultimate -> General -> Disable (while moving around files - It seemed to help greatly!) Was previously talking 15s+ to move a file. I then reabled reshaper and tried to move a file. Again it is taking 15s+ – Tom May 19 '17 at 17:25

3 Answers3

2

I've had the same issues over many years on my home laptop, which is pretty old and under-powered.

In the office on several different much more powerfull PCs, whilst working on the same solution with the same version of VS the problem rarely happens. I'm consistently performing the same actions at home and at work.

There's no additional s/w running on my laptop, in fact I even disabled most VS extensions, and my AV software, to no avail.

Whilst hardly a scientific answer, I am convinced my issues are simply caused by a well under-powered machine, which I've been too lazy to upgrade given I've got access to powerful machines in my day job.

So if your machine isn't an especially high spec one, I'd suggest trying one that is, if for no other reason than ruling that out.

Greg Trevellick
  • 1,361
  • 1
  • 16
  • 26
  • I think there are multiple sources of this problem. This just started occurring for me on a PC which for years never before had the issue. – StayOnTarget Feb 26 '20 at 14:06
2

If you are using Reshaper and moving files is taking a long time.

Do this before you move a file:

Tools → Options → Reshaper Ultimate → General → Suspend Now

I assign the Reshaper_ToggleSuspended to keyboard shortcut Ctrl+Shift+Alt+S to allow quick Suspending + Resuming.

Then resume after you are done to get the nice Reshaper features back...

Uwe Keim
  • 39,551
  • 56
  • 175
  • 291
Tom
  • 6,325
  • 4
  • 31
  • 55
1

If you are working in a WPF project, it might also be a problem with one of the XDesProc processes. When this happens to me, I kill all of those processes, and that unlocks things.

GordoFabulous
  • 195
  • 2
  • 12