linux 执行脚本报错:nginx_check.sh:行10: 语法错误: 未预期的文件结尾
出现的问题可能是格式有问题:
脚本是windows下写的,然后传到linux下运行的,文件格式需要给dos文件格式转成unix
dos转unix
安装: yum install dos2unix
命令: dos2unix filename

给脚本添加可执行权限: chmod -R 777 filename.sh
linux 执行脚本报错:nginx_check.sh:行10: 语法错误: 未预期的文件结尾
参考:https://www.cnblogs.com/lurenjia1994/p/9485682.html

相关文章:

  • 2022-12-23
  • 2021-08-27
  • 2022-12-23
  • 2021-08-17
  • 2021-06-10
  • 2021-12-04
  • 2022-02-02
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-01-21
  • 2022-12-23
  • 2022-12-23
  • 2023-02-15
  • 2022-01-20
相关资源
相似解决方案