Linux 下执行指令出现“bad interpreter”错误的解决方法
来源:互联网 发布:淘宝店招图片多大尺寸 编辑:程序博客网 时间:2024/05/22 05:27
经常会遇到这种情况,在windows下写的脚本、代码会在linux下无法执行,出现如下错误:
: bad interpreter: No such file or directory
1 原因
这通常都是由于windows下对文本文件的保存格式与unix下不同造成的,windows下回车的字符是’/r/n’,而linux下是’/n’。
2 解决方法
vi file
在命令模式下,输入 set ,查看文件格式为dos或者unix,如:
set fileformat=unix
wq保存,即可。
- Linux 下执行指令出现“bad interpreter”错误的解决方法
- Linux 下执行指令出现“bad interpreter”错误的解决方法
- Linux 下执行指令出现“bad interpreter”错误的解决方法
- Linux执行shell出现错误bad interpreter: No such file or directory解决方法
- LINUX下执行脚本时,出现bad interpreter:No such file or directory的原因
- linux 脚本不执行,出现错误bad interpreter: No such file or directory
- linux可执行文件bad interpreter解决方法
- linux可执行文件bad interpreter解决方法
- linux下错误bad interpreter: No such file or directory
- sed—在linux 中执行脚本的时候出现: /bin/bash^M: bad interpreter: No such file or directory
- 执行脚本过程中出现^M: bad interpreter: No such file or directory错误解决方案
- 【Linux】执行shell脚本出现异常:bad interpreter: No such file or directory如何解决
- UNIX/Linux下运行脚本文件出现bad interpreter:No such file or directory的原因和解决办法
- /bin/sh^M: bad interpreter的解决方法
- /bin/sh^M: bad interpreter的解决方法
- CentOS7.4安装软件出现错误:/lib/ld-linux.so.2: bad ELF interpreter 解决
- 安装php出现“/replace/with/path/to/perl/interpreter: bad interpreter: No such file or directory ”的解决方法
- 脚本执行异常(bad interpreter: No such file or directory)的解决方法
- list,set,map,数组间的相互转换
- RTC和LDAP服务器之间的账号同步
- javascript中的反射机制的应用
- 如何实现WCF中的自定义集合类型传输
- strcpy/strncpy/strcpy_s比较
- Linux 下执行指令出现“bad interpreter”错误的解决方法
- 十年职业流水帐(希望对工作中的朋友有帮助)
- SWT学习站点
- 三个数比较大小
- 3D图形矩阵变换总结
- svn服务器的架构和配置
- 使用ORACLE 10.2G DBMS_CHANGE_NOTIFICATION 解决参数表的CACHE问题
- cas ucenter 集成
- 敲cmd窗口感觉很爽