su: warning: cannot change directory to /home/oracle: Permission denied

来源:互联网 发布:淘宝烈士墙是什么意思 编辑:程序博客网 时间:2024/05/16 12:09

 

 
[root@localhost ~]# su - oracle
su: warning: cannot change directory to /home/oracle: Permission denied

解决方法:
[root@localhost ~]#stat /
输出如下:因为你ls是看不到的。
File: “/”
Size: 1024 Blocks: 2 IO Block: 1024 目录
Device: 803h/2051d Inode: 2 Links: 22
Access: (0666/drw-rw-rw-) Uid: ( 0/ root) Gid: (0/ root)
Access: 2007-12-01 22:28:48.000000000 +0800
Modify: 2007-12-01 22:28:34.000000000 +0800
Change: 2007-12-01 23:17:35.000000000 +0800

问题出来了,这里的权限是错误的,X权限的丢失造成的。

[root@localhost ~]#chmod 755 /


修改后,问题消失。
from :http://blog.sina.com.cn/s/blog_98a8738901014ufr.html
原创粉丝点击