maths / stack_util_maximapool

Pooling solution for starting up maxima processes so that moodle-qtype_stack does not need to wait.
10 stars 14 forks source link

Syntax error?? #27

Closed t6nis closed 6 years ago

t6nis commented 6 years ago

Hello!

Trying to make maximapool work. STACK 4.1 and Moodle 3.1.9 are working and healthcheck shows at the bottom:

  unix
OK You have chosen the "default" version of Maxima, so no Maxima version checking is being done. Your raw connection is actually using version "5.41.0" (41.0). CAS returned data as expected. You have a live connection to the CAS.
OK Maxima image created at: timeout --kill-after=10s 10s /usr/lib/clisp-2.49/base/lisp.run -q -M (..path)/moodledata/stack/maxima_opt_auto.mem
OK Correct and expected STACK-Maxima library version being used (2017121800).
  CAS results are not being cached.

When i execute - (..path)/moodledata/stack/maxima_opt_auto.mem from command line or low level health check i get this - "(..path)/moodledata/stack/maxima_opt_auto.mem: 1: ..path/moodledata/stack/maxima_opt_auto.mem: Syntax error: "(" unexpected"

Any ideas?

Maxima: Maxima 5.41.0 http://maxima.sourceforge.net using Lisp CLISP 2.49.60+ (2017-06-25) Distributed under the GNU Public License. See the file COPYING. Dedicated to the memory of William Schelter. The function bug_report() provides bug reporting information.

aharjula commented 6 years ago

Syntax error: "(" unexpected

Surely, your command line contains no ( char that would cause that error? What is the raw command in your process config? Feel free to change random chars in the path if you need to obfuscate but don't hide the form i.e. are there spaces or other special chars there...

In any case first try to get that command working to find out if this is a MaximaPool issue. lisp.run -q -M maxima_opt_auto.mem is basically the form of the command as long as the paths have been prefixed to the lisp.run and the image and you are using CLISP.

t6nis commented 6 years ago

Ok here is the full command - user@maxima:/var/lib/maximapool/2017121800$ sudo /usr/lib/clisp-2.49/base/lisp.run -q -M /opt/veebid/vhosts/moodle.ut.ee/moodledata/stack/maxima_opt_auto.mem /usr/lib/clisp-2.49/base/lisp.run: initialization file `/opt/veebid/vhosts/moodle.ut.ee/moodledata/stack/maxima_opt_auto.mem' was not created by this version of CLISP runtime

Although if i delete maxima_opt_auto.mem, the healthcheck creates it again. I suppose it creates using the same CLISP version.

aharjula commented 6 years ago

It might be that the healtcheck just fails in the image creation? If you move the image to another machine which would be sensible for a MaximaPool install there may be numerous other things that change with the lisp runtime.

Typically, people create the image manually when using MaximaPool as the Pool normally presides on another machine. Try creating your own memory image.. Personally, I do it like this:

t6nis commented 6 years ago

Thank you for your feedback!

I got this now working but i had to compile Maxima image from scratch(changed from 5.41.0 to 5.38.1) using this tutorial - https://github.com/maths/moodle-qtype_stack/blob/master/doc/en/CAS/Optimising_Maxima.md#compiling-a-maxima-image (Ubuntu) part.

The problem before was that i downloaded a prebuilt Maxima image with clisp and that throwed the error message "was not created by this version of CLISP".

CLISP version was before using Lisp CLISP 2.49.60+ (2017-06-25) - that was wrong..

Now it is: using Lisp CLISP 2.49 (2010-07-07) and everything is working.