StartOSW. sh:./OSWatcher. sh:/bin/ksh: badinterpreter: Permissiondenied solution

Source: Internet
Author: User
StartOSW. sh:./OSWatcher. sh:/bin/ksh: badinterpreter: Permissiondenied solution 1 view oswatcher_restart.sh content [root @ xxdb0402dbscripts] # moreoswatcher_restart.sh #! /Bin startOSW. sh:./OSWatcher. sh:/bin/ksh: bad interpreter: Permission denied solution 1 view the contents of the handler [root @ xxdb0402 dbscripts] # more oswatcher_restart.sh #! /Bin/ksh # export oswdir = 'df | grep mysqllog | awk {'print $6} ''export oswdir =/mysqllog # th = 'PS-ef | grep-v $ $ | grep OSWatcher. sh' # echo $ th; if ['PS-ef | grep-v grep | grep OSWatcher. sh | wc-l '= "0"] then cd $ oswdir/osw echo "begin 1" sh startOSW. sh 60 216 error after else echo "OSWatcher is running" fiexit 2 run [root @ xxdb0402 dbscripts] # bash-x oswatcher_restart.sh + export oswdir =/mysqllog + ps -Ef ++ grep-v grep ++ grep OSWatcher. sh ++ wc-l + '['0 = 0']' + cd/mysqllog/osw + echo 'In in 1' begin 1 + sh startOSW. sh 60 216 + exit [root @ xxdb0402 dbscripts] # startOSW. sh :. /OSWatcher. sh:/bin/ksh: bad interpreter: Permission denied solution 1. reinstall ksh and report the same error. 2. execute sh startOSW directly. sh 60 216 also reported the same error 3 file format. I copied the file from prod to the local pc, and then copied it from the local pc to test the linux environment, I deleted the sh file, directly installed vim on the prod, copied the text, and pasted it to the test linux environment. the same error was reported after execution. Finally, I tried to set the first line of the file content startOSW. sh and startOSW. sh #! /Bin/ksh: delete the reference and execute bash-x oswatcher_restart.sh. OK. The/bin/ksh: bad interpreter: Permission denied error will no longer be reported.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.