I Have a application that need to run like root user, but I need that the enviroment, will be of an unprivileged user.

For example:

ipython, start by root (ubuntu) user; but I need that cann't run code with commands using sudo.

So, I believe that, maybe; if I run the job like root, but...HOW, only works for a "x" user.

Any idea?


2 Answers 2


sudo works both ways, root can also act as a regular user sudo -u userName -g groupName I haven't used it but it looks like gksudo has the same functionality for desktop top applications

  • Thanks!... I did it, your answer; but not works... The solution was add; root ALL = NOEXEC: /usr/bin/sudo in visudo.
    – Xpersona
    Jun 17, 2015 at 4:01

You could consider making your application a startup service.

Here is a good guide to get you started.

  • IM application and runs as a service; which is launched by the root user. But I do not want my users to gain privileges (eg sudo) to use.
    – Xpersona
    Jun 17, 2015 at 4:10

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.