< Previous | Front page | Next >
Skip to end of metadata
Go to start of metadata

JBoss Server Migration Tool User Guide


Migrating an existing application server configuration from one release to another is a complex task. It requires a complete understanding of the current server configuration. It also required extensive knowledge of what has changed in the target release. The individuals performing the migration generally must copy and edit several configuration files, and then make the updates needed to keep the same behavior in the new release. If it is not done correctly, the new server does not work as expected, often because some functionality is not supported by the new server. The JBoss Server Migration Tool is a Java application that automatically migrates JBoss EAP and WildFly server configurations with minimal or no interaction required.


Minimal Requirements

The JBoss Server Migration Tool is a Java standalone application. It requires Java version 8 or later.

It is recommended that you start the tool using the provided .sh (Linux, Mac OS) and .bat (Windows) scripts.

Binary Distribution

Download the JBoss Server Migration Tool ZIP archive from https://github.com/wildfly/wildfly-server-migration/releases.Simply unzip the archive into a directory of your choice. No further setup is needed.

Source Code

The JBoss Server Migration Tool source code is open source. The source repository is located in GitHub at https://github.com/wildfly/wildfly-server-migration.

Apache Maven 3.x or later is required to build the application from source code.

To build the tool, open a terminal, navigate to the root directory of the project, and type the following Maven command:

This creates a ZIP archive in the build/target/ directory containing the tool. As with the downloaded binary distribution, unzip the ZIP archive into the directory of your choice.

Executing the JBoss Server Migration Tool

Running the JBoss Server Migration Tool

To run the JBoss Server Migration Tool, open a terminal, navigate to the root directory where you downloaded or built the tool, and run the the provided script. This is the server-migration.sh file for Linux or the server-migration.bat file for Windows.

The following is the basic command to run tool.

The following arguments are required when you execute the script:

  • ---source <server-from-path>
  • ---target <server-to-path>

Replace <server-from-path> with the path to the server you are migrating from.

Replace <server-to-path> with the path to the server you are migrating to.

These paths should be absolute paths or relative to the current directory.

For example, if the source server base directory relative path is ../jboss-eap-6.4 and the target server base directory relative path is ../jboss-eap-7.0, execute the following command to migrate the server configuration.

NOTE: If no arguments are provided, the tool prints usage instructions and provides a list of supported arguments.

Upon execution, the tool scans the specified source and target server base directories to identify each server. It then delegates the migration process to the target server.

This is a fully automated process. The tool execution will fail if a server is not recognized or if the target server does not support migration from the specified source server.

Running in Interactive Mode

The JBoss Server Migration Tool can be run in either interactive mode, meaning the user may be prompted for input, or non-interactive mode, meaning the input values are preconfigured and available to the tool without user input.

You can explicitly set the mode by providing the following argument.

  • ---interactive <true or false>

Please note that this mode defaults to true, thus the tool is executed in interactive mode when this argument is not specified.

To use predefined behaviors and run in non-interactive mode, you must specify false for this argument.

NOTE: Non-interactive mode predefined behavior is specific to each supported server migration and is described in more detail in the related sections of this document.

Configuring the JBoss Server Migration Tool

The JBoss Server Migration Tool is configured using a combination of properties defined within the tool, user properties passed on the command line, and system environment variables.

Note that the environment properties required for each supported server migration may differ. Refer to the specific server migration user guide for the list of valid properties for that migration.

Tool Configuration Properties

You can configure the JBoss Migration Server Tool using the environment.properties file located in the config/ directory. Valid properties for this standard Java properties file can be found in the guide for each specific server migration.

User Configuration Properties

User configuration properties are defined in a standard Java properties file and are passed on the command line using the following argument.

  • ---environment <path-to-properties-file>

Replace <path-to-properties-file> with the path to the properties file. This path should be an absolute path or a path relative to the current directory.

The following example demonstrates how to pass user configuration properties on the command line.

Properties defined in files passed on the command line using the ---environment argument override the ones specified in the server configuration config/ directory.

System Configuration Properties

System configuration properties may also be used to set migration's environment properties on the command line, using the following syntax.

The System property name should be jboss.server.migration concatenated with the environment property name, the following example demonstrates how to specify migration-report.xml as the name of the XML report file when starting the JBoss Server Migration Tool.

System property names override both user configuration properties and tool configuration properties.

Logging Configuration

The JBoss Server Migration Tool uses the JBoss Logging framework to log the migration progress. Results are written to the Java console and also to a file named migration.log, which is located in the current user directory. This log file is created if it does not exist and its content is overwritten on each subsequent execution of the tool.

The logging configuration is provided by the config/logging.properties file. You can modify the configuration file or specify an alternative logging configuration file by specifying the following system property on the command line.

Migration Reports

The tool generates multiples reports, of different formats, after the server migration completes. Such reports may be used to analyse in detail how the target server was setup.

Migration Tasks

The data collected from executing the server migration logic is structured as a tree of Migration Tasks. Each server migration implementation has a root task, which executes its subtasks, and so on.

Each Migration Task has a name, made of a name string and optional attributes. In most cases the name string defines the task subject or type, while attributes are used to distinguish between siblings, e.g. a task with name string config-file handles migration of a single server config file, and an attribute source is then used to identify which of the config files the task handles, e.g. its file name. The textual format of a task name is string_name(attribute1_name=attribute1_value, attribute2_name=attribute2_value, ...), such representation for the previous example could be config-file(source=standalone.xml).

Since a Migration Task may be executed multiple times, under different parent tasks, each execution has a path in the task execution tree, made of the names of the parent tasks, since root, and the task's own name, e.g. server>standalone>config-file(source=standalone.xml) is a path representation using '>' as each task name's separator.

Each Migration Task execution obvioulsy has a result, which status may be:

  • Success, the task executed successfully as expected
  • Skipped, the task skipped the execution, in most cases due to not be needed
  • Fail, the task execution failed due to a specific reason
    Beyond the status, some tasks may also attach attributes to its execution result, data which may be relevant, for instance to understand why its execution failed or was skipped.

Summary Report

The Summary Report is generated and printed in the migration console/logs, as it's name suggests it provides only a summary of the server migration execution, more specifically it lists the name and status of tasks which executed with success or failed status result. An example of such report:

The ident of each task name line defines the task/subtask relationship, in the example above migrate-subsystem(name=web) is a subtask of subsystems-management-resources.

Summary Report Environment Properties

Property Name Description Value Type Default Value
report.summary.maxTaskPathSizeToDisplaySubtasks Subtasks will be visible if the task has a path size smaller or equal Int 5

HTML Report

The HTML Report provides a high level and interactive interface to the migration data, it may be found in the output directory, by default its filename is migration-report.html

The report has three sections: Summary, Environment and Tasks.

The Summary section provides the migration's start time, information about the source and target servers, and the migration's result.

The Environment section lists all used environment properties.

Last but not least, the Tasks section provides statistics and a map of the executed Migration Tasks:

Each task is listed by it's name, which is coloured according to the task status result: green if Success, red if Failed, gray if Skipped.

The Migration Tasks map is interactive, it provides three controls, as highlighted below:

The minus, highlighted with a red circle, hides the task's subtasks:

The plus, highlighted with a green circle, show's the task's subtasks:

Clicking a task name, as the one highlighted with a orange rectangle, shows/hides the task details:

HTML Report Environment Properties

Property Name Description Value Type Default Value
report.html.fileName The name of file to write the HTML report. If not set the report will not be generated. String migration-report.html
report.html.maxTaskPathSizeToDisplaySubtasks Subtasks will be visible if the task has a path size smaller or equal Int 4
report.html.templateFileName The HTML report template file name. String migration-report-template.html

XML Report

The XML Report is a low level report that provides all migration data gathered by the tool, in a format which may be worked out by 3rd party tools. An example of such report:

The XML Report may be found in the output directory, by default its filename is migration-report.xml

XML Report Environment Properties

Property Name Description Value Type Default Value
report.xml.fileName The name of file to write the XML report. If not set the report will not be generated. String migration-report.xml

Supported Server Migrations

Unable to render {include} Couldn't find a page to include called: Supported Server Migrations (beta)
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.