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

    Is it still possible to ssh as root while emulationstation is working?

    Scheduled Pinned Locked Moved Help and Support
    sshroot
    14 Posts 3 Posters 1.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.
    • mituM
      mitu Global Moderator
      last edited by mitu

      Are you just using root to perform some administrative actions or are you trying to run Emulationstation as root ? How are you 'changing to root' ?

      Y 1 Reply Last reply Reply Quote 0
      • Y
        youxia @mitu
        last edited by youxia

        @mitu said in Is it still possible to ssh as root while emulationstation is working?:

        Are you just using root to perform some administrative actions or are you trying to run Emulationstation as root ?

        I need it to make on the fly changes to runcommand and numerous other configs using WinSCP

        How are you 'changing to root' ?

        By using the guide from Wiki: https://github.com/RetroPie/RetroPie-Setup/wiki/FAQ#why-cant-i-ssh-as-root-anymore

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

          Then I don't see how that would influence Emulationstation's ability to start, apart from some permission errors.
          if you log in as the pi user and just run emulationstation, do you get any error ? Are there any indicative error messages in /home/pi/.emulationstation/es_log.txt ?

          NB: The /opt/retropie/configs folder is owned by the installation user (pi on a Raspberry Pi), you don't need to be root in order to change something in that folder.

          Y 1 Reply Last reply Reply Quote 1
          • Y
            youxia @mitu
            last edited by

            @mitu So I can assumethat nothing has changed since that guide was written and I should be able to log in as root via ssh and use emulationstation/play games like it was before? I just wanted to confirm that, because if yes it means the error is on my side somewhere and I can try again.

            When I log in as pi emulationstation (auto)starts fine. When I try to run it as root from command line I get the message "you shouldn't use emulationstation as root ..." (but before I never needed to do it anyway because it was autostarting with root and working ok).

            I think most of the things I need changing are in the folder you mention so maybe user:pi would be sufficient to use now, but it wasn't like that before (otherwise I'd never bother with root). Still, I would like to find the answer what's wrong all the same, it bugs me when something's not working ;)

            Thanks for replying btw.

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

              @youxia said in Is it still possible to ssh as root while emulationstation is working?:

              When I log in as pi emulationstation (auto)starts fine. When I try to run it as root from command line I get the message "you shouldn't use emulationstation as root ..." (but before I never needed to do it anyway because it was autostarting with root and working ok).

              I specifically asked if you were trying to run ES as root - that's not supported, just as the message says. Logging in as root is ok, that's what the Wiki shows - but that doesn't mean you're meant to run Emulationstation as root.

              I think most of the things I need changing are in the folder you mention so maybe user:pi would be sufficient to use now, but it wasn't like that before (otherwise I'd never bother with root).

              It was like that for a long time, the configs folder is meant to be readable and writable by the installation user (be it pi or other account of you're using a PC/Ubuntu/Debian install).

              Still, I would like to find the answer what's wrong all the same, it bugs me when something's not working ;)

              I don't see anything wrong with the installation.

              Y 1 Reply Last reply Reply Quote 0
              • Y
                youxia @mitu
                last edited by

                @mitu

                I specifically asked if you were trying to run ES as root - that's not supported, just as the message says. Logging in as root is ok, that's what the Wiki shows - but that doesn't mean you're meant to run Emulationstation as root.

                Well, it's in the topic of this thread, and in the first post. Yes, I am trying to run Emulationstation, while logged in as root and ssh-ing and making changes. And that message is the same message that was there before too, yet it was working fine then. I was logged in as root, Emulationstation was running, games were playing. For years. I still have a backup of my 32GB image which does just that, no problem. Like I said in my first post, I am fully aware of any risks or damage which may occur to my system, so I'm not sure what "you're not meant to run Emulationstation as root" means in this context. Does it mean it is not technically possible, or that it's not advised?

                It was like that for a long time, the configs folder is meant to be readable and writable by the installation user (be it pi or other account of you're using a PC/Ubuntu/Debian install).

                I wouldn't follow the root route if there was no explicit reason for it.

                I don't see anything wrong with the installation.

                I meant my installation. There clearly is either something wrong with it or something has changed in the Retropie build. Because before Emulationstation was working with root enabled, now it isn't. I assume the former, but would like to make sure before I go on a wild goose chase.

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

                  Leaving aside the peculiarities of your setup - not recommended - I don't think the reason for not working is any recent change in RetroPie. There must be something else that's at stake, but I don't know what it could be.

                  I wouldn't follow the root route if there was no explicit reason for it.

                  Can you expand on the reasons ?

                  Y 1 Reply Last reply Reply Quote 0
                  • ClydeC
                    Clyde @youxia
                    last edited by

                    @youxia By the way, you can log in as often as you want simultaneously, so you could log in as pi, run Emulation Station, and then log in once more as root, and do the stuff you want to do as root. Is that a valid option for you?

                    Alternatively, you could just log in as pi and then run any command with administrative rights with sudo, or even get a root shell with sudo -i.

                    On most Linux systems, it is a traditional safefy measure to run commands and programs as root only when neccessary, so that is the way RetroPie is set up, too. You may run into problems if files that are expected to belong to pi are created or changed as root by you or a root-owned ES. Programs run by the user pi might not be able to read or write these files afterwards.

                    Y 1 Reply Last reply Reply Quote 0
                    • Y
                      youxia @mitu
                      last edited by

                      @mitu said in Is it still possible to ssh as root while emulationstation is working?:

                      Leaving aside the peculiarities of your setup - not recommended - I don't think the reason for not working is any recent change in RetroPie. There must be something else that's at stake, but I don't know what it could be.

                      And that's all I needed to know. Most likely I did something wrong along the way because I'm a bit out of practice.

                      I wouldn't follow the root route if there was no explicit reason for it.

                      Can you expand on the reasons ?

                      The same I have now, and which were mentioned earlier: I need to adjust heaps of configs due to using various methods of connecting to CRTs and dealing mostly with less popular platforms. This requires a lot of on-the-fly tweaking.

                      And like I also said earlier, it was necessary (or perhaps much more convenient than separate command line operations) to use root when I first started doing this (about 2-3 years ago). Well, at least that's what I was told, because as a complete noob when it comes to Linux I did not come up with this idea myself.

                      mituM 1 Reply Last reply Reply Quote 0
                      • Y
                        youxia @Clyde
                        last edited by

                        @Clyde said in Is it still possible to ssh as root while emulationstation is working?:

                        @youxia By the way, you can log in as often as you want simultaneously, so you could log in as pi, run Emulation Station, and then log in once more as root, and do the stuff you want to do as root. Is that a valid option for you?

                        Alternatively, you could just log in as pi and then run any command with administrative rights with sudo, or even get a root shell with sudo -i.

                        Thanks, but I'm just curious why beforehand I could autologin into ES with root and never do any extra steps. I might just stick with logging in as pi because most of the configs I need tweaking are indeed in the /opt/retropie/configs and as @mitu says this is owned by user pi.

                        On most Linux systems, it is a traditional safefy measure to run commands and programs as root only when neccessary, so that is the way RetroPie is set up, too. You may run into problems if files that are expected to belong to pi are created or changed as root by you or a root-owned ES. Programs run by the user pi might not be able to read or write these files afterwards.

                        I'm aware of all that, like I said in the first post :) I've been using the Pie this way for a really long time and never had any major problems or breakdowns because of the root (yes, I was once stumped by the permissions but quick look online sorted it out).

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

                          @youxia said in Is it still possible to ssh as root while emulationstation is working?:

                          The same I have now, and which were mentioned earlier: I need to adjust heaps of configs due to using various methods of connecting to CRTs and dealing mostly with less popular platforms. This requires a lot of on-the-fly tweaking.

                          Well, I got that from the previous post(s), but I was curious on the actual details (commands/scripts) - just to see what exactly would still warrant root access and what can be left as is (i.e. only needs regular user access).

                          Y 1 Reply Last reply Reply Quote 0
                          • Y
                            youxia @mitu
                            last edited by

                            @mitu said in [Is it still possible to ssh as root while emulationstation is working?]

                            Well, I got that from the previous post(s), but I was curious on the actual details (commands/scripts) - just to see what exactly would still warrant root access and what can be left as is (i.e. only needs regular user access).

                            I'm curious myself now, since I don't inherently need root in my life and I'd rather do without the extra step of enabling it (which I did countless times making new images). I'm currently building my setup from scratch as user:pi, if I encounter some stumbling blocks which do need root after all I will update this thread.

                            ClydeC 1 Reply Last reply Reply Quote 0
                            • ClydeC
                              Clyde @youxia
                              last edited by

                              @youxia said in Is it still possible to ssh as root while emulationstation is working?:

                              I don't inherently need root in my life

                              Well said. 🙂 Good luck with your new build.

                              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.