[Israel.pm] How to use Unix "su" (=switch user) command

David Baird david.baird at cmcrossroads.com
Wed Sep 22 01:03:02 PDT 2004

> Thank you.
> My problem is that I don't run the script from root user.
> Is it impossible to do it from usual account (if I have the 
> user & password)?

Using sudo is the proper and safe way to handle this, even if you do it
in a system command in your script. You can use sudo to run command as
specific user. You should read about it. There is a sudo Perl module
available on search.cpan.org.


More information about the Perl mailing list