Zerobrain & Linux Issues {Solved}
#1
I am having troubles getting basic debugging working with Cuberite and Zerobrain. I never see the Cubrite server fully start, with a terminal window. My google-fu is failing to find a solution. I am hoping someone here goes oh yeah you need to do <insert fix here> and bam this is done.

So I follow the instructions over here to get to this point.

Since I get the choice of Cuberite - release mode and Cuberite - debug mode in the ZeroBrain IDE, as well I get code completion, I assume I have the IDE configured correctly.

Since I am using the pre-compiled binary, I have "Cuberite - release mode" selected.

My project folder is set to
Code:
/home/user/Server/Plugins/APIDump

When I press F5 I get the following from the ouput window in ZeroBrain:
Code:
Debugger server started at computername:8172.
Program starting as '/home/user/Server/Cuberite --no-output-buffering'.
Program 'Cuberite' started in '/home/user/Server/' (pid: 9356).
Debugging session started in '/home/user/Server/'.

ps aux |grep Cuberite shows that it is started:
Code:
user   9356  0.0  0.1  58416 12312 ?        Ssl  22:35   0:00 /home/user/Server/Cuberite --no-output-buffering
From here I would expect to able to connect to the server, as well as use the webadmin to control the server to some extent. Is this assumption correct?

Also the server starts fine from the terminal by running ./Cuberite and output of:
Code:
[22:43:02] --- Started Log ---
[22:43:02] Cuberite Jenkins clang x64 Release (master) build id: #279
[22:43:02] from commit id: d6ad5245b3590cc71686a763d71db82542b2f279 built at: Wed 25 Nov 16:52:16 CET 2015
[22:43:02] Creating new server instance...
[22:43:02] Reading server config...
[22:43:02] Starting server...
[22:43:02] Compatible clients: 1.7.x, 1.8.x
[22:43:02] Compatible protocol versions 4, 5, 47
[22:43:02] WebServer: The server is running in secure HTTPS mode.
[22:43:02] Loaded 443 crafting recipes
[22:43:02] Loaded 20 furnace recipes and 56 fuels
[22:43:02] Loaded 88 brewing recipes
[22:43:02] -- Loading Plugins --
[22:43:02] Initialising APIDump v.0
[22:43:02] Initialized ChatLog v.3
[22:43:02] Initialised Core v.15
[22:43:02] Initialized TransAPI v.1
[22:43:02] [WorldEdit] Enabling WorldEdit v0
[22:43:02] -- Loaded 5 Plugins --
[22:43:03] Startup complete, took 855ms!

Here is the 411 on the rig I am playing with:
Code:
Intel Core i5 Toshiba Laptop with 8GB ram

lsb_release -a returns:
No LSB modules are available.
Distributor ID:    Ubuntu
Description:    Ubuntu 14.04.3 LTS
Release:    14.04
Codename:    trusty

Uname -a:
Linux <Computername> 3.16.0-55-lowlatency #74~14.04.1-Ubuntu SMP PREEMPT Tue Nov 17 11:50:19 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Thanks for reading to here...

Chrobi
Reply
Thanks given by:
#2
I've just tried running ZBS + Cuberite on Linux for the first time Smile

I see similar results to what you're seeing - the server seemingly starts, but is not available. In my case, it also terminates rather soon, within 2 seconds, so that was my clue. After doing some sniffing around, I found out that the issue is caused by ZBS launching Cuberite in a detached state and closing its stdin; Cuberite by default terminates when its stdin is closed, so effectively the server starts up and terminates immediately.

Please try this fix first:
In ZBS's packages folder, there's the "cuberite.lua" file (that you downloaded from ZeroBranePackages), open it up and it should have this on line 132:
false,                  -- Redirect debuggee output to Output pane? (NOTE: This force-hides the Cuberite window, not desirable!)
Change that line to a simple
true,
and restart ZBS. This should force the debugger to instead put both cuberite's output and input in the Output pane of ZBS and for me it has helped keep the server running.

If this works, I'll update the package accordingly. The "false" value is there because on Windows, the redirection doesn't work, so I expect we'll need per-OS value there in the end.

And yes, your assumptions were correct Smile
Reply
Thanks given by:
#3
This was the issue fixer as exactly described. Thank you for the response.

Chrobi
Reply
Thanks given by:




Users browsing this thread: 1 Guest(s)