RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    For JamRom2 - getting Jzintv up and running

    Scheduled Pinned Locked Moved Help and Support
    jzintv
    24 Posts 2 Posters 3.5k 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.
    • M
      MiksArcade
      last edited by MiksArcade

      Hi -

      Yeah, it's a bit messed up but I think it can be fixed. In fact, my Pi machine booted up as normal today and the music is playing. And of course I didn't back it up. At least with WinSCP it should be a lot easier to make a back up, Before, I had to take the SD card out, plug it into my laptop and back it up that way.

      When I open Win SCP, it shows
      usr as 0777
      local is 2331
      and I don't even have permissions to drill down past local, which makes sense based on the value for local.

      I don't know if this matters, but there is a share folder that is a sibling of local in addition to the share folder child under local, Is that normal?

      jamrom2J 1 Reply Last reply Reply Quote 0
      • jamrom2J
        jamrom2 @MiksArcade
        last edited by

        @miksarcade WinSCP is only an FTP that allows you to work with the Linux file structure under a Windows environment. You can't back up your image from it. You have to use an SD card imager. But please back up the image before you mess with it. You can always just reimage and try again once you do.

        I have no idea how you have a folder with permissions like that. Wow. All that command does is unlock your folder so you can use it.

        jamrom2J 1 Reply Last reply Reply Quote 0
        • jamrom2J
          jamrom2 @jamrom2
          last edited by

          @jamrom2

          To effectively work with RetroPie in Windows, you need WinSCP, Putty and an SD reader/writer for the imaging.

          After that, you'll be using it like a master

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

            I actually have all 3 now.

            I installed Putty a while back and forget how I even used it. And I have an SD card reader. I backed up my build over a year ago but it is way outdated now. It's just kind of a pain because I have to open up my bartop, dig out the mini box the pi is in, and then remove the SD card and plug it into my laptop to back it up.

            Is there an easy way to restore the usr folder to what it was before? I think that was the only file that was impacted by CHMOD. I'm pretty sure the local folder is the same it was before. I figured it would be easy to just remove what I originally added as permissions but that did not seem to work.

            jamrom2J 1 Reply Last reply Reply Quote 0
            • jamrom2J
              jamrom2 @MiksArcade
              last edited by jamrom2

              @miksarcade

              What did you try?

              I would think it would be... sudo chmod -w foldername

              So jump into \usr and try sudo chmod -w \local
              That should take out the -write attribute of all files and folders in \local and under it as well. Then you can go back and add the -write attribute to only the \share folder in that same \usr\local\ directory.

              is \usr also 0777 as well?? If so, then change that as well, back to 0755.

              I always open a Putty session and WinSCP side-by-side whenever I'm working with changing any folder permissions in my Pi. So I know what I did worked right away.

              Also... Linux is not like Windows. There is NO warning questions... Are you sure?... bells.. .nothing. You type and hit enter, it's done. So always back-up before screwing with anything.

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

                ok, here is the current deal.

                usr is 0777

                when I try to change /local and /usr in WinSCP I get a generic permissions denied error.

                When I exit Emulationstation and run from the command line the error message is more specific:

                sudo: error in /etc/sudo.conf line 0 while loading plugin "sudoers_policy"
                sudo: /usr/lib/sudo/sudoers.so must be only writeable by owner
                sudo: fatal error, unable to load plugins

                so far, the only "problem" I encouter is when I shut down the pi. Rather than turn off, I get booted to the command line because of the same plugin error. The machine boots up just fine.

                jamrom2J 1 Reply Last reply Reply Quote 0
                • jamrom2J
                  jamrom2 @MiksArcade
                  last edited by jamrom2

                  @miksarcade you can't change permissions in WinSCP. You can only view them because it doesn't use the "super user" sudo.

                  You have to change permission in a Putty session, or direct in command out of Emulation Station.

                  Did you try this command in Putty?

                  sudo chmod -w \local

                  This should remove the "write" permission from the "local" folder.

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

                    I will try the command using PUTTY.

                    It did not work when I did it from the command line after exited Emulationstation on the Raspberry Pi itsef.

                    jamrom2J 1 Reply Last reply Reply Quote 0
                    • jamrom2J
                      jamrom2 @MiksArcade
                      last edited by

                      @miksarcade I have another chip with an old image on it I can blow up and play with. I'll see what happenes and try to reverse it.

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

                        Yeah, I get same thing in PUTTY

                        pic.png

                        I googled the error message and found this link, but I'd rather wait for your advice....thanks
                        https://askubuntu.com/questions/234603/how-do-i-deal-with-sudoers-so-must-be-only-be-writable-by-owner

                        jamrom2J 1 Reply Last reply Reply Quote 0
                        • jamrom2J
                          jamrom2 @MiksArcade
                          last edited by jamrom2

                          @miksarcade
                          Yeah.. not sure what that is, but reading it... might have to go that route.

                          So here is what I did. I set the /usr/local folder to open 0777 then returned it back to normal as you can see below.

                          usr.jpg

                          Try this command in the /usr .

                          The command is sudo chmod ugo-w /usr/local

                          You should see the /local folder go back to a blue color. The move back to the root and try that some command on the /usr folder by removing the "/local" from the command.

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

                            yeah, same error. My usr folder is also drwxrwxrwx

                            it says only the owner can writeable by owner.

                            when I connect, i use the username = pi and password = raspberry

                            Is that like the default owner account? It is not the password I set up originallly, and now I can't connect to that other pi user I set up.

                            Also, I what is difference between sudo chmod and just chmod? Is it possible that it is failing the "sudo" part and just running as chmod?

                            Honestly, I'm just lost on this whole process now. I don't even remember what state these folders/files need to be in.

                            At the root/top level, there is now a green file called tmp that was created on 12/22 and it is set as drwxrwxrwt

                            so the green files at the top of the path are:

                            tmp = drwxrwxrwt under tmp is some private thing I don't know what it is
                            usr = drwxrwxrwx
                            under usr, there are 6 files with the same setup as usr (games, include, lib,sbin, share,src)
                            oddly enough, local is set as d-wx-ws--x (I think that is different than before)

                            My whole game systems runs fine, but some of the retropie commands no longer work, such as "Show Ip" aka > ip addr show

                            jamrom2J 1 Reply Last reply Reply Quote 0
                            • jamrom2J
                              jamrom2 @MiksArcade
                              last edited by

                              @miksarcade yes, that's the default admin user.

                              pi/raspberry

                              I tried the original command again, and it worked. you can see it below.

                              So I'm not sure what happened... all that command does is open the /usr/local/share to be written to by all users. None of what you have should be happening. Did you do any other commands? That string only points to 1 folder. If you went and unlocked all the others... then yes, it will blow up for sure. /usr should not be unlocked.

                              usr2.jpg

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

                                honestly, I think the problem is that "sudo" does not work.

                                I just type sudo and hit return and I get the same error

                                this started when I typed this in:

                                sudo chmod -R ugo+rw /usr/local/share

                                It was the ONLY thing I did...

                                scratch that....it looks like I did THIS:

                                . I was able to use CHMOD on the usr folder, but something broke.

                                sound like this was a bad thing....

                                jamrom2J 2 Replies Last reply Reply Quote 0
                                • jamrom2J
                                  jamrom2 @MiksArcade
                                  last edited by

                                  @miksarcade yup.. and I hate to say it. Your build is flogged.

                                  I can imagine how this happened, but there is no simple way to bring it back. I've been reading about this all morning. Not easy and outside of my skill with Linux. I've had this happen in the past, with either commands, or building emulators, breaking SD cards, etc.

                                  Hence why it's very important to have a build back-up.

                                  So... thinking you're on your own and screwed? No... not at all. Where did you get the build? Byte Knight or is this your own from scratch?

                                  1 Reply Last reply Reply Quote 0
                                  • jamrom2J
                                    jamrom2 @MiksArcade
                                    last edited by

                                    @miksarcade yes... a very bad thing.

                                    Basically using that command on anything other than what I posted ... well.. .really on the /usr folder... knocks out control of the /usr folder by sudo.

                                    It's only meant to be used to unlock the specific folder I had it pointed to, that's all that was needed.

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

                                      ah, what a bummer. You are not kidding when you say it is easy to break. sadly, I have no idea where the build originally came from.

                                      I bought it from a guy on craigslist a couple years ago and just added a boatload of games, added a music soundtrack and didn't do much else. The only times I have played at the command line was getting the music player to work and to get the PC port of Bomberman's Streets of Rage Remake to work. For the most part, I just transfer ROMS and images, and edit the gamelist and emualator.cfg files to clean them up.

                                      So, is the MAIN problem here that the USR folder is set to drwxrwxrwx ? (7770?) What does that need to be? I guess I will just have to try to find another way to get that back to normal? Or, is there any way to just redo the build without wiping all the games?

                                      jamrom2J 1 Reply Last reply Reply Quote 0
                                      • jamrom2J
                                        jamrom2 @MiksArcade
                                        last edited by

                                        @miksarcade

                                        Hit me with a PM on AA.

                                        jamrom2J 1 Reply Last reply Reply Quote 0
                                        • jamrom2J
                                          jamrom2 @jamrom2
                                          last edited by

                                          @jamrom2 Yes. Once sudo is removed from a root folder... it's done.

                                          You basically open the folder to everything. Which looses control of sudo. Without sudo, you have no way to set permissions.

                                          It's possible to boot into root and try to fix it, but the time and effort is usually not worth it with how quick you can get another build up and running.

                                          So, while I talk to you on AA for one solution... the other can be that you copy everything in the BIOS, ROMS, theme, and .emulationstation folder over and start the process of rebuilding.

                                          There are other files as well... but that's normally where it all starts.

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

                                            I can check my old build. If it has the music player and Streets of Rage, then all it will be missing is the new games and systems I set up and all I will need to do is dump the missing ROMS, images and update game lists, emulators.cfg and whatever file stores the retroarch settings

                                            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.