Skip to content

Instantly share code, notes, and snippets.

@tsunyoku
Last active April 14, 2024 13:10
Show Gist options
  • Star 54 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tsunyoku/354fa74945d9477b583b2e645c7d88b2 to your computer and use it in GitHub Desktop.
Save tsunyoku/354fa74945d9477b583b2e645c7d88b2 to your computer and use it in GitHub Desktop.
osu! install guide for Linux (up-to-date)

osu! install guide for Linux

I know a lot of people have been facing issues setting up osu! on Linux. Most of the guides online are either outdated or just all over the place, so I hope to maintain a good guide here that is relatively easy to follow.

I'd like to start by saying I have only tested this on Debian-based distributions, however it should work fine on others.

If you have any problems during or after installation, please don't hesitate to contact me on Discord (tsunyoku#0066) and I will try my best to help.

Installing Lutris

To start with the osu! installation, we want to install Lutris. Lutris is the program that will manage all the wine bullshit for us.

To install on Ubuntu or other Debian-based software:

sudo add-apt-repository ppa:lutris-team/lutris
sudo apt update
sudo apt install lutris

To install on Arch-based distributions:

sudo pacman -S lutris

For other distributions, see here.

Installing osu!

Once Lutris is installed, we need to install osu! through Lutris. Lutris will be available as a regular application so find it and open it.

Once it is open, you will see a sidebar with a heading called Sources. Press on the Lutris option and then type osu! in the Search games search bar. You will find osu! here. Click on it and press Install.

It'll come up with a dialog asking to select what version to install, scroll until you see a version called Windows and then continue. Lutris will begin installing dependencies and osu! itself. This can take anywhere between 2 and 15 minutes from my experience so just wait it out.

Once it has installed, try to play it to verify that it opens. Audio and other things may be glitchy, but we will fix that below. If it doesn't open at all or there is an error, scroll to the Known Issues section and see if that solves your problem. If not, feel free to contact for help!

Optimising osu!

Once you have installed osu! and it can run, close it and we will begin a series of fixes/optimisations to make your experience better.

First, we want to use ThePooN's winepulse patches for audio. Run these commands in a Terminal window:

cd ~/.local/share/lutris/runners/wine/lutris-osu-2-x86_64/lib/wine && rm -rf winepulse.drv.so && wget https://blog.thepoon.fr/assets/articles/2018-06-16-osuLinuxAudioLatency/32bit/winepulse.drv.so
cd ~/.local/share/lutris/runners/wine/lutris-osu-2-x86_64/lib64/wine && rm -rf winepulse.drv.so && wget https://blog.thepoon.fr/assets/articles/2018-06-16-osuLinuxAudioLatency/64bit/winepulse.drv.so

Once we have applied the patches, we need to edit pulse's config to help with latency:

sudo mkdir -p /etc/pulse/daemon.conf.d/
echo "high-priority = yes
nice-level = -15

realtime-scheduling = yes
realtime-priority = 50

resample-method = speex-float-0

default-fragments = 2 # Minimum is 2
default-fragment-size-msec = 2 # You can set this to 1, but that will break OBS audio capture." | sudo tee -a /etc/pulse/daemon.conf.d/10-better-latency.conf

Now, we want to increase our user's priority (you will probably need to run this with sudo su):

REMEMBER TO REPLACE USERNAME WITH YOUR USERNAME

echo "USERNAME - nice -20

USERNAME - rtprio 99" >> /etc/security/limits.conf

Next we need to do some more config editing.

Open pulse's default config like so:

sudo nano -c /etc/pulse/default.pa

Once you are in the config, look for this line: load-module module-udev-detect (it was around line 52 for me) Once you have found this line, add tsched=0 on the end of this line so it looks like so: load-module module-udev-detect tsched=0. Then save and exit.

Next, we need to add a environment variable to our osu! install before restarting to finish our installation. Open up Lutris again and you should find osu! in your Games library. Right click it and press configure.

Go to the System options tab and scroll until you find a Environment variables table. In the Key box, type STAGING_AUDIO_DURATION (case sensitive) and set the Value to 5000.

Then press save and you should be good to go! Note that you must restart your system first. After you reboot and open osu!, make sure to set Audio compatibility mode on, otherwise your audio will be very fucked.

Known Issues

After restarting or upon first open, the osu! splash screen appears and shortly closes.

This is due to some Lutris dependency stuff. We can fix it though! Open up a Terminal window and run these commands:

apt remove gamemode
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/gamemode_1.6.1-1_amd64.deb
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/gamemode-daemon_1.6.1-1_amd64.deb
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/libgamemode0_1.6.1-1_amd64.deb
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/libgamemodeauto0_1.6.1-1_amd64.deb
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/libgamemode0_1.6.1-1_i386.deb
wget http://ftp.us.debian.org/debian/pool/main/g/gamemode/libgamemodeauto0_1.6.1-1_i386.deb
apt install -f ./gamemode_1.6.1-1_amd64.deb ./gamemode-daemon_1.6.1-1_amd64.deb ./libgamemode0_1.6.1-1_amd64.deb ./libgamemodeauto0_1.6.1-1_amd64.deb ./libgamemode0_1.6.1-1_i386.deb ./libgamemodeauto0_1.6.1-1_i386.deb

Once it's done, reboot your system and try again.

My Discord Rich Presence doesn't show or it's incorrect

First, you will need to download an IPC bridge for Discord which you can find here. You will need to run the exe in the same wine prefix as your osu!, and the best way is probably to make it run in a pre-startup script in Lutris.

If after this, it still doesn't work then chances are that you have installed Discord using snap so the ipc locations are different. In this case, we can just symlink like so:

ln -s /run/user/<id>/snap.discord/discord-ipc-0 /run/user/<id>/discord-ipc-0

Note: I believe the id should be 1000 for everyone, but I maybe wrong hence why I've left it for you to work out. Just cd into /run/user and you'll find it.

My cursor keeps teleporting when I use my tablet

Chances are, you installed OpenTabletDriver and use them as your drivers. Some distributions some with drivers for tablets also, and they are clashing.

To fix this problem we just need to disable the ones in your kernel like so: sudo rmmod wacom if you are using a Wacom tablet. If you aren't using a Wacom tablet, then I would do some research to find out what it's called as I have no clue.

You will need to run this at every startup, so feel free to make a startup script for it.

Other common problems can usually be found here so I recommend you also look around here. If you're still having problems with your tablet or it isn't disabling, I recommend you join the OpenTabletDriver Discord server as the support there is generally very good.

'NoneType' object has no attribute 'lower'

Right click osu! in your Lutris library and press Configure. Go to the Runner options tab and disable Enable DXVK/VKD3D option. Press save and run osu! again and it should work correctly.

Black screen when opening osu!

Install lib32-libxcomposite.

Note: this is also sometimes a problem with pulse so ensure lib32-libpulse is also installed if the above lib doesn't fix it for you.

Useful things

Importing maps

I've yet to find an efficient way to do this with Lutris yet. You can find your osu! install in /home/<your username>/Games/osu/drive_c/osu (unless you manually changed it.)

Update: If you are using Arch there is a package to handle maps/skins for you. You can find it here. I will do more research into making this work for other distros and update this later.

Download any maps you want from the website and place the .osz files in your Songs folder, F5 in game will take care of them for you.

Importing skins

Skins are a nightmare. Download the skin you want and open the .osk file in your Archive Manager.

Update: If you are using Arch there is a package to handle maps/skins for you. You can find it here. I will do more research into making this work for other distros and update this later.

Navigate to your osu! install folder (you can find it in the part above) and go to your Skins folder.

Create a new folder for the Skin naming it whatever you want and then drag the contents of the .osk from your Archive Manager into it. Then, ingame press the keybind CTRL + SHIFT + S to reload your current skin and the skin list, where you will find your new skin.

Desktop shortcut for osu!

Lutris is actually handy in the sense it can create them for you. Right click osu! in your Lutris library and there is a button to create a shortcut.

If you are like me and use Ubuntu 20.04 or later, there is a very irritating process with allowing shortcuts to run. Right click the shortcut you find on your desktop and press properties. Go to the permissions tab and ensure that it is allowed to run and then it should work.

PP Counter

I've not tested StreamCompanion, but I can say gosumemory works really well.

Head over to the github repo and go to the releases tab. Download the linux version and extract the zip somewhere.

Before we can use gosumemory we need to setup the config, so run sudo ./gosumemory to generate one. Open the config.ini file and we will do some configuring. First, set wine to True since osu! is running using wine.

Since we are running on Wine, we will need to set our Songs path manually.

By default this is /home/<your username>/Games/osu/drive_c/osu/Songs but you can set it accordingly if you edited it yourself.

Once you've edited these 2 entries, you are good to go and you can run it by using sudo ./gosumemory.

With this version, the ingame overlay won't be available to you as it is running natively.

If you want the ingame overlay, you can download the Windows version and run it in Lutris' wine prefix for osu! however I never got it working so I won't provide instructions for that here yet.

If you're having troubles at any point with gosumemory, then I suggest you join their discord.

@asukaminato0721
Copy link

Another way: not install , but easier.

Go to https://github.com/ppy/osu/releases?page=1

Download osu.AppImage, chmod +x osu.AppImage , then run it.

@tsunyoku
Copy link
Author

Another way: not install , but easier.

Go to https://github.com/ppy/osu/releases?page=1

Download osu.AppImage, chmod +x osu.AppImage , then run it.

This is for osu!lazer - the future client. Yes this is easier and it works, but lazer is still a work in progress and for those wanting to compete online it is useless. The current osu! client has no AppImage and so my guide is relevant for 90% of people

@gabman15
Copy link

Hi, I'm running into a lot of problems on my system, would you mind adding me on discord? I just sent you a friend request (Lord_GabeM#8535)

@jxu
Copy link

jxu commented Dec 9, 2021

I had the issue of the splash screen appearing and then game disappearing - maybe due to an older (2019) more manual installation of osu with winetricks.

Started initial process 416277 from /home/jx/.local/share/lutris/runners/wine/lutris-osu-2-x86_64/bin/wine /home/jx/osu/drive_c/osu/osu!install.exe
Start monitoring process.
0234:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0234:fixme:ntdll:EtwEventRegister ({319dc449-ada5-50f7-428e-957db6791668}, 0x101fb8f0, 0x10741058, 0x10741070) stub.
0234:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x100109ad, 28) stub
0234:fixme:kernelbase:QuirkIsEnabled3 (0031F510, FFFFFFFF) stub!
0234:fixme:heap:GetNumaHighestNodeNumber semi-stub: 0031FC40
0234:fixme:ntdll:EtwEventRegister ({e13c0d23-ccbc-4e12-931b-d9cc2eee27e4}, 0x10334330, 0x10741100, 0x1074c108) stub.
0234:fixme:ntdll:EtwEventRegister ({763fd754-7086-4dfe-95eb-c01a46faf4ca}, 0x10334330, 0x10742258, 0x107422c8) stub.
0234:fixme:ntdll:EtwEventRegister ({a669021c-c450-4609-a035-5af59af4df18}, 0x10334330, 0x1074ac30, 0x1074c118) stub.
0234:fixme:ntdll:EtwEventRegister ({cc2bcbba-16b6-4cf3-8990-d74c2e8af500}, 0x10334330, 0x10741220, 0x10741288) stub.
0234:fixme:seh:WerRegisterRuntimeExceptionModule (L"C:\\windows\\Microsoft.NET\\Framework\\v4.0.30319\\mscordacwks.dll", 10000000) stub
01ec:err:ole:CoGetContextToken apartment not initialised
0234:fixme:process:GetEnabledXStateFeatures 
0234:fixme:ntdll:EtwEventRegister ({35167f8e-49b2-4b96-ab86-435b59336b5e}, 0x10d0526, (nil), 0x1579ff8) stub.
0234:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x1579fa0, 65) stub
0234:fixme:path:parse_url failed to parse L"System.Windows.Forms"
0234:fixme:path:parse_url failed to parse L"System.Security"
0234:fixme:path:parse_url failed to parse L"System.Xml"
0234:fixme:path:parse_url failed to parse L"System"
0234:fixme:path:parse_url failed to parse L"System.Configuration"
0234:fixme:path:parse_url failed to parse L"System.Drawing"
0234:fixme:path:parse_url failed to parse L"Accessibility"
0234:fixme:path:parse_url failed to parse L"System.Core"
0234:fixme:path:parse_url failed to parse L"System.Deployment"
0234:fixme:path:parse_url failed to parse L"System.Runtime.Serialization.Formatters.Soap"
0234:fixme:path:parse_url failed to parse L"System"
0234:fixme:path:parse_url failed to parse L"System.Drawing"
0234:fixme:nls:LCIDToLocaleName unsupported flags 8000000
0234:fixme:nls:get_dummy_preferred_ui_language (0x8 0x31dc90 (nil) 0x31dc94) returning a dummy value (current locale)
0234:fixme:nls:get_dummy_preferred_ui_language (0x8 0x31dc90 0x37f7c30 0x31dc94) returning a dummy value (current locale)
0234:fixme:ntdll:EtwEventRegister ({8e9f5090-2d75-4d03-8a81-e5afbf85daf1}, 0x10d054e, (nil), 0x157f71c) stub.
0234:fixme:path:parse_url failed to parse L"System.Core"
0234:fixme:path:parse_url failed to parse L"System.Numerics"
0234:fixme:path:parse_url failed to parse L"osu!.resources"
0234:fixme:nls:LCMapStringEx unsupported lparam 380b760
0234:fixme:path:parse_url failed to parse L"osu!.resources"
0234:fixme:amsi:AmsiInitialize L"DotNet", 0031E6C8
0234:fixme:amsi:AmsiScanBuffer DEADBEEF, 02579540, 223232, (null), 00000000, 0031E6BC
0234:fixme:path:parse_url failed to parse L"System.Configuration"
0234:fixme:path:parse_url failed to parse L"System.Xml"
0234:fixme:path:parse_url failed to parse L"System.Data.SqlXml"
0234:fixme:ntdll:NtQuerySystemInformation (0x000000ce,0x31e87c,0x00000008,(nil)) stub
0234:fixme:bcrypt:BCryptGetFipsAlgorithmMode 0x31e6a4 - semi-stub
079c:fixme:sync:SetWaitableTimerEx (000001DC, 0778FEB4, 500, 00000000, 00000000, 00000000, 50) semi-stub
06c4:fixme:exec:SHELL_execute flags ignored: 0x00000100
0614:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0614:fixme:ntdll:EtwEventRegister ({319dc449-ada5-50f7-428e-957db6791668}, 0x101fb8f0, 0x10741058, 0x10741070) stub.
0614:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x100109ad, 28) stub
0614:fixme:kernelbase:QuirkIsEnabled3 (0031F510, FFFFFFFF) stub!
0614:fixme:heap:GetNumaHighestNodeNumber semi-stub: 0031FC40
0614:fixme:ntdll:EtwEventRegister ({e13c0d23-ccbc-4e12-931b-d9cc2eee27e4}, 0x10334330, 0x10741100, 0x1074c108) stub.
0614:fixme:ntdll:EtwEventRegister ({763fd754-7086-4dfe-95eb-c01a46faf4ca}, 0x10334330, 0x10742258, 0x107422c8) stub.
0614:fixme:ntdll:EtwEventRegister ({a669021c-c450-4609-a035-5af59af4df18}, 0x10334330, 0x1074ac30, 0x1074c118) stub.
0614:fixme:ntdll:EtwEventRegister ({cc2bcbba-16b6-4cf3-8990-d74c2e8af500}, 0x10334330, 0x10741220, 0x10741288) stub.
0614:fixme:seh:WerRegisterRuntimeExceptionModule (L"C:\\windows\\Microsoft.NET\\Framework\\v4.0.30319\\mscordacwks.dll", 10000000) stub
Monitored process exited.
Initial process has exited (return code: 65280)
Exit with return code 65280

There are also these warnings (lutris script appears to use an old version of wine)

warning: Your version of wine 4.11-9594-g532f6014d8a is no longer supported upstream. You should upgrade to 5.x

warning: You are using a 64-bit WINEPREFIX. Note that many verbs only install 32-bit versions of packages. If you encounter problems, please retest in a clean 32-bit WINEPREFIX before reporting a bug.

Trying to run osu anyway with say WINEPREFIX=~/Games/osu; wine osu!\.exe just says wine mono is not installed.

@jxu
Copy link

jxu commented Dec 29, 2021

https://osu.ppy.sh/community/forums/topics/794952?n=1 this seems more reliable since it uses pre-packaged wine prefix

@melcone
Copy link

melcone commented Mar 7, 2022

I followed your guide but this message appears whenever I try to open osu!:
image

@Karlono05
Copy link

hello, so i followed your guide, but when i installed osu, and tried to open it, it showed me this
Screenshot from 2022-03-11 20-26-14
:

@melcone
Copy link

melcone commented Mar 17, 2022

I followed your guide but this message appears whenever I try to open osu!: image

Fix: go to your osu directory and open osu!.(name).cfg, find CompatibilityContext and change 0 to 1.

@glu8716
Copy link

glu8716 commented Mar 21, 2022

@melcone Another way to fix this is to disable DXVK NVAPI from Lutris in the game's settings. I don't know which is the better workaround tho, as I'm not an advanced user. Maybe someone can explain what is going on here?

@INDIG0N
Copy link

INDIG0N commented Mar 31, 2022

@tsunyoku I'm having the same problem as Karlono05
I'm also having a permissions issue with limits.conf and I can't seem to change the permissions through chmod, but mainly it's the no executeable set problem.

@INDIG0N
Copy link

INDIG0N commented Mar 31, 2022

@tsunyoku
uuuh, ok nevermind about the osu problem, following the guide has messed up my audio, badly. I don't know if it has anything to do with the /etc permission problems, but for the moment, do you know how I can undo the audio changes?

@INDIG0N
Copy link

INDIG0N commented Mar 31, 2022

Nevermind, I was able to fix the audio.

If anyone else has this issue, restoring the default.pa file and removing the STAGING_AUDIO_DURATION environment variable fixed it. Still can't launch osu! but that's much less dire. Keeo in mind I'm using ubuntu 20.04, so yuor mileage may vary depending on your OS.

@not-lucky
Copy link

Has anyone checked whether pipewire after some optimizations provides better audio compatibility and latency than the poon's patch?

@Dizzy611
Copy link

Dizzy611 commented Nov 5, 2022

The lutris ppa doesn't exist anymore and hasn't existed as of at least a month ago.

lutris/lutris#4558

@kz-n
Copy link

kz-n commented Nov 13, 2022

Hello, i followed your guide, however i get really poor performance (20fps). I've sent you a friend request on discord, I'm kz-n#1350

@Zerogoki00
Copy link

I followed your guide by my osu crashes when I try to play a map :(

@Bubelka
Copy link

Bubelka commented Mar 18, 2023

Guys, try this:
https://github.com/Francesco149/linux-osu

I'm on Fedora and it's works
srry for my eng, i'm from Russia :")

@FlySlime
Copy link

FlySlime commented Sep 21, 2023

This is the most up-to-date osu!stable installer for Linux. Only one that worked for me, and works flawlessly at that.

@yellowbadbeast
Copy link

How do you log in to an account? It just says to verify my account, but nothing happens when I click the dialogue..

@zyn23
Copy link

zyn23 commented Nov 3, 2023

If I already have a partition with osu! installed and want to use that partition for this osu instalation...( Like in mcosu) Is that possible?

@mys1erious
Copy link

In case anyone else has an issue with game crashes after a few seconds of playing the map, disabling Audio compatibility mode helped me

@vtrgnc
Copy link

vtrgnc commented Jan 22, 2024

If I already have a partition with osu! installed and want to use that partition for this osu instalation...( Like in mcosu) Is that possible?

if you mean like a dual-boot with windows that has osu! installed, i think the best option still would be to copy over that installation to your new lutris directory, since using the windows partition could make some undesirable damage (it uses a different filesystem than Linux, and it may overwrite some data while reading/writing)

@Afdusrt
Copy link

Afdusrt commented Apr 14, 2024

black screen upon startup, I can hear sounds and interact, but not see. arch and i3wm

FIX: spam until you enter a map or the editor, exit the map or editor and you can see!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment