2

I'm trying to run a gameserver for the game "Insurgency: Modern Infantry Combat" on a VPS rented from Kimsufi running Ubuntu 15.10.

I've had prior experience messing around with Wine and Xvfb but right now I'm unsure of how to continue and solve these issues. I need to use Wine and Xvfb as I'm trying to run a Windows-based gameserver on my VPS because the Linux version of the gameserver is horribly broken and has no chance of being fixed because of the developer releasing a new Insurgency game back in 2014.

Here's the startup script I did for the server. I have to do things this way because there's no physical "screen" for the VPS, and I don't know how to make it use my own desktop as a "screen" to display things.

#!/bin/bash
Xvfb :1&
export DISPLAY=:1
wine start srcds.exe -console -secure -game insurgency +map ins_karam +rcon_password RdbtTc5CR4QrjZiQirhp -strictportbind -port 27050 +clientport 27150 +tv_port 27155 -maxplayers 32 +sv_master_legacy_mode 0 &

And here's what I'm getting spat out at me every time I try to start the server.

_XSERVTransSocketUNIXCreateListener: ...SocketCreateListener() failed
_XSERVTransMakeAllCOTSServerListeners: server already running
(EE)
Fatal server error:
(EE) Cannot establish any listening sockets - Make sure an X server isn't already running(EE)
fixme:exec:SHELL_execute flags ignored: 0x00000100
fixme:keyboard:X11DRV_LoadKeyboardLayout L"00000409", 0000: stub!
fixme:ver:GetCurrentPackageId (0x33d720 (nil)): stub
fixme:ver:GetCurrentPackageId (0x33d0dc (nil)): stub
fixme:ver:GetCurrentPackageId (0xf09e03c (nil)): stub
fixme:ver:GetCurrentPackageId (0xf29e9e8 (nil)): stub
fixme:ver:GetCurrentPackageId (0x33d488 (nil)): stub
fixme:ntdll:NtLockFile I/O completion on lock not implemented yet
fixme:advapi:EventRegister {47a9201e-73b0-42ce-9821-7e134361bc6f}, 0xfde5b30, 0xfe1ab30, 0xfe1ab28
fixme:advapi:EventRegister {58a9201e-73b0-42ce-9821-7e134361bc70}, 0xfde5b30, 0xfe1ab68, 0xfe1ab60
fixme:advapi:EventRegister {3fa9201e-73b0-43fe-9821-7e145359bc6f}, 0xfde5b30, 0xfe1aaf8, 0xfe1aaf0
fixme:advapi:EventRegister {1432afee-73b0-42ce-9821-7e134361b433}, 0xfde5b30, 0xfe1aba0, 0xfe1ab98
fixme:advapi:EventRegister {4372afee-73b0-42ce-9821-7e134361b519}, 0xfde5b30, 0xfe1abd8, 0xfe1abd0
err:secur32:SECUR32_initSchannelSP TLS library not found, SSL connections will fail
err:winediag:SECUR32_initNTLMSP ntlm_auth was not found or is outdated. Make sure that ntlm_auth >= 3.0.25 is in your path. Usually, you can find it in the winbind package of your distribution.

Not sure what to do here. If you guys need any additional info, just let me know.

4

(EE) Cannot establish any listening sockets - Make sure an X server isn't already running(EE) fixme:exec:SHELL_execute flags ignored:

Either there is an Xfvb (or another X server) already running on display :1 or there are some lock files left from a previous run.

See ls -l /tmp/.X* and look at your process list ps aux | grep -i xvfb.

In case another X is running you may kill it. Or manually delete the X1* lock files. Or choose another display for you Xvfb (Xvfb :123).

Your start script should make sure to kill the X server on exit. Otherwise you could also re-use the Xvfb session if it's already running.

FYI I have such a Xvfb/wine script running in production. Although also not perfect it always run without any problems since years via cron. Here it is:

#!/bin/bash

VNC_PORT=29
export DISPLAY=":${VNC_PORT}.0"

/usr/bin/Xvfb :${VNC_PORT} -screen 0 1024x768x8 -fbdir /var/tmp  &
XVFB_PID=$!

# waiting for XServer  established (or failure)
sleep 1

if test "${XVFB_PID}" != "$(jobs -p)" ;then
    echo "error, Xvfb failed"
    exit 1
fi

/usr/bin/wine **your command**
RET=$?
echo "wine returned '$RET'"

# waiting for shutdown all wine stuff completely
sleep 2

kill $XVFB_PID
exit $RET

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy