Re: Running shell scripts from external media

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



James B. Byrne wrote:
Problem:
As 'root', when running a script resident on the external drive mounted at
/media/disk I receive the following error:

/bin/sh: bad interpreter: Permission denied


Usually, I've found this is because the file is stored with DOS style line endings.
Maybe you could try:

dos2unix -n hello.sh hello2.sh
chmod +x hello2.sh
./hello2.sh

Does that fix it?

Greg
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux