Some users may be experiencing issues when trying to access customer resources like the Case Portal or the Product Licensing Center. Our team is aware of the issue and is working to resolve it. Click here for more information.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Azure connector - Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.

Hi there,

I'm currently facing the following issue after I implemented the Azure Connector based on the documentation. I'm running 2021R1 and I have all hotfixes installed. I already installed the Azure.Core version 1.14 package manually, but it didn't solve the problem. I already tested the PS commands manually and I can connect to Azure to fetch the data needed.

2021-10-12 20:00:26,608 [INFO ] Running Compliance import with "-us false -processremotepackages true -importtype Readers -s AzureVMsWSATenant" parameters
2021-10-12 20:00:30,608 [INFO ] Reading 'ActiveDirectory' data from 'Azure Virtual Machines WSA Tenant' (ver 1.0) data source
2021-10-12 20:00:30,608 [INFO ] Reading data for 'ActiveDirectory' successfully processed in 0 seconds.
2021-10-12 20:00:30,686 [INFO ] Released application lock Reader_fe56bd38-9de7-4510-9977-611d0fe31890_ActiveDirectory_ALL
2021-10-12 20:00:30,686 [INFO ] Reading 'Computer' data from 'Azure Virtual Machines WSA Tenant' (ver 1.0) data source
2021-10-12 20:00:30,686 [INFO ] Reading data for 'Computer' successfully processed in 0 seconds.
2021-10-12 20:00:30,686 [INFO ] Released application lock Reader_fe56bd38-9de7-4510-9977-611d0fe31890_Computer_ALL
2021-10-12 20:00:30,686 [INFO ] Reading 'VirtualMachine' data from 'Azure Virtual Machines WSA Tenant' (ver 1.0) data source
2021-10-12 20:00:30,686 [INFO ] Get Azure VM Instances (Transfer data from source 'Azure Virtual Machines WSA Tenant' to FNMP)
2021-10-12 20:00:30,920 [INFO ] #ObjectModel_CloudServiceInstance_GetAzureVMInstances
2021-10-12 20:00:30,951 [WARN ] Warning! The maximum key length is 900 bytes. The index 'CK_#ObjectModel_CloudServiceInstance_GetAzureVMInstances' has maximum length of 1824 bytes. For some combination of large values, the insert/update operation will fail.
2021-10-12 20:00:47,092 [INFO ] Failed to execute Reader 'Get Azure VM Instances' from file C:\ProgramData\Flexera Software\Compliance\ImportProcedures\Inventory\Reader\microsoft azure\Instance.xml, at step line 1
Error: Please review the error message and correct the issue, then try again:
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
2021-10-12 20:00:47,092 [INFO ] All retries have been attempted for Reader 'Get Azure VM Instances'
2021-10-12 20:00:47,092 [INFO ] Completed with error in 16 seconds.
2021-10-12 20:00:47,092 [INFO ] Released application lock Reader_fe56bd38-9de7-4510-9977-611d0fe31890_VirtualMachine_ALL
2021-10-12 20:00:47,092 [ERROR] System.Management.Automation.RuntimeException: Please review the error message and correct the issue, then try again:
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
---> System.Management.Automation.RuntimeException: Please review the error message and correct the issue, then try again:
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
--- End of inner exception stack trace ---
at ManageSoft.Compliance.Importer.Logic.PowerShellDataReader.Read()
at System.Data.SqlClient.SqlBulkCopy.ReadFromRowSourceAsync(CancellationToken cts)
at System.Data.SqlClient.SqlBulkCopy.WriteToServerInternalAsync(CancellationToken ctoken)
at System.Data.SqlClient.SqlBulkCopy.WriteRowSourceToServerAsync(Int32 columnCount, CancellationToken ctoken)
at System.Data.SqlClient.SqlBulkCopy.WriteToServer(IDataReader reader)
at ManageSoft.Compliance.Importer.Logic.DatabaseConnection.LoadData(IDataReader p_DataReader, String p_TableName, Int32 p_BatchSize, Boolean p_ExplicitColumns)
at ManageSoft.Compliance.Importer.Logic.XML.SourceToTarget.ExecuteReader(IExecutionContext context, ISourceConnection sourceConn, IDataReader reader)
at ManageSoft.Compliance.Importer.Logic.PublicObjectModel.SourceToImportedTableObject.ExecuteReader(IValidatingDataReader reader, SourceToObject STOObject)
at ManageSoft.Compliance.Importer.Logic.PublicObjectModel.SourceToObjectImplementation.ExecuteImplementationSQL(IExecutionContext context, SourceToObject sourceToObject)
at ManageSoft.Compliance.Importer.Logic.XML.Reader.Execute(IExecutionContext context)
at ManageSoft.Compliance.Importer.Logic.ActionExecuter.ReaderExecuter.ExecuteSingleReader(Reader reader, Int32 procedureOrder, Version sourceDatabaseVersion)
at ManageSoft.Compliance.Importer.Logic.ActionExecuter.ReaderExecuter.Execute()
at ManageSoft.Compliance.Importer.Logic.ComplianceImporter.ProcessExecution(ComplianceReader p_ComplianceReader, Tenant p_Tenant, IExecutionContext p_Context)

During my Google research I found a couple of articles stating that I might have to add the following line to a .NET config file, but I couldn't find that file:

<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>

Could not load file or assembly 'Azure.Core, Version=1.0.2.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified. · Issue #16095 · Azure/azure-sdk-for-net · GitHub

Does anyone got this error as well and found a solution?

Thx

Jules

(23) Replies

Hi

 

Is your beacon services are running as Local system or using some service account.

Hi, It's using a service account that has admin permissions on the server.

Just tested with local system, but I get the same error

Hi

Can you confirm below 

 

  • PowerShell 5.1 or later is running on Windows Server 2008 R2 SP1 or later, or Windows 7 SP1 or later; with the PowerShell execution policy set to RemoteSigned.
  • Install .NET Framework 4.7.2 or later (installation instructions and downloads start from https://docs.microsoft.com/en-us/dotnet/framework/install/).
  • Ensure that the Windows Environment Variable PSModulePath includes the following path:
  • %ProgramFiles%\WindowsPowerShell\Modules
  • The FlexNet Beacon software installed on the inventory beacon must be release 17.1.0 (shipped with FlexNet Manager Suite 2021 R1) or later.
  • A web browser is installed and enabled on the inventory beacon.
  • You must log onto the inventory beacon, and run FlexNet Beacon, using an account with administrator privileges.
  • Install the Microsoft Az module, version 6.1.0 or later. Instructions are included in the process below

 

  • Install Microsoft Azure Resource Graph module version 0.11 or later (remembering that this requires Microsoft Az for Windows PowerShell version 6.1.0 or later, as mentioned above). Instructions are included below. Flexera recommends that you install this as it optimizes performance, especially for large-scale implementations in Azure.
 

Yes, please see attached

It seems, During installation of Azure connector, there are some files are missing , due to this , we are getting this error. Are you doing manually installation of module or its getting direct required file from internet. Can you remove everything & try to reinstall & monitor no error during installation.

I installed the modules via the install-module command. I'll uninstall all az & az.* modules again, reinstall it and let you know the result

I removed all the modules from x64 and x86 bit PS.

This time, I downloaded the Az nuget package version 6.4.0, extracted it to the modules directory and installed the az.resourcegraph module.

Unfortuntely I receive exactly the same error.

I will now test it with the AzureRM modules instead of the new Az ones

It does work with AzureRM. However, I don't get VMs or SQL VMs inventoried even though my registered application has VM and SQL read access at the root management group level and can list all subscriptions, but that's another story.

EDIT: looks like I was wrong. Even though the task shows "Devices read from source: 0" in the staging part, it does show 164 devices in the mport inventory devices part

That's great. At least one issue got solve & we know the reason. 

 

 

Unfortuntenaly it looks like that there is still an issue even though the import was successful in the task overveiew.

I don't get any Azure Hybrid Information imported, which is the most relevant information I need. Is there maybe any guide how to troubleshoot this easily. I already started using the commands from PS script of the Azure VM reader, but it still puzzles me which function to execute in which order 🙂

The connector to Azure is only a part of a complete "bring your own software license", or BYOSL management strategy for
instances (typically, virtual machines that are tracked as inventory devices) that are hosted for you by this cloud service
provider. By itself, the connector does not gather sufficient data to allow for license management: for example, it does not
gather software inventory for the applications that are running on your cloud-hosted devices.
For that reason, this part covers more than the connector itself. As well as details of prerequisites, set up, and data
gathering with the connector, the part includes some insights into:
• Processes for gathering complete hardware and software inventory for your cloud-based instances
• Considerations for license management.

agree, but what I need is whether or not AHB is used on a (SQL) VM or not.

According to Azure inventory connector will not support Microsoft PowerShell AzureRM module from 2021 R2 release ... - Community (flexera.com) the AzureRM module does not support gathering this information, but Az does. 
So I will uninstall AzureRM again and reinstall Az. Most likely I will be back to where I was in my first post in this thread. I will keep you guys updated.

Now, the initial problem is back:

Import failed. Error: Please review the error message and correct the issue, then try again:
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.
Could not load file or assembly 'Azure.Core, Version=1.14.0.0, Culture=neutral, PublicKeyToken=92742159e12e44c8' or one of its dependencies. The system cannot find the file specified.

Anything else I can do to solve this problem? I'd highly appreciate any help, cause I need this data quite urgently for the upcoming TrueUp.

I tried to bulk override the cloud license model, but this does not work either 😞

Hi

 

Can you raise a support case with Flexera. It seems some issue with new module & need to check by them.

will do, thank you all for your support!

 

Always welcome. 

 

Do share once received solution & root cause.

I have the same issue, raised a case but there was no conclusion and could not be reproduced.

I've tried reinstalling all AZ components. It seems the issue does not happen on remote beacons when running Azure connector, but only appears on Flexera app server if Beacon is deployed there and connector is run. Both remote beacon and app server are running exactly same PS version and same Az components & prereqs, yet only the app server connector fails with the same error every time.

Let us know if you have any progress in the case!

Flexera does not recommend to use beacon in application server.

Good to know that you have the same problem like we have. I meanwhile installed the connector on our test system and I get the same error. I have installed all components on one server since it is supported. 

I'm a bit frustrated with Flexera support meanwhile. Support is even worse than free Microsoft online support these days. Even I classified my problem as high because I needed a solution for the upcoming MS TrueUp, I did not receive a second reply for more than 2 weeks.

Hi @JulesB did you have any conclusion to the case? I've tried everything from editing the web.config files and installing all prereqs all over again. Still it refuses to work on all app servers where beacon is installed, only on remote beacon it works.

BR, Antti