I'm really new to Linux. I'm currently running an Ubuntu version and I would like to run a program that was installed by root as a non root user.

Or how do I install a program for all users?

Thank you in advance

  • In Ubuntu there is no normally no "root user" (there is one but its password is unusable). Normally when software is installed it is installed for all users. What makes you think that the non-root user cannot execute it? – xenoid Aug 28 '17 at 7:24
  • when I install steam in the first account I need to install it for the second as well – Hani-7amad Aug 28 '17 at 9:59
  • There were some options to do that - in this thread: superuser.com/questions/835779/…, guess that's what you're talking about. – Strepsils Aug 31 '17 at 14:34

You need to be root to modify user permissions for any given program. If you are the root user, simply open a terminal and type sudo chmod 755 path/to/program. If you need to give permissions to a directory, it would be sudo chmod -R 755 path/to/program. After entering in the command, it will ask you to type in the root password. You should now be able to run the program.

If you are not the root user, you need to ask them to give you proper permissions. The solution I gave you allows anyone to read and execute the program, which may not be the desired result. Depending on your setup, you may desire to create a user group so that only certain members of the group have access to the file. Additionally, if you want full permissions for everyone, you would use 777 instead of 755. You can find an explanation of what these numbers mean and of the chmod command by typing man chmod in the terminal. This is a manual page explaining the command. When you are done reading, hit the q key on your keyboard to exit. If you need any further clarification, please feel free to comment.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.