7 Replies Latest reply on Apr 11, 2012 4:55 AM by JBoss Fan

    embedded Agent on RHQ Server

    JBoss Fan Newbie

      Hi Gurus,



      I 'am a newbie to RHQ , still learnign it... I was installed RHQ on 3 systems I have.. 2 ahents and 1 servers, Also.. I want to Monitor embedded agent on RHQ servers along with the Jboss RHQ runs on.. However when I started the process it all looked good.. but I had to bump up JVM heapsize after which I dont; see embedded agent won't come up... is there a way to start embedded agent on RHQ server ?




        • 1. Re: embedded Agent on RHQ Server
          Ian Springer Master

          The embedded Agent has some known issues, and we generally do not recommend using it (see http://rhq-project.org/display/JOPR2/Running+the+RHQ+Server#RunningtheRHQServer-RunningtheEmbeddedAgentintheRHQServer). The recommended alternative is to install the standalone Agent on the RHQ Server machine, just as you did on your other two machines.  That said, if you really want to use the embedded Agent, we can try to help you, but you'll need to attach your RHQ Server log, so we can try to figure out what the issue is.

          • 2. Re: embedded Agent on RHQ Server
            JBoss Fan Newbie

            so.. how can I remove embeded Agent ? from my current installation .. Another question's I have are..

            • if I change my RHQ server from Server A to Server B how do I make my already installed agents look for new RHQ server ?..
            • Also.. is there a way to completely remove an agent from any of the server I run agent from ?


            I 'am currently using RHQ 4.3 and doing a POC for my work to sell this product to my manager...

            • 3. Re: embedded Agent on RHQ Server
              mazz Master

              If you are changing the location of all your RHQ Servers, it is recommended that you keep at least one of the original ones up while installing the new ones. This way, your agents will remain connected to some RHQ Server during your server migration. So, install your RHQ Server B but leave RHQ Server A running for at least  an hour. This will ensure that the agents will automatically get their new failover lists that will now include server B. This is because, by default, the agent's configuration preference rhq.agent.primary-server-switchover-check-interval-msecs is set to 1 hour - and this setting determines how often the agent periodically downloads its failover list from the server. Whenever you add a new server to the RHQ HA server cloud, each agent gets a new failover list assigned which includes the new server. If you don't want to wait an hour, execute the "Download Latest Failover List" operation on your RHQ Agent resources (if you've imported them into inventory). There is also a "failover --check" agent prompt command you can use. Also restarting the agent will immediately download the latest failover list. So you can see there are several ways to get the agent to download its new failover list that includes the new server - but the easiest way is just do nothing except wait over an hour :)  So, once all your agents get their new failover lists (which will now include RHQ Server B), you can shutdown RHQ Server A and, via the Server B's GUI, you can remove Server A from the server list (see the Administration > Servers screen). The agents will see server A has gone down and switch over to server B. Within another hour, the agents will call into server B, download their latest failover lists again (which now will not have server A in them) and your agents will be up to date and will only try to talk to server B.  Note that you don't have to do this if you have several RHQ Servers already in your HA Server cloud and only only want to migrate one or some of them. You only have to do this "start a new server and wait for an hour" thing if you are migrating ALL of your servers because your agents need at least one good server in their failover list to maintain connectivity to your RHQ infrastructure.  As for your second question, to remove an agent completely from inventory, simply shutdown that agent and then uninventory the platform resource that was associated with that agent. Uninventorying a platform will also remove the agent itself from the RHQ database.

              • 4. Re: embedded Agent on RHQ Server
                mazz Master

                Oh, I guess I didn't answer this : "how can I remove embeded Agent ?"  You will need to edit your /bin/rhq-server.properties and set the property "rhq.server.embedded-agent.enabled" to "false". Restart your RHQ Server once you do this. At this point, your embedded agent won't restart with the server and you can then uninventory the platform that was associated with the embedded agent.

                • 5. Re: embedded Agent on RHQ Server
                  JBoss Fan Newbie

                  Thanks a lot John... I will try this..sicne am just doingthis on a sandbox.. want to try a little more actually..


                  BTW, may be am not gettign your drift.. how do I Uninventory my agent ?

                  • 6. Re: embedded Agent on RHQ Server
                    Ian Springer Master

                    After disabling the embedded Agent as John described, go to http://localhost:7080/coregui/#Inventory/Resources/Platforms and look for the platform Resource corresponding to the now-disabled embedded Agent (it should be DOWN/red), Select that platform Resource and then click the Uninventory button to remove it from inventory.

                    • 7. Re: embedded Agent on RHQ Server
                      JBoss Fan Newbie

                      Thank you for all the support Gurus.. learned a lot about this tool now.. will explore more..