Highlighted
Absent Member.
Absent Member.
1156 views

Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

webservice scripts are running fine if we take local copy of script and run in LR VUGen 12.

 

getting below error only when we run script placed in shared network drive. 

Kindly provide solution for this issue.

 

we will be running tests in Performance center only, so will this error occur in PC also?

 

DetailedError:

System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.

   at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)

   at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)

   at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection, Boolean suppressSecurityChecks)

   at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)

   at System.Reflection.Assembly.LoadFrom(String assemblyFile)

   at Mercury.LR.LrWsNetClient.FSProxyAssemblyProvider.GetProxyAssembly(String msWSDLUri, String msServiceName, String msPortName, WSDLRepository moWSDLRepository, AssemblyType eAssemblyType)

  at Mercury.LR.LrWsNetClient.WSDLRepository.GetProxyAssembly(String msWSDLUri, String msServiceName, String msPortName, AssemblyType eAssemblyType)

   at Mercury.LR.LrWsNetClient.ProxyCreator.PortInfo.LoadProxy()

   at Mercury.LR.LrWsNetClient.ProxyCreator.PortInfo..ctor(ServiceInfo service, String name)

   at Mercury.LR.LrWsNetClient.ProxyCreator.Init(String msWSDL, String msService, String msPort, INativeRepositoryApi moNativeRepository)

   at Mercury.LR.LrWsNetClient.NetReplay.InvokeMethod(String sMethod, IWSMethodParameters mParams, String sAsyncEvent)

 

0 Likes
5 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

Re: Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

Can you please  unblock this file  xunit.runner.tdnet.dll , this file when blocked its prevent you to do the test .

Just right click and unblock and try to run the test again .

 

Cheers

MohammedHamed

0 Likes
Highlighted
Absent Member.
Absent Member.

Re: Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

Hi Mohamed

 

How can we achieve this, please provide steps.

 

Regards,


@Mohammed Hamed wrote:

Can you please  unblock this file  xunit.runner.tdnet.dll , this file when blocked its prevent you to do the test .

Just right click and unblock and try to run the test again .

 

Cheers

MohammedHamed


 

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

Re: Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

0 Likes
Highlighted
Absent Member.
Absent Member.

Re: Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

Hi,

Please go to the <LR installation folder>\bin, open file HP.Utt.StandaloneDebugger.exe.config
In this file HP.Utt.StandaloneDebugger.exe.config, add these lines below after </startup> tag
  <runtime>
    <loadFromRemoteSources enabled="true"/>
  </runtime>

It will be:

<?xml version="1.0"?>
<configuration>
  <startup useLegacyV2RuntimeActivationPolicy="true">
    <supportedRuntime version="v4.0"

                      sku=".NETFramework,Version=v4.0"/>

  </startup>
  <runtime>
    <loadFromRemoteSources enabled="true"/>
  </runtime>
</configuration>

Restart Vugen and run script again.
 
Thanks,
Phuong Nguyen
From HP LR Team

0 Likes
Highlighted
Trusted Contributor.
Trusted Contributor.

Re: Loadrunner VUGen 12 -Running from Network - Error : System.IO.FileLoadException:

Hi Phuong,

 

Your suggestion is working! 

 

Best Regards,

 

Valentin 

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.