Jump to content

The Linux compatibility thread!


Recommended Posts

Unfortunately, there is no driver from the vendor for my video card. As I said legacy fglrx is not supporting Ubuntu 12.04 or above. And it is not an ancient card, the notebook is only 2 years old... Nice, isn't it?

Link to comment
Share on other sites

Naturally, I'm not speaking about rewriting mesa/mono/gallium3d/KSP, but just doing a quick check to find what has changed. .19 was OK, probably it is not impossible to fix .20 as well, even if that is not the fault of KSP.

My opinion that this is a bug coming from mono <-> mesa+gallium interaction. Is there a way to start the game with my own mono installed on my system? And how can I debug KSP? Is there some debug mode with normal logging? And where is the coredump?

KSP on Linux does not use the version of mono installed on your system, it uses an internal version so that should not be the issue.

Unfortunately, there is no driver from the vendor for my video card. As I said legacy fglrx is not supporting Ubuntu 12.04 or above. And it is not an ancient card, the notebook is only 2 years old... Nice, isn't it?

Hmm, I thought the old fglrx was only broken on versions above the LTS, as I was running KSP on Ubuntu 12.04 LTS on an ATI 4850HD without much trouble.

I wish AMD hadn't dropped the old cards, they are not exactly old either but there is nothing we can do about it, KSP can run on the open drivers by the way but it's slow and does not work for everyone.

I really don't know what to suggest, well no that's not true but I don't want to have to tell you that you need different hardware thanks to AMD dropping support.

Link to comment
Share on other sites

Observing disassembly around the crash point reveals that there is some obviously 32-bit code in the supposedly 64-bit executable. Some research shows that it comes from hand-coded assembly within pngvcrd.c of libpng: http://pastebin.com/599g7h7i. This code obviously should never be included in a 64-bit build, and will crash whenever called with pointers that don't fit in the low 4 GB.

now that's some ninja debugging, nice work :)

hopefully that's the only reason that KSP.x86_64 has been reported as unstable!

So.. until fixed, don't install so many mods that KSP uses 4G ram?

Link to comment
Share on other sites

It's largely a matter of chance, based on where the kernel chooses to place memory areas for heap, and how to grow it. Allocating lots of memory merely makes it more likely. For some people it seems it crashes basically as soon as it tries to load a png image: http://bugs.kerbalspaceprogram.com/issues/752 (no idea what's the problem with his 32-bit version, since there is only one log)

What might work is changing a couple of bytes in the executable to make libpng think that the cpu doesn't support MMX and skip all this optimized stuff, but I didn't have time to test it much yet.

Link to comment
Share on other sites

I want to report a definite miscompilation bug in the 64-bit linux executable of KSP 0.20.* that results in a segfault in certain circumstances.

It can be reproduced by loading the png file coming with the HydroTech Mouse Drive mod; it is not reliable, and is helped by high memory usage due to other mods and trying multiple times: http://filebin.ca/jFdwbprJ5pz/Player.log

Observing disassembly around the crash point reveals that there is some obviously 32-bit code in the supposedly 64-bit executable. Some research shows that it comes from hand-coded assembly within pngvcrd.c of libpng: http://pastebin.com/599g7h7i. This code obviously should never be included in a 64-bit build, and will crash whenever called with pointers that don't fit in the low 4 GB.

Since as I understand Squad doesn't actually build the native executables from source, this issue probably should be forwarded to Unity.

This is a Unity issue and you'd need to take it up with them to be honest, but it'd explain why the 64bit binaries are unstable.

Well, the OSX and Windows ones are, at least the Linux version runs :)

Link to comment
Share on other sites

One thing you could quickly check is if the (unreleased) 64-bit build for windows contains the string "asm_flags may not have been initialized" that is used in that source code file inside the relevant ifdefs - if it does, chances are it has the same problem.

Link to comment
Share on other sites

Hi guys, my game isn't even starting to load, it just open a black window and then the processor usage goes up to 100% and it stays like this forever, with also around 20-25mb of memory usage, with the same black screen. I am using the (Steam version of the fix) LC_ALL_C fix explained, but it doesn't change anything.

My Ubuntu is a fresh 12.04 install, with an core i3 and Intell Graphics 4000, and I'm running KSP from Steam.

Anyone know what could cause this, and how to fix it? I have to kill the process everytime, lest my laptop would start flying from the fan speed o_O

Link to comment
Share on other sites

I have an old ThinkPad X60s with an Intel i810 graphics processor.

I'm using the Intel X driver:


cat /var/log/Xorg.0.log | grep -i driver
[ 106.326] X.Org Video Driver: 12.1
[ 106.326] X.Org XInput driver : 16.0
[ 107.440] (==) Matched intel as autoconfigured driver 0
[ 107.440] (==) Matched vesa as autoconfigured driver 1
[ 107.440] (==) Matched fbdev as autoconfigured driver 2
[ 107.440] (==) Assigned the driver to the xf86ConfigLayout
[ 107.440] (II) Loading /usr/lib/xorg/modules/drivers/intel_drv.so
[ 107.562] Module class: X.Org Video Driver
[ 107.562] ABI class: X.Org Video Driver, version 12.1
[ 107.562] (II) Loading /usr/lib/xorg/modules/drivers/vesa_drv.so
[ 107.579] Module class: X.Org Video Driver
[ 107.579] ABI class: X.Org Video Driver, version 12.0
[ 107.580] (II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
[ 107.583] ABI class: X.Org Video Driver, version 12.0
[ 107.583] (II) intel: Driver for Intel Integrated Graphics Chipsets: i810,
[ 107.584] (II) VESA: driver for VESA chipsets: vesa
[ 107.584] (II) FBDEV: driver for framebuffer: fbdev
[ 107.686] ABI class: X.Org Video Driver, version 12.1
[ 109.490] (II) intel(0): [DRI2] DRI driver: i915
[ 109.563] (II) UXA(0): Driver registered support for the following operations:
[ 114.149] Module class: X.Org XInput Driver
[ 114.150] ABI class: X.Org XInput driver, version 16.0

and glx is direct


glxinfo | grep direct
direct rendering: Yes

unfortunately, when I start up the demo the menu comes up extremely slowly (as in 10 seconds between frames) making the game unplayable. I have confirmed that the demo works fine on the exact same hardware under Windows XP. Is there anything I can do to make this work under Linux (debian)?

Link to comment
Share on other sites

@birdspider

Thanks. I'll check out those links. Unfortunately, I'm kinda stuck with hardware at the moment. However, my wife runs the same machine with WinXP -- so for the moment I can steal that.

Still, the support for linux was enough to push me over the edge to purchase the full KSP, thanks SQUAD.

Link to comment
Share on other sites

Hi guys, my game isn't even starting to load, it just open a black window and then the processor usage goes up to 100% and it stays like this forever, with also around 20-25mb of memory usage, with the same black screen. I am using the (Steam version of the fix) LC_ALL_C fix explained, but it doesn't change anything.

My Ubuntu is a fresh 12.04 install, with an core i3 and Intell Graphics 4000, and I'm running KSP from Steam.

Anyone know what could cause this, and how to fix it? I have to kill the process everytime, lest my laptop would start flying from the fan speed o_O

We'll need your player.log and KSP.log, check the opening post for info :)

@birdspider

Thanks. I'll check out those links. Unfortunately, I'm kinda stuck with hardware at the moment. However, my wife runs the same machine with WinXP -- so for the moment I can steal that.

Still, the support for linux was enough to push me over the edge to purchase the full KSP, thanks SQUAD.

If you don't mind Wine, you can still run the Windows version using it, so at least you can avoid hogging the wife's PC :D

Edited by sal_vager
Link to comment
Share on other sites

Just a quick rundown on my experience getting KSP to run on Linux Mint 15 "Olivia" (via Steam).

Fresh install of Mint. I use an Nvidia GTS 250 graphics card, and initially KSP is HORRIBLY slow. Really unplayable. So I determine that it might have something to do with the Nvidia 310 driver I am using (Mint's "reccomended" driver).

I update the driver to the 319.23. This is the bleeding edge Nvidia driver which is supposedly optimized for Steam, and the update takes several hours due to installation issues. At first, it breaks my X server, so I get a command line. After some hunting around I purge nvidia and reinstall the driver using the PPD for it and restart the system. This fixes the problem- incompatibilities between the driver components and the kernal module, the latter of which are for earlier version.

OK, so now Nvidia 319.23 is humming away, and I fire up KSP and it Just Works. Also, I am using the 64-bit version (KSP_x64) which works without any problems so far. Seems to be fairly fast too, and my system is several years old.

Link to comment
Share on other sites

Edit: This post is outdated. Most problems with adding mods that I ran into with the 64-bit executable were solved by using a.g.'s fix. If you're crashing during the initial load (or loading Kethane or ISA Map parts on the launchpad), that's likely a good place to start.

As promised a bit earlier up the thread, a list of mods that work with KSP.x86_64 (ver 0.20.2):

Working mods:

Mechjeb 2.0.8

SubAssembly (with fix found on the forums)

KSP Stock Part Expansion (KSPx)

H.O.M.E. 1.0.3

B9

Crew Manifest

Tri-Struts

Hyper-Edit

Kethane

Haystack

Quantum Struts

Common Berthing Mechanism

Non-Working, Non-Crashing Mods (if you don't add the associated part, it won't CTD on the launchpad):

Chatterer

ISA Map (dev build)

Crashing Mods (cause CTDs even if not used)

Editor Part Filter (on loading VAB screen)

We did a bit of Reddit crowdsourcing for the list (thanks to those who participated!), so I haven't personally confirmed each one works. I actually have some intermittent CTDs on the initial load when adding some of the larger parts mods (B9, Kethane), though sometimes they manage to load nicely.

Hope that helps someone.

Edited by DorfKerbin
Link to comment
Share on other sites

Thank's a lot for this very useful Thread - now everything works good enough to enjoy the game :-)

I had encountered most of these issues and several others.

So just to mention it, i now run KSP on an 64Bit Xubuntu an a Laptop with Nvidia Optmus-Technology through Steam...nativly

After Steam released L4D2 Beta for Linux i thought, this would be the right moment, to switch my entire IT (Thinkpad, Gaming-Laptop, Fujitsu-Workstation) to Linux and finally to leave Dual-Boot behind. And after i did this, i found KSP...so after reading forum-threads about "is it worth buying", the decision was pretty clear. And i didn't regret it...

So SQAUD, thanks alot, that you brought KSP to Linux too. I think, this is going to be a step, you won't regret... keep going, you are my heros (around several others ;-)

Link to comment
Share on other sites

Good work DorfKerbin, I'm going to add this to the opening post :)

Glad it might help. :)

Does your stack trace in Player.log contain the address 0xbcec9f? If so, check out this bug: http://bugs.kerbalspaceprogram.com/issues/752#note-2

In fact, it does:

Stacktrace:

at (wrapper managed-to-native) UnityEngine.WWW.GetTexture (bool) <0x00069>

at (wrapper managed-to-native) UnityEngine.WWW.GetTexture (bool) <0x00069>

at UnityEngine.WWW.get_texture () <0x0000f>

at DatabaseLoaderTexture_PNG/

.MoveNext () <0x00227>

at (wrapper runtime-invoke) <Module>.runtime_invoke_bool__this__ (object,intptr,intptr,intptr) <0x00059>

Native stacktrace:

/home/DorfKerbin/.local/share/Steam/SteamApps/common/Kerbal Space Program/KSP_Data/Mono/x86_64/libmono.so(+0x92c92) [0x7f2718729c92]

/home/DorfKerbin/.local/share/Steam/SteamApps/common/Kerbal Space Program/KSP_Data/Mono/x86_64/libmono.so(+0xd000d) [0x7f271876700d]

/lib/x86_64-linux-gnu/libpthread.so.0(+0xfbd0) [0x7f271cb3ebd0]

/home/DorfKerbin/.local/share/Steam/SteamApps/common/Kerbal Space Program/KSP.x86_64() [0xbcec9f]

[0x7fff54e21740]

Unfortunately (for me), I think the 'fix' you suggest is a bit beyond my skillset. ;)

With my present mod setup, this CTD happens about 3 out of every 5 times I start KSP, so it certainly sounds like it could be that bug.

Link to comment
Share on other sites

Here's a reminder for anyone using a dual-boot.

You must have KSP on a Linux-based partition; other file-systems can't handle Linux file attributes and so KSP will lack the executable tag.

Haven't tried it, but wouldn't it just work anyway?

I have run KSP from USB stick on Linux, from fat32, ntfs and udf memory sticks, no trouble.

Link to comment
Share on other sites

Thanks! That seems to have helped. :)

Actually the Kethane mod crashes in KSP.x86_64 on my computer.

Runs fine on KSP.x86.

I had a chance to play with the 0.5 version last night. Loaded fine for me, and runs well except when one of the survey parts is used - it then CTDs on the launchpad (same as ISA Map).

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...