script giving strange error not seen before

(Nic Hubbard) #1

Matrix Version:

We are needing to move our Matrix install from one server to another, so I am needing to use the script, which I have used many times before. Strangely I get this error:

/opt/matrix/scripts/ 328: /opt/matrix/scripts/ [[: not found
/opt/matrix/scripts/ 343: /opt/matrix/scripts/ [[: not found
/opt/matrix/scripts/ 795: /opt/matrix/scripts/ [[: not found
Backup failed
gzip: compressed data not written to a terminal. Use -f to force compression.
For help, type: gzip -h

Has anyone seen this before or know why this would happen?

(Chiranjivi Upreti) #2

Tested my local system and had no issues.

How exactly are you running it?

(Nic Hubbard) #3

Running it as root and using the manuals as a guide:

./scripts/ /opt/matrix

(Chiranjivi Upreti) #4

Thats strange. I am running the same version of the script and I am getting any errors.

This is the only issue I am aware that not been fixed yet:

(Nic Hubbard) #5

It is strange.

I had to do bash ./scripts/ /opt/matrix before it would work. Never had to do that before!

(David Schoen) #6

You must have an actual posix shell at /bin/sh (basically unheard of in our hosting) and our still specifies (incorrectly) /bin/sh despite using bashisms (the [[ is a bash keyword).

Calling it the way you do is a fine work around.

(David Schoen) #7

I’ve lodged a bug for this: