Results 1 to 2 of 2
Hello all, I am new to linux bash shell scripting. I am trying to execute the following script on my linux box, but getting error. Can anyone please help me ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 10-21-2010 #1
- Join Date
- Oct 2010
Bash shell script error
I am new to linux bash shell scripting.
I am trying to execute the following script on my linux box, but getting error.
Can anyone please help me to get out of it....?
Functionality : I have one search tool CCSearchX, whenever I execute the toll it generates some files. So here here first I am checking whether the same process is in execution or not, if yes then do nothing and if no then check whether any previous result file is available or not. if result file is available then do nothing and if result file is not available execute the CCSearchX utility.
following is the shell script
pgrep -f "CCSearchX"
if [ $status != 0 -a $status != 1 -a $status != "" ];
echo "Process is running"
if [ "$(find -name 'linux_result_cc_search_*')" != "" ];
echo "Output file linux_result_cc_search_* exist."
./CCSearchX --input=/ --output=/tmp/linux_result_cc_search_1287659590.txt
And I am getting following error
bash_cc_search_1287659890.sh: line 16: syntax error: unexpected end of file
Last edited by ecomwebtester; 10-21-2010 at 11:51 AM. Reason: forgot to add some code #!/bin/bash
- 10-21-2010 #2
- Join Date
- Apr 2010
- Novosibirsk, Russia