本文介绍了使用init.d脚本将文件从USB闪存驱动器复制到系统的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我正在创建一个linux init脚本,将一些文件从笔式驱动器复制到我的raspberry系统驱动器。但它不会在启动时将文件从笔式驱动器复制到系统。但当我从终端执行它的工作正常。I am creating a linux init script to copy some files from my pen drive to my raspberry system drive. but its not copying the files from pen drive to system on booting time. but when i executed it from terminal its working fine.for PENDRIVE in /media/*doif [ -d "$PENDRIVE/Update" ]; thenINSTALLDIR="$PENDRIVE/Update"cp -r $INSTALLDIR /tmp/chmod a+x /tmp/Update/install.sh/tmp/Update/install.sh /tmp/Updatefidone 我试过也可以在rc.local中编辑。但它显示错误无法找到要复制的文件...I tried to edit in rc.local too. But it shows the error cannot find the file to copy...推荐答案 我也尝试在rc.local中编辑。但它显示错误无法找到要复制的文件...I tried to edit in rc.local too. But it shows the error cannot find the file to copy... 这篇关于使用init.d脚本将文件从USB闪存驱动器复制到系统的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 07-29 22:39