Linux Support

Ask here if you experience technical problems with X4: Foundations.

Moderator: Moderators for English X Forum

hakzsam
Posts: 6
Joined: Fri, 1. Mar 19, 17:58

Re: Linux Support (Beta)

Post by hakzsam »

Thanks for confirming guys. I still have no ideas why it hangs with DCC enabled but I will investigate.
Hopefully, I should be able to fix the problem soon. I will let you know.
_JD_
Posts: 137
Joined: Wed, 29. Oct 08, 15:05
x4

Re: Linux Support (Beta)

Post by _JD_ »

_JD_ wrote: Sat, 2. Mar 19, 15:25
_JD_ wrote: Thu, 28. Feb 19, 22:11 I encountered a really annoying issue: the joystick deadzone is not working at all. I tried with both a Logitech Force 3d Pro and X52 Pro [...]
_JD_ wrote: Fri, 1. Mar 19, 16:33 Ok, I did some more tests and it seems a Linux related issue: I rebooted on Windows 10, installed X4 and tested the X52 Pro and the deadzone slider is correctly working: I was able to feel a huge difference going from 25% to 0%.
cicero111 wrote: Fri, 1. Mar 19, 02:07 Same issue as _JD_ mentioned with setting 0 deadzone. Reducing does have some effect for me but setting 0 would compare to about 10 in the windows version I guess.
9000 wrote: Fri, 1. Mar 19, 18:46 I can confirm that issue using a T.16000M. Fighting against S/M-Ships is now a lot more... thrilling :wink:
So, for the people playing with a Joystick/HOTAS: is the deadzone setting working for you? And by working I mean that you get a huge difference setting it to 0% and to 25%.
For all the people with the Joystick deadzone issue: it seems that the Public Beta - Version: 2.20 Beta 1 (338019) fixes the issue! I tried it and the deadzone slider works again!
mflayer
Posts: 5
Joined: Thu, 29. Nov 18, 06:13
x4

Re: Linux Support (Beta)

Post by mflayer »

Phipsz wrote: Mon, 4. Mar 19, 14:55A quick search for your GPU came up with this: https://forums.linuxmint.com/viewtopic.php?t=272283 , saying your GPU does support vulkan, but amd is too lazy to fix a bug that prevents usage of the respective driver on linux. may that be the cause? But since you are using manjaro, maybe the Arch wiki can help you here? https://wiki.archlinux.org/index.php/AMDGPU
Yeah you were right! Twice!
1) by default radeon is (sometimes?) preferred to amdgpu for Southern Islands chipsets
2) arch wiki had all the info about it (duh!), I just didn't look hard enough. Thank you for the link!
After adding kernel params to use amdgpu, my vulkaninfo gave no more errors. Game started but hard-locked during splash screen.
Using RADV_DEBUG=nodcc didn't help with the lock up @ start, but installing amdvlk-git from AUR and using

Code: Select all

VK_ICD_FILENAMES="/usr/share/vulkan/icd.d/amd_icd64.json" %command% -skipintro
as launch settings in steam solved the issue - somebody posted that solution earlier in the thread.
After all that I've reached the main menu without crashes and was able to start a new game.

All in all, it was a multitude of issues, all fixable. It works fine now, played a couple minutes on the new game without any issues, even the performance is ok.

For posterity and google searches: This was on Manjaro (4.19 kernel), Radeon R9 280, amdgpu 18.1.0, mesa 18.3.3, amdvlk 2.63.1120, using the above launch options in steam.

Huge thanks to everyone who contributed solutions. Now on to migrating my 300+ hours save from windows.
Last edited by mflayer on Mon, 11. Mar 19, 13:06, edited 1 time in total.
User avatar
Brianetta
Posts: 3203
Joined: Tue, 12. Nov 02, 14:22
x4

Re: Linux Support (Beta)

Post by Brianetta »

radcapricorn wrote: Sat, 2. Mar 19, 16:22
Brianetta wrote: Wed, 27. Feb 19, 17:16 It seems that the Linux beta doesn't sign saved games as valid, and so it isn't really possible to test ventures.
I just sent a ship off on a venture.
Well, I could explore this more, but mine failed to go on a venture after I loaded the save in Windows again.
PGP fingerprint: FA3D CA2F 38D3 BA69 87E1 D52E C204 FB5C 430A 0BFA
hogy
Posts: 20
Joined: Wed, 6. Nov 02, 20:31
x4

Re: Linux Support (Beta)

Post by hogy »

Spotted some graphical corruption in the encyclopedia (looks different every time), when right clicking a mining turret from the buy ships interface at Wharf in Argon Prime and going to encyclopedia entry.

Image

Save game: https://www.dropbox.com/s/o86b0twh3gf26 ... ml.gz?dl=0

Talk to the bloke
Buy Ships
Size M - Drill Vanguard Miner
Turrets - right click Mining Turret Mk 1, Encyclopedia

And I just noticed that when I alt+tab while looking at that bloke from that save game, when I go back to the game his face freezes but his body and eyes keep moving... Freaky!

Image

I'm unable to check if either of these happen on Windows.

Kernel: 4.20.12.a-1-hardened (archlinux linux-hardened)
Graphics card is GeForce GTX 1060 6GB
Vulkan Instance Version: 1.1.101

Code: Select all

VkPhysicalDeviceDriverProperties:
=================================
        driverID   = 4
        driverName = NVIDIA
        driverInfo = 418.43
        conformanceVersion:
                major    = 1
                minor    = 1
                subminor = 2
                patch    = 3
hogy
Posts: 20
Joined: Wed, 6. Nov 02, 20:31
x4

Re: Linux Support (Beta)

Post by hogy »

hogy wrote: Tue, 5. Mar 19, 22:24 And I just noticed that when I alt+tab while looking at that bloke from that save game, when I go back to the game his face freezes but his body and eyes keep moving... Freaky!
Actually I've seen some other odd things happen after Alt-Tab'ing:
  • In one case the "fog of war" stopped updating, I could fly around a sector where I hadn't been before and the map wouldn't clear away the fog until I quick saved (save file: https://www.dropbox.com/s/r61nxna2auy7q ... ml.gz?dl=0) and reloaded, where it then worked. I could reproduce that again once after loading, but then...
  • Trying again from there with another Alt+Tab, the ship speed on the HUD stopped updating, it was just fixed at 700ish m/s, whether traveling or flying normally, and even after a reload. That one didn't sort itself out until I restarted the game. This happened a couple of times when I tried to reproduce the "fog of war" issue.
Here's a screenshot showing high speed on HUD but speed bar at 0 (the ship isn't moving):
Image
User avatar
Knossos
Posts: 56
Joined: Tue, 1. Jun 04, 19:47
x4

Re: Linux Support (Beta)

Post by Knossos »

BerndHohmann wrote: Sun, 3. Mar 19, 11:21
Knossos wrote: Sun, 3. Mar 19, 10:41 ERROR: [Loader Message] Code 0 : /usr/lib/i386-linux-gnu/libvulkan_radeon.so: wrong ELF class: ELFCLASS32
Try to remove the two Vulcan :i386 libs you had installed before, X4 is 64bit only.

Also chdir to the X4 Steam installation directory and try

Code: Select all

ldd -d X4 | grep -e vulkan
Output should look like

Code: Select all

libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007f48c3a33000)
And /usr/lib/x86_64-linux-gnu/libvulcan.so.1 should exist.

Bernd
I deleted the vulkan libs you mentioned.

The current status:

Code: Select all

$ ldd -d X4 | grep -e vulkan
	libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007fa688dcc000)
Same error.
Android Software Engineer
Try my hands-free notification reader for your car.
mflayer
Posts: 5
Joined: Thu, 29. Nov 18, 06:13
x4

Re: Linux Support (Beta)

Post by mflayer »

Knossos wrote: Wed, 6. Mar 19, 08:22 I deleted the vulkan libs you mentioned.

The current status:

Code: Select all

$ ldd -d X4 | grep -e vulkan
	libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007fa688dcc000)
Same error.
When you do "lspci -v", what does it say for your vga driver in use?
Mine says

Code: Select all

Kernel driver in use: amdgpu
Kernel modules: radeon, amdgpu
It used to be radeon, and i was getting the same error as you.
timon37
EGOSOFT
EGOSOFT
Posts: 508
Joined: Fri, 14. Dec 12, 11:02
x4

Re: Linux Support (Beta)

Post by timon37 »

@Knossos and others
keep in mind steam modifies the environment when launching.
So using ldd from a console isn't representative, instead you can modify the testandlaunch script in the game folder, and launch steam from the console using "steam -console" then you'll get nice output and the ability to mess with stuff.

Relating to that is the steam-runtime, in general I'd say that you want it enabled (should be the default afaik). To explicitly make sure, open a console and launch steam with e.g. "STEAM_RUNTIME=1 steam -console". We're building against the runtime and from what I saw the game's relatively unlikely to launch on a modern distro without it.

@all
Savegame signing is broken. Work in progress. Really sorry about it, should've mentioned that much sooner:(
So if you really care about that it's safest to not use the linux version for now.
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: Linux Support (Beta)

Post by radcapricorn »

timon37 wrote: Wed, 6. Mar 19, 15:29 Savegame signing is broken. Work in progress. Really sorry about it, should've mentioned that much sooner:(
So if you really care about that it's safest to not use the linux version for now.
Broken as in "may or may not be working"? Because it sure works for me. (As in, ventures work).

Any news about other issues? I've them all in a list if you need it =)
User avatar
Knossos
Posts: 56
Joined: Tue, 1. Jun 04, 19:47
x4

Re: Linux Support (Beta)

Post by Knossos »

mflayer wrote: Wed, 6. Mar 19, 08:45
Knossos wrote: Wed, 6. Mar 19, 08:22 I deleted the vulkan libs you mentioned.

The current status:

Code: Select all

$ ldd -d X4 | grep -e vulkan
	libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007fa688dcc000)
Same error.
When you do "lspci -v", what does it say for your vga driver in use?
Mine says

Code: Select all

Kernel driver in use: amdgpu
Kernel modules: radeon, amdgpu
It used to be radeon, and i was getting the same error as you.

Code: Select all

01:00.0 VGA compatible controller: NVIDIA Corporation GM204 [GeForce GTX 970] (rev a1) (prog-if 00 [VGA controller])
	Subsystem: Micro-Star International Co., Ltd. [MSI] GM204 [GeForce GTX 970]
	Flags: bus master, fast devsel, latency 0, IRQ 55
	Memory at f6000000 (32-bit, non-prefetchable) [size=16M]
	Memory at e0000000 (64-bit, prefetchable) [size=256M]
	Memory at f0000000 (64-bit, prefetchable) [size=32M]
	I/O ports at e000 [size=128]
	Expansion ROM at 000c0000 [disabled] [size=128K]
	Capabilities: <access denied>
	Kernel driver in use: nouveau
	Kernel modules: nvidiafb, nouveau
But from what timon37 says, my diagnostics could be wrong.

This is what I get from the testandlaunch script, when adding before and after running X4:

Code: Select all

./testandlaunch 
	libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007fd781aaf000)
Elephant Memory Manager Initialized with 0MB
Elephant Memory Manager Name And Callstack Base Address is 0x19aaba3
Elephant Memory Manager Mode: Resizable Mode, Has small heap: No, 64bit, Version: 1.7.3
Heap Resize Generic 0x0x7fb7acd36000 to 0x0x7fb7b6d35fc0
Running Steam on ubuntu 18.10 64-bit
STEAM_RUNTIME is enabled automatically
Pins up-to-date!
	libvulkan.so.1 => /usr/lib/x86_64-linux-gnu/libvulkan.so.1 (0x00007f26f0c9e000)
I really don't know if that helps.
Android Software Engineer
Try my hands-free notification reader for your car.
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: Linux Support (Beta)

Post by radcapricorn »

Knossos wrote: Wed, 6. Mar 19, 16:03 Kernel driver in use: nouveau
Well, there's your culprit.

From the OP:
At the moment only the proprietary driver from nvidia and the open-source mesa/radv amd drivers are supported.
mflayer
Posts: 5
Joined: Thu, 29. Nov 18, 06:13
x4

Re: Linux Support (Beta)

Post by mflayer »

radcapricorn wrote: Wed, 6. Mar 19, 16:15
Knossos wrote: Wed, 6. Mar 19, 16:03 Kernel driver in use: nouveau
Well, there's your culprit.

From the OP:
At the moment only the proprietary driver from nvidia and the open-source mesa/radv amd drivers are supported.
Exactly what I meant. Unless you're a die-hard FOSS advocate, I suggest always using proprietary Nvidia drivers over the open-source ones if you want any semblance of performance. Nouveau are notoriously slow.
User avatar
Knossos
Posts: 56
Joined: Tue, 1. Jun 04, 19:47
x4

Re: Linux Support (Beta)

Post by Knossos »

radcapricorn wrote: Wed, 6. Mar 19, 16:15
Knossos wrote: Wed, 6. Mar 19, 16:03 Kernel driver in use: nouveau
Well, there's your culprit.

From the OP:
At the moment only the proprietary driver from nvidia and the open-source mesa/radv amd drivers are supported.
:facepalm:

Thank you for helping me figure this out.
Android Software Engineer
Try my hands-free notification reader for your car.
Mahi Ma
Posts: 76
Joined: Mon, 16. Mar 15, 14:10
x4

Re: Linux Support (Beta)

Post by Mahi Ma »

I got the latest AchLinux, AMD Vega 56 and Ryzen R7 2700, 32gb ram.
mesa-18.3.4-1 and radv (Vulkan 1.1.2.0)

The intro is visible, the music audible but then it freezes the screen and I get colorful dots everywhere.
Need to kill X to fix. . .

I tried both, 2.0 and the current 2.20 beta
BerndHohmann
Posts: 45
Joined: Tue, 16. Feb 16, 00:14

Re: Linux Support (Beta)

Post by BerndHohmann »

Knossos wrote: Wed, 6. Mar 19, 17:01
:facepalm:
Oh well, I thought you had read the thing with the nvidia proprietary :-)

Bernd
User avatar
Knossos
Posts: 56
Joined: Tue, 1. Jun 04, 19:47
x4

Re: Linux Support (Beta)

Post by Knossos »

BerndHohmann wrote: Wed, 6. Mar 19, 18:42
Knossos wrote: Wed, 6. Mar 19, 17:01
:facepalm:
Oh well, I thought you had read the thing with the nvidia proprietary :-)

Bernd
I had, but I didn't realise that I had a different kind by default. It makes sense now to think about it. I'm not used to playing games on Linux.

Played a short bit just now, everything seems to run super right now.
Android Software Engineer
Try my hands-free notification reader for your car.
Phipsz
Posts: 335
Joined: Mon, 23. Apr 12, 23:56
x4

Re: Linux Support (Beta)

Post by Phipsz »

Mahi Ma wrote: Wed, 6. Mar 19, 17:47 I got the latest AchLinux, AMD Vega 56 and Ryzen R7 2700, 32gb ram.
mesa-18.3.4-1 and radv (Vulkan 1.1.2.0)

The intro is visible, the music audible but then it freezes the screen and I get colorful dots everywhere.
Need to kill X to fix. . .

I tried both, 2.0 and the current 2.20 beta
Which GPU driver is loaded? radeon or amdgpu?
Mahi Ma
Posts: 76
Joined: Mon, 16. Mar 15, 14:10
x4

Re: Linux Support (Beta)

Post by Mahi Ma »

Phipsz wrote: Wed, 6. Mar 19, 19:50
Mahi Ma wrote: Wed, 6. Mar 19, 17:47 I got the latest AchLinux, AMD Vega 56 and Ryzen R7 2700, 32gb ram.
mesa-18.3.4-1 and radv (Vulkan 1.1.2.0)

The intro is visible, the music audible but then it freezes the screen and I get colorful dots everywhere.
Need to kill X to fix. . .

I tried both, 2.0 and the current 2.20 beta
Which GPU driver is loaded? radeon or amdgpu?
Radeon
edmondo
Posts: 14
Joined: Wed, 6. Nov 02, 20:31
x4

Re: Linux Support (Beta)

Post by edmondo »

Mahi Ma wrote: Wed, 6. Mar 19, 19:52
Phipsz wrote: Wed, 6. Mar 19, 19:50
Mahi Ma wrote: Wed, 6. Mar 19, 17:47 I got the latest AchLinux, AMD Vega 56 and Ryzen R7 2700, 32gb ram.
mesa-18.3.4-1 and radv (Vulkan 1.1.2.0)

The intro is visible, the music audible but then it freezes the screen and I get colorful dots everywhere.
Need to kill X to fix. . .

I tried both, 2.0 and the current 2.20 beta
Which GPU driver is loaded? radeon or amdgpu?
Radeon
I don't think there is a Vega support in the radeon driver. It has to be amdgpu. Also for radv (vulkan) you need to have the amdgpu.

You could try following and see if you get a similar result:

Code: Select all

$ lsmod | grep amdgpu
amdgpu               2617344  38
chash                  16384  1 amdgpu
backlight              16384  1 amdgpu
gpu_sched              32768  1 amdgpu
ttm                    86016  1 amdgpu
And if you have vulkaninfo installed, could you look if you have something simalar to this? The string after "GPU id : 0" interests me:

Code: Select all

Presentable Surfaces:
=====================
GPU id       : 0 (AMD RADV POLARIS10 (LLVM 8.0.0))
Surface type : VK_KHR_xcb_surface

Return to “X4: Foundations - Technical Support”