sudo and su

sudo bash : change the current user into root

su u1: change the current user into u1

useradd: add new user into system

userdel: delete a user from system

groups: check a user's group information

chown: chang a file's owner

chmod: chang a file's mod

gpasswd -a u3 foo: add user into a group

su u1 -c "./objput doc<testfile"

 

posted @ 2014-10-27 22:01  airforce  阅读(134)  评论(0编辑  收藏  举报