2 Replies Latest reply on Dec 29, 2003 3:18 PM by ctaggart

    twiddle usage

    ctaggart

      A coworker of mine just came back from some JBoss administrative training and said that twiddle.bat or twiddle.sh can be using to get information about the server. Upon further investigation, I found out that twiddle uses JMX and MBeans, but I can't seem to get it to work. Can someone give an example. E.G. get any of the information that appears on the web-console front page like # of threads, start date, host.

      I am able to get a list of 302 mbeans doing this.
      cd C:\java\jboss-3.2.3
      set PATH=%PATH%;bin
      set JBOSS_CLASSPATH=client\jbossall-client.jar
      twiddle serverinfo -l > mbeans.txt

      After that I am at a loss. I can't seem to get 'twiddle info' or 'twiddle get' working. Any help would be appreciated.

      Thanks,
      Cameron

        • 1. Re: twiddle usage
          ctaggart

          Here are some commands that I have tried and the errors I receive. I'm running the default server (JBoss 3.2.3) without any modification on WinXP laptop currently with JRockit JVM 1.4.2.

          These three commands:

          twiddle info jboss.system:type=Server
          twiddle info jboss.system:type=ServerInfo
          twiddle info jboss.system:type=ServerConfig

          all return this error:

          twiddle: Invalid object name: jboss.system:type
          Get the metadata for an MBean
          usage: info <mbean-name>
          Use '*' to query for all attributes

          Did I not get the mbean names correct?


          • 2. Solved: forgot quotes
            ctaggart

            Problem: I forgot to put quotes around the MBean arguments. Here are some examples that work for me:

            cd C:\java\jboss-3.2.3
            set PATH=%PATH%;bin
            set JBOSS_CLASSPATH=client\jbossall-client.jar

            twiddle info "jboss.system:type=Server"
            twiddle info "jboss.system:type=ServerInfo"

            twiddle get "jboss.system:type=Server" Version VersionName BuildDate
            twiddle get "jboss.system:type=ServerInfo" HostName HostAddress JavaVMVendor JavaVMVersion
            twiddle get "jboss.system:type=ServerInfo" FreeMemory TotalMemory ActiveThreadCount