$ sudo -V
Display the version of sudo command currently used.
[vagrant@localhost ~]$ sudo -V
Sudo バージョン 1.8.6p3
Sudoers policy plugin version 1.8.6p3
Sudoers file grammar version 42
Sudoers I/O plugin version 1.8.6p3
ん、なんだこれ?
$ sudo -l
Display command that the user can (or cannot) do on the current host by using the sudo command.
[vagrant@localhost ~]$ sudo -l
このホスト上でユーザー vagrant
に一致したデフォルト項目:
!visiblepw, always_set_home, env_reset, env_keep=”COLORS DISPLAY
HOSTNAME HISTSIZE INPUTRC KDEDIR LS_COLORS”, env_keep+=”MAIL PS1 PS2
QTDIR USERNAME LANG LC_ADDRESS LC_CTYPE”, env_keep+=”LC_COLLATE
LC_IDENTIFICATION LC_MEASUREMENT LC_MESSAGES”,
env_keep+=”LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER LC_TELEPHONE”,
env_keep+=”LC_TIME LC_ALL LANGUAGE LINGUAS _XKB_CHARSET XAUTHORITY”,
secure_path=/sbin\:/bin\:/usr/sbin\:/usr/bin
ユーザー vagrant
は次のコマンドをこのホスト上で実行できます:
(ALL) NOPASSWD: ALL
$ sudo -h
Display help for sudo command.
$ sudo -u username hoge
Execute hoge command as a username
なんか、この辺は知らんとモグリと思われるな。