Instalação do Oracle VM Manager
By franky
Olá pessoal, aqui vamos demonstrar como instalar e configurar o Oracle VM Manager num servidor fora do Oracle VM Server que foi instalado no último post. O Oracle VM Manager é, como o próprio nome já diz, um gerenciador para toda a nossa infraestrutura virtualizada. A instalação é bastante simples, mas o ambiente parece ser um pouco complexo em sua composição:
- MySQL Database Server
- Java
- Oracle WebLogic Server
- Oracle ADF
- Oracle VM Manager application
- Oracle WebLogic Server domain
Configurações do servidor:
- Sistema Operacional: Oracle Linux Server 7.5 - Armazenamento: SSD 240GB - Memória Física: 16GB - Quantidade de Cores: 4 físicos (8 lógicos)
O primeiro passo é efetuar o download da mídia a partir do Patch 22902502 no MOS.
Feito isso vamos descompactar o arquivo p22902502_345_Linux-x86-64.zip no diretório desejado
[root@vision ~]# unzip /home/loredata/Downloads/VMManager/p22902502_345_Linux-x86-64.zip -d /home/loredata/Downloads/VMManager/ Archive: /home/loredata/Downloads/VMManager/p22902502_345_Linux-x86-64.zip inflating: /home/loredata/Downloads/VMManager/ovmm-3.4.5-installer-OracleLinux-b1919.iso inflating: /home/loredata/Downloads/VMManager/README.html
Em seguida montamos a imagem ISO ovmm-3.4.5-installer-OracleLinux-b1919.iso que foi descompactada:
[root@vision ~]# mount /home/loredata/Downloads/VMManager/ovmm-3.4.5-installer-OracleLinux-b1919.iso /mnt mount: /dev/loop0 is write-protected, mounting read-only
Conferimos os arquivos dentro da ISO:
[root@vision ~]# cd /mnt [root@vision mnt]# ls -lh total 151M -rw-r--r--. 1 root root 4.1M May 30 19:33 OvmSDK_3.4.5.1919.zip -r--r--r--. 1 root root 1.6K May 30 19:37 TRANS.TBL drwxr-xr-x. 7 root root 8.0K May 30 19:37 components -r-xr-x---. 1 root root 12K May 30 19:36 createOracle.sh -rw-r--r--. 1 root root 230 May 30 19:36 oracle-validated.params -r-xr-x---. 1 root root 147M May 30 19:37 ovmm-installer.bsx -r-xr-x---. 1 root root 1.9K May 30 19:37 runInstaller.sh -rw-r--r--. 1 root root 372 May 30 19:37 sample.yml
Ainda com o usuário root executamos o script createOracle.sh. Este script criará o usuário oracle e o grupo dba, a partição /u01 e também ajustará o parâmetros de memória no arquivo /etc/security/limits.conf e também ajustará as portas que devem ser abertas no arquivo /etc/sysconfig/iptables.
Antes de executar vamos confirmar que o serviço do iptables está ativo:
[root@vision mnt]# systemctl status iptables Unit iptables.service could not be found.
Veja que o serviço iptables não existe.
Vamos confirmar se o Firewall está ativo:
[root@vision mnt]# systemctl status firewalld ● firewalld.service - firewalld - dynamic firewall daemon Loaded: loaded (/usr/lib/systemd/system/firewalld.service; enabled; vendor preset: enabled) Active: active (running) since Tue 2018-10-09 19:10:50 -03; 31min ago Docs: man:firewalld(1) Main PID: 803 (firewalld) CGroup: /system.slice/firewalld.service └─803 /usr/bin/python -Es /usr/sbin/firewalld --nofork --nopid Oct 09 19:10:50 vision.loredata.com.br systemd[1]: Starting firewalld - dynamic firewall daemon... Oct 09 19:10:50 vision.loredata.com.br systemd[1]: Started firewalld - dynamic firewall daemon.
OK, vamos executar o script createOracle.sh:
[root@vision mnt]# ./createOracle.sh Missing required package, Oracle VM Manager requires 'iptables-services' to be installed, you can use 'yum install iptables-services' to install it.
Veja que é pré-requisito que o iptables esteja instalado. Então vamos instalá-lo:
[root@vision mnt]# yum install iptables-services Failed to set locale, defaulting to C Loaded plugins: langpacks, ulninfo ol7_UEKR4 | 1.2 kB 00:00:00 ol7_latest | 1.4 kB 00:00:00 Resolving Dependencies --> Running transaction check ---> Package iptables-services.x86_64 0:1.4.21-24.1.el7_5 will be installed --> Processing Dependency: iptables = 1.4.21-24.1.el7_5 for package: iptables-services-1.4.21-24.1.el7_5.x86_64 --> Running transaction check ---> Package iptables.x86_64 0:1.4.21-24.el7 will be updated ---> Package iptables.x86_64 0:1.4.21-24.1.el7_5 will be an update --> Finished Dependency Resolution Dependencies Resolved ========================================================================================================================================================================================= Package Arch Version Repository Size ========================================================================================================================================================================================= Installing: iptables-services x86_64 1.4.21-24.1.el7_5 ol7_latest 51 k Updating for dependencies: iptables x86_64 1.4.21-24.1.el7_5 ol7_latest 431 k Transaction Summary ========================================================================================================================================================================================= Install 1 Package Upgrade ( 1 Dependent package) Total size: 482 k Total download size: 51 k Is this ok [y/d/N]: y Downloading packages: iptables-services-1.4.21-24.1.el7_5.x86_64.rpm | 51 kB 00:00:00 Running transaction check Running transaction test Transaction test succeeded Running transaction Updating : iptables-1.4.21-24.1.el7_5.x86_64 1/3 Installing : iptables-services-1.4.21-24.1.el7_5.x86_64 2/3 Cleanup : iptables-1.4.21-24.el7.x86_64 3/3 Verifying : iptables-services-1.4.21-24.1.el7_5.x86_64 1/3 Verifying : iptables-1.4.21-24.1.el7_5.x86_64 2/3 Verifying : iptables-1.4.21-24.el7.x86_64 3/3 Installed: iptables-services.x86_64 0:1.4.21-24.1.el7_5 Dependency Updated: iptables.x86_64 0:1.4.21-24.1.el7_5 Complete!
Executamos novamente o script createOracle.sh:
[root@vision mnt]# ./createOracle.sh Removed symlink /etc/systemd/system/multi-user.target.wants/firewalld.service. Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service. Created symlink from /etc/systemd/system/basic.target.wants/iptables.service to /usr/lib/systemd/system/iptables.service. Adding group 'oinstall' with gid '54321' ... Adding group 'dba' Adding user 'oracle' with user id '54321', initial login group 'dba', supplementary group 'oinstall' and home directory '/home/oracle' ... Changing ownership of '/home/oracle' to oracle:dba Creating user 'oracle' succeeded ... For security reasons, no default password was set for user 'oracle'. If you wish to login as the 'oracle' user, you will need to set a password for this account. Verifying user 'oracle' OS prerequisites for Oracle VM Manager ... oracle soft nofile 8192 oracle hard nofile 65536 oracle soft nproc 2048 oracle hard nproc 16384 oracle soft stack 10240 oracle hard stack 32768 oracle soft core unlimited oracle hard core unlimited Setting user 'oracle' OS limits for Oracle VM Manager ... Altered file /etc/security/limits.conf Original file backed up at /etc/security/limits.conf.orabackup Verifying & setting of user limits succeeded ... Creating mountpoint '/u01' ... Modifying iptables for OVM Adding rules to enable access to: 7002 : Oracle VM Manager https 123 : NTP 10000 : Oracle VM Manager CLI Tool Redirecting to /bin/systemctl status iptables.service Redirecting to /bin/systemctl status iptables.service Redirecting to /bin/systemctl restart iptables.service iptables: Saving firewall rules to /etc/sysconfig/iptables:[ OK ] Redirecting to /bin/systemctl restart iptables.service Rules added.
Podemos observar que o script fez várias alterações no nosso ambiente, então precisamos ter certeza de como isso afetará o servidor e demais serviços dependentes desse servidor onde estamos instalando o OVM Manager.
Uma coisa que o script não faz é ajustar o /etc/hosts, então precisamos fazer isso manualmente:
[root@vision ~]# vi /etc/hosts 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 192.168.118.103 vision.loredata.com.br vision
Um último ponto antes de iniciarmos a instalação… Este é um Oracle Linux 7.5, então ele vem com alguns pacotes do Maria DB instalados (irônico né? ), é necessário remover estes pacotes antes de seguir com a instalação do OVM Manager:
[root@vision mnt]# yum remove mariadb-libs Failed to set locale, defaulting to C Loaded plugins: langpacks, ulninfo Resolving Dependencies --> Running transaction check ---> Package mariadb-libs.x86_64 1:5.5.56-2.el7 will be erased --> Processing Dependency: libmysqlclient.so.18()(64bit) for package: 2:postfix-2.10.1-6.0.1.el7.x86_64 --> Processing Dependency: libmysqlclient.so.18(libmysqlclient_18)(64bit) for package: 2:postfix-2.10.1-6.0.1.el7.x86_64 --> Running transaction check ---> Package postfix.x86_64 2:2.10.1-6.0.1.el7 will be erased --> Finished Dependency Resolution Dependencies Resolved ========================================================================================================================================================================================= Package Arch Version Repository Size ========================================================================================================================================================================================= Removing: mariadb-libs x86_64 1:5.5.56-2.el7 @anaconda/7.5 4.4 M Removing for dependencies: postfix x86_64 2:2.10.1-6.0.1.el7 @anaconda/7.5 12 M Transaction Summary ========================================================================================================================================================================================= Remove 1 Package (+1 Dependent package) Installed size: 17 M Is this ok [y/N]: y Downloading packages: Running transaction check Running transaction test Transaction test succeeded Running transaction Erasing : 2:postfix-2.10.1-6.0.1.el7.x86_64 1/2 Erasing : 1:mariadb-libs-5.5.56-2.el7.x86_64 2/2 Verifying : 1:mariadb-libs-5.5.56-2.el7.x86_64 1/2 Verifying : 2:postfix-2.10.1-6.0.1.el7.x86_64 2/2 Removed: mariadb-libs.x86_64 1:5.5.56-2.el7 Dependency Removed: postfix.x86_64 2:2.10.1-6.0.1.el7 Complete!
Partimos agora para a instalação do Software do Oracle VM Manager em si. Durante o processo de instalação um prompt vai aguardar a entrada de algumas informações para proceeder com a instalação. Para instalar o OVM Manager isso executamos com o usuário root o script runInstaller.sh e provemos as entradas necessárias nos prompts:
[root@vision mnt]# ./runInstaller.sh Oracle VM Manager Release 3.4.5 Installer Oracle VM Manager Installer log file: /var/log/ovmm/ovm-manager-3-install-2018-10-09-200245.log Please select an installation type: 1: Install 2: Upgrade 3: Uninstall 4: Help Select Number (1-4): 1 Verifying installation prerequisites ... Starting production with local database installation ... One password is used for all users created and used during the installation. Enter a password for all logins used during the installation: Invalid password. Passwords need to be between 8 and 16 characters in length. Passwords must contain at least 1 lower case and 1 upper case letter. Passwords must contain at least 1 numeric value. Enter a password for all logins used during the installation: Enter a password for all logins used during the installation (confirm): Please enter your fully qualified domain name, e.g. ovs123.us.oracle.com, (or IP address) of your management server for SSL certification generation, more than one IP address are detected: 192.168.118.103 192.168.122.1 [vision.loredata.com.br]: vision.loredata.com.br Verifying configuration ... Start installing Oracle VM Manager: 1: Continue 2: Abort Select Number (1-2): 1 Step 1 of 7 : Database Software ... Installing Database Software... Retrieving MySQL Database 5.6 ... Unzipping MySQL RPM File ... Installing MySQL 5.6 RPM package ... Configuring MySQL Database 5.6 ... Installing MySQL backup RPM package ... Step 2 of 7 : Java ... Installing Java ... Step 3 of 7 : WebLogic and ADF ... Retrieving Oracle WebLogic Server 12c and ADF ... Installing Oracle WebLogic Server 12c and ADF ... Applying patches to Weblogic ... Applying patch to ADF ... Step 4 of 7 : Oracle VM ... Installing Oracle VM Manager Core ... Retrieving Oracle VM Manager Application ... Extracting Oracle VM Manager Application ... Retrieving Oracle VM Manager Upgrade tool ... Extracting Oracle VM Manager Upgrade tool ... Installing Oracle VM Manager Upgrade tool ... Retrieving Oracle VM Manager CLI tool ... Extracting Oracle VM Manager CLI tool... Installing Oracle VM Manager CLI tool ... Installing Oracle VM Manager WLST Scripts ... Step 5 of 7 : Domain creation ... Creating domain ... Step 6 of 7 : Oracle VM Tools ... Retrieving Oracle VM Manager Shell & API ... Extracting Oracle VM Manager Shell & API ... Installing Oracle VM Manager Shell & API ... Retrieving Oracle VM Manager Wsh tool ... Extracting Oracle VM Manager Wsh tool ... Installing Oracle VM Manager Wsh tool ... Retrieving Oracle VM Manager Tools ... Extracting Oracle VM Manager Tools ... Installing Oracle VM Manager Tools ... Retrieving ovmcore-console ... Installing ovmcore-console RPM package ... Copying Oracle VM Manager shell to '/usr/bin/ovm_shell.sh' ... Installing ovm_admin.sh in '/u01/app/oracle/ovm-manager-3/bin' ... Installing ovm_upgrade.sh in '/u01/app/oracle/ovm-manager-3/bin' ... Step 7 of 7 : Start OVM Manager ... Enabling Oracle VM Manager service ... Shutting down Oracle VM Manager instance ... Starting Oracle VM Manager instance ... Please wait while WebLogic configures the applications... Trying to connect to core via ovmwsh (attempt 1 of 20) ... Trying to connect to core via ovm_shell (attempt 1 of 5)... Oracle VM Manager installed. Installation Summary -------------------- Database configuration: Database type : MySQL Database host name : localhost Database name : ovs Database listener port : 49500 Database user : ovs Weblogic Server configuration: Administration username : weblogic Oracle VM Manager configuration: Username : admin Core management port : 54321 UUID : 0004fb00000100001aeeb16123751a51 Passwords: There are no default passwords for any users. The passwords to use for Oracle VM Manager, Database, and Oracle WebLogic Server have been set by you during this installation. In the case of a default install, all passwords are the same. Oracle VM Manager UI: https://vision.loredata.com.br:7002/ovm/console Log in with the user 'admin', and the password you set during the installation. For more information about Oracle Virtualization, please visit: http://www.oracle.com/virtualization/ As of Oracle VM Release 3.4.5, the TLSv1.2 protocol is used for all connections and management of 3.2.10/11 servers is not possible by default. TLSv1 protocol must be enabled, which is less secure. For instructions, see the Oracle VM 3.4 Installation and Upgrade guide. Oracle VM Manager installation complete. Please remove configuration file /tmp/ovm_configgnwe_q.
Instalação finalizada com sucesso!
Além das portas, links e usuários mencionados ao final da instalação também temos as seguintes informações importantes sobre esse ambiente:
Para gerenciar os serviços que compõem o OVM Manager usamos o utilitário service (ou systemctl) do Linux.
Para verificar se o OVM Manager está rodando:
[root@vision ~]# service ovmm status Oracle VM Manager is running...
Para parar o OVM Manager:
[root@vision ~]# service ovmm stop Stopping ovmm (via systemctl): [ OK ]
E para iniciar o OVM Manager:
[root@vision ~]# service ovmm start Starting ovmm (via systemctl): [ OK ]
Para acessar a página de administração é só abrir no browser o link informado ao final da instalação e entrar com o usuário admin e credenciais também informadas durante a instalação:
Neste artigo vimos como configurar o Linux e como instalar o software Oracle VM Manager para gerenciar nossas máquinas virtuais.
Por hoje é só pessoal e espero que tenham gostado.
No próximo artigo vamos ver como registrar o Oracle VM Server via console.
Abraços,
Franky
O post Instalação do Oracle VM Manager apareceu primeiro em Lore Data.
Fonte: Franky Weber – Lore Data