4 Migrate an Instance to Oracle WebLogic Server for Oracle Cloud Infrastructure Using Classic Tools
Use the Oracle Cloud Infrastructure Classic Java Migration Tool to migrate your Oracle WebLogic Server domain resources and applications from your existing Oracle Java Cloud Service instance in Oracle Cloud Infrastructure Classic to a new domain in Oracle WebLogic Server for Oracle Cloud Infrastructure.
Note:
Oracle recommends migrating your existing domains in Oracle Java Cloud Service to Oracle WebLogic Server for Oracle Cloud Infrastructure.Before you begin the migration process, see Prepare to Migrate Oracle Java Cloud Service to Oracle Cloud Infrastructure.
When you migrate an Oracle Java Cloud Service instance, the following terms are used:
- Source: The Oracle Java Cloud Service instance in Oracle Cloud Infrastructure Classic.
- Target: The domain and related cloud resources in Oracle WebLogic Server for Oracle Cloud Infrastructure.
Topics:
- Get Information About the Target Environment
- Launch the Migration Controller Instance in the Source Environment
- Update the Secret File
- Update the Default Profile File
- Discover Resources in Your Source Environment
- List Your Oracle Java Cloud Service Instances
- Export Your Source Instance Configuration
- Perform Prerequisite Tasks for Oracle WebLogic Server for Oracle Cloud Infrastructure
- Create the Target Domain Using Oracle WebLogic Server for Oracle Cloud Infrastructure
- Migrate Oracle Fusion Middleware Security Resources
- Migrate Oracle Identity Cloud Service Roles and Policies
- Integrate Fusion Middleware Components with Oracle Identity Cloud Service
- Edit the Domain Configuration File
- Copy Supporting Files to the Target
- Update the Oracle WebLogic Server Domain on the Target Instance
Get Information About the Target Environment
Collect the information required for the migration tools to connect to the target Oracle Cloud Infrastructure environment.
The following table shows sample values for each input.
Name | Sample Value |
---|---|
Tenancy OCID |
|
User OCID |
|
User API Key Fingerprint |
|
Compartment OCID |
|
Region |
|
Availability Domain |
|
Subnet OCID |
|
Identity Domain ID |
|
Launch the Migration Controller Instance in the Source Environment
In your Oracle Cloud Infrastructure Compute Classic account, create the source controller (Control-S) instance, which includes Oracle Cloud Infrastructure Classic Java Migration Tool.
The Control-S compute instance must be created in the same identity domain and site as the source Oracle Java Cloud Service instance that you want to migrate.
The Control-S compute instance and associated storage volumes are by default billed at the applicable rates for your account. However, you can rename these resources so that the name includes /oraclemigration
as a container. Resources created in this /oraclemigration
container aren't billed to your account.
Update the Secret File
All of the tools required for the migration are already installed on the Control-S instance, but additional configuration is required to provide details about the source and target environments.
Update the Default Profile File
The Oracle Cloud Infrastructure Classic Java Migration Tool connects to your source environment using information that you provide in a profile file.
The information you provide in the profile file includes the user name or identity for each service in the source environment, as well as the service end point and region. If you want to run the tool in multiple regions or tenancies, you can create separate profile files for each region and tenancy.
You also provide connectivity details for each Oracle Java Cloud Service instance that you want to migrate. If you include the WebLogic Server administrator credentials for a service instance, Oracle Cloud Infrastructure Classic Java Migration Tool also migrates any Oracle Fusion Middleware security resources (custom users, groups, roles, policies, or credential maps) to the target domain.
Discover Resources in Your Source Environment
To discover all Oracle Cloud Infrastructure Classic resources in the services for which you've provided credentials, log in to the Control-S instance and run the following command.
opcmigrate discover
When prompted, enter the passwords for the user names that you specified in the default profile.
For example:
opcmigrate discover
Compute Classic Password [/Compute-ExampleDomain/user@example.com]:
INFO Authenticating with OCI Classic Compute API
INFO Compute Endpoint: https://compute.uscom-central-1.oraclecloud.com
INFO Discovering resources for "ExampleDomain".
WARNING Load Balancer Classic credentials not configured in profile
PaaS Services Password [user@example.com]:
WARNING Object Storage Classic credentials not configured in profile
INFO Discovering containers: ['/Compute-ExampleDomain']
INFO Getting Account Resources for /Compute-ExampleDomain
INFO Getting Network Resources for /Compute-ExampleDomain
INFO Getting Network Resources for /oracle/public
INFO Getting Instance Resources for /Compute-ExampleDomain
INFO Getting Instance Resources for /oracle/public
INFO Getting Instances for /Compute-ExampleDomain
INFO Getting PaaS Resources for uscom-central-1
INFO Storing discovered resources to 'resources-default.json'
List Your Oracle Java Cloud Service Instances
To list the Oracle Java Cloud Service instances in the source environment, log in to the Control-S instance and run the following command.
opcmigrate migrate jcs list
This command uses the output generated by the discover
command to identify and list the available Oracle Java Cloud
Service instances.
For example:
opcmigrate migrate jcs list
INFO Loaded resources from 'resources-default.json' ...
Java Cloud Service Instances
Name Version State Description
-------------------- -------------------- -------------------- ------------------------------------------------------------
MyJavaInstance 11gR1 READY My first instance
AnotherInstance 12cR3 READY My second instance
Export Your Source Instance Configuration
To create an archive of the source Oracle Java Cloud Service instance using the WebLogic Server Deploy Tooling, log in to the Control-S instance and run the following command.
opcmigrate migrate jcs export -s <instance_name>
This command creates the following files:
<instance_name>-<date>-<timestamp>.tgz
: An archive of the source instance, which includes the applications that are on the source instance as well as the domain configuration metadata. This archive is uploaded to Oracle Cloud Infrastructure Object Storage.<instance_name>-<date>-<timestamp>.json
: You edit this file to specify the required passwords for the target domain, as well as to specify any configuration parameters that will be different on the target instance.
For example:
opcmigrate migrate jcs export -s MyJavaInstance
INFO Loaded resources from 'resources-default.json' ...
INFO Exporting JCS service 'MyJavaInstance'
INFO Installing Oracle WebLogic Server Deploy Tooling on 203.0.113.13
INFO Create temporary directory on controller
INFO Download WebLogic Deploy Tooling to controller
INFO Upload and Extract WebLogic Deploy Tooling archive to remote host
INFO Remove temporary directory from controller
INFO Exporting WebLogic Domain at 203.0.113.13
INFO Create temporary directory on remote host
INFO Run WebLogic Deploy Tooling discoverDomain.sh command
INFO Download discovered domain files to controller
INFO Remove temp directory from remote
INFO Generating WebLogic config template 'MyJavaInstance-20190722-18:50:35.json'
INFO Creating instance archive 'MyJavaInstance-20190722-18:50:35.tgz'
INFO Uploading artifacts to object storage
INFO JCS service 'MyJavaInstance' export complete
By default, this command uses the resources-default.json
file in the local directory. You can use the --file
option to specify a resources file with a different name or in a different directory.
Perform Prerequisite Tasks for Oracle WebLogic Server for Oracle Cloud Infrastructure
Before you create a WebLogic Server domain using Oracle WebLogic Server for Oracle Cloud Infrastructure, you must create the required infrastructure and database resources.
See Before You Begin with Oracle WebLogic Server for Oracle Cloud Infrastructure in Using Oracle WebLogic Server for Oracle Cloud Infrastructure.
Create the Target Domain Using Oracle WebLogic Server for Oracle Cloud Infrastructure
Launch the Oracle WebLogic Server for Oracle Cloud Infrastructure application in the Oracle Cloud Infrastructure Marketplace to create a new domain. This domain must have the same topology and configuration as the source Oracle Java Cloud Service instance.
Note:
The migration import tooling uses the SSH keys specified for the source instance in your ~/.opc/profiles/default
file (or ~/.opc/profiles/<profile>
file) on the Control-S instance. Be sure to use the same SSH key pair to create your target domain with Oracle WebLogic Server
for Oracle Cloud Infrastructure.
Before creating a domain, copy the OCIDs for the secrets that contain your Oracle WebLogic Server administrator password and your database password. Use the same credentials as your source instance.
See Create a JRF-Enabled Domain in Using Oracle WebLogic Server for Oracle Cloud Infrastructure.
Migrate Oracle Fusion Middleware Security Resources
If you customized the Oracle WebLogic Server security providers in your source Oracle Java Cloud Service instance, then you must apply the same changes in the target domain.
If you specified the WebLogic Server administrator credentials for your source instance in the default profile, the Oracle Cloud Infrastructure Classic Java Migration Tool automatically migrates the following Oracle Fusion Middleware security resources from the source domain to the target domain:
- Users
- Groups
- Roles
- Policies
- Keystores
- Credential maps
- Audit policies
- Web Services Manager (WSM) policies
The tool does not automatically update the security providers in the target domain.
Migrate Oracle Identity Cloud Service Roles and Policies
If your source Oracle Java Cloud Service instance uses Oracle Identity Cloud Service for authentication, then you must migrate the administrator roles and web tier policy to the target domain.
The source and target are each associated with a security application in Oracle Identity Cloud Service. The security application grants administrative rights for the WebLogic Server domain to specific users and groups in Oracle Identity Cloud Service.
Integrate Fusion Middleware Components with Oracle Identity Cloud Service
If your source Oracle Java Cloud Service instance uses Oracle Identity Cloud Service for authentication, then you can integrate certain Oracle Fusion Middleware components in the target domain with Oracle Identity Cloud Service.
If your source instance uses Oracle Web Services Manager to protect web service applications and clients, then see Secure Web Services Using Identity Cloud Service in Using Oracle WebLogic Server for Oracle Cloud Infrastructure.
If applications on your source instance use Oracle Platform Security Services APIs to look up user and group information, then see Integrate OPSS User and Group APIs with Identity Cloud Service in Using Oracle WebLogic Server for Oracle Cloud Infrastructure.
Edit the Domain Configuration File
The export
command creates a file that contains parameters for updating the target WebLogic Server domain. Specify JDBC URLs and passwords, SSL keystore passwords, and other details for the target instance.
For security purposes, Oracle WebLogic Server Deploy Tooling excludes the values of all passwords during domain discovery.
Copy Supporting Files to the Target
Identify and copy any files to your target domain that are not managed by Oracle WebLogic Server Deploy Tooling.
Oracle WebLogic Server Deploy Tooling automatically finds and archives the following types of files in your source instance's domain configuration. It also adds these files to your target domain configuration:
- Application deployments
- Library deployments
- Custom keystores
Other files that your applications or domain resources require are not automatically managed by Oracle WebLogic Server Deploy Tooling, including files that are located outside the DOMAIN_HOME
directory. You must manually copy these files to the target nodes.