【发布时间】:2017-01-31 21:32:10
【问题描述】:
这是我的Tomcat,我复制到~/Library目录下:
当我修改权限目录使用时:
sudo chmod 755 /Library/Tomcat9/bin/*.sh
出现问题:
chmod: /Library/Tomcat9/bin/*.sh: 没有这样的文件或目录
问题截图:
【问题讨论】:
这是我的Tomcat,我复制到~/Library目录下:
当我修改权限目录使用时:
sudo chmod 755 /Library/Tomcat9/bin/*.sh
出现问题:
chmod: /Library/Tomcat9/bin/*.sh: 没有这样的文件或目录
问题截图:
【问题讨论】:
chmod 755 /Library/{filename} 尝试在根目录/ 内的Library 中更改filename 的权限。在您的情况下,根目录中没有文件夹 Library,这就是您收到错误 No such file or directory 的原因。
我会这样做:
cd ~/Library/Tomcat9/bin #change to the Library directory in your Home-Folder and further to Tomcat9/bin
sudo chmod 755 startup.sh #inside /bin change the permission of the startup script
./startup.sh #execute the file
【讨论】:
./startup.sh 时,出现错误:Cannot find ./catalina.sh The file is absent or does not have execute permission This file is needed to run this program