getcwd: cannot access parent directories的解决方法

Posted 邱明成

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了getcwd: cannot access parent directories的解决方法相关的知识,希望对你有一定的参考价值。


shell-init: error retrieving current directory: getcwd: cannot access parent directories: 没有那个文件或目录
chdir: error retrieving current directory: getcwd: cannot access parent directories: 没有那个文件或目录
1
2
该错误表示 getcwd 命令无法定位到当前工作目录。一般来说是因为你 cd 到了某个目录之后 rm 了这个目录
这时去执行某些 service 脚本的时候就会报 getcwd 错误。
只需要 cd 到任何一个实际存在的目录下在执行命令即可。
出现这种现象的原因还有,当前用户没有当前目录的可执行权限
————————————————
版权声明:本文为CSDN博主「UpUpUpUpUpUpUp」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/u012599988/article/details/46651087

以上是关于getcwd: cannot access parent directories的解决方法的主要内容,如果未能解决你的问题,请参考以下文章

python之文件目录操作

Intellij IDEA 提示 Cannot access com... 解决办法

Cannot access org.springframework.context.ConfigurableApplicationContext

Cannot access org.springframework.context.ConfigurableApplicationContext

无法完成安装:'Cannot access storage file '/

cannot access android.support.v4.app.BaseFragmentActivityJB的解决