Hi
Say I am running a script using my user id csaha. How can I run any specific command in the same sctipr using any other user id (say root). Definitely I have the password of root. Any idea how the same can be achieved ???
Example:
I need to run a script using my id (csaha) only on csaha dir, but needs to access few files in stadby dir (as shown below ).
Clearly visible I need to give +rx permission (i.e. need to run "chmod +rx standby") before that using my script and root userid and want to revert back once the script is complete.
[csaha@server-a home]# ls -ltr
drwxr-xr-x 4 csaha perforce 4096 Feb 15 20:12 csaha
drwx------ 54 perforce perforce 4096 Feb 16 03:05 standby
Thanks a lot to all in advance
C Saha