Try using this script to launch TF2 with optirun instead:
#!/bin/bash
# hl2.sh modified for TF2 and optirun
# http://steamcommunity.com/groups/LinuxOptimus
GAMEROOT=$(cd "${0%/*}" && echo $PWD)
STEAMPATH=$(readlink ~/.steampath)
export LD_LIBRARY_PATH="${GAMEROOT}"/bin:$LD_LIBRARY_PATH
if [ ! -z ${STEAMPATH} ]; then
export LD_LIBRARY_PATH="$(dirname ${STEAMPATH})":$LD_LIBRARY_PATH
fi
ulimit -n 2048
export __GL_THREADED_OPTIMIZATIONS=1
cd "$GAMEROOT"
if [ ! -f steam_appid.txt ]; then
echo "440" > steam_appid.txt
fi
LD_LIBRARY_PATH=~/Steam/ubuntu12_32:$LD_LIBRARY_PATH optirun ./hl2_linux -game tf -steam "$@" -novid
Place the script in ~/Steam/SteamApps/USERNAME/Team Fortress 2/ and launch it from there.
optirun is not recommended for running games using Steam. Use primusrun instead. See instructions here: http://www.webupd8.org/2012/11/primus-better-performance-and-less.html
Yes, but the issue he's experiencing would also occur with primus according to the thread he linked to on the Steam for Linux group. It is probably best to get it to work with optirun before using primusrun.
After further digging, it looks like the issue is that @terkhen's video card does not have the GL_EXT_draw_buffers2 extension which results in the entry point glColorMaskIndexedEXT being missing. @davidw-valve, using primus would have not solved this. Primus, to put it in simple terms, is a different method of OpenGL offloading.
There has been quite a bit of discussion at Steam for Linux group forums regarding this issue.
As mentioned in my original bug report, when I launched the previous version of the Steam client with primusrun, it failed to open Team Fortress 2 with the same error than optirun did. When I launch the current version of the Steam linux client with primusrun, it crashes with the following log:
Installing breakpad exception handler for appid(steam)/version(1355957371_client) Looks like steam didn't shutdown cleanly, scheduling immediate update check Installing breakpad exception handler for appid(steam)/version(1355957371_client) Installing breakpad exception handler for appid(steam)/version(1355957371_client) unlinked 4 orphaned pipes removing stale semaphore last operated on by process 1432 with name 0eBlobRegistryMutex_3908EC59FEE43C48EA7800F36B77C639 removing stale semaphore last operated on by process 1432 with name 0eBlobRegistrySignal_3908EC59FEE43C48EA7800F36B77C639 removing stale semaphore last operated on by process 1963 with name 0emSteamEngineInstance removing stale semaphore last operated on by process 1432 with name 0eSteamEngineLock Installing breakpad exception handler for appid(steam)/version(1355957371_client) (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:2045): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", The program 'steam' received an X Window System error. This probably reflects a bug in the program. The error was 'BadMatch (invalid parameter attributes)'. (Details: serial 24 error_code 8 request_code 154 minor_code 11) (Note to programmers: normally, X errors are reported asynchronously; that is, you will receive the error a while after causing it. To debug your program, run it with the --sync command line option to change this behavior. You can then get a meaningful backtrace from your debugger if you break on the gdk_x_error() function.) [1221/141856:ERROR:object_proxy.cc(239)] Failed to call method: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.NetworkManager was not provided by any .service files [1221/141856:WARNING:proxy_service.cc(646)] PAC support disabled because there is no system implementation CAsyncIOManager: 0 threads terminating. 0 reads, 0 writes, 0 deferrals. CAsyncIOManager: 40 single object sleeps, 2 multi object sleeps CAsyncIOManager: 0 single object alertable sleeps, 1 multi object alertable sleeps FATAL: exception not rethrown Uploading dump (in-process) [proxy ''] /tmp/dumps/crash_20121221141856_1.dmp peek of pipe from 0/0 failed: 11 success = yes response: CrashID=bp-46564443-1c82-49df-a0f7-6f9952121221 /home/terkhen/.local/share/Steam/steam.sh: line 287: 2045 Aborted (core dumped) $DEBUGGER "$STEAMROOT/$PLATFORM/$STEAMEXE" "$@"
I would also like to insist on this issue being mentioned on the Bumblebee tracker:
https://github.com/Bumblebee-Project/Bumblebee/issues/280#issuecomment-10524842
kramerc: Thank you but I would prefer to be able to run Team Fortress out of the box :)
Thank you for the link, I did not find any information in the forums when I searched before opening my own bug report.
__GL_THREADED_OPTIMIZATIONS=1x1 2012-12
I'm using Arch Linux. When I open Steam with Bumblebee (using optirun) I get a popup with the following error whenever I launch Team Fortress 2.
Could not find required OpenGL entry point 'glColorMaskIndexedEXT' Either your video card is unsupported, or your OpenGL driver needs to be updated.
When I launch Steam without Bumblebee, Team Fortress 2 opens fine.
This is the log I get when I try to open Team Fortress 2 with optirun:
Installing breakpad exception handler for appid(steam)/version(1355250651_client) [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. Installing breakpad exception handler for appid(steam)/version(1355250651_client) unlinked 0 orphaned pipes Installing breakpad exception handler for appid(steam)/version(1355250651_client) [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. surface_linux.cpp (1383) : Assertion Failed: X context is not using direct rendering. Unfasten your seatbelt... Assert( Assertion Failed: X context is not using direct rendering. Unfasten your seatbelt... ):/home/buildbot/buildslave_steam/steam_rel_client_ubuntu12_linux/build/src/vgui2/src/surface_linux.cpp:1383 Installing breakpad exception handler for appid(steam)/version(1355250651_client) (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", (steam:1360): Gtk-WARNING **: Unable to locate theme engine in module_path: "clearlooks", Uploading dump (in-process) [proxy ''] /tmp/dumps/assert_20121220200022_1.dmp [1220/200022:ERROR:object_proxy.cc(239)] Failed to call method: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.NetworkManager was not provided by any .service files [1220/200022:WARNING:proxy_service.cc(646)] PAC support disabled because there is no system implementation success = yes response: CrashID=bp-5ef07aaf-6e14-405e-9e8e-fa6e42121220 Installing breakpad exception handler for appid(steam)/version(1355250651_client) Installing breakpad exception handler for appid(steam)/version(1355250651_client) Installing breakpad exception handler for appid(steam)/version(1355250651_client) Installing breakpad exception handler for appid(steam)/version(1355250651_client) PulseAudio connect failed (used only for Mic Volume Control) with error: Access denied Generating new string page texture 2: 48x256, total string texture memory is 49.15 KB Generating new string page texture 3: 256x256, total string texture memory is 311.30 KB Installing breakpad exception handler for appid(steam)/version(1355250651_client) Installing breakpad exception handler for appid(steam)/version(1355250651_client) Installing breakpad exception handler for appid(steam)/version(1355250651_client) crypto.cpp (1320) : Assertion Failed: cubInput > 0 Installing breakpad exception handler for appid(steam)/version(1355250651_client) Adding license for package 964 Adding license for package 1070 Adding license for package 469 Adding license for package 1215 Adding license for package 1259 Adding license for package 1110 Adding license for package 636 Adding license for package 1995 Adding license for package 2483 Adding license for package 609 Adding license for package 34 Adding license for package 4323 Adding license for package 4991 Adding license for package 6896 Adding license for package 402 Adding license for package 4402 Adding license for package 7361 Adding license for package 7764 Adding license for package 7760 Adding license for package 297 Adding license for package 8647 Adding license for package 8535 Adding license for package 8644 Adding license for package 8648 Adding license for package 8645 Adding license for package 8635 Adding license for package 12225 Adding license for package 6424 Adding license for package 12164 Adding license for package 14728 Adding license for package 16557 Adding license for package 0 Adding license for package 13662 Adding license for package 17731 Adding license for package 16374 Adding license for package 17905 Adding license for package 18001 Adding license for package 18162 Adding license for package 16222 Adding license for package 18393 Adding license for package 16549 Adding license for package 18639 roaming config store loaded successfully - 5915 bytes. migrating temporary roaming config store ExecCommandLine: "/home/terkhen/.local/share/Steam/ubuntu12_32/steam" Generating new string page texture 70: 1024x256, total string texture memory is 1.36 MB Generating new string page texture 71: 128x256, total string texture memory is 1.49 MB Generating new string page texture 72: 128x256, total string texture memory is 131.07 KB Generating new string page texture 73: 64x256, total string texture memory is 1.56 MB Generating new string page texture 74: 32x256, total string texture memory is 1.59 MB System startup time: 16.26 seconds [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. Traceback (most recent call last): File "/home/terkhen/.local/share/Steam/ubuntu12_32/driverhelper.py", line 431, in sys.exit(main(sys.argv[1:])) File "/home/terkhen/.local/share/Steam/ubuntu12_32/driverhelper.py", line 368, in main pkgInfo.init((args[1], args[2], args[3])) File "/home/terkhen/.local/share/Steam/ubuntu12_32/driverhelper.py", line 276, in init f = file(self.cache_file, 'w') NameError: global name 'file' is not defined Generating new string page texture 77: 128x256, total string texture memory is 1.72 MB Generating new string page texture 80: 256x256, total string texture memory is 1.98 MB Generating new string page texture 106: 128x256, total string texture memory is 2.11 MB Installing breakpad exception handler for appid(steam)/version(1355250651_client) Generating new string page texture 108: 384x256, total string texture memory is 2.51 MB Game update: AppID 440 "Team Fortress 2", ProcID 1420, IP 0.0.0.0:0 ERROR: ld.so: object 'gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded: ignored. ERROR: ld.so: object 'gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded: ignored. ERROR: ld.so: object 'gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded: ignored. ERROR: ld.so: object 'gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded: ignored. ERROR: ld.so: object 'gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded: ignored. [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. SDL video target is 'x11' SDL video target is 'x11' [VGL] WARNING: The OpenGL rendering context obtained on X display [VGL] :8 is indirect, which may cause performance to suffer. [VGL] If :8 is a local X display, then the framebuffer device [VGL] permissions may be set incorrectly. SDL failed to create GL compatibility profile (whichProfile=0! This system supports the OpenGL extension GL_EXT_framebuffer_object. This system supports the OpenGL extension GL_EXT_framebuffer_blit. This system supports the OpenGL extension GL_EXT_framebuffer_multisample. This system DOES NOT support the OpenGL extension GL_APPLE_fence. This system supports the OpenGL extension GL_NV_fence. This system DOES NOT support the OpenGL extension GL_ARB_sync. This system DOES NOT support the OpenGL extension GL_EXT_draw_buffers2. Could not find required OpenGL entry point 'glColorMaskIndexedEXT'! Either your video card is unsupported, or your OpenGL driver needs to be updated. saving roaming config store to 'sharedconfig.vdf' roaming config store 2 saved successfully Game removed: AppID 440 "Team Fortress 2", ProcID 1420 saving roaming config store to 'sharedconfig.vdf' roaming config store 2 saved successfullyThe following text is my system information, as displayed by Steam when I run it with optirun.
Processor Information: Vendor: GenuineIntel Speed: 2301 Mhz 8 logical processors 4 physical processors HyperThreading: Supported FCMOV: Supported SSE2: Supported SSE3: Supported SSSE3: Supported SSE4a: Unsupported SSE41: Supported SSE42: Supported Network Information: Network Speed: Operating System Version: "Arch Linux" (64 bit) Kernel Name: Linux Kernel Version: 3.6.10-1-ARCH X Server vendor: The X.Org Foundation X Server release: 11301000 Video Card: Driver: NVIDIA Corporation GeForce GT 650M/PCIe/SSE2 Driver Version: 2.1.2 NVIDIA 313.09 Desktop Color Depth: 24 bits per pixel Monitor Refresh Rate: 59 Hz VendorID: 0x10de DeviceID: 0xfd1 Number of Monitors: 1 Number of Logical Video Cards: 2 Primary Display Resolution: 1920 x 1080 Desktop Resolution: 1920 x 1080 Primary Display Size: 13.58" x 7.64" (15.55" diag) 34.5cm x 19.4cm (39.5cm diag) Primary VRAM: 0 MB Sound card: Audio device: Intel PantherPoint HDMI Memory: RAM: 7883 Mb Miscellaneous: UI Language: English LANG: en_US.UTF-8 Microphone: Not set Total Hard Disk Space Available: 446146 Mb Largest Free Hard Disk Block: 338480 Mb Installed software: Recent Failure Reports: Thu Dec 20 18:53:52 2012 GMT: file ''/tmp/dumps/assert_20121220195350_1.dmp'', upload yes: ''CrashID=bp-f8fb0839-f78c-4bfc-b009-3fcef2121220'' Thu Dec 20 19:00:24 2012 GMT: file ''/tmp/dumps/assert_20121220200022_1.dmp'', upload yes: ''CrashID=bp-5ef07aaf-6e14-405e-9e8e-fa6e42121220''This issue was also reported before on the forums, at the following post: http://steamcommunity.com/app/221410/discussions/1/846939854072203387/