protonscr

Encrypted /home folder causes Steam to go crazy

steamclosed reviewedSteam client
ValveSoftware/steam-for-linux#2515 · opened 2013-05-23 by ghost · updated 2016-01-09 · 42 comments · github
?ghost 2013-05-23 github

Basically if I have a encrypted folder I can download any source game (from what I could see) and after verifiyng the game's cache Steam starts the download again.

More: https://github.com/ValveSoftware/Source-1-Games/issues/706#issuecomment-18354354, https://github.com/ValveSoftware/Source-1-Games/issues/584, https://github.com/ValveSoftware/Source-1-Games/issues/717#issuecomment-18089731


Update: Added a video showing what happened after downloading Counter Strike Source. I copied the folder before verifiying the cache so I don't have to download it again. The game works fine tho.

http://www.youtube.com/watch?v=mhPqBIx39Ms

Ubuntu 12.04.2 64bit
AMD Athlon II X2 250 @3.6GHz
NVIDIA 9800GT - driver version 310-Experimental

?ghost 2013-05-24 github

Update: Happens with Counter Strike as well.

?ghost 2013-05-31 github

Any news?

Jjohndrinkwater 2013-06-01 github

It’s being looked into, @martino-valve is assigned.

?ghost 2013-06-17 github

Still no fix?

Mmadsl 2013-06-23 github

I'm experiencing this as well. Had Half-Life 2 downloaded to an encrypted volume (xfs on cryptsetup on mdadm RAID 10), now I have to redownload it after the Steam-client has been offline for a while.

?ghost 2013-06-23 github

@madsl I learned to make a copy of all my games on Linux and WIndows as well, you never know when a problem might appear =)

Mmadsl 2013-06-24 github

@amarildojr that does leave us non-windows users out a bit in the cold though :) But as things are now, I can't have a Steam Library folder on an encrypted volume. But it did work to move the completed downloaded files over to a steam library folder that wasn't encrypted, and then reinstall the game to that library location. Steam now finds the files you placed there. Can't remember that feature in the Linux version before, so that's nice I guess...

Ddietrmat 2013-06-24 github

It's also an issue with Ubuntu 13.04 x64

?ghost 2013-06-25 github

Basically any distro that encrypts the /home folder.

Full disk encryption on the other hand does not cause this.

Aalfred-valve maintainer 2013-07-30 github

Can you post the content_log.txt from the logs/ folder under your steam install please.

?ghost 2013-07-30 github

Hi @alfred-valve . I don't have an encrypted /home folder anymore.

Aalfred-valve maintainer 2013-07-30 github

@amarildojr , so you no longer have this bug then?

?ghost 2013-07-30 github

@alfred-valve No, because I use partition encryption now. But I know there are lost of people out there who are still facing this issue.

?ghost 2013-07-31 github

No one asked, but here is my "content_log.txt": https://gist.github.com/forever1percent/f0bcbd007b7d355542ea

Don't know if it's clear from the log, but with TF2 I tried to use files copied from Windows install

Hhellmind 2013-09-05 github

SteamCMD fails to validates files if you are using zfs or a non ext3/4 filesystem

Ggoooooal 2013-10-29 github

During installation Ubuntu offers option to ecnrypt home directory, which puts all user files on ecryptfs. When verifying integrity of game cache, Steam tries to use Direct I/O (open with O_DIRECT flag), which is not implemented for encryptfs. Validation fails with"Validation: file locked" logged in content_log.txt and all game files are downloaded again, whether they are really broken or not.

Would it be possible to add immediate second open call without O_DIRECT, just after the first one (with O_DIRECT) fails with EINVAL, before giving up on a file completely? It's still better to have verification run slower than to redownload everything, isn't it?

Ssebleblanc 2013-12-28 github

Also having this issue.

?ghost 2013-12-28 github

I strongly suggest you either using the alternate install to encrypt THE DISK and not the /home folder, or move away from Ubuntu. Debian is way better.

I'm using Arch and never had this problem.

Ssebleblanc 2013-12-28 github

It is actually an eCryptfs directory that was carried over from an OEM Ubuntu install to Arch Linux. I am running Arch.

?ghost 2013-12-28 github

Then I would back up my data and re-install everything.

I use 4 partitions, 1 for /boot and the rest encrypted (root, swap, home). It's much safer than just encrypt the home folder.

I can put all the commands needed here, if you want.

Ggoooooal 2013-12-29 github

Or even better install Windows 7, you'll have so much better gaming experience.

Why does Steam need to use O_DIRECT? https://lkml.org/lkml/2007/1/10/233

?ghost 2013-12-29 github

We're here to discuss Linux issues. We're not here because we want advises to install Windows.

Ggoooooal 2013-12-29 github

But we're here to suggest someone with perfectly working Linux installation changing their Linux OS or partitions layout, only because there's one application using rare feature and only for rarely executed function - verification of cache integrity.

No, thank you.

?ghost 2013-12-29 github

That's the main thing. We're here to discuss this issue and try to find a solution. Windows is NOT a solution, otherwise we would be using it and not being here to discuss LINUX ISSUES.

Since I'm the only user of this machine I don't feel the need to encrypt the /home folder when I can encrypt the whole disk. My suggestion was to encrypt the disk and not the /home folder since it's a much more secure solution to privacy and also doesn't cause this bug to happen.

Ggoooooal 2013-12-29 github

On the other hand my suggestion is not to use O_DIRECT, which is deprecated and strongly advised against by the very creator of the system we're all running.

@martino-valve: are you alive? do you care to comment?

?ghost 2013-12-29 github

I don't get it too :)

And Valve probably doesn't care for this thread anymore. Otherwise it would be fixed a long time ago. It's a shame that it's been almost 8 months and yet they didn't fix this. Clearly their goal on the desktop market isn't as big as the one on SteamOS, which is based off of Debian and won't have any /home encryption.

Tturl 2014-04-22 github

Any news on this @martino-valve, @alfred-valve? I'm still hitting this issue on ZFS, because O_DIRECT is not supported. @goooooal's suggestion[1] should do the trick for us users with "rare" filesystems. Let me know if I can be of any use testing anything or providing any logs. ZFS snapshots and rollbacking make it easy to test this while not having to redownload the full game :-)

[1] https://github.com/ValveSoftware/steam-for-linux/issues/2515#issuecomment-27282139

Ffz6 2014-06-19 github

This is STILL broken. Seriously, it's been more than a year... are you going to fix it or not?

?ghost 2014-06-20 github

Probably not. Too bad Valve doesn't care much for this and other bugs. I thought they were an excelent company.

Sstevenroose 2014-06-23 github

I added a Steam Library folder at /opt/SteamLibrary and I'm installing me games there. I bet it should work. Probably you will have to make the folder with sudo mkdir /opt/SteamLibrary and use sudo chown username:username /opt/SteamLibrary to give your user permission to the folder.

Xxplt 2014-09-01 github

I have the same issue (all games fail to pass the validation and being re-downloaded every time) with ReiserFS + encyptfs on Ubuntu 14.04 (yes, I'm aware that Canonical will probably drop support for Reiser v3 in future releases)

Rrobertfoss 2015-08-02 github

I'm experiencing this bug too.

Jjtrees 2015-11-14 github

I am also experiencing this issue. If Valve doesn't intend to fix it I wish they would just tell us.

Rriccardobl 2015-12-29 github

I have this problem with steam installed on an encrypted partition and the library on an unionfs mount.

?ghost 2015-12-30 github

Seriously? VALVe still haven't fixed this?

PPlagman 2016-01-09 github

Hi,

Can you try this scenario with today's Beta client?

SSpice-King 2016-01-09 github

Looks good to me. Made a new user on my Ubuntu 15.10 laptop with sudo adduser --encrypted-home test-steam, logged in, opted into the beta and downloaded a few small games. So encryptfs on top of Ext4. Both VVVVVV and Papers, Please pass the cache verification just fine, even after restarting the Steam client and a full reboot of the laptop.

screenshot from 2016-01-08 19-38-23

Would love to hear what is happening with other filesystems people are using.

Xxplt 2016-01-09 github

Unfortunately, it still doesn't work with ReiserFS and completely re-downloads the files
Edit: I wasn't running the latest beta version of the client

PPlagman 2016-01-09 github

Are you sure you are running the Beta branch and got tonight's update? If so, next step would be to capture an strace log of the issue and try to identify where the problem is.

Xxplt 2016-01-09 github

Yes, sorry. I jumped to conclusion too early: I thought I had the latest version of Steam, though, I hadn't. Fixed for me as well (tried on OlliOlli and Sid Meier's Civillization V). Thank you, VALVe!

PPlagman 2016-01-09 github

Thanks for double-checking. Going to close this now, feel free to file another issue if running into more problems.

?ghost 2016-01-09 github

Nicely done. It only took 2 years to solve it hehehe.