locked
Visual Studio 2010 Profiler Error VSP1398 RRS feed

  • Question

  • Hi there,

    I am trying to profile my code using Visual Studio 2010 Premium on Windows 8 Pro.

    Every time I try and start the profiler it seems to be blocked from loading (Error VSP1398). Every time it is ran it asks me to upgrade my credentials in order to start it...

    I have tried running VS as Admin and also tried adding my user name to /Admin:security,FullAcccess

    I have also tried uninstalling the Profiler and reinstalling it from the stand alone directory of the DVD

    It seems I can start the profiler from an elevated command line no problem, but VS seems to have trouble getting it to start...

    If you need any more info, let me know.

    Many Thanks,


    Dave

    Below is the what is displayed in the output window in VS:

    Error VSP1398: The monitor was unable to start the VS performance driver.  Access is denied. Consider using the /Admin:Driver,Start and /Admin:Security options of VSPerfCmd from an elevated environment.  Profiling cannot continue.
    Error VSP1341: Could not start logging engine.  Shutting down.
    Profiling finished.
    PRF0010: Launch Aborted - Unable to start vsperfmon.exe

    • Edited by DMcB Tuesday, November 6, 2012 8:19 PM
    Monday, November 5, 2012 11:58 PM

All replies

  • Hi DMcB,

    Thank you for posting in the MSDN forum.

    Which specific app are you profiling? Whether all projects have the same issue? For example, if you create a simple app, does it work well?

    As you said that it worked well when you run it in the command line, but it doesn’t work in the VS IDE with the admin, if so, I suggest you try to change the Platform target or the Target framework, check it again. To make sure that it isn’t related to the VS, I suggest you profile it in other machine, does it work well? If possible, please install the VS2010 sp1.

    Error VSP1398 : The monitor was unable to install the VS performance driver. The system cannot find the file specified. Consider using the /Admin: Driver,Install option of VSPerfCmd from an elevated environment. Profiling cannot continue.

    In addition, whether it worked well before? I doubt that it is related to the installing like this blog. So you would make sure that you download the correct version, please download it from here:

    http://www.microsoft.com/en-us/download/details.aspx?id=23205

    Actually, I just find this issue in the VS2008 like this document, it seems that it has been resolved in the VS2010 version. If still no help, to repro this issue, I suggest you share us a simple app, I will try to profile it in my machine. Thanks for your understanding.

    Best Regards,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Wednesday, November 7, 2012 6:04 AM
    Moderator
  • Hi Jack,

    I've removed my old versions of Performance Tools and installed the one from the link you gave me, still the same problem.

    I even tried it running with the basic WPF Application that is generated when you create a new project, and i've also tested it running with just a plain for loop that incremements a variable from 0 to 10,000, but the profiler still doesn't seem to work inside VS.

    The original app that I am trying to profile is XNA/Kinect based if thats any help, I've also tested it out on another computer at University and the profiler starts, runs, but then fails to load a bunch of symbols and crashes VS when you exit the application (I presume this is when it is generating some sort of report on the profiling).

    On my home computer the profiler still won't start though :(

    Thanks,

    Dave

    EDIT: Starting the driver now doesn't seem to work either (from an Administrator cmd.exe):

    C:\Windows\system32>vsperfcmd /Admin:Driver,Start
    Microsoft (R) VSPerf Command Version 10.0.40219 x86
    Copyright (C) Microsoft Corp. All rights reserved.
    
    Driver,Start
    
    Starting VSPerfDrv100Error VSP1449: Unable to start VSPerfDrv100. This driver has been blocked from loading
    Try using the /Admin switch of VSPerfCmd from an elevated environment.



    • Edited by DMcB Thursday, November 8, 2012 3:46 PM
    Thursday, November 8, 2012 1:31 PM
  • Hi, I`m having the same problem with the profiler.

    On my Windows 8 machine both Visual studio 2010 and 2012 are installed, with 2012 the profiler works, with 2010 the profiler driver fails to start with same errors as above.


    Friday, November 9, 2012 1:57 AM
  • Hi DMcB,

    Glad to receive your reply.

    I've also tested it out on another computer at University and the profiler starts, runs, but then fails to load a bunch of symbols and crashes VS when you exit the application

    If possible, I suggest you try to debug your app, and check whether you could get any message in the Output window. If it couldn’t load symbols, I suggest you try to load symbol file manually. You can select Debug -> Windows -> Modules, on the Modules window, right click the symbol item, and select Load Symbols. For detailed information, see “How to: Use a Symbol Server”. Hope it could help.

    Since I couldn’t repro this issue, if still no help, I suggest you share us a simple sample, I will try to profile it in my machine.

    Please also attach your Visual Studio project, you can upload it to the sky driver, and then share the download link in your post.

    Have a nice weekend,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Friday, November 9, 2012 6:25 AM
    Moderator
  • Jack,

    I really think this is some sort of UAC type issue outside of visual studio to be honest.

    I just tried to uninstall and reinstall the driver using vsperfcmd:

    C:\Windows\system32>vsperfcmd /Admin:driver,uninstall
    Microsoft (R) VSPerf Command Version 10.0.40219 x86
    Copyright (C) Microsoft Corp. All rights reserved.
    
    
    
    driver,uninstall
    
    Uninstalling VSPerfDrv100
    VSPerfDrv100 uninstalled
    
    C:\Windows\system32>vsperfcmd /Admin:driver,install
    Microsoft (R) VSPerf Command Version 10.0.40219 x86
    Copyright (C) Microsoft Corp. All rights reserved.
    
    
    
    driver,install
    
    Installing VSPerfDrv100
    VSPerfDrv100 installed

    As soon as the install command finished, I was presented with a Program Compatibility Assistant popup that says that VSPerf Profiling Control Driver cannot be used due to compatibility issues.

    Could this be whats preventing it from starting?

    I no longer think this is a Visual Studio issue, as I can't start the driver from an elevated command prompt.

    As for the a simple sample project, even one of the generated WPF projects don't profile. I've created the most simple project i could think of and uploaded it to SkyDrive here: 

    https://skydrive.live.com/redir?resid=5E29559879071961!196&authkey=!ABthmddCuCYQNAQ

    Many Thanks,

    Dave

    Friday, November 9, 2012 3:18 PM
  • Hi Dave,

    Glad to receive your reply.

    I try to profile it in my VS2010 in my Environment, and I could get the following information.

    The original app that I am trying to profile is XNA/Kinect based if thats any help, I've also tested it out on another computer at University and the profiler starts, runs, but then fails to load a bunch of symbols and crashes VS when you exit the application (I presume this is when it is generating some sort of report on the profiling).

    Of course, I just profile it in my window 7 Environment, but as you said that it worked well in other machine, I’m afraid that it is related to your Environment. Maybe you could try to run your VS in SafeMode and check it.

    Use the following command line options, check it again.

    Devenv.exe /ResetSettings: Restores the IDE's default settings, optionally resets to the specified VSSettings file.

    Devenv.exe /ResetAddin: Removes commands and command UI associated with the specified Add-in.

    Devenv.exe /ResetSkipPkgs: Clears all SkipLoading tags added to VSPackages.

    If still no help, how about re-installing the VS? In addition, you would check whether you installed any third party tool. Close other processes like the firewall or the anti-virus software. Check it again.

    Best Regards,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Monday, November 12, 2012 6:18 AM
    Moderator
  • Jack,

    Still nothing on my Windows 8 Machine, tried the devenv.exe /Reset commands, and also tried running devenv in safe mode, it still won't start the profiler.

    On a plus note, I can now profile my application on Windows 7 workstation at University, so I guess that'll have to do for now.

    I've tried various re-installs of the profiler, disabling Windows firewall etc to no avail.

    I'll have a go reinstalling Visual Studio in the next day or so and let you know if it works :)

    Thanks for your help,

    Dave McB

    Monday, November 12, 2012 8:16 PM
  • Hi Dave,

    I'll have a go reinstalling Visual Studio in the next day or so and let you know if it works :)

    I look forward to hearing from you.

    In addition, I try to profile your app in the window 8 Environment, it still worked well. If re-installing the VS couldn't resolve this issue, I’m afraid that it is related to your Environment.

    Have a nice day,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Tuesday, November 13, 2012 3:15 AM
    Moderator
  • Jack,

    there has to be something else.  I am also running Win8, VS2010 as Admin and having the identical problem as Dave.

    With just a blank WinForm project the profiler will not start.

    If you're logged on to Win8 with Admin rights you might not be seeing the problem.

    There seems to be a growing number of people having this problem that goes beyond default environment settings for Win or VS.

    Both my OS and VS are fresh, default installations.

    Apparently, Elevated Rights is insufficient for whatever process is trying start.

    -Bob

    Thursday, November 15, 2012 2:49 PM
  • Jack,

    Fresh install of Visual Studio 2010, (not yet updated to SP1 as far as i can see).  When I run the profiler on the SImpleProfiling Project from SkyDrive it stops working and I am presented with the option to launch the Just In Time Debugger.  Upon launching the debugger I am presented with:

    "A buffer overrun has occurred in VSPerfCmd.exe which has corrupted the program's internal state. Press Break to debug the program or Continue to terminate the program.

    For more details please see Help topic 'How to debug Buffer Overrun Issues'."

    Is this related to me having not updated to SP1? Easy enough to update and try again...

    Have to be inclined to agree a bit with Bob, the process is getting blocked from starting by something somewhere.

    Should I update to SP1?

    Many Thanks,

    Dave

    Thursday, November 15, 2012 10:09 PM
  • Hi Dave,

    Sorry for my reply no help.

    Since I couldn’t repro this issue, to help you resolve this issue, I’m afraid these questions require a more in-depth level of support. I suggest you visit the following link to see the various paid support options that are available to better meet your needs.http://support.microsoft.com/default.aspx?id=fh;en-us;offerprophone, thanks for your understanding.

    Have a nice weekend,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Friday, November 16, 2012 4:42 AM
    Moderator
  • Hi Dave,

    Sorry for any inconvenience.

    Actually we try to repro this issue in the same Environment , and it worked normally. So I doubt that it is related to your VS installing, but it seems that re-installing the VS couldn’t help. If possible, you could try to clean your machine and check it. But if still no help, I’m afraid that it will require a more in-depth level of support.

    Since the product team itself no longer directly accepting feedback for Microsoft Visual Studio 2010. To help you resolve this issue, so I suggest you visited the various paid support options. Thanks for your understanding.

    Sincerely,


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us

    Monday, November 26, 2012 9:18 AM
    Moderator
  • Hello,

    I just installed VS2010 and the Program Compatibility Assistant message box popped up with the following:

    "This driver cannot be used due to compatibility issues.  VSPerf Profiling Control Driver".  

    Here's a sequence of events that may be relevant:

    1.  Upgraded machine from Win 7 to Win 8 Professional.

    2.  Used my outlook.com account for most of my logins, including remote desktop.

    3.  Installed VS2012 without a problem.

    4.  While logged in with Remote Desktop, I installed VS2010.  Error message occurred.  

    I've done little else to this machine other than move some tiles around, create a different background for desktop mode, etc.  To be fair, this was an upgrade from Win 7 (I think it was pro - can't remember.)  It had minimal stuff on it.  I don't believe it had anything significant like VS or SQL or anything like that.  I was essentially using it as a backup server.

    Tuesday, November 27, 2012 4:10 PM
  • Just FYI I solved this by figuring out where the service is exactly located using this command:
    sc qc VSPerfDrv100

    Once it told me the file location, I made sure the current user had permissions to the entire folder structure. 

    That fixed it.

    Thursday, November 29, 2012 6:16 PM
  • Hi Mickey, can you please describe exactly what you did?

    sc qc VSPerfDrv100 gave me the path "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Performance Tools\x64\VSPerfDrv100.sys" so I've added myself to the list of users of that folder with full access rights, but I already had administrator rights for that account and this didn't help. I also tried to turn UAC off; to run VS2010 "as administrator"; to start VSPerfMon from cmd runned "as administrator" with /Admin switch and nothing of this helped so far. 

     I suppose this problem has something to do with user rights/UAC but using account with administrator rights doesn't help.
    Sunday, December 2, 2012 7:07 PM