steam_deck_encryption icon indicating copy to clipboard operation
steam_deck_encryption copied to clipboard

Make game data not encrypted

Open e-minguez opened this issue 2 years ago • 4 comments

While ideally everything must be encrypted, game data can earn some performance if they are not encrypted. Maybe maintaining a symlink on the proper .local data folder to the non crypted folder....

e-minguez avatar Jul 23 '23 10:07 e-minguez

LUKS is quite fast to notice any delay on most games (I see ~2G / s encryption/decryption speed with cryptsetup benchmark).

But may be it can speed up loading textures for some really heavy games? Would be worth checking to see if we indeed see any difference (my guess is that it would be imperceptible but I'm happy to be proven wrong).

If you want to try it, I suggest letting steam manage it by adding a path to an unencrypted location in Steam's storage settings (i.e. Option 2).

Option 1: Symlink ourselves

This involves moving and symlinking /home/deck/.local/share/Steam/steamapps somewhere, e.g. into /home/_unencrypted_steamapps.

I am fairly sure Steam should work fine with this.

Option 2: Add unencrypted directory to Steam storage settings

This may be simpler and safer. Create a common directory -

sudo mkdir /home/_unencrypted_games
sudo chown deck:deck /home/_unencrypted_games

And just add it to Settings --> Storage from the Steam UI.

This will allow Steam to fully manage the directory, and also allow us to choose destinations of games.

hirak99 avatar Jul 23 '23 13:07 hirak99

I don't have any numbers and I've read opinions on both fronts (see https://scs.community/2023/02/24/impact-of-disk-encryption/ for a recent one). I'll try to find time to try your second approach as it seems easier. Thanks.

e-minguez avatar Jul 23 '23 19:07 e-minguez

SG. Let me know if you run into any issues.

hirak99 avatar Jul 23 '23 19:07 hirak99

Creating a new library works like a charm. The only detail is that the shader cache and compdata is still stored in the encrypted container but it can be solved with a couple of symlinks. Thanks!

e-minguez avatar Jun 11 '24 04:06 e-minguez

You're welcome. Resolving.

hirak99 avatar Nov 12 '24 17:11 hirak99