April 19, 2021

Mac? X11? Oracle Cloud Infrastructure? - How To Get runInstaller To run ...

Summary

Long story told short: Got two OCI machines and tried to install some Oracle stuff - Enterprise Manager, Database Software, Weblogic Server and such 'things'. Problem: How to install that without having a possibility to run a GUI? Well - I'm used to install oracle products using the 'silent' way. Nevertheless - How the heck can I get a GUI to run on a Mac? Here's the How To.

Environment

MacBook Pro (Mid 2014 - yes it's old, but I'm still waiting for the all new MacBook M1X, latest generation, 32GB RAM at least. Possibly, tomorrow I know more :-))

OCI - two machines running Linux, 32GB RAM, nothing special

To Do's

  • Get XQUARTZ from the manufacturers website and install it on Your Mac
  • connect to Your OCI machine(s) as user opc and login as root (sudo su -)
  • check / change / edit '/etc/ssh/sshd_config:
    X11Forwarding yes
    X11UseLocalhost no

  • restart sshd
    systemctl restart sshd

  • install two more packages - xterm (nice to have to check x11) and xauth. Simply run the two statements. In case xterm and/or xauth are installed already, nothing happens.
    yum -y install xterm
    yum -y install xauth


Let's try ...

  • start XQUARTZ
  • connect as opc to Your OCI machine (doesn't matter if You use mac's terminal.app or an XQUARTZ window:
    ssh -CX opc@<OCI machine>
  • In case You're connecting using a ssh key:
    ssh -CX -i <Path to the public key> opc@<OCI machine>
  • run these two commands (You'll need the output right after the login as oracle):
    echo "xauth add $(xauth list | grep `echo $DISPLAY | awk '{ print substr($0,index($0,":"),3) }'` | grep `hostname`)"
    echo export DISPLAY=$DISPLAY
  • connect as user oracle
    sudo su - oracle
  • execute the result of the two commands (xauth and echo) - which is something like this:
    xauth add <oci machine hostname, full qualified>:<Display #>  MIT-MAGIC-COOKIE-1  <some kind of key>
    export DISPLAY=<IP>:<Display #>
  • run Your GUI stuff :-)




Share:

April 11, 2021

Upgrading Enterprise Manager 13.4 to 13.5 - The Silent Way


Just a short description of what I did to upgrade an existing Enterprise Manager 13.4 (RU9) to the latest release 13.5 ...

Environment:

OCI machine, Oracle Linux 7.9, Enterprise Manager 13.4 RU9
OCI machine, Oracle Linux 7.9, Repository Database Release 19.3


Software-Download

EM 13.5 - downloaded from edelivery.oracle.com


Preparation

Creating the new em13500 base directory, the MiddlewareHome and the Instance Home. 

mkdir $ORACLE_BASE/product/em13500
mkdir $ORACLE_BASE/product/em13500/em13500
mkdir $ORACLE_BASE/product/em13500/gc_inst

I prefer to have one separate EM Release Base Directory for each release, instead of creating everything in $ORACLE_BASE/product.


Extracting the response files from the installation media

./em13500_linux64.bin -getResponseFileTemplates -outputLoc /u01/software/em_install


Preparing some init parameters in the repository database (restart after)

alter system reset "_optimizer_nlj_hj_adaptive_join" scope=both sid='*'; 
alter system reset "_optimizer_strans_adaptive_pruning" scope=both sid='*';
alter system reset "_px_adaptive_dist_method" scope=both sid='*';
alter system reset "_sql_plan_directive_mgmt_control" scope=both sid='*';
alter system reset "_optimizer_dsdir_usage_control" scope=both sid='*';
alter system reset "_optimizer_use_feedback" scope=both sid='*';
alter system reset "_optimizer_gather_feedback" scope=both sid='*';
alter system reset "_optimizer_performance_feedback" scope=both sid='*';


Adopting upgrade.rsp to the environment

RESPONSEFILE_VERSION=2.2.1.0.0
UNIX_GROUP_NAME="dba"
INVENTORY_LOCATION=/u01/app/oraInventory
INSTALL_UPDATES_SELECTION=skip
ORACLE_MIDDLEWARE_HOME_LOCATION=/u01/app/oracle/product/em13500/em13500
ORACLE_INSTANCE_HOME_LOCATION=/u01/app/oracle/product/em13500/gc_inst
OLD_BASE_DIR=/u01/app/oracle/product/em13400/em13400
ORACLE_HOSTNAME=oem1.demo.ch
ONE_SYSTEM=true
WLS_ADMIN_SERVER_USERNAME=weblogic
WLS_ADMIN_SERVER_PASSWORD=manager
WLS_ADMIN_SERVER_CONFIRM_PASSWORD=manager
NODE_MANAGER_PASSWORD=manager
NODE_MANAGER_CONFIRM_PASSWORD=manager
WLS_ADMIN_SERVER_PASSWORD=manager
DATABASE_HOSTNAME=oem2.demo.ch
LISTENER_PORT=1521
SERVICENAME_OR_SID=poem1.demo.ch
SYS_PASSWORD=manager
SYSMAN_PASSWORD=manager
EMPREREQ_AUTO_CORRECTION=false
REPOSITORY_BACKUP_DONE=true
PLUGIN_SELECTION={}
b_upgrade=true
EM_INSTALL_TYPE=NOSEED


Stopping the central agent

emctl stop agent

Stopping Enterprise Manager - and only the Enterprise Manager. You'll need a running AdminServer (an an open repository database)

emctl stop oms


Starting the installer

    em13500_linux64.bin -silent -responseFile /u01/software/em_install/upgrade.rsp


    Waiting, waiting, waiting ... about 30 minutes in my environment. But this can take much longer in real life environments.

    To be honest: Because of the missing upgrade instructions, it took two tries to install. In both cases, the installer created a really helpful log file in html format, and left the original installation unchanged.


    Finally


    Important

    An Enterprise Manager Upgrade is - as always - an out-of-place upgrade. Keep in mind that any connection descriptions to LDAP as well as Your certificates are not (!) upgraded / moved to the new installation. So, if You're using LDAP for authentication or having Your own certificates in place: Save the information / the certificate and apply it after the upgrade to the new EM.
    Share:

    Copyright © Robert Crames' Oracle Database and Middleware Blog | Powered by Blogger
    Design by SimpleWpThemes | Blogger Theme by NewBloggerThemes.com