Mostrando postagens com marcador ODA. Mostrar todas as postagens
Mostrando postagens com marcador ODA. Mostrar todas as postagens

quarta-feira, 12 de junho de 2024

[ORACLE] Cleanup Repository Area - Oracle Database Appliance (ODA)



Hello everyone.

How are you doing?

Today, I'll share with you a simple tip about ODA.

When I need to clean the repository area, I use these steps:

But always remember:  

  • This step-by-step worked for me, but it may not work for you.
  • It's a test environment. The real life will be different, for sure.
  • This post is for study and testing as well and has no concern for performance and security best practices.

1) List your dbhomes.

# odacli list-dbhomes



2) Check the directory size (/opt).

df -h
Filesystem                          Size  Used Avail Use% Mounted on
devtmpfs                            189G  176K  189G   1% /dev
tmpfs                               189G  845M  188G   1% /dev/shm
tmpfs                               189G  4.1G  185G   3% /run
tmpfs                               189G     0  189G   0% /sys/fs/cgroup
/dev/mapper/VolGroupSys-LogVolRoot   30G  9.6G   19G  35% /
/dev/md0                            476M  123M  329M  28% /boot
/dev/sda1                           500M  8.6M  492M   2% /boot/efi

/dev/mapper/VolGroupSys-LogVolOpt    59G   45G   11G  81% /opt

/dev/mapper/VolGroupSys-LogVolU01    99G   47G   47G  51% /u01
/dev/asm/datprds-31                 370G  291G   80G  79% /u02/app/oracle/oradata/prd
/dev/asm/commonstore-31             5.0G  631M  4.4G  13% /opt/oracle/dcs/commonstore
/dev/asm/datprodp-31                2.2T  1.6T  673G  70% /u02/app/oracle/oradata/mcg
/dev/asm/redo-365                   236G  184G   53G  78% /u04/app/oracle/redo
/dev/asm/reco-8                     1.8T  865G  936G  49% /u03/app/oracle
/dev/asm/datprodmv-31                17T   17T   16G 100% /u02/app/oracle/oradata/prodmvx7hmcg
tmpfs                                38G     0   38G   0% /run/user/54325
tmpfs                                38G     0   38G   0% /run/user/1000
tmpfs                                38G     0   38G   0% /run/user/0


3) Check the repository area.

cd /opt/oracle/oak/pkgrepos

ll -lrht orapkgs/clones/
total 9.0G
-rw-r--r-- 1 root root 2.9G Jan 15  2021 db112.210119.tar.gz
-rw-r--r-- 1 root root 6.1G Feb  8  2021 grid19.tar.gz
-rw-r--r-- 1 root root  11K Feb 12  2021 clonemetadata.xml

du -sh *
38M     asr
16G     db
44M     dcsadmin
609M    dcsagent
46M     dcscli
175M    dcscontroller
32M     firmwarecontroller
48M     firmwaredisk
12M     firmwareexpander
8.6M    hmp
216M    ilom
238M    java
981M    mysql
79M     oak
585M    opatch
9.7G    orapkgs
527M    os
91M     oss
3.4M    System
302M    thirdpartypkgs
8.4M    zookeeper

4) Cleanup the repo area

# odacli cleanup-patchrepo -cl
# odacli describe-job -i "5793e96c-159e-46cc-999e-938e339e8773"



5) Check the directory size (/opt).

df -h

Filesystem                          Size  Used Avail Use% Mounted on
devtmpfs                            189G  176K  189G   1% /dev
tmpfs                               189G  845M  188G   1% /dev/shm
tmpfs                               189G  4.1G  185G   3% /run
tmpfs                               189G     0  189G   0% /sys/fs/cgroup
/dev/mapper/VolGroupSys-LogVolRoot   30G  9.6G   19G  35% /
/dev/md0                            476M  123M  329M  28% /boot
/dev/sda1                           500M  8.6M  492M   2% /boot/efi

/dev/mapper/VolGroupSys-LogVolOpt    59G   39G   18G  70% /opt

/dev/mapper/VolGroupSys-LogVolU01    99G   47G   47G  51% /u01
/dev/asm/datprds-31                 370G  291G   80G  79% /u02/app/oracle/oradata/prd
/dev/asm/commonstore-31             5.0G  631M  4.4G  13% /opt/oracle/dcs/commonstore
/dev/asm/datprodp-31                2.2T  1.6T  673G  70% /u02/app/oracle/oradata/mcg
/dev/asm/datprodp-31                2.2T  1.6T  673G  70% /u02/app/oracle/oradata/mcg
/dev/asm/redo-365                   236G  184G   53G  78% /u04/app/oracle/redo
/dev/asm/reco-8                     1.8T  866G  935G  49% /u03/app/oracle
/dev/asm/datprodmv-31                17T   17T   16G 100% /u02/app/oracle/oradata/prodmvx7hmcg
tmpfs                                38G     0   38G   0% /run/user/54325
tmpfs                                38G     0   38G   0% /run/user/1000
tmpfs                                38G     0   38G   0% /run/user/0

6) Check the repository area.

cd /opt/oracle/oak/pkgrepos

ll -lrht orapkgs/clones
total 2.9G
-rw-r--r-- 1 root root 2.9G Jan 15  2021 db112.210119.tar.gz
-rw-r--r-- 1 root root  11K Feb 12  2021 clonemetadata.xml

du -sh *
38M     asr
16G     db
44M     dcsadmin
609M    dcsagent
46M     dcscli
175M    dcscontroller
32M     firmwarecontroller
48M     firmwaredisk
12M     firmwareexpander
8.6M    hmp
216M    ilom
238M    java
981M    mysql
79M     oak
585M    opatch
3.6G    orapkgs
527M    os
91M     oss
3.4M    System
302M    thirdpartypkgs
8.4M    zookeeper

That's it. As simple as that.

I hope that this tip help you.

Regards
Mario

sexta-feira, 14 de outubro de 2016

Conhecendo o mundo do tal do ODA - purgeODALog Tool

Olá pessoal.

Quem trabalha com o Oracle Database Appliance (ODA) já deve ter reparado como são gerados muitos arquivos de log, trace, etc.

É uma enormidade mesmo. E como na configuração do ODA o "/u01" vem com um tamanho relativamente pequeno, várias vezes chegamos a ter uma ocupação alta dessa área.

Mesmo configurando o ADRCI para fazer o purge dos arquivos de alert, trace, etc ainda temos vários outros tipos de arquivos gerados e que vão ficando por lá consumindo muito espaço. 

Para resolver isso, apesar de muitos DBA's não conhecerem, a Oracle oferece um script de limpeza muito simples de ser usado. 

Mas cuidado, como tudo tem seu lado negro da força, se errar na passagem de parâmetros você pode gerar sérios probemas já que o script é executado como root e ele limpa mesmo, sem piedade.

Informações detalhadas desse script vocês acham em "ODA (Oracle Database Appliance): Cleanup trace and log files Using purgeODALog Tool (Doc ID 2081655.1)".

Repare na mensagem muito importante do note:


AHAHHAH, ou seja, use por sua conta e risco e com muito cuidado.

Abaixo, vou mostrar um exemplo que uso esse script.

Primeiro é claro, faça o download do script no note acima. Eu salvo esse script no home do root, mas escolha onde achar melhor.

O uso pode ser individual ou com várias opções combinadas.

Usage:
purgeODALog
    [ -orcl ] | 
 [ -tfa ]  |
    [ -osw ]  | 
 [ -oak ]  |
    [ -extra '    ': | [, '     ':] ]
    [ -lsnr ]
    [ -dryrun ]
OPTIONS:
-orcl             Purge only GI/RDBMS logs & traces (Default 30 days)
-tfa               Purge only TFA repository older then # days (Default 30 days)
-osw             Purge only OSW archives older then # days (Default 30 days)
-oak              Purge only OAK logs and trace older then # days (Default 30 days)
-extra '':        Purge only files in user specified folders (Default 30 days)
-lsnr              It will force the cleanup of listeners log independently by the age
-dryrun         It will show the purge commands w/o execute them
-h                 Display this help and exit

Eu costumo usar assim, em alguns de meus ambientes:
1) Lista o que vai ser excluído, sem é claro efetuar a limpeza.
./purgeODALog -orcl 15 -tfa 15 -osw 15 -oak 15 -lsnr -dryrun 

2) Efetua a limpeza
./purgeODALog -orcl 15 -tfa 15 -osw 15 -oak 15 -lsnr

O final do log gerado é esse:
...
2016-10-13 09:58:45: I ... purging ALERT older than 15 days
2016-10-13 09:58:45: I ... purging INCIDENT older than 15 days
2016-10-13 09:58:45: I ... purging TRACE older than 15 days
2016-10-13 09:58:45: I ... purging CDUMP older than 15 days
2016-10-13 09:58:45: I ... purging HM older than 15 days
2016-10-13 09:58:45: I Purging TFA archives older then 15 days
2016-10-13 09:58:48: I Purging OSW archives older then 15 days
2016-10-13 09:58:48: I Purging OAK logs older then 15 days
2016-10-13 09:58:48: S Purging completed succesfully!

Veja o antes e depois do diretório onde a limpeza aconteceu:
-- Antes
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroupSys-LogVolU01
  97G   79G   14G  86% /u01
-- Depois
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroupSys-LogVolU01
  97G   63G   30G  68% /u01

Deixei separado aqui para mostrar a opção "extra". Ela é muito interessante, mas como disse acima devemos tomar muito cuidado.

Digamos que temos a pasta "/tmp/exemplo" e lá temos alguns arquivos e mais um outro diretório chamado "outrapasta".
[srv1 exemplo]$ su -

[srv1 exemplo]$ cd /tmp/exemplo

[srv1 exemplo]$ pwd
/tmp/exemplo

[srv1 exemplo]$ ls -lrht
-rw-r--r-- 1 oracle oinstall 0 Sep 14 10:16 z.txt
-rw-r--r-- 1 oracle oinstall 0 Sep 14 10:16 x.txt
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:16 y.txt
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:16 zzz.dmp
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 www.dmp
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 aaa.log
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:19 outrapasta
-rw-r--r-- 1 oracle oinstall 0 Sep 14 10:17 bbb.log
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 aaa.log
Vou passar para o script os parâmetros para:
1) Limpar "/tmp/exemplo" e deixar apenas arquivos com menos de 10 dias.
2) Limpar "/tmp/exemplo/outrapasta" e deixar apenas arquivos com menos de 20 dias.
Agora é só executar:
./purgeODALog -extra '/tmp/exemplo':10, '/tmp/exemplo/outrapasta':20

[srv1 exemplo]$ ls -lrht
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:16 y.txt
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:16 zzz.dmp
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 www.dmp
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 aaa.log
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:19 outrapasta
-rw-r--r-- 1 oracle oinstall 0 Oct 14 10:17 aaa.log

Repare que só restaram os arquivos de Outubro, ou seja, os que tem menos do que 10 e 20 dias respectivamente.

E claro, você pode agendar essas limpezas no crontab para automatizar o processo.

É isso pessoal, espero que ajude.

Abraço
Mario

quinta-feira, 2 de junho de 2016

Conhecendo o mundo do tal do ODA - Criando um database

Olá jovens.

Vamos direto ao ponto hoje, vamos criar uma nova base de dados no ODA X5. Assim, simples e rápido...

Vamos lá.

Então começamos preparando nosso script de criação da base: 
CREATE DATABASE TESTE...

Opa!!! Para!!! Para!!! Para!!! Para!!! 

Tipo João Kleber manja ahahahhaha... O que é isso pequeno gafanhoto, não precisamos de nada disso não.  

Mais uma vez nosso amigo OAKCLI vai nos ajudar. Vamos lá, agora é sério...

Primeiro vamos gerar um arquivo com algumas configurações. Esse não é um passo obrigatório, mas pode ser que o template do ODA não sirva para o que você quer então acho legal fazer isso.

1) Conecta como root
su - 
2) Manda o comando abaixo:
[root@odax51 ~]# oakcli create db_config_params -conf rsfile

Agora é só responder as perguntas. Eu vou colocar todo o log aqui para vocês verem. Vai ficar um pouco grande mas acho que vale a pena.
Please select one of the following for Database Block Size  [1 .. 4]:
1    => 4096
2    => 8192
3    => 16384
4    => 32768
2
Selected value is : 8192

Specify the  Database Language (1. AMERICAN 2. Others) [1]:2
Please select one of the following for Database Language    [0 .. 10] :
0    => Others
1    => ALBANIAN
2    => AMERICAN
3    => VIETNAMESE
4    => ARABIC
5    => ASSAMESE
6    => AZERBAIJANI
7    => BANGLA
8    => BELARUSIAN
9    => BRAZILIAN PORTUGUESE
10    => BULGARIAN
2
Selected value is: AMERICAN

Specify the  Database Characterset (1. AL32UTF8 2. Others) [1]:
2
Please select one of the following for Database Characterset    [0 .. 10] :
0    => Others
1    => AL32UTF8
2    => AR8ADOS710
3    => AR8ADOS720
4    => AR8APTEC715
5    => AR8APTEC715T
6    => AR8ARABICMACS
7    => AR8ASMO8X
8    => AR8HPARABIC8T
9    => AR8ISO8859P6
10    => AR8MSWIN1256
0

Please select one of the following for Database Characterset    [0 .. 21] :
11    => AR8MUSSAD768
12    => AR8MUSSAD768T
13    => AR8NAFITHA711
14    => AR8NAFITHA711T
15    => AR8NAFITHA721
16    => AR8NAFITHA721T
17    => AR8SAKHR706
18    => AR8SAKHR707
19    => AR8SAKHR707T
20    => AZ8ISO8859P9E
21    => BG8MSWIN
0

Please select one of the following for Database Characterset    [0 .. 32] :
22    => BG8PC437S
23    => BLT8CP921
24    => BLT8ISO8859P13
25    => BLT8MSWIN1257
26    => BLT8PC775
27    => BN8BSCII
28    => CDN8PC863
29    => CEL8ISO8859P14
30    => CL8ISO8859P5
31    => CL8ISOIR111
32    => CL8KOI8R
0

Please select one of the following for Database Characterset    [0 .. 43] :
33    => CL8KOI8U
34    => CL8MACCYRILLICS
35    => CL8MSWIN1251
36    => EE8ISO8859P2
37    => EE8MACCES
38    => EE8MACCROATIANS
39    => EE8MSWIN1250
40    => EE8PC852
41    => EL8DEC
42    => EL8ISO8859P7
43    => EL8MACGREEKS
0

Please select one of the following for Database Characterset    [0 .. 54] :
44    => EL8MSWIN1253
45    => EL8PC437S
46    => EL8PC851
47    => EL8PC869
48    => ET8MSWIN923
49    => HU8ABMOD
50    => HU8CWI2
51    => IN8ISCII
52    => IS8PC861
53    => IW8ISO8859P8
54    => IW8MACHEBREWS
0

Please select one of the following for Database Characterset    [0 .. 65] :
55    => IW8MSWIN1255
56    => IW8PC1507
57    => JA16EUC
58    => JA16EUCTILDE
59    => JA16SJIS
60    => JA16SJISTILDE
61    => JA16VMS
62    => KO16KSC5601
63    => KO16KSCCS
64    => KO16MSWIN949
65    => LA8ISO6937
0

Please select one of the following for Database Characterset    [0 .. 76] :
66    => LA8PASSPORT
67    => LT8MSWIN921
68    => LT8PC772
69    => LT8PC774
70    => LV8PC1117
71    => LV8PC8LR
72    => LV8RST104090
73    => N8PC865
74    => NE8ISO8859P10
75    => NEE8ISO8859P4
76    => RU8BESTA
0

Please select one of the following for Database Characterset    [0 .. 87] :
77    => RU8PC855
78    => RU8PC866
79    => SE8ISO8859P3
80    => TH8MACTHAIS
81    => TH8TISASCII
82    => TR8DEC
83    => TR8MACTURKISHS
84    => TR8MSWIN1254
85    => TR8PC857
86    => US8PC437
87    => UTF8
0

Please select one of the following for Database Characterset    [0 .. 98] :
88    => VN8MSWIN1258
89    => VN8VN3
90    => WE8DEC
91    => WE8DG
92    => WE8ISO8859P1
93    => WE8ISO8859P15
94    => WE8ISO8859P9
95    => WE8MACROMAN8S
96    => WE8MSWIN1252
97    => WE8NCR4970
98    => WE8NEXTSTEP
92
Selected value is: WE8ISO8859P1

Specify the  Database Territory (1. AMERICA 2. Others) [1]:
2
Please select one of the following for Database Territory    [0 .. 10] :
0    => Others
1    => ALBANIA
2    => ALGERIA
3    => AMERICA
4    => ARGENTINA
5    => AUSTRALIA
6    => AUSTRIA
7    => AZERBAIJAN
8    => BAHRAIN
9    => BANGLADESH
10    => BELARUS
3
Selected value is: AMERICA

Specify the  Component Language (1. en 2. Others) [1]:
2
Please select one of the following for Component Language    [0 .. 10] :
0    => Others
1    => en : Engilish
2    => fr : French
3    => ar : Arabic
4    => bn : Bengali
5    => pt_BR : Brazilian Portuguese
6    => bg : Bulgarian
7    => fr_CA : Canadian French
8    => ca : Catalan
9    => hr : Croatian
10    => cs : Czech
1
Selected value is: en
Please select one of the following for NLS Characterset  [1 .. 2]:
1    => AL16UTF16
2    => UTF8
1
Selected value is : AL16UTF16

Successfully generated the Database parameter file 'rsfile'

3) Vamos verificar o que acabamos de gerar
oakcli show db_config_params
Available DB configuration files are:
default ==> Olha aqui o default do ODA
rsfile ==> O que acabamos de criar

oakcli show db_config_params -conf rsfile -detail
DATABASE_BLOCK_SIZE       =>    8192
DATABASE_LANGUAGE         =>    AMERICAN
DATABASE_CHARACTERSET     =>    WE8ISO8859P1
DATABASE_TERRITORY        =>    AMERICA
COMPONENT_LANGUAGES       =>    en
NLS_NCHAR_CHARACTERSET    =>    AL16UTF16

4) Veja os ORACLE_HOMES disponíveis. Você vai precisar. 
[root@odax51 ~]# oakcli show dbhomes








5) Então pequeno amigo, agora é só ter o trabalho de olhar o ODA trabalhar

oakcli create database -db teste -oh OraDb11204_home1 -params rsfile 
Please enter the 'SYSASM'  password : (During deployment we set the SYSASM password to 'welcome1'):
Please re-enter the 'SYSASM' password:
Please select one of the following for Database type  [1 .. 2]:
1    => OLTP
2    => DSS
1
Selected value is : OLTP
Please select one of the following for Database Deployment  [1 .. 3]:
1    => EE : Enterprise Edition
2    => RACONE
3    => RAC
3
Selected value is : RAC
Please select one of the following for Database Class  [1 .. 5]:
1    => odb-01s  (   1 cores ,     4 GB memory)
2    =>  odb-01  (   1 cores ,     8 GB memory)
3    =>  odb-02  (   2 cores ,    16 GB memory)
4    =>  odb-04  (   4 cores ,    32 GB memory)
5    =>  odb-06  (   6 cores ,    48 GB memory)
2
Selected value is : odb-01  (   1 cores ,     8 GB memory)

Do you want to setup the EM DB Console for this database [ Y | N ] ? : N

Agora basta seguirmos o log
INFO   : Logging all actions in the file /opt/oracle/oak/log/hscodax41/patch/12.1.2.6.0/hscodax41-20160517105858.log and traces in  the file /opt/oracle/oak/log/hscodax41/patch/12.1.2.6.0/hscodax41-20160517105858.trc
INFO   : Loading the configuration file /opt/oracle/oak/onecmd/create_database.params...
INFO   : Creating the node list files...
INFO   : Setting up ssh for root...
INFO   : Setting up SSH across the Private Network...
...
INFO   : Running as root: /usr/bin/ssh -l root 192.168.16.24 /root/DoAllcmds.sh
INFO   : Running as root: /usr/bin/ssh -l root 192.168.16.25 /root/DoAllcmds.sh
INFO   : Background process 76404 (node: 192.168.16.24) gets done with the exit code 0
INFO   : Background process 76430 (node: 192.168.16.25) gets done with the exit code 0
INFO   : Setting up SSH completed successfully
INFO   : Running the command /usr/bin/rsync -tarqvz /opt/oracle/oak/onecmd/ root@192.168.16.25:/opt/oracle/oak/onecmd --exclude=*zip --exclude=*gz --exclude=*log --exclude=*trc --exclude=*rpm to sync directory
on node <192 .168.16.25="">
SUCCESS: Ran /usr/bin/rsync -tarqvz /opt/oracle/oak/onecmd/ root@192.168.16.25:/opt/oracle/oak/onecmd --exclude=*zip --exclude=*gz --exclude=*log --exclude=*trc --exclude=*rpm and it returned: RC=0
...INFO   : Did not do scp for node : hscodax41
INFO   : Running as root: /usr/bin/ssh -l root hscodax41 /root/DoAllcmds.sh
INFO   : Background process 77099 (node: hscodax41) gets done with the exit code 0
INFO   : Running as root: /usr/bin/ssh -l root hscodax42 /root/DoAllcmds.sh
INFO   : Background process 77126 (node: hscodax42) gets done with the exit code 0
INFO   : Did not do scp for node : hscodax41
INFO   : Running as root: /usr/bin/ssh -l root hscodax41 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517105939.sh
INFO   : Running as root: /usr/bin/ssh -l root hscodax42 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517105939.sh
INFO   : Background process 77181 (node: hscodax41) gets done with the exit code 0
INFO   : Background process 77207 (node: hscodax42) gets done with the exit code 0
INFO   : Setting up SSH for user oracle...
...
INFO   : checking nodes in /opt/oracle/oak/onecmd/tmp/db_nodes...
...
SUCCESS: All nodes in /opt/oracle/oak/onecmd/tmp/db_nodes are pingable and alive.
INFO   : Checking SSH setup for user (oracle) on nodes in /opt/oracle/oak/onecmd/tmp/db_nodes...
INFO   : Did not do scp for node : hscodax41
INFO   : This is root, will become oracle and run: /bin/su oracle -c /usr/bin/ssh -l oracle hscodax41 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517105958.sh
INFO   : Running on the local node: /bin/su oracle -c /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517105958.sh
INFO   : Background process 77766 (node: hscodax41) gets done with the exit code 0
INFO   : This is root, will become oracle and run: /bin/su oracle -c /usr/bin/ssh -l oracle hscodax42 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517105958.sh
INFO   : Background process 77792 (node: hscodax42) gets done with the exit code 0
INFO   : Setting up ACFS storage
INFO   : Did not do scp for node : hscodax41
INFO   : Running as root: /usr/bin/ssh -l root hscodax41 /opt/oracle/oak/onecmd/tmp/acfsm_72134.sh
INFO   : Running as root: /usr/bin/ssh -l root hscodax42 /opt/oracle/oak/onecmd/tmp/acfsm_72134.sh
INFO   : Background process 77986 (node: hscodax41) gets done with the exit code 0
INFO   : Background process 78012 (node: hscodax42) gets done with the exit code 0
INFO: 2016-05-17 11:00:14: Creating the volume datastore on the diskgroup REDO of size 52 G
INFO: 2016-05-17 11:00:24: Creating acfs on volume datastore
INFO: 2016-05-17 11:00:25: Registering datastore with clusterware
INFO: 2016-05-17 11:00:38: Creating the volume datastore on the diskgroup DATA of size 1625 G
INFO: 2016-05-17 11:00:53: Creating accelerator volume acldatstore
INFO: 2016-05-17 11:00:59: Creating acfs on volume datastore
INFO: 2016-05-17 11:01:44: Registering datastore with clusterware
INFO: 2016-05-17 11:02:09: Creating the volume datastore on the diskgroup RECO of size 374 G
INFO: 2016-05-17 11:02:21: Creating acfs on volume datastore
INFO: 2016-05-17 11:02:37: Registering datastore with clusterware
INFO: 2016-05-17 11:02:50: Successfully setup the storage structure for the database 'teste'
SUCCESS: Successfully setup ACFS storage for the database teste
INFO   : Creating Database using DBCA...
INFO   : Did not do scp for node : hscodax41
INFO   : Running as root: /usr/bin/ssh -l root hscodax41 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517110250.sh
INFO   : Running as root: /usr/bin/ssh -l root hscodax42 /opt/oracle/oak/onecmd/tmp/DoAllcmds-20160517110250.sh
INFO   : Background process 91175 (node: hscodax41) gets done with the exit code 0
INFO   : Background process 91201 (node: hscodax42) gets done with the exit code 0
INFO   : Running DBCA using /opt/oracle/oak/onecmd/tmp/dbca-teste.sh on hscodax41 as oracle...
INFO   : Check output in /opt/oracle/oak/onecmd/tmp/dbca-teste-20160517105858.log on hscodax41
INFO   : This is root, will become oracle and run: /bin/su oracle -c /usr/bin/ssh -l oracle hscodax41 /opt/oracle/oak/onecmd/tmp/dbca-teste.sh
INFO   : Running on the local node: /bin/su oracle -c /opt/oracle/oak/onecmd/tmp/dbca-teste.sh
Instance teste1 is running on node hscodax41
Instance teste2 is running on node hscodax42
INFO   : One or more Instances running on the cluster nodes.
INFO   : Running export ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/dbhome_1;/u01/app/oracle/product/11.2.0.4/dbhome_1/bin/srvctl setenv database -d teste -t 'TZ=America/Sao_Paulo' to set DB timezone
INFO   : Running the command /u01/app/12.1.0.2/grid/bin/crsctl stat resource ora.teste.db -p
.INFO   : Did not do scp for node : hscodax41
..
INFO   : This is root, will become oracle and run: /bin/su oracle -c /usr/bin/ssh -l oracle hscodax41 /opt/oracle/oak/onecmd/tmp/dbupdates-teste.sh
INFO   : Running on the local node: /bin/su oracle -c /opt/oracle/oak/onecmd/tmp/dbupdates-teste.sh
INFO   : Running export ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/dbhome_1;/u01/app/oracle/product/11.2.0.4/dbhome_1/bin/srvctl stop database -d teste
INFO   : Running export ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/dbhome_1;/u01/app/oracle/product/11.2.0.4/dbhome_1/bin/srvctl start database -d teste
INFO: 2016-05-17 11:12:25: Successfully set the RMAN SNAPSHOT control file

E se tudo correu bem, acabamos assim:
SUCCESS: 2016-05-17 11:12:26: Successfully created the Database : teste

Olha só que legal, ele já fez tudo, até registrar a nova base no RAC. É ou não é nosso amigo esse tal de OAKCLI ahahahha.

Ai claro, dá uma conferida lá né o preguiça:






Bom pessoal, espero que ajude. Dica simples mas bastante útil.

Abraço
Mario

Postagem em destaque

[ORACLE] Useful scripts for the day-to-day life of a DBA (Part 3) - System metrics

Hello everyone.   Hope you're doing well! As I said here , I've created a repository on GITHUB to share some scripts that I like t...