gamemode: ERROR: ld.so: object '/usr/$LIB/libgamemodeauto.so.0' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.

Describe the bug If I attempt to use any other runner in lutris besides “lutris-5.6-2-x86_64” the game(battle.net) will not load and I receive the following error message in the logs: Running gamemoderun /opt/wine-staging/bin/wine /home/mike/Games/battlenet/drive_c/Program Files (x86)/Battle.net/Battle.net.exe Initial process has started with pid 13467 Game is considered started. ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. neboot.exe: unix/virtual.c:581: free_ranges_remove_range: Assertion range->base <= view_base && range->end >= view_end' failed. plorer.exe: unix/virtual.c:581: free_ranges_remove_range: Assertion range->base <= view_base && range->end >= view_end’ failed. ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. t=48: unix/virtual.c:581: free_ranges_remove_range: Assertion `range->base <= view_base && range->end >= view_end’ failed. [0610/144414.001:ERROR:network_change_notifier_win.cc(156)] WSALookupServiceBegin failed with: 0 ERROR: ld.so: object ‘/usr/$LIB/libgamemodeauto.so.0’ from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored. Initial process has exited. Game is considered exited. All monitored processes have exited. Exit with returncode 256

To Reproduce Steps used to reproduce the behavior:

  1. using Lutris to launch Battle.net application
  2. installed from lutris script
  3. prefix exectuable with “gamemoderun”
  4. See error

Expected behavior I expect the game to load

System Info (please complete the following information):

  • Linux pop-os 5.4.0-7634-generic #38~1591219791~20.04~6b1c5de-Ubuntu SMP
  • GameMode Version now 1.5.1-0ubuntu3.1 amd64 [installed]

Additional context I’m using Lutris. I installed Lutris and all dependencies. After that, I used Lutris to install Battle.net using this script. I then launched Battle.net and installed World of Warcraft(bfa) from there. The Default lutris settings have Battle.net running "lutris-5.6-2-x86_64 as the runner. Battle.net will launch properly with this setting. If I change that setting however to “WineHQ Staging 5.10”, the program will NOT launch and when I check the logs, I see the errors which I’ve posted in the beginning of this thread.

Thank you very much for looking into this.

About this issue

  • Original URL
  • State: open
  • Created 4 years ago
  • Reactions: 7
  • Comments: 36 (11 by maintainers)

Most upvoted comments

Where did you download the files to? The path /gamemode/ sounds rather wrong to me.

Please run the following code:

cd /tmp
mkdir gamemode
cd gamemode
sudo apt remove *gamemode* --autoremove
wget http://ftp.debian.org/debian/pool/main/g/gamemode/gamemode_1.6.1-1_amd64.deb http://ftp.debian.org/debian/pool/main/g/gamemode/gamemode-daemon_1.6.1-1_amd64.deb http://ftp.debian.org/debian/pool/main/g/gamemode/libgamemode0_1.6.1-1_amd64.deb http://ftp.debian.org/debian/pool/main/g/gamemode/libgamemodeauto0_1.6.1-1_amd64.deb http://ftp.debian.org/debian/pool/main/g/gamemode/libgamemode0_1.6.1-1_i386.deb http://ftp.debian.org/debian/pool/main/g/gamemode/libgamemodeauto0_1.6.1-1_i386.deb
sudo apt install ./gamemode_1.6.1-1_amd64.deb ./gamemode-daemon_1.6.1-1_amd64.deb ./libgamemode0_1.6.1-1_amd64.deb ./libgamemode0_1.6.1-1_i386.deb ./libgamemodeauto0_1.6.1-1_amd64.deb ./libgamemodeauto0_1.6.1-1_i386.deb

I installed gamemode using “apt install gamemode”(After adding the repository).

Yeah so you’re missing the 32bit libs. Remove gamemode (apt remove gamemode --autoremove), and download the Debian packages: https://packages.debian.org/sid/amd64/gamemode/download https://packages.debian.org/sid/amd64/gamemode-daemon/download https://packages.debian.org/sid/amd64/libgamemode0/download https://packages.debian.org/sid/amd64/libgamemodeauto0/download https://packages.debian.org/sid/i386/libgamemode0/download https://packages.debian.org/sid/i386/libgamemodeauto0/download

then install all .deb’s with this command:

apt install -f path/to/gamemode.deb path/to/gamemode-daemon.deb ...

This should fix your problem.

On Ubuntu 20.04 I installed gamemod in 64 AND 32 bits using this method: https://github.com/FeralInteractive/gamemode/issues/254#issuecomment-740117461 and I have no more errors messages. Why this packages are not available in Ubuntu 20.04???

I installed gamemode using “apt install gamemode”(After adding the repository).

Yeah so you’re missing the 32bit libs. Remove gamemode (apt remove gamemode --autoremove), and download the Debian packages: https://packages.debian.org/sid/amd64/gamemode/download https://packages.debian.org/sid/amd64/gamemode-daemon/download https://packages.debian.org/sid/amd64/libgamemode0/download https://packages.debian.org/sid/amd64/libgamemodeauto0/download https://packages.debian.org/sid/i386/libgamemode0/download https://packages.debian.org/sid/i386/libgamemodeauto0/download

then install all .deb’s with this command:

apt install -f path/to/gamemode.deb path/to/gamemode-daemon.deb ...

This should fix your problem.

I am having the same issue but following these instructions did not help, the message stays the same.

Here is the output of ls /usr/lib/*/libgamemodeauto.so.0:

/usr/lib/i386-linux-gnu/libgamemodeauto.so.0
/usr/lib/x86_64-linux-gnu/libgamemodeauto.so.0

Hi, I was also getting the same error message while I was trying to launch Dave the diver with ubuntu 22.04/Lutris/proton ERROR: ld.so: object 'libgamemodeauto.so.0' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS64): ignored.

I actually installed the latest gamemode debian packages:

apt list --installed \*gamemode\*
Listing... Done
gamemode-daemon/now 1.7-2+b1 amd64 [installed,local]
gamemode/now 1.7-2+b1 amd64 [installed,local]
libgamemode0/now 1.7-2+b1 amd64 [installed,local]
libgamemode0/now 1.7-2+b1 i386 [installed,local]
libgamemodeauto0/now 1.7-2+b1 amd64 [installed,local]
libgamemodeauto0/now 1.7-2+b1 i386 [installed,local]

All the tests are passing (and glxgears are working too):

gamemoded -t
: Loading config
Loading config file [/usr/share/gamemode/gamemode.ini]
: Running tests

:: Basic client tests
:: Passed

:: Dual client tests
gamemode request succeeded and is active
Quitting by request...
:: Passed

:: Gamemoderun and reaper thread tests
...Waiting for child to quit...
...Waiting for reaper thread (reaper_frequency set to 5 seconds)...
:: Passed

:: Supervisor tests
:: Passed

:: Feature tests
::: Verifying CPU governor setting
::: Passed
::: Verifying Scripts
::: Passed (no scripts configured to run)
::: Verifying GPU Optimisations
::: Passed (gpu optimisations not configured to run)
::: Verifying renice
::: Passed (no renice configured)
::: Verifying ioprio
::: Passed
:: Passed

: All Tests Passed!

the log doesn’t display any more error messages about wrong ELF class:

Started initial process 205968 from gamemoderun ~/.local/share/lutris/runners/wine/lutris-GE-Proton8-10-x86_64/bin/wine /home/obs/Games/dave-the-diver/drive_c/Games/Dave the Diver/UnityCrashHandler64.exe
Start monitoring process.
gamemodeauto: 
fsync: up and running.
wine: RLIMIT_NICE is <= 20, unable to use setpriority safely
Found 0 potential reports:
Done.
Initial process has exited (return code: 0)
Monitored process exited.
Exit with return code 0

But the game still doesn’t run. Am I missing something?

I installed gamemode using “apt install gamemode”(After adding the repository).

Yeah so you’re missing the 32bit libs. Remove gamemode (apt remove gamemode --autoremove), and download the Debian packages: https://packages.debian.org/sid/amd64/gamemode/download https://packages.debian.org/sid/amd64/gamemode-daemon/download https://packages.debian.org/sid/amd64/libgamemode0/download https://packages.debian.org/sid/amd64/libgamemodeauto0/download https://packages.debian.org/sid/i386/libgamemode0/download https://packages.debian.org/sid/i386/libgamemodeauto0/download

then install all .deb’s with this command:

apt install -f path/to/gamemode.deb path/to/gamemode-daemon.deb ...

This should fix your problem.

All mirrors give corrupted, unsecure files

Noting here that when running it right after trying to run the game I get:

This is to be expected, but it only happens right after the game, a couple of seconds later and it should be fine.

I realised my message is slightly different, and I am getting these errors when running via Lutris:

Can you run gamemoderun glxgears or something equivalent?

How did you install gamemode? Also, please provide the output of

ls /usr/lib/*/libgamemodeauto.so.0

I suspect that the 32bit libs are missing.