Today, when using the WCET analyzed by Chronos, there is an error:
: Syntax error: Bad fd number
This error occurs when executing the SH script and when opening the file
solution:
after consulting the data, it is possible that SH is linked to dash rather than bash, so you only need to check the link
execute command
ls -l /bin/sh
Results:
if the above results are obtained, continue to execute the command:
sudo mv /bin/sh /bin/sh.orig
sudo ln -s /bin/bash /bin/sh
Check again and you should get the correct results
Read More:
- Syntax error: Bad fd number
- [shell] sh executes the script and reports an error syntax error: “(” unexpected “)
- Shell script: syntax error: bad for loop variable error resolution
- When sh. / xxx.sh is executed, syntax error: “unexpected” appears
- SH script reports error “Eval: Line 1: syntax error: terminated quoted string”
- Prompt when executing sh file in Linux: nohup: unable to run command “. / startup. Sh”: insufficient permissions
- Vue executes NPM run Dev and reports an error: missing script: dev
- Syntax error near unexpected token `newline’script cannot be executed
- Shell script syntax error near unexpected token ‘$’Do
- SCRIPT1002: syntax error File: 0. chunk.js ,SCRIPT5009: ‘Map‘ is undefined File: 0. chunk.js -Solutions
- Find files with suffix. Sh under Linux
- R load(xxx.Rdata) Error bad restore file magic number (file may be corrupted) — no data loaded
- Solve the problem of shell script “syntax error near unexpected token `fi’”.
- Solve syntax error: unexpected end of file or /bin/bash^m: bad interpeneter: no match file or directory
- Shell script execution error: “syntax error near unexpected token”
- The solution of push D command execution error (/ bin / sh: 1: push D: not found) on Ubuntu
- The remote port occupation of Linux startup jar package script reports an error
- When Linux installs redis, it executes make install and reports an error: Make: * * [server. O] error 1 (solved)
- Solution to shell script error “expr: syntax error”
- Vue project reports an error on ie11 white screen. Script1002: syntax error