How to Change the Oracle OEM Domain in a URL
Oracle Enterprise Manager (OEM) is a robust tool used for monitoring and managing Oracle environments. Occasionally, you may need to update the domain name in the OEM URL, such as when transitioning to a new network, updating a Fully Qualified Domain Name (FQDN), or integrating with new DNS settings. This blog outlines the step-by-step process to change the domain name in the OEM URL.
Why Change the OEM Domain?
There are several reasons you might need to update the domain in the OEM URL:
Network migration: Moving OEM to a new network.
Domain standardization: Aligning with organizational naming conventions.
SSL updates: Adopting a new domain for secure connections.
For example, changing the URL from
https://oem.old-domain.com:7801/em
to
https://oem.new-domain.com:7801/em
.
Steps to Change the Domain
Step 1: Update Hostname in Configuration Files
Locate the OEM Configuration Directory: Navigate to the configuration directory in your Oracle Management Service (OMS) installation:
cd $OMS_HOME/sysman/config
Modify the
emoms.properties
File: Open theemoms.properties
file:vi emoms.properties
Update the URL to reflect the new domain:
oracle.sysman.eml.mntr.emdURL=https://<new-domain>:<port>/emd/main
Save and exit the file.
Check the
emomslogging.properties
File: Review this file for any references to the old domain and update them if needed.Backup Configuration Files: Before proceeding further, ensure that you back up all configuration files in the directory:
cp *.properties /backup/location/
Step 2: Update the WebLogic Server Configuration
Access the WebLogic Admin Console: Navigate to the WebLogic Admin Console at:
http://<current-domain>:7001/console
Log in using your WebLogic admin credentials.
Update the Server URL:
Go to Servers >
AdminServer
> Protocols > HTTP.Update the
Listen Address
to the new FQDN.Save and apply the changes.
Restart WebLogic Services: Stop and restart the WebLogic Admin and Managed Servers:
$DOMAIN_HOME/bin/stopWebLogic.sh $DOMAIN_HOME/bin/startWebLogic.sh
Verify Changes in WebLogic Logs: Monitor the WebLogic logs to ensure there are no errors during the restart:
tail -f $DOMAIN_HOME/servers/AdminServer/logs/AdminServer.log
Step 3: Update the Repository Information
Stop OMS:
$OMS_HOME/bin/emctl stop oms
Update the OMS Configuration: Run the following command to update the domain name in the repository:
$OMS_HOME/bin/emctl config oms -repos_pwd <repository_password>
Restart OMS:
$OMS_HOME/bin/emctl start oms
Synchronize Agents: Ensure that all OEM agents are synchronized with the new domain by reconfiguring them:
<AGENT_HOME>/bin/emctl stop agent <AGENT_HOME>/bin/emctl clearstate <AGENT_HOME>/bin/emctl start agent
Step 4: Validate the New URL
Access the New OEM URL: Open a browser and visit:
https://<new-domain>:<port>/em
Ensure the page loads correctly.
Test Agent Connectivity: Verify that all agents can communicate with the new OMS URL:
<AGENT_HOME>/bin/emctl status agent <AGENT_HOME>/bin/emctl upload
Validate Reporting: Test report generation and dashboard views to ensure the changes did not disrupt critical OEM functionality.
Step 5: Update DNS and SSL Certificates (if Applicable)
Update DNS Records: Ensure the new domain is mapped to the OEM server's IP address in the DNS system.
Regenerate SSL Certificates: If SSL is enabled, regenerate certificates with the new domain name using Oracle Wallet Manager or a tool like OpenSSL. Replace the old certificates on the server.
Restart HTTPS Services: After updating SSL certificates, restart HTTPS services to apply changes:
$OMS_HOME/bin/emctl secure oms -remove $OMS_HOME/bin/emctl secure oms -enable
Verification
Monitor Logs for Errors: Check the OEM logs for any errors during or after the update:
tail -f $OMS_HOME/sysman/log/emctl.log
Validate with RMAN: Run an RMAN validation to ensure no issues in agent communication:
RMAN> BACKUP VALIDATE CHECK LOGICAL DATABASE;
Perform a Full System Health Check:
Run a database diagnostic check using OEM.
Confirm all critical alerts and notifications are working as expected.
Best Practices to Prevent Future Issues
Backup Configuration Files Regularly: Always take a backup before making any configuration changes.
Monitor Undo Tablespace and Redo Logs: Maintain sufficient space to avoid database corruption during recovery.
Apply Oracle Patches: Keep your Oracle environment updated with the latest patches.
Document Changes: Maintain detailed documentation of all changes made to facilitate troubleshooting and audits.
By following these steps, you can seamlessly change the domain name in the Oracle OEM URL while ensuring minimal disruption to monitoring and management activities.
No comments:
Post a Comment