Forum Discussion

walidmef's avatar
walidmef
New Contributor
12 years ago

Unable to run LoadUI from command Line Centos

Hi All,

Hi All,

I have been trying to run LoadUI from command line on Centos but I am getting some errors.
The first issue was resolved by converting the loadUI-cmd.sh from dos to unix using fromdos.

Now that loadUI-cmd.sh is working, I am getting the following error: A an error message window pops-up and it has the following:
JavaFX Launcher Error: Unable to invoke main method

Then this is what I get in the shell:

Starting with arguments: [--cmd=true, --nofx=true, -nofx, -Dlog4j.configuration=log4j_headless.xml, -p, walidtest.xml]
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.javafx.main.Main.launchApp(Main.java:502)
at com.javafx.main.Main.main(Main.java:638)
Caused by: java.lang.UnsatisfiedLinkError: /usr/local/SmartBear/LoadUI-2.6.8/jre/lib/i386/libjavafx-font.so: /lib/libc.so.6: version `GLIBC_2.11' not found (required by /usr/local/SmartBear/LoadUI-2.6.8/jre/lib/i386/libjavafx-font.so)
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary1(Unknown Source)
at java.lang.ClassLoader.loadLibrary0(Unknown Source)
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.load0(Unknown Source)
at java.lang.System.load(Unknown Source)
at com.sun.javafx.runtime.NativeLibLoader.loadLibraryFullPath(NativeLibLoader.java:200)
at com.sun.javafx.runtime.NativeLibLoader.loadLibraryInternal(NativeLibLoader.java:88)
at com.sun.javafx.runtime.NativeLibLoader.loadLibrary(NativeLibLoader.java:31)
at com.sun.t2k.T2KFontFactory$1.run(T2KFontFactory.java:58)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.t2k.T2KFontFactory.<clinit>(T2KFontFactory.java:55)
at com.sun.javafx.font.PrismFontLoader.getSystemFontSize(PrismFontLoader.java:474)
at javafx.scene.text.Font.getDefaultSystemFontSize(Font.java:69)
at javafx.scene.text.Font.getDefault(Font.java:85)
at com.eviware.loadui.launcher.JavaFxStarter.isJavaFXFontsAvailable(JavaFxStarter.java:61)
at com.eviware.loadui.launcher.JavaFxStarter.ensureFontsAvailableForJavaFX(JavaFxStarter.java:38)
at com.eviware.loadui.launcher.JavaFxStarter.startJavaFxEnv(JavaFxStarter.java:33)
at com.eviware.loadui.launcher.JavaFxStarter.<init>(JavaFxStarter.java:21)
at com.eviware.loadui.launcher.CommandLineStarter.<init>(CommandLineStarter.java:5)
at com.eviware.loadui.launcher.LoadUIStarter.launchCmdRunner(LoadUIStarter.java:42)
at com.eviware.loadui.launcher.LoadUIStarter.main(LoadUIStarter.java:22)
... 6 more


I tried to run the binary: ./LoadUI-2.6.8 --cmd=true but still the same error "JavaFX Launcher Error: Unable to invoke main method "
Any help please.
I need to be able to run LoadUI from command line as I am planning to automate the tests.

Thanks,

4 Replies

  • walidmef's avatar
    walidmef
    New Contributor
    Hi Rao,

    Thanks for the reply.
    Unfortunately, the post that you provided me with didn't help.

    I think my problem is more of a compatibility issue especially if you check the cause of the error message: it seems it is caused by "GLIBC_2.11".
    My CentOS is a server version 5.8 and I have GLIBC_2.5 so I am assuming that is the issue.

    I have asked around and some people said that it is impossible to overcome that error. They suggested either i upgrade my OS or use an older version of loadUI.

    Any suggestions?
    Thanks,
  • Hello walid,

    Sounds like you need to try the development packages for glibc2: glibc2-devel,
    if i don't remember incorrectly that'll include backward compatibility for GLIBC_2.11.

    Best,

    Mikael
  • Hello again,

    I did some research into this and came to the conclusion that some parts of JavaFX is compiled using GLIBC_2.11 which is from 2009.
    This is about the same year as JavaFX was released, so that pretty much makes sense.

    As with many other *nix-libraries you cannot compile with a "new" one and run it with an old one, the other way around usually works though.
    To recompile glibc for a specific version can be very dangerous for any distro and is prone to breaking a'lot of stuff.
    That is something i would never recommend anyone to attempt doing.

    This means that the LoadUI controller will most likely never work in CentOS 5.8 unfortunately.
    The agent should work just fine though, as it has been cleaned up from JavaFX dependencies.

    An alternative if you are stuck with a production environment that is old and gold is to use virtualization to achieve what you need.

    I hope it works out!

    Best regards,
    Mikael