3

Observed

I have a Jenkins build job that runs on a Windows slave. The slave has MSBuild set up properly and is running Windows Server 2012R2 Standard x64.

That build job is compiling and running the Unittests for my project. The tests are using DUnit and DelphiXE2 compilers. Building the tests is no problem. But when the test executable is started, Runtime error 216 at 00406E56 occurs. The executable produces no output and the test result file is not created. The test executable uses the ConsoleRunner rather than the GUI.

When I run the exe as a local administrator or a restricted user, it works as expected.

Expected

The test executable normally produces output. It prints a dot for every test run. I'd expect the exe to start running, anyway.

Own research

  • There is a question here that seems to describe the same behavior.

  • The issue is occuring on Windows Server 2012 and 2012R2 when running the executable as local system (e.g. via PSExec).

  • I had a look at the library dependencies with Dependency Walker and found that all the libraries are accessible for the exe. PATH and other search paths for library dependencies all have at least read access permission for local system

  • I made sure that WOW64 is working.

Suspects

I don't know if DUnit or Delphi XE2 in general requires the permission to set up a visible user interface. This is one of the things the local system account is lacking.

HaMster
  • 533
  • 1
  • 6
  • 17
  • Seems very odd that you would want to do this. Surely you should be running as a standard user, or are you testing your code under localsystem specifically? – David Heffernan Dec 07 '15 at 17:07
  • I want the Jenkins slave to be easily replaceable, thus I try to keep it as basic as possible. And also if I add more slaves and have to configure the individual machines it would be a lot overhead. – HaMster Dec 07 '15 at 17:51
  • I don't understand that. Never mind. – David Heffernan Dec 07 '15 at 17:51

0 Answers0