Hi everyone, We want to install Mendix Server on Linux (Ubuntu). Previously, with OpenJDK, it is Ok. Now, we want to use Sun JDK. So, we have: $ java -version java version "1.6.029" Java(TM) SE Runtime Environment (build 1.6.029-b11) Java HotSpot(TM) 64-Bit Server VM (build 20.4-b02, mixed mode) However, if we try to start the server from m2ee(root), we have errors: m2ee(root): start INFO: Trying to start the MxRuntime... Traceback (most recent call last): File "/usr/bin/m2ee", line 769, in <module> m2ee.cmdloop() File "/usr/lib/python2.6/cmd.py", line 142, in cmdloop stop = self.onecmd(line) File "/usr/lib/python2.6/cmd.py", line 219, in onecmd return func(arg) File "/usr/bin/m2ee", line 88, in dostart self.start() File "/usr/bin/m2ee", line 150, in start if not self.runner.start(): File "/usr/share/m2ee-tools/m2ee/runner.py", line 130, in start env=self.config.getjavaenv() File "/usr/lib/python2.6/subprocess.py", line 633, in init errread, errwrite) File "/usr/lib/python2.6/subprocess.py", line 1139, in _executechild raise child_exception OSError: [Errno 2] No such file or directory ERROR: Starting the JVM process did not succeed... It seems that the script cannot find the directory of JVM. The directory of JVM in our machine is: "/usr/lib/jvm/jdk1.6.0_29 " Do you know how we can solve the problem? Regards,
NEVER run mendix (or any other process that does not need root privileges) as the root user on a *nix system. Just don't. Never ever. Really.
Having said that:
It seems the java executable is not on your search path. Right now m2ee-tools uses the default 'java' program on the filesystem search path. Did you install the sun java jre using Ubuntu packages?
Ubuntu has the update-java-alternatives program to switch default JVM on a machine. What's the output of update-java-alternatives -l ?
Hans van Kranenburg
Based on your answer, I found out the solution.
My problem was that I installed JDK manually from the "jdk1.6.0_29.bin" package. Therefore, m2ee-tools can not find the JVM.
So now, I install Java by using apt-get. (Ref: https://help.ubuntu.com/community/Java)
Then, I use sudo update-java-alternatives -s java-6-sun to change the default JVM to java-6-sun.
Hope that someone in the same situation can overcome it :)