Possible to synchronize save games between multiple MiSTer? (re: network shares)

For topics which do not fit in other specific forums.
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by sofakng »

Is it possible to synchronize save games for the different console cores (Genesis, SNES, etc) between multiple MiSTer devices?

I know that you can enable network support with a wireless dongle (which I have) and enable CIFS mounting, but can you have each core default to loading from a network directory as well?

For example, when I select the SNES core, it defaults to sdcard:/games/SNES, but can it default to cifs://myserver/games/SNES ? If so I can point multiple MiSTers to that same location and share save games, etc.

I'd also be interested if any other/better options exist.
User avatar
lomdar67
Posts: 182
Joined: Sun May 24, 2020 8:27 pm
Has thanked: 12 times
Been thanked: 8 times

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by lomdar67 »

Sure, you can simply use a cifs share. Take a look at the cifs_mount.sh in your Scripts folder. The remarks in there are pretty self explanatory.

With the LOCAL_DIR option you can mount single directories or the whole share and with BASE_PATH you can e.g. mount to /media/fat/games
We raise hopes here...until they're old enough to fend for themselves.
--Mike Callahan
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by sofakng »

Great, thanks so much!

I'll give it a try myself, but how is the experience with loading/navigation times versus a local SD card?
User avatar
lomdar67
Posts: 182
Joined: Sun May 24, 2020 8:27 pm
Has thanked: 12 times
Been thanked: 8 times

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by lomdar67 »

sofakng wrote: Thu Jul 02, 2020 2:38 pm I'll give it a try myself, but how is the experience with loading/navigation times versus a local SD card?
With navigation I would say it makes absolute no difference. Most of the roms are also quite small so no big difference there too.
I haven’t compared virtual hard drives, but for me this setups works very well. I have the complete games folder on a nas.
We raise hopes here...until they're old enough to fend for themselves.
--Mike Callahan
sofakng
Posts: 137
Joined: Fri Jun 19, 2020 12:52 am
Been thanked: 23 times

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by sofakng »

Thanks again. I've just tested it and it's almost the same speed as the SD card but maybe just a bit slower.

Have you (or anybody else) tried using NFS instead of CIFS/SMB?

I'm using a Debian Linux server for my storage so I can also try to setup an NFS share and export it to the MiSTer. I remember a while ago when I had an XMBC/Kodi box, there was a significant difference between CIFS and NFS. When I played a video over NFS it started instantly but CIFS had a second or two delay, etc.

EDIT: Hmmm, I don't think the current kernel supports NFS?

Code: Select all

mount -t nfs 192.168.10.50:/tank_console /tmp/n
mount: /tmp/n: unknown filesystem type 'nfs'.

Code: Select all

/lib/modules/4.19.0-socfpga-r1# cat modules.builtin | grep nfs -i
/lib/modules/4.19.0-socfpga-r1#
I wonder if we could get this added?
User avatar
lomdar67
Posts: 182
Joined: Sun May 24, 2020 8:27 pm
Has thanked: 12 times
Been thanked: 8 times

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by lomdar67 »

As far as I know NFS is not terribly secure, and CIFS isn't terribly efficient by comparison. But as we don't have big files I don't think NFS would have a big advantage.
We raise hopes here...until they're old enough to fend for themselves.
--Mike Callahan
seviien
Posts: 1
Joined: Mon Oct 19, 2020 1:07 am

Re: Possible to synchronize save games between multiple MiSTer? (re: network shares)

Unread post by seviien »

Could I ask if this could be unpacked a little more for someone who's looking to accomplish the same (saves and games folders stored on a network drive) but has lower/little familiarity with Linux file systems?

I get the CIFS share, I think. At least in that i've mapped a Synology NAS to a windows box via SMB and I can google stuff. Hopefully it's not much more than enabling a setting in the NAS to allow CIFS and using the code above in the MiSTer file.

What I don't understand is how to setup the folder structure on the share so the MiSTer knows to associate/treat the network drive the same way as the one on the SD. Is it as simple as making a folder on the share called something like "MiSTer Share" and then putting sub folders in there called "games", "saves", and "savestates" then setting "MiSTer Share" as the mount point?

I tinkered with an RG350, which is linux based and has two SD cards, and it seemed like this was how the file system worked. But that's more or less the extent of my experience with linux and how it sets up files or directories.

And would setting it up this way cause write of save files to go to the network drive, or would that drive just be read and the writes occur to the SD?

Thank you so much. I've dug into this and tried to find an answer. This thread is the closest I've gotten and i just can't cross the goal line with it.
Post Reply