4.8. Upgrading JBoss ON
4.8.1. Upgrading the JBoss ON Server
- First, do some prep work on the JBoss ON configuration. It is easier to clean up the configuration before migration than it is after.
- Remove any unused or out of service platforms from the inventory.
- Remove any alert definitions which use conditions for obsolete metrics.For migrating to JBoss ON 3.1.2, there are four alert conditions — all for PostgreSQL databases — which should be removed:
- User Time
- Kernel Time
- Physical Memory
- Virtual Memory
- Prepare the JBoss ON agents for upgrade. Agents will auto-upgrade, meaning that when they detect that the server has a new version, the agent will request an update. Follow the instructions at Section 8.7, “About Agent Automatic Updates” to prepare the agent, and then just leave it running. The agent should be running in the background to upgrade properly, as in Section 8.4, “Running the JBoss ON Agent as a Service”.In some rare cases, the agent will be upgraded manually instead of upgrading itself. In that case, stop the agent before upgrading the server, and follow the instructions at Section 8.8, “Manually Upgrading the JBoss ON Agent”.
- Stop the JBoss ON server which is being upgraded as well as any currently running JBoss ON instances. For example:
WarningIf the upgraded JBoss ON server will use a database that existing JBoss ON instances are also using, then all of the existing JBoss ON instances have to be stopped. Otherwise, the installer will hang when it tries to contact the database and the database is unavailable because it is in use by another JBoss ON server.
- Open the server root directory. For example:
- Unzip the server packages.
ImportantDo not copy the new server installation on top of a previous server installation.The directory structure within the server package gives the new server installation directory a version-specific name, such as
- Copy over any changes in your original
rhq-server.propertiesfile to the new file in
serverRoot/jon-server-126.96.36.199.GA1/bin. Changes to this file include things like setting up SSL and enabling SMTP for email notifications.
NoteIn JBoss ON 2.3.1 and older versions, the password to access the database is stored in plaintext. In JBoss ON 3.1.2, this password is hashed for security.
NoteIf you don't want to edit the
rhq-server.propertiesfile manually, you can change the server settings to the proper configuration in the Advanced Settings form during the server setup.
- If the server was installed as a Windows service, then uninstall the Windows service for the original server:
cd c:\old-serverRoot\bin ./rhq-server.bat removeThen install the new server as a Windows service:
cd c:\new-serverRoot\bin ./rhq-server.bat install
- Additional plug-in packs for specific needs (such as supporting management tasks for EWS, EAP, and SOA-P) are available to be installed separate from the core JBoss ON agent packages. Each plug-in pack as at least one (and sometimes more than one) agent plug-in. Each zip file for the plug-ins has a README.txt file with specific setup instructions.The plug-in files can be unzipped anywhere. For example:
cd /opt/jon/jon-server-188.8.131.52.GA1 unzip jon-plugin-pack-agent_plugin_name-184.108.40.206.GA1.zip
NoteIf there are multiple JBoss ON servers in a high availability setup, the agent plug-in pack only has to be installed once. The other servers will pick up the plug-ins as part of the high availability polls.
- Start the JBoss ON server. For example:
- Back up your server database before going through the setup wizard. In case there is a problem with the upgrade process, the backup allows you to restore to its previous state.
- Open the web UI.
http://hostname:7080As with a new installation, the installer opens after you log in.
- The setup process is the same as the initial setup procedure in Section 4.3, “Going Through the Web Installer”.
WarningDo not change any of the settings for the server, especially identifying information such as the Server Name field. This can cause errors during the upgrade process.When the database connection information is entered, the JBoss ON installer detects the existing JBoss ON database. This introduces a new field to the installer, prompting you for what to do with the existing database.Choose the default, Keep (maintain existing data). Do not choose Overwrite (lose existing data), or the installer will delete all of your JBoss ON data, including your inventory, monitoring history, alerts, and metrics.
- The Registered Servers lists every server in the server cloud. For upgrades and re-installs, this gives you the option to keep the existing server configuration (such as ports and notification settings) or to set new values. To preserve the settings, select the server from the registered servers list; otherwise, select New Server.
- Restart the browser after upgrade completes or force the browser to refresh, using Ctrl+F5.
NoteThe browser caches an old session ID for the previous JBoss ON server installation. Attempting to open the GUI without refreshing the cache causes the login to fail and throws an error in the JBoss ON server logs:
Exception: 2012-05-23 16:37:08,046 ERROR [org.apache.catalina.connector.CoyoteAdapter] An exception or error occurred in the container during the request processing java.lang.NullPointerException at org.apache.catalina.connector.CoyoteAdapter.parseSessionCookiesId(CoyoteAdapter.java:507) at org.apache.catalina.connector.CoyoteAdapter.postParseRequest(CoyoteAdapter.java:449) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:239) ... 8< ...
- Start any JBoss ON agents that were stopped for the upgrade process.
- If the older JBoss ON server was added to the JBoss ON inventory, then remove it. The old JBoss ON server must be removed from the inventory because it is no longer a usable resource.
- Optional. Add the new JBoss ON server as a resource in the inventory.
4.8.2. Migrating SNMP Settings
- Run a SQL command to copy the settings from the database table for the old server instance into the table for the new instance.
- Set the SNMP settings in the JBoss ON GUI.
220.127.116.11. Running SQL Commands to Migrate the SNMP Settings
- Open the administrative page, with the location
admin/test/sql.jsp. For example:
- Run the command to migrate the SNMP settings:
select property_key,property_value from RHQ_SYSTEM_CONFIG where property_key like 'SNMP%';
- Click thebutton.
- Reconfigure all of the SNMP alert notification senders.
18.104.22.168. Configuring SNMP Settings in the GUI
- In the top menu, click the Administration tab.
- In the Configuration box on the left navigation bar, click the Plugins link.
- Click the Server Plugins tab.
- Click the name of the SNMP plug-in in the list.
- In the plug-in details page, click the Configure 'Alert:SNMP' link to open the configuration page for the plug-in.
- Click thebutton at the bottom of the configuration screen to make the fields active.
- All SNMP versions require the JBoss ON MIB OID (
22.214.171.124.4.1.18016.2.1) and selected version, plus optional information to access the trap. Expand the version-specific configuration section and fill in the information about the SNMP agent.
- Once SNMP is set up for the server, reconfigure all of the SNMP alert notification senders.
4.8.3. Upgrading the JBoss EAP 6 Resource Plug-in
- Delete the original tech preview plug-in and purge it from the JBoss ON database. Purging the plug-in allows the server to deploy the new plug-in in its place.
- In the top menu, click the Administration tab.
- In the Configuration box on the left navigation bar, click the Agent Plugins link.
- Select the EAP 6 tech preview plug-in.
- Click the Delete button.
- Click the SHOW DELETED button at the bottom of the plug-ins list.
- Select the EAP 6 plug-in, and then click the PURGE button. This removes the entry in the JBoss ON database that tells the servers to ignore that original tech preview plug-in and any updates to it.
ImportantWait for the purge operation to complete before continuing with the upgrade process.
- If the server has not already been upgraded, upgrade the JBoss ON server, as described in Section 3.8.1, “Upgrading the JBoss ON Server”.
- Install the EAP 6 plug-in pack, as described in Chapter 5, Installing JBoss Agent Plug-in Packs.
- Import the EAP 6 server and its children.Configuring and managing resources for EAP 6 domains and standalone servers is described in How to Manage JBoss Servers.