Skip to content
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

E_CSC_SYSTEM_INTERNAL: Internal error! A procedure imported by 'ScopeEngineManaged.dll' could not be loaded. #66

Closed
jonstaten opened this issue Dec 22, 2016 · 28 comments

Comments

@jonstaten
Copy link

Hello,

After installing the latest version of the ADLA tool I am now receiving the following error when building the usql script.

Version: 2.2.4000.0
MSI: Microsoft.Azure.DataLakeToolsForVS2015.msi

E_CSC_SYSTEM_INTERNAL: Internal error! A procedure imported by 'ScopeEngineManaged.dll' could not be loaded.

Is there anything I can do to resolve this error?

I'm running on windows 7 with VS 2015.

Thanks

@yangyud-cn
Copy link

yangyud-cn commented Dec 29, 2016

Summarized the fix for Windows 7 as this:

  1. Please make sure you use 64-bits Windows 7
  2. Please make sure to update Windows with most recent patches
  3. Please make sure you have .Net Framework 4.5.1 or later
  4. please make sure you have VS 2015 updated 3 installed
  5. please make sure to install this UCRT update: https://www.microsoft.com/en-us/download/details.aspx?id=50410
  6. Please download the package here in a web browser: http://www.nuget.org/packages/Microsoft.Azure.DataLake.USQL.SDK/1.2.5169224
  7. Extract the contents to a folder using any unzip tool, like: C:\U-SQLSDK. You may need to change the file extension to "zip" to do that.
  8. Inside Visual Studio, click "Data Lake"-> "Options and Settings, then Change the Runtime Path to "c:\U-SQLSDK\build\runtime" and Click OK to save the settings.
  9. Build clean your existing projects
  10. Bring up Windows Task Manager, find all instances of "LocalRunHelper.exe", kill them.
  11. Build the project now.

@antonio-tortolero
Copy link

Hello yangyud-cn and jonstaten,

I have experienced the same issue under the same environment described by jonstaten, I have done the mentioned update and the same error still happens. The submission to the cloud to execute works fine. The issue is when trying to submit to (local).

Is there any other thing that I can do to run locally?

Thanks.

@d333wd
Copy link

d333wd commented Feb 27, 2017

Hello,

I am experiencing the same error condition described in this thread. I too have made sure that I have the 5 requirements as outlined by yangyud-cn, but I am still get this error when I attempt to create a database or table or resister an assembly locally. Help!
Thank you.

@yangyud-cn
Copy link

You will need the 64 bit version of vc runtime. Please choose
"vc_redist.x64.exe" from below and install.

https://www.microsoft.com/en-us/download/details.aspx?id=53587

And for none Windows 10 users, please also install the x64 version of UCRT here:

https://support.microsoft.com/en-us/help/2999226/update-for-universal-c-runtime-in-windows

@d333wd
Copy link

d333wd commented Mar 1, 2017 via email

@melpcollins
Copy link

I followed these instructions but received the same error. I have Window 7. It was working fine before I upgraded to 2.2.5000.0 this morning.
I have Microsoft Azure Tools for Microsoft Visual Studio 2015 - v2.9.41104.6 installed.

You will need the 64 bit version of vc runtime. Please choose
"vc_redist.x64.exe" from below and install.
https://www.microsoft.com/en-us/download/details.aspx?id=53587
And for none Windows 10 users, please also install the x64 version of UCRT here:
https://support.microsoft.com/en-us/help/2999226/update-for-universal-c-runtime-in-windows

@sqlaz
Copy link

sqlaz commented Mar 3, 2017

Getting a usql internal error. Thought I'd uninstall, and reinstall the ADL Tools for VS, and now the submit, local/remote option, DB nor schema dropdowns are no longer available. Using v2.2.5000.0 on VS 2015 Enterprise.

usql_internalerror

@yangyud-cn
Copy link

This looks to be a newly introduced dependency of some system API not available on Windows 7. We are still investigating this issue. As a temporary solution, you will need to downgrade the U-SQL SDK to a lower version.

  1. Please get the package here: http://www.nuget.org/packages/Microsoft.Azure.DataLake.USQL.SDK/1.2.5169224
  2. Extract the contents to a folder, like: C:\U-SQLSDK
  3. Inside Visual Studio, click "Data Lake"-> "Options and Settings, then Change the Runtime Path to "c:\U-SQLSDK\build\runtime" and Click OK to save the settings.
  4. Build clean your existing projects
  5. Bring up Windows Task Manager, find all instances of "LocalRunHelper.exe", kill them.
  6. Build the project now.

@melpcollins
Copy link

melpcollins commented Mar 6, 2017

This did fix the problem above as I can now submit a local job without error via Data Lake -> Submit Job
And can compile scripts.

Unfortunately the drop down menu's in USQL script are no longer present. And I see the message "Cannot start build task due to null compute account." Until after I submit the first job.
(I have RC of 2017 and drop down menus do where there so I might just start using that instead)

@yangyud-cn
Copy link

@melpcollins
What version of ADL Tools you are using? I didn't reproduce this issue with 2.2.5000.0. Also, please make sure VS 2015 is updated to Update 3 since there were some API changes in VS that were not available in the RTW version.

@sqlaz
Copy link

sqlaz commented Mar 7, 2017

I am using ADL Tools v2.2.5000.0, and VS 2015 has Update 3 installed.

usql_error
vs_update3

@sqlaz
Copy link

sqlaz commented Mar 7, 2017

One thing I noticed is that in the Project's references section, it came out as empty (no reference to any DLLs). Is this normal? I even created a new project, and still found the References empty. Uninstalled, and re-installed ADL tools v2.2.5000.0 a couple of times, and still the same outcome.

Would you be interested in checking any of my registry keys, or log files, or anything that might give a clue?

@melpcollins
Copy link

I have same as @sqlaz
Microsoft Azure Tools for Microsoft Visual Studio 2015 - v2.9.41104.6
and Microsoft Azure Data Lake Tools for Visual Studio 2.2.5000.0
and I've Update 3 also and .Net 4.6.01590

The downgrade solution you provided did work except I'm missing the drop down lists and get "Cannot start build task due to null compute account." in 2015. It works correctly with downgraded system in "2017 RC"

@yangyud-cn
Copy link

yangyud-cn commented Mar 8, 2017

@sqlaz, The references section is empty by default, This is expected. The root cause of the failure "ScopedEngineManaged.dll" is because in the newer versions of runtime, some newly added code refer to APIs not existing in Windows 7.

@melpcollins, I still can't reproduce the error. Could you please help to check the log here to see if there are issues related to this error ? You should be able to open the file and look for error messages there.

C:\Users\YOUR_ACCOUNT\AppData\Roaming\Microsoft\DataLake\log

Thanks a lot,
Yu Dong

@yangyud-cn
Copy link

yangyud-cn commented Mar 8, 2017

@melpcollins , regarding the issue, could you please try to reset the VS MEF cache by deleting the following folder before you start VS ? This can become corrupted and cause issues. It will recreate by VS automatically if you delete it.

C:\Users\YOUR_ACCOUNT\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache

@melpcollins
Copy link

Deleting ComponentModelCache brought back drop down menu's.

Logs show this:
KPI.Log.0
2017/03/08 08:28:23.172,"OsVersion=Microsoft Windows NT 6.1.7601 Service Pack 1",OsType=64bits,TraceVersion=1,ScopeStudioVersion=2.2.5000.0,Pid=59764,Tid=1,"Uid=domain\userName,","IPAddress=1.1.1.1",SQMVersion=1,RecordType=KPIOperation,Category=ScopeStudio,Key=Initailize,DRI=True,"Value=Package"

DataLake$$.svclog
did not find much in here.. lots of warnings.. No errors. Do you want me to Zip & email this to you or something?

capture

@itsjai
Copy link

itsjai commented Mar 8, 2017

I am also facing the same issue. I am trying to Create a Local U-SQL Database (Under Data Lake Analytics) using Server Explorer.

My OS is Windows 7 X64 with Visual Studio 2017 (RTM) installed. I was facing the same issue in Visual Studio 2013 also. I upgraded to Visual Studio 2017 today but the Issue Remains.

[Job Error]
E_CSC_SYSTEM_INTERNAL: Internal error! A procedure imported by 'ScopeEngineManaged.dll' could not be loaded.
========== Local execution failure ==========

@yangyud-cn
Copy link

@yangyud-cn
Copy link

@melpcollins , it's good to know that your problem is resolved. We don't need the logs in this case as it is a known issue of MEF cache corruption.

Thanks a lot,
Yu Dong

@melpcollins
Copy link

melpcollins commented Mar 9, 2017

@yangyud-cn Just to be clear. Everything works if I use the workaround of rolling back the version you suggested "Please get the package here: http://www.nuget.org/packages/Microsoft.Azure.DataLake.USQL.SDK/1.2.5169224"
The MEF cache corruption corrected the issue where I had no drop down lists on the USQL editor.

The latest version 2.2.5000.0 does not work on my machine. I always get 'ScopeEngineManaged.dll' could not be loaded with version 2.2.5000.0

@jonstaten
Copy link
Author

Hello, thanks for the response. I was able to rollback to the previous installed version and I can now compile and run USQL.

Thanks

@melpcollins
Copy link

Is there a plan to get the latest version of this working on Windows 7? Or will it just be fixed in 2.2.6000.0 ? ?

@ishepherd
Copy link

@yangyud-cn @MikeRys Hi guys. This bug here got closed. Are you working on a fix to get the ADLA tools working again on Windows 7? (Or will it be Win 10 only?) Cheers.

@yangyud-cn
Copy link

The failure is due to that some recent code made use of an ODBC32 API that is only available on Windows 8 or later. We understand that many users are still using Windows 7. However, it is also not feasible for us to revert back the change as that improvement is important for performance of related functions. I will update here once we have agreed on the solution.

@melpcollins
Copy link

@yangyud-cn you never did update this thread "once we have agreed on the solution"

@kmleow
Copy link

kmleow commented Jul 22, 2017

@yangyud-cn I hope that you can reconsider making it compatible with Windows 7

@yifungl
Copy link

yifungl commented Jul 28, 2017

This should now be working on Windows 7 for the current version 2.2.7000.3 and higher

@kotpal
Copy link

kotpal commented May 21, 2020

This issue is happened on Windows 10 as well. DependencyWalker shows that CRT is missing - but it is already installed.

image

What gives? What is the resolution?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests