手机
当前位置:查字典教程网 >脚本专栏 >linuxshell >getcwd cannot access parent directories错误解决方法
getcwd cannot access parent directories错误解决方法
摘要:复制代码代码如下:[root@web-serverphp]#/etc/init.d/httpdrestartshell-init:error...

复制代码 代码如下:

[root@web-server php]# /etc/init.d/httpd restart

shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory

该错误表示 getcwd 命令无法定位到当前工作目录。一般来说是因为你 cd 到了某个目录之后 rm 了这个目录,这时去执行某些 service 脚本的时候就会报 getcwd 错误。只需要 cd 到任何一个实际存在的目录下在执行命令即可。

【getcwd cannot access parent directories错误解决方法】相关文章:

linux bash中too many arguments问题的解决方法

CentOS下redis自启动shell脚本

shell脚本实现文件锁功能

php编译安装常见错误大全和解决方法

Python执行Linux系统命令的4种方法

如何编写健壮的Bash脚本(经验分享)

Linux执行.sh文件时提示No such file or directory该怎么办(三种解决办法)

bash scp command not found的解决方法

Shell编程中while与for的区别及用法详解

shell中使用echo打印彩色字体和彩色背景的方法

精品推荐
分类导航