RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login

    Running ROMs from a Network Share

    Scheduled Pinned Locked Moved General Discussion and Gaming
    109 Posts 48 Posters 86.4k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      crazyp
      last edited by crazyp

      I am having some trouble getting my network share on my apple airport router to work on my pi 3 at boot. If I enter the mount command at the command line the network drive mounts and when I open emulation station all my games are there. I haven't been able to get the drive to mount at startup though. below is my autostart.sh

      GNU nano 2.2.6 File: autostart.sh

      sudo mount -t cifs //10.0.1.1/pi/roms -o username=pi,password=raspberry,sec=ntlm,file_mode=0777,dir_mode=07$
      emulationstation #auto

                                                [ Read 2 lines ]
      

      ^G Get Help ^O WriteOut ^R Read File ^Y Prev Page ^K Cut Text ^C Cur Pos
      ^X Exit ^J Justify ^W Where Is ^V Next Page ^U UnCut Text ^T To Spell

      1 Reply Last reply Reply Quote 0
      • P
        pappabees
        last edited by pappabees

        OK just wanted to share how I got this to work every time quite simply. Might be stated here didn't find it all in one place so here goes:

                              From the share server (my case Win10)
        
        1. add a share drive in my windows 10 server with read/write access to a single user in my case pappabees

                           From the RetroPie 
          
        2. sudo nano /etc/fstab
          add the following line:
          //<Servername>/Retropi_Roms /home/pi/RetroPie cifs noauto,credentials=/home/pi/.smbcredentials,uid=1000,gid=1000,forcegid,forceuid
          Note the noauto makes it so it doesn't come online while the network is still coming up. solves that issue, created security file so you don't have userid/pass in plain site. Also the GID and UID sets the directory to be owned by the PI user so that takes care of the R/W access.

        3. sudo nano /home/pi/.smbcredentials
          create a file in the ~home directory called .smbcredentials note this file has a dot (.) in the name
          in that file add the following 2 lines
          username=<add your username on the windows 10 box that has R/W to the share>
          password=<add password to above username>

          Ex. username=pappabes
          password=nicetry!2
          There is a 3rd line you can add if your on a domain but most homes don't use this domain=(domain)

        Change the permissions of the file to prevent unwanted access to your credentials:
        4) sudo chmod 600 ~/.smbcredentials

        Now lets add the mount command after everything is booted
        5) sudo nano /etc/rc.local
        add to the end of the file before the exit 0 line the following line
        sudo mount //<Servername>/<sharename>
        example sudo mount //bell-server/RetroPie_Share

        1. sudo reboot

        Once your back up you should be able to ssh to your box and do a df and see your new sharedrive

        Hopefully this will help us beginners a with one quick spot until the RetroPie Gods smile on us and add this feature which if I read this thread correctly may come some day.

        Note: Got a few error (13) issues and found in my case that I had misspelled some share names or directory names and had to really slow down and double check spellings :-)

        1 Reply Last reply Reply Quote 0
        • M
          mouser
          last edited by

          I've followed the instructions in this guide and can see the roms on my share within Emulation Station, but trying to run any of them just immediately bumps back out to the ES menu.

          If I don't mount the share in autostart.sh and copy the same roms from the share to the appropriate directory on the RP3, the roms run just fine. I've checked that the (Windows 10) share user has read/write permissions and that the properties on the shared folder do not include "Read Only" for anything in the shared filesystem.

          Any thoughts on where my problem might lie?

          1 Reply Last reply Reply Quote 0
          • P
            pina
            last edited by

            I ran through all the steps via option #1, but retropie still copies the roms to the internal SD instead of the NAS.

            1. First I made a new network share:

            //retropie

            with the following folders:

            /home/pi/Retropie/BIOS
            /home/pi/Retropie/roms

            1. I enabled ssh (I'm working through Bootberry)
            2. Using terminal in Mac, I SSH to my retropie
            3. sudo raspi-config -> Boot options, wait for network
            4. edit autostart.sh : sudo nano /opt/retropie/configs/all/autostart.sh

            sudo mount -t cifs -o username=xxx,password=xxx //192.168.11.100/retropie/home/pi/RetroPie /home/pi/RetroPie

            then sudo reboot

            Whenever I place a rom into, retropie keeps taking the internal SD as source and not my NAS. I don't know what went wrong in here, stayed almost all night up to figure it out :((

            1 Reply Last reply Reply Quote 1
            • G
              Guy-Sensei
              last edited by

              I have successfully enabled network share by following the wiki and although it didn't work at first, I did more research and added uid=1000,gid=1000 to the mounting line and it has been working flawlessly. However, after a bit of testing, I discovered that lr-snes9x won't load MSU-1 games (it just plays the rom with original sound and no videos) - and lr-mame2003 simply won't load roms at all.... However, they work fine if I run the exact same rom files using the same emulators from the microSD rather than over network.

              Here's my setup:

              RPi 3B:

              • NOT overclocked
              • CanaKit 2.5A Power Supply
              • 32Gb SanDisk MicroSD
              • HDMI output
              • Ethernet wired connection
              • Updated RetroPie Setup script and latest updates for lr-snes9x and lr-mame2003
              • autostart.sh modified to mount network rom folder from desktop running windows. Added line: sudo mount -t cifs -o username=XXXX,password=XXXX,uid=1000,gid=1000 //DESKTOP/retropie/ /home/RetroPie/roms (i don't understand exactly how this works, but this is what I do to enable network share and it wouldn't work unless I added the uid and gid parameters. Username and password obviously replaced with Windows username and password)

              Desktop:

              • Windows 10
              • Roms located in shared folder on 3TB secondary exFAT partition (F: drive)
              • Also ethernet wired connection on same home network

              The following things do not work unless I disable the network share and run the exact same roms with the same emulators from the microSD card locally:

              Snes MSU-1 roms:
              I patched the games correctly and am able to get them to work on lr-snes9x ONLY if I run the exact same files directly off the microSD. Network share doesn't work for some reason - the games will play fine but I don't get the new music or video. I tested Megaman X, Rock n Roll Racing, Secret of Mana, and Zelda.

              lr-mame2003 0.78 romset:
              I have the correct romsets verified with clrmamepro (it says "You have 4719 of 4720 known MAME 0.78 sets (+ BIOS sets)" after scanning).
              They are all located in the roms/arcade folder
              Tried running a bunch of roms at random including UMK3, MK2, Ergheiz, and Pac-Man. None of them loaded.
              Tried running the same roms from the microSD and they work fine.

              I wonder if these issues can be fixed. I assume the programmers must be able to fix it somehow. I'm just not sure who I should notify or where to post this.

              Besides that, the network share works surprisingly well with almost anything else including PSP and PS1. I'm very happy with this feature overall. Thank you!

              1 Reply Last reply Reply Quote 0
              • D
                dyers
                last edited by dyers

                Can anyone confirm that they are able to run zipped roms over the network shares? I've setup a network mapping to the entire /home/pi/RetroPie folder and copied the data over scp to my windows file server. Everything shows up but only non zip roms work, i noticed the pattern and then unzipped a single file from each emulator and indeed it's the compressed files that create a problem. Has anyone else run into this? I'm using a pi3. I've tried option 1 and 2 from the guide and both have the same impact.
                I do have an upgraded install so my next step is to totally start over.

                Edit: adding some more details, I've checked the logs, they appear identical to working launches, some emulators just stall doing nothing, shift+x brings retroarch menu up, so it isn't hung. Other's just bomb back to the rom list.

                D 1 Reply Last reply Reply Quote 0
                • D
                  dyers @dyers
                  last edited by

                  My problem might be related to this: https://github.com/libretro/Lakka-LibreELEC/issues/115

                  1 Reply Last reply Reply Quote 0
                  • H
                    Haris1977 @zehjrack
                    last edited by

                    @zehjrack i have the exact issue my self. Everything plays fine EXCEPT FOR mame roms..

                    I opened a new thread also here . Have y managed to fix it? I am out of ideas....

                    1 Reply Last reply Reply Quote 0
                    • H
                      Haris1977 @spieddy
                      last edited by Haris1977

                      @spieddy said in Running ROMs from a Network Share:

                      to modify Fstab and everyting works fine

                      How did y do that? I am having same issue with my mame roms. All other roms are ok.

                      Anyone else is having problem with mame roms (not working)?

                      1 Reply Last reply Reply Quote 0
                      • H
                        Haris1977
                        last edited by Haris1977

                        Well i ve finally managed to run all of my games (mame roms too) by just following option 2 (unfortunately option 1 didnt work 4 me) from here. I ve also managed to wake my nas server first (as most of the time is in "sleeping" state) , wait some time (in order for the samba to work) and then mount the samba share. Works as expected.

                        Thanks again for the info :-)

                        G 1 Reply Last reply Reply Quote 0
                        • G
                          Guy-Sensei @Haris1977
                          last edited by Guy-Sensei

                          @haris1977 Would you mind giving more details about how you solved this? Specifically, what is your command in fstab for option 2?
                          I have the same problem (see my post above from 2 months ago).

                          H 1 Reply Last reply Reply Quote 0
                          • R
                            ringnutz
                            last edited by

                            @guy-sensei

                            I had the exact same issue. It is not the fstab part that is important here but the options. Specifically one of "nounix,noserverino,defaults,users,auto". I have not deduced which one fixed it, but I am using the Autostart.sh and it works fine as follows

                            sudo mount -t cifs -o gid=1000,uid=1000,username=USER,password=PASS,domain=DOMAIN,nounix,noserverino,defaults,users,auto //192.168.X.X/SHARENAME /home/pi/RetroPie/roms

                            Note that you may not need domain above for your share.

                            After unmounting and remounting the share using the above arguments, I am now able to launch Mame2003 Roms just fine.

                            B 1 Reply Last reply Reply Quote 1
                            • H
                              Haris1977 @Guy-Sensei
                              last edited by Haris1977

                              @guy-sensei sorry for the late answer

                              Mine fstab looks like this:

                              //192.168.X.XXX/SHARENAME /home/pi/RetroPie cifs username=XXX,password=XXX,nounix,noserverino,defaults,users,auto 0 0

                              1 Reply Last reply Reply Quote 0
                              • proxypunkP
                                proxypunk
                                last edited by proxypunk

                                I had serious trouble getting Samba share to work!
                                After hours of trying, I figured out it has something to do with the network interface not being ready, although I enabled waiting for network on boot.
                                Finally I ended up starting kodi before sudo mount and afterwards emulationstation in autostart.sh.
                                Like this:

                                kodi
                                sudo mount -t cifs -o sec=ntlm,user='username',password='password' //hostip/roms /home/pi/RetroPie/roms
                                emulationstation

                                Ofc, I gotta quit Kodi each time to get to EmulationStation. If you don't need Kodi, you could try it with sleep x (x=seconds to wait) instead.

                                mituM 1 Reply Last reply Reply Quote 0
                                • N
                                  nightmaresteam
                                  last edited by

                                  For people using Windows 10 you need to have SMB 1.0/CIFS File Sharing Support enabled in windows features for this to work. I just enabled that and now my network share is working.

                                  1 Reply Last reply Reply Quote 0
                                  • mituM
                                    mitu Global Moderator @proxypunk
                                    last edited by mitu

                                    @proxypunk You could just add a sleep 8 before running emulationstation just so the mount succeeds before ES start and leave the normal mount working from fstab. If 8 seconds is not enough, you can start increasing the wait period until you get the correct number of seconds.

                                    1 Reply Last reply Reply Quote 1
                                    • B
                                      BlackMage
                                      last edited by BlackMage

                                      Found a solution to your save and scrapping issue. if you simply add:

                                      ,rw,file_mode=0777,dir_mode=0777
                                      

                                      after the username and password in your autostart.sh it will give your write access and will allow you to scrap and save to the NAS

                                      Just be sure that access permissions are set correctly on the Windows share, including all sub-folders that you wish to share or else it will still not work.

                                      This allows you to keep saves and scraps on the network and for a setup like mine where i have multiple RetroPies in the house this allows me to create a save folder for each Pi that way we are not overwriting each others saves

                                      1 Reply Last reply Reply Quote 0
                                      • E
                                        EVH
                                        last edited by EVH

                                        Hi guys,

                                        I need some help with running my roms from a Synology NAS.

                                        Despite following the guide, I can't get any of my systems or games to appear in RetroPie. I've tried putting a line in autostart.sh which didn't work and I've tried using fstab to no avail :(

                                        I'm running a pre-made image of the latest build - RetroPie 4.4 on a Raspberry Pi 3B+ connected to my home network via ethernet. My Synology NAS is running on IP 10.0.0.10 and has a "Media" cifs share with guest access.

                                        The line I've added to autostart.sh is:

                                        `sudo mount -t cifs -o username=xxxxx,password=xxxxx //10.0.0.10/Media/RetroPie/roms /home/pi/RetroPie/roms

                                        If I try "sudo mount -a" I don't get any errors, but I still don't see what the issue is. I've even tried using the hostname of the server e.g. "SYNOLOGY" in the path and it doesn't work.

                                        Help!

                                        mituM 1 Reply Last reply Reply Quote 0
                                        • mituM
                                          mitu Global Moderator @EVH
                                          last edited by

                                          @evh If the share name is Media, then the mount command is not correct. You can't mount arbitrary folders inside a share, you should mount the share itself.
                                          My advice is to create a different share and name it RetroPie-Roms, then follow the docs and add the share to the /etc/fstab file to be auto-mounted to /home/pi/RetroPie/roms. Restart and see if the share is correctly mounted, then restart Emulationstation and see if the ROMs from the share appear in the list.

                                          E 1 Reply Last reply Reply Quote 0
                                          • E
                                            EVH @mitu
                                            last edited by EVH

                                            @mitu said in Running ROMs from a Network Share:

                                            @evh If the share name is Media, then the mount command is not correct. You can't mount arbitrary folders inside a share, you should mount the share itself.
                                            My advice is to create a different share and name it RetroPie-Roms, then follow the docs and add the share to the /etc/fstab file to be auto-mounted to /home/pi/RetroPie/roms. Restart and see if the share is correctly mounted, then restart Emulationstation and see if the ROMs from the share appear in the list.

                                            Makes sense, I'll try it later and update.

                                            The docs suggest that the path can contain folders... which I wrongly assumed would work.

                                            sudo mount -t cifs -o username=something,password=something **//REMOTEHOST/path/to/roms** /home/pi/RetroPie/roms

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post

                                            Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                                            Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.