Steam for Linux > 综合讨论 > 主题详情
Revelation 2012年11月18日上午6:53
Sharing data files between Windows Steam and Linux Steam
What would be a really nice feature is if Steam could share data between its Windows client and Linux client (point both clients to the same data folder). For us dual boot users, this would mean having the data files only once, which is quite a considerable amount of disk space (TF2 alone is about 9 gb!).

Since most of the data is platform independent, this seems feasible. Although I could be wrong about this, since I can't look into the source code ;)
正在显示第 1 - 15 条,共 25 条留言
< >
th0br0 2012年11月18日上午6:58 
Just mount the windows files & symlink them.
BurritoBazooka [AwayButNotDead] 2012年11月18日上午9:59 
Yes, you may read up on symbolic links under Windows here:
https://en.wikipedia.org/wiki/NTFS_symbolic_link
Linux:
https://en.wikipedia.org/wiki/Symlink#POSIX_and_Unix-like_operating_systems
http://www.nixtutor.com/freebsd/understanding-symbolic-links/

I'll try and put it in my own words:

A symbolic link (or symlink) is basically a reference which points from one folder to another folder or file. For all intents and purposes (except in file browsers), that reference is the same as the folder/file it is pointing to. So if you make a symlink in /home/user/potato/ named 'glados' and make it point to /media/windows/steam/potato/glados/, your Steam client will see /home/user/potato/glados/ as THE SAME as /media/windows/steam/potato/glados/. The files from the symlink's target would appear to be in a folder with the symlink's name. No copying required. Only a tiny bit of extra space used.

You can also make symlinks to individual files. They don't have to be to folders. The symlink will look like it is THE SAME as the file it is pointing to.

It is different from a shortcut. But most file browsers would treat symlinks as shortcuts. If you delete the symlink in the file browser, its target will not be deleted.

You can use this to link up all the texture files and mods that you might have installed. Conf files also work.

I don't recommend using symbolic links between filesystems with Steam. I highly recommend using ext4 on Linux, and using NTFS on Windows. The NTFS drivers on Linux are iffy. And Steam for Windows doesn't always like ext2 or FAT. I speak from personal experience. Portal 2 for Windows only likes NTFS.

I've used symlinks to link content between a Garry's Mod game server and my Garry's Mod client. It's very effective at keeping things the same (maps, for example)
最后由 BurritoBazooka [AwayButNotDead] 编辑于; 2012年11月18日上午10:09
Von the Failman 2012年11月18日上午10:52 
To use linux and not to know what symlink is is just... I dunno. I guess I'll never get used to this ubuntu popularity growth. =/

Anyway, I don't see any problems with modern hard drives. 500G is common and is not expensive, and more than 1T drives are available too. Add the fact that there will not be many linux games any time soon.

Exporting and importing game files from the installations you have on other systems, on the other hand, would be nice since downloading 9G takes time even on fast broadband connection. Not to mention those unlucky ADSL1 users...
DarkStarSword 2012年11月18日下午8:54 
DO NOT SYMLINK YOUR WINDOWS STEAMAPPS TO LINUX!
At least, not until there is some word that this is officially supported.

I tried this and ended up with Borderlands 2 and Assassins Creed 2 being completely deleted (even though these are windows only titles) as well as another 20 games (most of these are/were listed in the Linux client) becoming corrupt before I realised what was happening and closed Steam. I then had to spend a good deal of time restoring these from my backups.

In the case of the Windows only titles, I am guessing that Steam read the game's .acf file, noticed that the .manifest files it was using were not "up to date" for Linux, then deleted every file mentioned in the old .manifest file that was not mentioned in the new .manifest file in order to apply the update... only, there was no new .manifest file...

In theory this should be possible for many/most games since the files that must be different between platforms do not have the same filename (e.g. game.exe vs bin/game, openal.dll vs lib/32/libopenal.so, etc.), and the platform independent content is identical and shares the same filename.

Some games, including Trine 2 and The Book of Unwritten Tales are problematic, as despite the fact that that there is no reason for the content to differ between platforms they do.

In the case of Trine 2 this is due to their build system that bundles a bunch of files into large archives without attempting to keep the archive files consistent (i.e. ordering of files within the archives, differing timestamps, etc), as well as some clear differences in where the files have been placed (linuxdata.fbq).

In the case of The Book of Unwritten Tales the vast majority of the differences are simply a directory that has a different name on Windows than it does on Linux (renaming this directory from a Windows installation prior to installing the game in Linux reduces the amount of data that Steam tries to download from 4GB to ~220MB).
mdkcore 2012年11月19日上午6:22 
I still have steam for windows running on my system via wine, besides the steam for linux, and have simlink to my windows game partition. Just use it for downloading games and never had a problem with it.
Revelation 2012年11月19日上午11:30 
I know very well what a symlink is :P Maybe I should have mentioned that I am an Arch Linux user.

I asked this question because I was already predicting bugs and glitches, like darkstarswood mentions now. These are issues that do not show up using Wine, because Wine can actually use all the same files.
MaPi_svk 2012年11月19日上午11:54 
Yeah, it would be very nice if there was an official and supported way of doing that.
love2spooge 2012年11月19日下午12:29 
You can use this:
Settings > Downloads > Steam Libary Folders
And add Steam folder on windows, i use this to update Dota 2 on linux. But i don't recommend this to everyone because i had one problem with corupted files as darkstarsworld, but verifiing integrity of files fixed it...
DarkStarSword 2012年11月19日下午6:17 
One compromise that might work is to periodically use rdfind to link just the identical files between a Windows and Linux SteamApps directories. There's a few things that I can think of that could cause this to go wrong (or at least confuse Steam) when a game is updated on either or both platforms, so I can't recommend it until I've tested how Steam actually copes with it in practice, but it might just work.

Edit: s/fdupes/rdfind/ - could have sworn that fdupes had an option to link duplicate files together...
最后由 DarkStarSword 编辑于; 2012年11月19日下午6:50
Killjoy 2012年11月19日下午9:19 
I actually found a way to do this inside the Steam Client.

In your settings, click the "Downloads + Cloud" tab. At the bottom of the window is a button that says "Steam Library Folders". Just use that to add your windows steam directory.
最后由 Killjoy 编辑于; 2012年11月19日下午9:19
DarkStarSword 2012年11月19日下午11:56 
@Thunderlane I'd be concerned that approach would suffer the same deletion & corruption issues that I had symlinking the entire SteamApps directory, unless the client has been programmed to recognise the second library as a Windows library. Also, last I checked that feature is (was?) currently broken/incomplete in the Linux client (works OK in the windows beta client).

I'd be interested to know how it goes - one problem I found was that the Windows client would only tell me that a game had been corrupted when I actually attempted to launch it, so you might have done damage to your library and not even know.
Mr. Tickle 2013年2月18日下午10:03 
I tried adding my windows folder through the Steam Library Folders method but I couldn't find any of my windows files. Am I doing something wrong?
DarkStarSword 2013年2月18日下午11:02 
Yeah -- don't:

https://github.com/ValveSoftware/steam-for-linux/blob/master/RelNotes.md

"Application files installed by Steam for Linux should not be shared (e.g. between Windows and Linux). This is a requirement of the Steam for Linux client."

They added that after too many people tried and had their library corrupted as a result.
Mr. Tickle 2013年2月18日下午11:12 
Aaaaah, okay, that's good to know, thank you!
jago25_98 2013年11月3日上午1:09 
Just tried it the other way round, downloaded on linux Day of Defeat, rebooted into Win7, installed windows steam in separate folder, _copied_ over SteamApps folder only from linux, started Steam for Windows and then "update required", ran update...
then steam failed to start.
Still, worth a shot since
bit annoying to have to download another XXXgb of mostly the same files over 3G
正在显示第 1 - 15 条,共 25 条留言
< >
每页显示数: 15 30 50
发帖日期: 2012年11月18日上午6:53
帖子数: 25