- Home /
Unity headless server on Windows Server Core (Docker)
I've been trying to run a Unity server in headless mode on Windows Server Core, using the new(ish) native Docker support for Windows.
Right now, I don't get any output, not even errors, when I run the server app, it just starts and immediately stops. This got me thinking that it might be due to Unity not running in a "true" headless mode on Windows, since it always spawn a custom console-like app (at least in this case), while on linux it works as expected.
So I guess my question is if it's possible to even run a headless Unity server on Windows without any additional windows/consoles/command prompts? Running as a background process would be fine too, since I have other ways of interacting with it.
I'm experiencing the same issue, but just trying to run the Unity Editor with "-batchmode -nographics -quit". No logs, nothing. I'm trying to containerize our build machines, but this issue is preventing me from doing so.
I get the same issue with Windows Server Core running right in Hyper-V, that is, outside of docker/containers I still see this.
Same. Technically Server Core still has a GUI, but that doesn't seem to matter in this case.
I also tried running a headless UE4 server on it, and actually got an error dialog saying that both VC++ and DirectX runtime need to be installed.
Thing is, Server Core doesn't have or even support DirectX, and it looks like you can't even install it, so it could be that Unity's looking for DirectX and silently failing, hard to tell.
If it does end up being that, then I'm sure there's a way to import registry entries from a desktop installation, then manually copy over DLLs etc.
And since there's no upgrade to full experience option (http://www.davidhill.co/2017/04/install-windows-server-2016-gui-desktop-experience/) as well as no base image for docker with the full experience we're kind of stuck here.
I just tried this with 2017.3, ran into the same issue you experienced. No error, no log. I am assu$$anonymous$$g its missing some dependencies that are not included in Server Core.
Now I gotta fuck with linux.... hate linux.
Answer by hoshhsiao · Aug 06, 2019 at 06:32 PM
I am running into a similar issue, when attempting this on Windows 2019 Sever Core. I did get a clue when I try to do this under bash.exe. I get this helpful hint:
error while loading shared libraries: GLU32.dll: cannot open shared object file: No such file or directory
Since Server Core is a stripped down Windows, it probably does not have library. (That looks like an OpenGL library of some kind). If I cannot figure out how to add those libraries back, I think I'll just start with the Full edition of Windows 2019.,I am running into something similar, running on Windows 2019 Server Core. When I attempt to run Unity in bash.exe, I get a more helpful error message:
C:/Unity/Editor/Unity.exe: error while loading shared libraries: GLU32.dll: cannot open shared object file: No such file or directory
Which I take it to mean that the GLU32.dll (part of the opengl libraries?) are not installed on Server Core by default. I'm looking into how I can install just that system. But if this isn't working, I'm just going to rebuild on top of the Full edition.
Your answer
Follow this Question
Related Questions
Linux Headless Server on Unity 5 - Idle CPU Load 1 Answer
Headless mode checkbox is uncheckable 1 Answer
Problem with connecting to AWS EC2 Server ... 0 Answers
Prefab created in Windows not opening on Mac 0 Answers
Gray window when opening Unity 2 Answers