Instalação 4.0

[root@vm-mba-01 ~]# lscpu 
Architecture:          x86_64
CPU op-mode(s):        32-bit, 64-bit
Byte Order:            Little Endian
CPU(s):                16
On-line CPU(s) list:   0-15
Thread(s) per core:    2
Core(s) per socket:    4
Socket(s):             2
NUMA node(s):          2
Vendor ID:             GenuineIntel
CPU family:            6
Model:                 26
Model name:            Intel(R) Xeon(R) CPU           E5520  @ 2.27GHz
Stepping:              5
CPU MHz:               1600.000
BogoMIPS:              4532.67
Virtualization:        VT-x      <= Suporte a virtualização
L1d cache:             32K
L1i cache:             32K
L2 cache:              256K
L3 cache:              8192K
NUMA node0 CPU(s):     0-3,8-11
NUMA node1 CPU(s):     4-7,12-15
[root@vm-mba-01 ~]# cat /proc/cpuinfo | egrep 'vmx|svm'
[root@vm-mba-01 ~]# hostname -s
vm-mba-01
[root@vm-mba-01 ~]# hostname -f
vm-mba-01.juntotelecom.com.br
[root@vm-mba-01 ~]# hostname -d
juntotelecom.com.br
[root@vm-mba-01 ~]# yum install targetcli
[root@vm-mba-01 ~]# targetcli 
/> backstores/fileio create ovirt /var/lib/iscsi/ovirt.img 60g
/> backstores/fileio create vms /var/lib/iscsi/vms.img 340g          
/> iscsi/ create iqn.2017-03.com.juntotelecom:tgt
/> iscsi/iqn.2017-03.com.juntotelecom:tgt/tpg1/luns create /backstores/fileio/ovirt 
/> iscsi/iqn.2017-03.com.juntotelecom:tgt/tpg1/luns create /backstores/fileio/vms 
/> iscsi/iqn.2017-03.com.juntotelecom:tgt/tpg1/ set attribute authentication=0
/> iscsi/iqn.2017-03.com.juntotelecom:tgt/tpg1/ set attribute generate_node_acls=1
/> iscsi/iqn.2017-03.com.juntotelecom:tgt/tpg1/ set attribute demo_mode_write_protect=0
/> saveconfig 
/> exit
[root@vm-mba-01 ~]# systemctl start target.service 
[root@vm-mba-01 ~]# systemctl enable target.service
[root@vm-mba-01 ~]# iscsiadm --mode discovery --type sendtargets --portal 127.0.0.1
[root@vm-mba-01 ~]# wget http://mirror.facom.ufms.br/centos/7/isos/x86_64/CentOS-7-x86_64-Minimal-1611.iso -P /var/tmp/
[root@vm-mba-01 ~]# yum -y install http://resources.ovirt.org/pub/yum-repo/ovirt-release40.rpm
[root@vm-mba-01 ~]# yum install ovirt-hosted-engine-setup
[root@vm-mba-01 ~]# yum install screen
[root@vm-mba-01 ~]# screen -RD
[root@vm-mba-01 ~]# hosted-engine --deploy
[ INFO  ] Etapa: Inicializando
[ INFO  ] Gerando uma senha VNC temporária
[ INFO  ] Etapa: Configuração de ambiente
          Durante a personalização use CTRL-D para abortar.
          Continuando irá configurar este host para servir como hypervisor e criar uma máquina virtual onde você tem que instalar o engine depois.
          Você tem certeza que quer continuar? (Sim, Não)[Sim]: <= ENTER
[ INFO  ] Hardware suporta virtualização
          Configuration files: []
          Arquivo de log: /var/log/ovirt-hosted-engine-setup/ovirt-hosted-engine-setup-20170328151951-1zqxmy.log
          Versão: otopi-1.5.2 (otopi-1.5.2-1.el7.centos)
[ INFO  ] Etapa: Configuração dos pacotes de ambiente
[ INFO  ] Etapa: Detecção de programas
[ INFO  ] Etapa: Configuração de ambiente
[ INFO  ] Gerando certificado libvirt-spice
[WARNING] Não posso localizar os pacotes gluster, a configuração para o suporte do Hyper Converged será desabilitada.
[ INFO  ] Por favor aborte a instalação e instale o vdsm-gluster, gluster-server >= 3.7.2 e reinicie o serviço vdsmd, a fim de obter o suporte para configuração do Hyper Converged.
[ INFO  ] Etapa: Personalização do ambiente
--== CONFIGURAÇÃO DO ARMAZENAMENTO ==--
 
          Por favor especifique o armazenamento que você gostaria de usar (glusterfs, iscsi, fc, nfs3, nfs4)[nfs3]: iscsi
          Por favor especifique o endereço IP do portal iSCSI: 127.0.0.1 <= ENDEREÇO DO PORTAL
          Por favor especifique a porta do portal iSCSI [3260]: <= ENTER
          Por favor especifique o usuário do portal iSCSI: <= ENTER
          Por favor especifique o nome de destino (iqn.2017-03.com.juntotelecom:tgt) [iqn.2017-03.com.juntotelecom:tgt]: <= ENTER
[ INFO  ] Discovering iSCSI node
[ INFO  ] Connecting to the storage server
          Os seguintes luns foram encontrados no destino solicitado:
                [1]     3600140542ea0a481f5d4fe9bf1995bb7       60GiB   LIO-ORG ovirt
                        status: free, caminhos: 1 ativos
 
                [2]     36001405be72117eefd14b5d8f291adab       340GiB  LIO-ORG vms
                        status: free, caminhos: 1 ativos
 
          Selecione a LUN de destino (1, 2) [1]: <= ENTER
--== CONFIGURAÇÃO DA REDE ==--
 
          iptables foi detectado no seu computador, você deseja que o setup configure-o? (Sim, Não)[Sim]: 
          Por favor indique um endereço IP pingável do gateway [192.168.120.1]: 
          Por favor indique um NIC para definir ovirtmgmt bridge em: (bond0, enp10s0f1, enp9s0f1, enp9s0f0, enp5s0f1, enp5s0f0) [bond0]: <= ENTER
--== CONFIGURAÇÃO DA VM ==--
 
          Iniciando a partir de uma imagem ISO baseada em RHEL7, como cdrom passthrough está desativado (BZ760885)
          Por favor especifique o dispositivo para inicializar VM a partir de (escolher o disco para a appliance do ovirt engine)
          (cdrom, disk, pxe) [disk]: cdrom
          Por favor especifique o tipo de console que você gostaria de usar para se conectar à VM (vnc, spice) [vnc]: 
          Os seguintes tipos de CPU são suportados por este host:
                 - model_Nehalem: Intel Nehalem Family
                 - model_Penryn: Intel Penryn Family
                 - model_Conroe: Intel Conroe Family
          Por favor especifique o tipo de CPU a ser usado pela VM [model_Nehalem]: 
          Por favor especifique o número de CPUs virtuais para a VM (Padrão pararequerimento mínimo): [2]: 
          Por favor especifique o tamanho do disco da VM em GB (Padrão para o requisito mínimo é): [25]: 60
[WARNING] Not enough free space, about 55 GiB will be available within the storage domain (required 60 GiB)
          Por favor especifique o tamanho do disco da VM em GB (Padrão para o requisito mínimo é): [25]: 55
          Você pode especificar um endereço MAC unicast para a VM ou aceitar um padrão gerado aleatoriamente [00:16:3e:21:f4:2a]: 
          Por favor especifique o tamanho da memória da VM em MB (Padrões para requerimento mínimo): [4096]: 
          Por favor especifique o caminho para a mídia installation que você gostaria de usar [None]: /var/tmp/CentOS-7-x86_64-Minimal-1611.iso
--== CONFIGURAÇÃO DO HOSTED ENGINE ==--
 
          Enter engine admin password: 
          Confirm engine admin password: 
          Digite o nome que será utilizado para identificar este host dentro do Portal do Administrador [hosted_engine_1]: vm-mba-01
          Por favor forneça o FQDN para o engine que você gostaria de usar.
          Isso precisa coincidir com o FQDN que você vai usar para a instalação do engine dentro da VM.
          Nota: Este será o FQDN da VM que você está criando agora,
          não deve apontar para o host de base ou para qualquer outra maquina existente .
          Engine FQDN:  []: ovirt.juntotelecom.com.br
--== PREVIEW DA CONFIGURAÇÃO ==--
 
          Interface Bridge                   : bond0
          FQDN do Engine                     : ovirt.juntotelecom.com.br
          Nome da Bridge                     : ovirtmgmt
          Endereço do Host                  : vm-mba-01
          Porta do daemon SSH                : 22
          Gerenciador de Firewall            : iptables
          Endereço do Gateway               : 192.168.120.1
          Nome do Host para aplicação web  : vm-mba-01
          Storage Domain type                : iscsi
          ID do Host                         : 1
          LUN ID                             : 3600140542ea0a481f5d4fe9bf1995bb7
          Tamanho da Imagem em GB            : 55
          Endereço IP do Portal iSCSI       : 127.0.0.1
          Nome do alvo iSCSI                 : iqn.2017-03.com.juntotelecom:tgt
          Porta do Portal iSCSI              : 3260
          Usuário do Portal iSCSI           : 
          Tipo de console                    : vnc
          Tamanho da memória em MB          : 4096
          Endereço MAC                      : 00:16:3e:21:f4:2a
          Tipo de Boot                       : cdrom
          Número de CPUs                    : 2
          Imagem ISO (cdrom boot/cloud-init) : /var/tmp/CentOS-7-x86_64-Minimal-1611.iso
          Tipo de CPU                        : model_Nehalem
[ INFO  ] Etapa: Fechando
[ INFO  ] Criando VM
          You can now connect to the VM with the following command:
                hosted-engine --console
          You can also graphically connect to the VM from your system with the following command:
                remote-viewer vnc://vm-mba-01:5900
          Use temporary password "3402ykhu" to connect to vnc console.
          Please ensure that your Guest OS is properly configured to support serial console according to your distro documentation.
          Follow http://www.ovirt.org/Serial_Console_Setup#I_need_to_access_the_console_the_old_way for more info.
          Se você necessitar reinicar a VM, você necessitará inicia-la manualmente usando o comando:
          hosted-engine --vm-start
          Você pode então definir uma senha temporária usando o comando:
          hosted-engine --add-console-password
 
 
          A VM foi iniciada.
          Para continuar por favor instale o Sistema Operacional e desligue ou reinicie a VM.
 
          Faça uma seleção das opções a seguir:
          (1) Continuar setup - Instalação do sistema operacional está completa
          (2) Abortar setup
          (3) Desligar e reiniciar a VM
          (4) Destruir a VM e abortar o setup
 
          (1, 2, 3, 4)[1]: 

Fazer acesso vnc e fazer a instalação da vm para continuar.

Por favor reinicie ou desligue a VM. 
 
          Verificando o desligamento...
[ INFO  ] Criando VM
          You can now connect to the VM with the following command:
                hosted-engine --console
          You can also graphically connect to the VM from your system with the following command:
                remote-viewer vnc://vm-mba-01:5900
          Use temporary password "3402ykhu" to connect to vnc console.
          Please ensure that your Guest OS is properly configured to support serial console according to your distro documentation.
          Follow http://www.ovirt.org/Serial_Console_Setup#I_need_to_access_the_console_the_old_way for more info.
          Se você necessitar reinicar a VM, você necessitará inicia-la manualmente usando o comando:
          hosted-engine --vm-start
          Você pode então definir uma senha temporária usando o comando:
          hosted-engine --add-console-password
          Por favor instale e configure o engine na VM.
          Você pode também estar interessado em instalar pacote ovirt-guest-agent-common na VM.
 
 
          A VM foi reiniciada.
          Para continuar, por favor instale oVirt-Engine na VM
          (Acesse http://www.ovirt.org/Quick_Start_Guide para maiores informações).
 
          Faça uma seleção das opções a seguir:
          (1) Continuar setup - A instalação do oVirt-Engine está pronta e serviço ovirt-engine está ativo
          (2) Abortar setup
          (3) Desligar e reiniciar a VM
          (4) Destruir a VM e abortar o setup

Agora passamos para a máquina virtual

[root@ovirt ~]# yum install nfs-utils
[root@ovirt ~]# mkdir /var/nfs-ovirt-iso-share/files
[root@ovirt ~]# chown 36:36 /var/nfs-ovirt-iso-share/files
[root@ovirt ~]# chmod -R 755 /var/nfs-ovirt-iso-share/files
[root@ovirt ~]# systemctl start rpcbind
[root@ovirt ~]# systemctl start nfs-server
[root@ovirt ~]# systemctl enable rpcbind
[root@ovirt ~]# systemctl enable nfs-server
[root@ovirt ~]# firewall-cmd --permanent --zone=public --add-service=nfs
[root@ovirt ~]# firewall-cmd --permanent --zone=public --add-service=mountd
[root@ovirt ~]# firewall-cmd --permanent --zone=public --add-service=rpc-bind
[root@ovirt ~]# firewall-cmd --reload
[root@ovirt ~]# yum install http://resources.ovirt.org/pub/yum-repo/ovirt-release40.rpm
[root@ovirt ~]# yum install ovirt-engine
[root@ovirt ~]# engine-setup 
[ INFO  ] Etapa: Inicializando
[ INFO  ] Etapa: Configuração de ambiente
          Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging-jboss.conf', '/etc/ovirt-engine-setup.conf.d/10-packaging.conf']
          Arquivo de log: /var/log/ovirt-engine/setup/ovirt-engine-setup-20170328165317-tth7y0.log
          Versão: otopi-1.5.2 (otopi-1.5.2-1.el7.centos)
[ INFO  ] Etapa: Configuração dos pacotes de ambiente
[ INFO  ] Yum Baixando: base/7/x86_64 (0%)
[ INFO  ] Etapa: Detecção de programas
[ INFO  ] Etapa: Configuração de ambiente
[ INFO  ] Etapa: Personalização do ambiente
 
          --== PRODUCT OPTIONS ==--
 
          Configure Engine on this host (Yes, No) [Yes]: 
          Configure Image I/O Proxy on this host? (Yes, No) [Yes]: 
          Configure WebSocket Proxy on this host (Yes, No) [Yes]: 
          Please note: Data Warehouse is required for the engine. If you choose to not configure it on this host, you have to configure it on a remote host, and then configure the engine on this host so that it can access the database of the remote Data Warehouse host.
          Configure Data Warehouse on this host (Yes, No) [Yes]: 
          Configure VM Console Proxy on this host (Yes, No) [Yes]:
--== NETWORK CONFIGURATION ==--
 
          Host fully qualified DNS name of this server [ovirt]: ovirt.juntotelecom.com.br
          Setup can automatically configure the firewall on this system.
          Note: automatic configuration of the firewall may overwrite current settings.
          Do you want Setup to configure the firewall? (Yes, No) [Yes]: 
[ INFO  ] firewalld will be configured as firewall manager.
--== DATABASE CONFIGURATION ==--
 
          Where is the DWH database located? (Local, Remote) [Local]: 
          Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications.
          Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]: 
          Where is the Engine database located? (Local, Remote) [Local]: 
          Setup can configure the local postgresql server automatically for the engine to run. This may conflict with existing applications.
          Would you like Setup to automatically configure postgresql and create Engine database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
--== OVIRT ENGINE CONFIGURATION ==--
 
          Engine admin password: 
          Confirm engine admin password: 
          Application mode (Virt, Gluster, Both) [Both]: 
 
          --== STORAGE CONFIGURATION ==--
 
          Default SAN wipe after delete (Yes, No) [No]:
--== PKI CONFIGURATION ==--
 
          Organization name for certificate [juntotelecom.com.br]: 
 
          --== APACHE CONFIGURATION ==--
 
          Setup can configure the default page of the web server to present the application home page. This may conflict with existing applications.
          Do you wish to set the application as the default page of the web server? (Yes, No) [Yes]: 
          Setup can configure apache to use SSL using a certificate issued from the internal CA.
          Do you wish Setup to configure that, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
--== SYSTEM CONFIGURATION ==--
 
          Configure an NFS share on this server to be used as an ISO Domain? (Yes, No) [No]: yes
          Local ISO domain path [/var/lib/exports/iso]: /var/nfs-ovirt-iso-share/files
 
          Please provide the ACL for the Local ISO domain.
          See the exports(5) manpage for the format.
          Examples:
          - To allow access for host1, host2 and host3, input: host1(rw) host2(rw) host3(rw)
          - To allow access to the entire Internet, input: *(rw)
 
          For more information, see: http://www.ovirt.org/Troubleshooting_NFS_Storage_Issues
 
          Local ISO domain ACL: 192.168.120.0/25 (rw)
          Local ISO domain name [ISO_DOMAIN]:
--== MISC CONFIGURATION ==--
 
          Please choose Data Warehouse sampling scale:
          (1) Basic
          (2) Full
          (1, 2)[1]:
--== CONFIGURATION PREVIEW ==--
 
          Application mode                        : both
          Default SAN wipe after delete           : False
          Firewall manager                        : firewalld
          Update Firewall                         : True
          Host FQDN                               : ovirt.juntotelecom.com.br
          Engine database secured connection      : False
          Engine database host                    : localhost
          Engine database user name               : engine
          Engine database name                    : engine
          Engine database port                    : 5432
          Engine database host name validation    : False
          DWH database secured connection         : False
          DWH database host                       : localhost
          DWH database user name                  : ovirt_engine_history
          DWH database name                       : ovirt_engine_history
          DWH database port                       : 5432
          DWH database host name validation       : False
          Engine installation                     : True
          NFS setup                               : True
          PKI organization                        : juntotelecom.com.br
          NFS export ACL                          : 192.168.120.0/25 (rw)
          NFS mount point                         : /var/nfs-ovirt-iso-share/files
          Configure local Engine database         : True
          Set application as default page         : True
          Configure Apache SSL                    : True
          DWH installation                        : True
          Configure local DWH database            : True
          Engine Host FQDN                        : ovirt.juntotelecom.com.br
          Configure Image I/O Proxy               : True
          Configure VMConsole Proxy               : True
          Configure WebSocket Proxy               : True
 
          Please confirm installation settings (OK, Cancel) [OK]:
--== SUMMARY ==--
 
[ INFO  ] Restarting httpd
          Please use the user 'admin@internal' and password specified in order to login
          Web access is enabled at:
              http://ovirt.juntotelecom.com.br:80/ovirt-engine
              https://ovirt.juntotelecom.com.br:443/ovirt-engine
          Internal CA F3:A7:C4:F6:43:F2:22:33:7A:C0:55:27:F6:D8:17:AB:7A:75:5A:A4
          SSH fingerprint: 85:a5:95:e3:0c:9f:5d:39:f6:1d:f2:36:b5:b4:d5:ce
[WARNING] Less than 16384MB of memory is available
 
          --== END OF SUMMARY ==--
 
[ INFO  ] Etapa: Limpando
          Log file is located at /var/log/ovirt-engine/setup/ovirt-engine-setup-20170328165317-tth7y0.log
[ INFO  ] Generating answer file '/var/lib/ovirt-engine/setup/answers/20170328170605-setup.conf'
[ INFO  ] Etapa: Pré-conclusão
[ INFO  ] Etapa: Conclusão
[ INFO  ] Execution of setup completed successfully

Agora voltamos para Hosted Engine

(1, 2, 3, 4)[1]: 
 
          Verificando status para o oVirt-Engine em ovirt.juntotelecom.com.br...
[ INFO  ] Engine respondeu: DB Up!Welcome to Health Status!
[ INFO  ] Acquiring internal CA cert from the engine
[ INFO  ] The following CA certificate is going to be used, please immediately interrupt if not correct:
[ INFO  ] Issuer: C=US, O=juntotelecom.com.br, CN=ovirt.juntotelecom.com.br.93405, Subject: C=US, O=juntotelecom.com.br, CN=ovirt.juntotelecom.com.br.93405, Fingerprint (SHA-1): F3A7C4F643F222337AC05527F6D817AB7A755AA4
[ INFO  ] Conectando à appliance do engine-setup
[ INFO  ] Esperando o host tornar-se operacional no engine. Isso pode demorar alguns minutos...
[ INFO  ] Ainda aguardando pelo host VDSM tornar-se operacional...
[ INFO  ] O Host VDSM agora está operacional
[ INFO  ] Salvando a configuração do hosted-engine no domínio do armazenamento compartilhado
          Por favor desligue a VM para permitir que o sistema lance-o como um serviço monitorado.
          O sistema irá esperar até que a VM esteja desligada.
[ INFO  ] Habilitando e iniciando os serviços HA
[ INFO  ] Etapa: Limpando
[ INFO  ] Gerando arquivo resposta '/var/lib/ovirt-hosted-engine-setup/answers/answers-20170328171056.conf'
[ INFO  ] Gerando arquivo resposta '/etc/ovirt-hosted-engine/answers.conf'
[ INFO  ] Etapa: Pré-conclusão
[ INFO  ] Etapa: Conclusão
[ INFO  ] Hosted Engine successfully deployed