source /etc/profile报错-bash: id:command is not found

由于误操作导致

source /etc/profile 报错

-bash: id:command is not found

此时,linux下很多命令到不能能用,包括vi ls 等...

可以使用

export PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin

重新启用这些命令

如果 /etc/profile存在错误而导致source 不能成功,可以使用

/bin/vi  /etc/profile 编辑

上一篇:Matter.js – 你不能错过的 2D 物理引擎


下一篇:【BZOJ 1001】[BeiJing2006]狼抓兔子