2 Replies Latest reply on Jul 30, 2009 9:07 AM by peterj

    Multiple instances with multiple configurations

    viniciuscarvalho

      Hello there! I've already ran multiple instances of jboss on the same machine, but I'm having problems trying to use multiple run.conf for those instances.

      We are using 4.0.1sp1 in a Suse linux

      We trigger the start using jboss_init_suse.sh

      What I've did was to create multiple runXX.conf for each jboss_init_suseXX.sh

      each jboss_init point to a server config, using a custom port according to the binding manager file. So far almost so good.

      from run.sh :

      # Read an optional running configuration file
      if [ "x$RUN_CONF" = "x" ]; then
       RUN_CONF="$DIRNAME/run.conf"
      fi
      if [ -r "$RUN_CONF" ]; then
       . "$RUN_CONF"
      fi
      


      So I tried to set the RUN_CONF on the jboss_init_suseXX, problem is that it is never read. I'm a total noob on unix shell scripts, what I'm trying to do is:

      DIRNAME=`dirname $0`
      RUN_CONF="$DIRNAME/run2.conf"
      export RUN_CONF
      


      but it is not working. Another problem is regarding the stop, I'm only being able to stop it using -s hostname:port and not -n serverName, the second option throws an exception:

      Exception in thread "main" javax.management.MalformedObjectNameException: Key properties cannot be empty
       at javax.management.ObjectName.construct(ObjectName.java:467)
       at javax.management.ObjectName.<init>(ObjectName.java:1394)
       at org.jboss.Shutdown.main(Shutdown.java:164)
      


      Any ideas on how can I solve this issues?

      Regards