Categories
General

Installing ElectroServer on Mac OSX

[This post is obsolete – ElectroServer doesn’t seem to exist any more]

What else to do in the Christmas holidays but finally get my head around ElectroServer? 🙂 Of course the first (sometimes significant) hurdle in getting started with any multi-user technology is just installing the server on your machine! ElectroServer4 (ES4) is Java based so it should work on OSX, but most of the documentation is for Windows, so I spent today installing it on my MacBook and thought I would share what I learned.

ES4 runs on Java 1.6 and OSX is shipped with 1.5. You can find instructions on getting the update here, but whatever you do don’t complete the steps to make 1.6 the default Java Virtual Machine (JVM), otherwise FlexBuilder won’t work any more!

Now you need to download the Unix package (the one marked “without JVM”) on the ElectroServer downloads page [sorry, no longer available], and unzip it somewhere suitable (I put it in my documents folder).

Then open up a terminal window and navigate into the folder where you unzipped it. (Handy shortcut : type “cd” followed by a space and then drag the folder from the finder onto your terminal where the full path name will be inserted).

There’s a file in here called ElectroServer that you run but you need to tell it where to find the latest JVM. According to this rather useful thread [link no longer available] you can do this by typing :

export INSTALL4J_JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home/

And then start the server normally by typing :

./ElectroServer

At which point you should see the happy message :

 
16:28:08,523 [main] INFO  DisplayLogger  - 
-=-=-=-=-=-=-=-
Starting ElectroServer 4.0.6
-=-=-=-=-=-=-=-
Computer Information
	Operating System: Mac OS X
	Operating System Architecture: x86_64
	Processors Available: 2
	Memory Available: 682Mb
-=-=-=-=-=-=-=-
Virtual Machine Information
	Virtual Machine Vendor: Apple Inc.
	Virtual Machine Version: 1.6.0_17


16:28:14,863 [pool-1-thread-1] INFO  DisplayLogger  - 
-=-=-=-=-=-=-=-
ElectroServer has started successfully

After several hours of fiddling around this was somewhat of a relief.

The next problem was that I couldn’t navigate to the admin panel which by default you can find at 127.0.0.1:8080/admin. But whenever I pointed my browser at it all I got was an empty binary file in my downloads folder. Thank goodness for Twitter where Matt Bolt saved the day with his tweet :

@sebleedelisle Make sure you’re using https, not http – I run into this constantly 🙂

Thank you Matt! I have no idea how I would have figured that one out without you! So I just navigated to //127.0.0.1:8080/admin and it worked.

I expect to be furthering my adventures in ElectroServer over the next few days so I’ll keep you informed of how I get along.

6 replies on “Installing ElectroServer on Mac OSX”

Is ElectroServer flash only? Either way, I’m excited to see what you discover as you get along. Should I be ashamed that this is the first I’ve ever heard of ElectroServer? :

Hi James, I think it’s just a socket server so in theory you could connect from any technology. I think it’s fair to say that it’s been designed with Flash in mind, and all the examples I’ve ever seen have been ActionScript based. No need to be ashamed that you haven’t heard of it. I doubt that you would unless you did a lot of multi-user/streaming stuff.

I had a small problem installing it. Though I had 1.6 Java and everything the way it should be it kept telling me:

Exception in thread “main” java.lang.NoClassDefFoundError: com/install4j/runtime/Launcher
Caused by: java.lang.ClassNotFoundException: com.install4j.runtime.Launcher
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:315)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330)
at java.lang.ClassLoader.loadClass(ClassLoader.java:250)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:398)

Solution as suggested here: //www.electro-server.com/forum/?f=2&m=9395

I had to run it from server folder with this command: java -jar lib/ElectroServer4-bootstrap.jar -mode StandAlone -config config/ES4Configuration.xml

and it works fine now.. uff, confusing..

Hi. I am also trying to use electroserver on a macbook pro!

Did you get it to work? How is development on it?

I am able to play the tutorials running it on my local machine. I am trying to use an external server now (Amazon ec2), but getting it configured it proving to be difficult..

I’ve been searching but I don’t know anyone else using electroserver.

If anyone wants to talk about electroserver email me 🙂
mrdotjim@gmail.com

Comments are closed.