LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Installed application with root privileges, need to run as normal user (https://www.linuxquestions.org/questions/linux-newbie-8/installed-application-with-root-privileges-need-to-run-as-normal-user-4175419008/)

sabresong 07-27-2012 08:07 PM

Installed application with root privileges, need to run as normal user
 
I messed up, and I'm trying to find a solution before resorting to uninstalling the application and reinstalling it properly. It's a game, Planeshift, installed via its installer script. I installed it without reading the README first, which I absolutely know is rather a stupid thing to do, but there it is. Now it won't run unless I run it as root or using sudo.

I did go back and read the README, and saw that I could have set the permissions manually during install, so I tried changing them from the command line, but that didn't work. The game got installed to /usr/bin.

The only similar thing I've been able to find via Google was here on LQ, and inly suggested setting the permissions of the folder to 0755. I was under the impression that that was the default for /usr/bin in Kubuntu, but tried that anyway, but it didn't work.

Is there a way to make it work as a normal user, or will I have to reinstall the application?

John VV 07-27-2012 10:14 PM

Quote:

Google was here on LQ, and inly suggested setting the permissions of the folder to 0755.
so you ran chmod on /usr/bin ???

not good

hopefully you did not royally mess up the system

but i am guessing here that you only needed to change the user group for the game ONLY

A guess here so....
but is the game a shell script to start the game ????
as in is the file in /usr/bin a text file

if so you most likely only need to run
( on the SHELL *.sh only if it is one ?? )

Code:

su -
chown root:users TheNameOfTheScript
chmod +x heNameOfTheScript


tommcd 07-28-2012 04:42 AM

Quote:

Originally Posted by sabresong (Post 4739727)
... The game got installed to /usr/bin. ...

It is unlikely that the entire game was installed to /usr/local/bin/.
Usually only the executable file that launches the game (or most any other app) will be installed to /usr/local/bin/.
The rest of the game was most likely installed to /usr/local/games/, or possibly just /usr/local/.
Quote:

Originally Posted by sabresong (Post 4739727)
setting the permissions of the folder to 0755

Never change permissions on system files unless you really know what you are doing.
Quote:

Originally Posted by sabresong (Post 4739727)
I installed it without reading the README first

If you read the README and INSTALL files for the game, they should tell you how to install, uninstall, and run the game.
These files, or the game's website, should also list whatever dependencies are needed for the game.

sabresong 07-28-2012 06:26 PM

Thanks for your responses. The problem was solved with chown, but the application wasn't, in fact, entirely installed to /usr/bin. I had to change /opt/PlaneShift as well. I also checked the permissions on /usr/bin, and they seem to be set correctly, so I don't think I broke anything. I think I need to learn more about permissions, groups and ownership. Again, thank you.


All times are GMT -5. The time now is 06:44 PM.