I am trying to run a
.run file, I log in as SU and run the following command:
but I am getting the following error:
Syntax error: Unterminated quoted string
What is the cause of this?
The cause is probably an unterminated quoted string in the installer. (well duh!).
Either run it with the -x option to get more debug information, or open the installer in an editor and look for unmatched pairs of quotes.
#!/usr/bin/env bash #My demo installer! # echo "starting here!" echo "and an error in this line echo "We will never get here!"
Notice the missing closing quote (
") in the second echo line.
I just downloaded a file called
xampp-linux-x64-1.8.3-1-installer.run from sourceforge (which I assume is the same file as you are using) and when I opened it in vim I noticed it starts with
^?ELF^. This file seems to be an ELF binary.
Using the file command on it confirms this:
file: ELF 32-bit LSB executable, Intel 80386, version 1 (GNU/Linux), statically linked, stripped
It is not a shell script and the normal way to execute it would either be:
xampp-linux-x64-1.8.3-1-installer.run(assuming the directory is in your search path),
./xampp-linux-x64-1.8.3-1-installer.runif you are already in the same directory where the file is. (This is why @erhun's answer worked).
It will work with this way.
chmod +x xampp-linux-x64-1.8.3-1-installer.run ./xampp-linux-x64-1.8.3-1-installer.run
I tried to install xampp-linux-x64-1.8.3-2-installer.run and had the same message. None of these answers worked for me because I think this is the x64 bit version and I was trying to install it on a 32bit Linux Mint.
Instead I downloaded xampp-linux-1.8.3-2-installer.run (notice the lack of x64 in the file name) and this one worked. I did the chmod , then sudo ./xampp-linux-1.8.3-2-installer.run and after good few seconds i had the gui installer running.
PS. You'll need to go to sourceforge because apachefriends.org website will give you x64 version as default download.
Looks not a problem with 64-bit OS.
I got same error and 'uname -m' can confirm it (displays x86_64), although I was already sure specifically purchase 64-bit machine.
Looks like while downloading (wget for many hours, very slow mobile Internet), 'xampp-linux-x64-1.8.3-4-installer.run' got corrupted!