'su' without password
On Thu, 2009-02-19 at 06:28 +0100, Pol wrote:
> Smoot Carl-Mitchell wrote:
> > On Wed, 2009-02-18 at 12:58 +0100, Pol wrote:
> >> How to let user1 'su' user2, without entering password?
> > Then user1 can run a command as user2 by typing:
> > sudo -u user2 command args ...
> It seems that 'command' does not get the environment of the user2, this way.
That is correct. If you want to become user2 completely, you can do:
sudo -u user2 -i
which will give you a shell with user2's environment. Any command typed
at that point will be with respect to user2's environment settings.
Computer Systems and
+1 480 922 7313
cell: +1 602 421 9005
ubuntu-users mailing list
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users