felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonhnny Weslley" <jonhnnywesl...@gmail.com>
Subject felix starter script
Date Fri, 19 Oct 2007 17:18:09 GMT

In Felix 1.0.1 release a script file is available to start the felix.
However, this script is placed at 'etc' directory, when usually
scripts are placed at 'bin' directory! Why?

The script is very simple, then I did another script attached in this mail.
But when I executed my script, or when I start felix from another
directory different of the installation directory, felix isn't able to find
my auto-started bundles.

The console output is:

CONSOLE ==========================================

jonhnny@argus:~ $ felix

Welcome to Felix.

Enter profile name: jonhnny

ERROR: Auto-properties install. (org.osgi.framework.BundleException : Unable
to cache bundle: file:bundle/org.apache.felix.shell-1.0.0.jar)
java.io.FileNotFoundException: bundle/org.apache.felix.shell-1.0.0.jar (No
such file or directory)
ERROR: Auto-properties install. (org.osgi.framework.BundleException: Unable
to cache bundle: file:bundle/org.apache.felix.shell.tui- 1.0.0.jar)
bundle/org.apache.felix.shell.tui-1.0.0.jar(No such file or directory)
and other auto-started bundles

My felix was installed at ' /usr/local/felix' directory.
However when I start felix, independently to be by shell script or directly
executing java comand, it searchs the auto-start bundles configured in the
config.properties at the local directory where the command was executed.
Then when I execute ' java -jar /usr/local/felix/bin/felix.jar' at my home
directory, it searchs my bundles at

I thought in a basic solution.
1. Define a system property felix.home, this value is assigned at the script
2. Change the config.properties file to:
felix.auto.start.1= \
 file:${felix.home}/bundle/org.apache.felix.shell-1.0.0.jar \
 file:${felix.home}/bundle/org.apache.felix.shell.tui-1.0.0.jar \

The script assumes the follow hierarchy directory:
   |- bin/
   |    |- felix     (the script file)
   |- lib/
   |    |-felix.jar  (the felix jar)
   |- bundle/
   |- conf/

  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message