Hello Foglight Folks,
Robert Statsinger here. On occasion you may run into a situation where you need to migrate your Foglight Management Server to a different host. Some circumstances that might necessitate this are:
1. You are upgrading your iron and you are not able to image or back up the system
2. You are changing the standard OS platform within your IT environment, including the OS platform for your FMS
3. You are moving to a virtualized infrastructure and you want to run your FMS on a VM rather than on real iron, and you are not able to image your FMS host onto a guest VM
The factors you’ll need to consider are:
1. Your current FMS – are you using the embedded MySQL repository, or a repository on a separate tier?
If your FMS installation is a physical 2 tier setup – i.e. your FMS repository is running on a separate host – then your repository will essentially never be aware that the migration has taken place. If your FMS was set up with the embedded MySQL instance or you are using a separate instance of MySQL Enterprise that is running on your FMS host and you plan to decommision this host, you will need to use MySQL native tools to dump this data and reestablish your MySQL repository elsewhere. This article will not address exporting or migrating data from the Foglight repository; those tasks will require you to use data export and import tools native to the database vendors in question and is outside the scope of our discussion here. We recommend that you work closely with your DBAs if you have this requirement.
2. Will the new FMS have the same hostname/IP address?
If the new FMS will have the same hostname and IP address, then you will not need to touch any of the configurations for FglAM or other agents out in the monitored environment. If this is not the case, then modifications to the agent configurations will probably be necessary – we’ll touch on that later.
3. What customizations exist in your current FMS?
If you have custom rules, dashboards, or scripts, you’ll want to export them from the FMS using the fglcmd command line tool.
The Almost Simplest Case – 2 Tier FMS, Same FMS IP Address, Different OS Platform
So let’s assume you have a 2 tier FMS install, and the FMS will move to a new platform with the same hostname and IP address but will continue talking to the existing Foglight repository. Here’s what you’ll want to do:
1. Make sure you have a copy of the license file for your current FMS.
2. Shut down all Foglight Agent Manager instances and other agents on the monitored hosts. This is not strictly necessary but it will prevent them from logging errors during the migration.
3. Shut down your current FMS.
4. Save a copy of the foglight.config file from your current FMS. This is important. Keep this copy around; we’ll need it on the new FMS.
5. Install your new FMS on your new platform. Choose the embedded MySQL installation type (don’t worry – we won’t actually be using the embedded MySQL instance for very long).
6. Install your license on the new FMS, and install every cartridge on the new FMS that you had installed on the old one.
7. Shut down the new FMS instance.
8. In the new FMS installation’s config directory, rename its copy of foglight.config to foglight.config.old.
9. Install the foglight.config from your old FMS into the new FMS’s config directory.
10. Restart your Foglight Agent Managers and other agents.
11. Restart your new FMS. It should successfully connect to your repository, allowing all previous users to resume using Foglight. Check the Agent Hosts and Agent Status dashboards to make sure your agents are reconnecting.
12. Install your customizations using fglcmd.
There – wasn’t that easy?
The Almost Simplest Cast – 2 Tier FMS, Different FMS IP Address
If the new FMS instance will not have the same IP address, then you’ll add one additional step between steps 9 and 10:
9a. Visit each machine where you are running the Foglight Agent Manager. In the Agent Manager’s installation, find the state/default/config directory and edit the file called fglam.config.xml. Look for a line that looks like
config:http-upstream [….] url=”http://<FMS Hostname or IP Addr>:<port>”/
Change the hostname or IP address in this URL so that it’s pointing to your new FMS. Note that if you are using the Agent Manager’s concentrator capability, this IP address might be the address of an upstream fglam instance and not of your Management Server. Make sure you only change this line if it is currently pointing to your old FMS.
If you are running any JavaEE agents, then you will want to modify the agent properties for your JavaEE Deployment Manager agents and change the NexusConnections configuration so that the agent reports to the new FMS.
That’s it. Have fun with your new FMS!