sudo: cd: command not found

    Read

如果你在搜索这个问题,可能是由于你采用的普通用户登录,而使用了visudo的授权方式。可以参考我之前写过的内容:《基于visudo(/etc/sudoets)的用户权限管理方案》

为了更好的和上一篇文章配合,方便普通用户使用,因此这篇普通用户可能遇到问题的文章诞生了!SourceByrd's Weblog-https://note.t4x.org/error/sudo-cd-command-not-found/

①:vim编辑文件,忘记sudo


②:执行命令忘记加sudo

③:执行shell内置命令的时候报错(类似sudo: cd: command not found)

更多参考:
-t type The -t (type) option causes the new (SELinux) security context to have the type specified by type. Ifno type is specified, the default type is derived from the specified role.
SUDO_EDITOR Default editor to use in -e (sudoedit) mode.
VISUAL Default editor to use in -e (sudoedit) mode if SUDO_EDITOR is not set.
内建命令:
bash, :, ., [, alias, bg, bind, break, builtin, caller, cd, command, compgen, complete, compopt, continue,
declare, dirs, disown, echo, enable, eval, exec, exit, export, false, fc, fg, getopts, hash, help, history, jobs,
kill, let, local, logout, mapfile, popd, printf, pushd, pwd, read, readonly, return, set, shift, shopt, source,
suspend, test, times, trap, true, type, typeset, ulimit, umask, unalias, unset, wait - bash built-in commands,
see bash(1)
外部命令:略!SourceByrd's Weblog-https://note.t4x.org/error/sudo-cd-command-not-found/

申明:本文由BYRD原创(基于Centos6.4 X64),未经许可禁止转载!SourceByrd's Weblog-https://note.t4x.org/error/sudo-cd-command-not-found/ SourceByrd's Weblog-https://note.t4x.org/error/sudo-cd-command-not-found/

申明:除非注明Byrd's Blog内容均为原创,未经许可禁止转载!详情请阅读版权申明!
Byrd
  • by Published on April 19, 2014
  • 原文链接:https://note.t4x.org/error/sudo-cd-command-not-found/
匿名

Comment

Anonymous

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: